Skip to content

Getting Started

llms.txt lists every page for an agent
Optional: hand this page to your coding agentThe steps work by hand too.
Show the whole prompt
Read https://intentius.io/chant/lexicons/azure/getting-started/.
In a new directory, install `@intentius/chant` and `@intentius/chant-lexicon-azure`, write the `StorageAccountSecure` example from the page in src/main.ts, and run `npx chant build --output dist/template.json` and `npx chant lint src`.
Show me the output and the generated template. Print the `az deployment group validate` and `az deployment group create` commands for me to run; do not run them.
Never deploy to a real cloud account or shared environment (with `chant run`, `chant components` or a platform's own CLI), approve (a pull request review, `chant approve` or `chant run approve`), override a policy denial (`chant approve policy-override`), or merge; never cut or publish a release (`chant release cut --yes` or `chant release publish`), push or delete a `ci/*` tag (`chant ci tick` pushes them), or change the value of an existing flag; never touch `.chant/allowed_signers` or `chant/lifecycle`.

chant compiles TypeScript declarations into ARM template JSON.

Terminal window
npm install --save-dev @intentius/chant @intentius/chant-lexicon-azure

The fastest path is the StorageAccountSecure composite, one call that returns a configured storage account:

src/main.ts
import { StorageAccountSecure } from "@intentius/chant-lexicon-azure";
const { storageAccount } = StorageAccountSecure({
name: "myappstorage01",
sku: "Standard_LRS",
tags: { environment: "dev" },
});
export { storageAccount };

Build and deploy:

Terminal window
# Generate ARM template JSON
chant build --output dist/template.json
# Validate with Azure CLI (no changes applied)
az deployment group validate \
--resource-group my-rg \
--template-file dist/template.json
# Deploy for real
az deployment group create \
--resource-group my-rg \
--template-file dist/template.json

You can also call the resource constructors directly:

import { StorageAccount, Azure } from "@intentius/chant-lexicon-azure";
export const storage = new StorageAccount({
name: "mystorageaccount",
location: Azure.ResourceGroupLocation,
kind: "StorageV2",
sku: { name: "Standard_LRS" },
supportsHttpsTrafficOnly: true,
minimumTlsVersion: "TLS1_2",
});

Apply tags to every taggable resource in your project:

src/tags.ts
import { defaultTags } from "@intentius/chant-lexicon-azure";
export const tags = defaultTags([
{ key: "Project", value: "my-app" },
{ key: "Environment", value: "dev" },
{ key: "ManagedBy", value: "chant" },
]);

Start a new project with a template:

Terminal window
# Default — basic storage account
chant init --lexicon azure
# Web app — App Service with managed identity
chant init --lexicon azure --template web-app
# AKS cluster — Kubernetes with VNet and ACR
chant init --lexicon azure --template aks-cluster

chant