CLI Reference
Complete reference for all azd app commands and flags.
Global Flags
These flags are available for all commands:
| Flag | Short | Description |
|---|---|---|
--output | -o | Output format (default, json) |
--debug | - | Enable debug logging |
--structured-logs | - | Enable structured JSON logging to stderr |
--cwd | -C | Sets the current working directory |
Commands
azd app reqsFull DocsVerifies that all required tools are installed and optionally checks if they are running. Can also auto-generate requirements from your project.
azd app depsFull DocsAutomatically detects your project type and installs all dependencies.
azd app addFull DocsAdd a well-known container service to your azure.yaml configuration.
azd app runFull DocsStarts your development environment based on project type with support for multi-service orchestration.
azd app startFull DocsStart stopped services.
azd app stopFull DocsStop running services, execute lifecycle hooks, and tear down the app.
azd app restartFull DocsRestart services.
azd app healthFull DocsMonitor the health status of running services with production-grade reliability and observability features.
azd app logsFull DocsView logs from running services with filtering and follow support.
azd app infoFull DocsShow comprehensive information about running services.
azd app testFull DocsRun tests for all services in your application with support for different test types and aggregated code coverage.
azd app certFull DocsGenerate local HTTPS certificates for development.
azd app cleanFull DocsRemove build output and cache directories for the services defined in `azure.yaml`.
azd app completionFull DocsGenerate shell autocompletion scripts for `azd app`.
azd app configFull DocsShow the configuration azd app resolved from azure.yaml for each service.
azd app doctorFull DocsChecks whether the local machine can run the project. Where `validate` checks `azure.yaml` itself, `doctor` also checks the environment around it: service paths on disk, required tools on `PATH`, port declarations, and whether the dashboard is already running. Nothing is started and no files are written.
azd app envFull DocsPrint the effective environment a service receives when it runs.
azd app graphFull DocsShow services, resources, dependency edges, and startup levels from `azure.yaml`.
azd app hooksFull DocsList the project-level lifecycle hooks configured in `azure.yaml`.
azd app initFull DocsScans your project to detect services, languages, frameworks, and infrastructure dependencies, then generates or enriches `azure.yaml` with all the settings needed for `azd app run`.
azd app mcpFull DocsModel Context Protocol (MCP) server for AI assistant integration. Enables AI assistants like Claude Desktop and GitHub Copilot to interact with your azd app projects.
azd app notificationsFull DocsView and manage notifications for service state changes and events.
azd app openFull DocsResolve a service URL from `azure.yaml` or the running app state and open it in the default browser.
azd app outdatedFull DocsCheck every service in `azure.yaml` for outdated dependencies and print one aggregated report.
azd app portsFull DocsReads `azure.yaml` and lists the host port each service binds. An explicit host port is shown as its number; a port left for the tool to assign is shown as `auto`. When two bindings claim the same explicit host port the command reports the conflict and exits non-zero, so it works as a preflight check before `azd app run`.
azd app proxyFull DocsStart a local reverse proxy for running services.
azd app removeFull DocsRemove a service from the `services` section of `azure.yaml`.
azd app statusFull DocsReport whether `azd app run` is currently active for this project, and print a one-line summary per service.
azd app support-bundleFull DocsCollect sanitized project, service, health, and log diagnostics into a local folder for issue reports.
azd app validateFull DocsValidates `azure.yaml` with read-only checks for service references, project paths, ports, service types, modes, and command readiness. Nothing is started and no files are written.
azd app versionFull DocsShow version information for the azd app extension.
Quick Reference
# Check prerequisitesazd app reqs
# Install dependenciesazd app deps
# Start development environmentazd app run
# Monitor service healthazd app health --stream
# View logsazd app logs --follow
# Show running servicesazd app info
# Start MCP server for AI debuggingazd app mcp serveEnvironment Variables
When running through azd app <command>, these Azure environment variables are automatically available:
| Variable | Description |
|---|---|
AZURE_SUBSCRIPTION_ID | Current Azure subscription |
AZURE_RESOURCE_GROUP_NAME | Target resource group |
AZURE_ENV_NAME | Environment name |
AZURE_LOCATION | Azure region |
AI-Powered Debugging with MCP
The azd app mcp command enables AI assistants like GitHub Copilot to interact with your running services.