Repository navigation
Quickstart | CLI Reference | Documentation
Highlights
- Default control-plane API version
2026-11-01with 1-line fallback to2025-09-01-preview: Switches the defaultMicrosoft.ApiManagement/aigatewaysARMapi-versionto2026-11-01and adaptsmodel-provider,model,mcp(including re-fetchingETagafterlistSecretsbeforeIf-MatchPATCHwrites),telemetry-exporter, and inlinerequestRateLimit/costLimitpolicy wire shapes transparently. Standard 1-line fallback to2025-09-01-previewis supported viaexport AZURE_AIGATEWAY_API_VERSION=2025-09-01-preview,az config set aigateway.api_version=2025-09-01-preview, or per-command--api-version 2025-09-01-preview. - Content Safety policy CLI commands and flags disabled pending
2026-11-01alignment: Removes unsupported Content Safety policy setters and flags fromaz aigateway policyandaz aigateway model policywhile preserving unrecognized server-side policy entries unchanged during read-modify-write policy updates. - Multi-target
model-aliastable output:az aigateway model-alias list -o tableandaz aigateway model-alias show -o tablenow render one row per backend target (Name,Gateway,ModelName,Target,Priority,Weight) instead of truncating multi-backend pools to the first target. - Actionable
@fileJSON diagnostics and idempotent policy removal: Malformed@file.jsonarguments now report the file path, line, column, and JSON parse error directly instead of cascading into shorthand syntax errors, andaz aigateway [model] policy removewarns and skips no-opPATCHwrites when a requested policy type is not configured on the resource.
Canonical DX
# 1. Create a gateway and configure model policies against 2026-11-01 (default)
az aigateway create -g rg-ai -n gw-01 -l eastus2
az aigateway model policy set \
-g rg-ai \
--gateway-name gw-01 \
--provider-name foundry-eastus2 \
-n gpt-5-mini \
--token-limit 50000 --token-period minute \
--cost-limit 100.50 --cost-period month
# 2. Inspect multi-target alias priorities and weights in table view
az aigateway model-alias list -g rg-ai --gateway-name gw-01 -o table
# 3. Optional 1-line fallback to 2025-09-01-preview
export AZURE_AIGATEWAY_API_VERSION=2025-09-01-preview
# Or persistent CLI config / single-command override:
az config set aigateway.api_version=2025-09-01-preview
az aigateway show -g rg-ai -n gw-01 --api-version 2025-09-01-previewInstall or Upgrade
macOS / Linux / WSL / Cloud Shell (Bash)
curl -fsSL https://raw.githubusercontent.com/Azure/aigateway/main/cli/install.sh | bashWindows (PowerShell)
irm https://raw.githubusercontent.com/Azure/aigateway/main/cli/install.ps1 | iexDirect Wheel Install
az extension remove --name aigateway 2>/dev/null || true
az extension add --upgrade --source https://github.com/Azure/aigateway/releases/download/cli-v1.0.0b34/aigateway-1.0.0b34-py3-none-any.whl --yesDocumentation URLs
- Quickstart & Overview: https://github.com/Azure/aigateway/blob/main/cli/README.md
- Command Reference: https://github.com/Azure/aigateway/blob/main/cli/command-reference.md
- AI Gateway Labs Quickstart: https://github.com/Azure/aigateway/blob/main/labs/quickstart/README.md
Release Asset & Checksum
- Asset:
aigateway-1.0.0b34-py3-none-any.whl - Download URL: https://github.com/Azure/aigateway/releases/download/cli-v1.0.0b34/aigateway-1.0.0b34-py3-none-any.whl
- SHA-256:
f4f1c509ccf0e8c5f135604f318bc60077eb14b4cef9036456f266874b9c5c86 - Checksum file:
SHA256SUMS