This guide provides design guidelines and best practices for developing extensions to the Azure Developer CLI (azd). Following these guidelines ensures that extensions maintain consistency with core azd functionality and provide a seamless user experience.
- New functionality should extend existing command categories
- Use a verb-first structure, where the primary action (e.g., add, create, delete, list) is the top-level command, and the target entity or context follows as an argument or subcommand.
- Example:
azd add <new-resource-type>instead ofazd <new-resource-type> add
- Reuse established parameter patterns across new commands
- Maintain consistent naming conventions (e.g.,
--subscription,--name,--type) - Provide sensible defaults to reduce cognitive load
- Integrate new functionality into existing
azd helpstructure - Provide contextual guidance within established command flows
- Maintain documentation consistency across core and extended features
- Leverage existing template system for new resource types
- Follow established template discovery and management patterns
- Integrate new resources into azd's resource lifecycle management
- Provide support for GitHub Actions and Azure DevOps
- Consider support for a range of IaC providers (Bicep, Terraform, etc.)
- User Familiarity: Builds on known command patterns and reduces learning curve
- Discoverability: New capabilities are found through existing workflows
- Consistency: Predictable behavior across all azd commands and extensions
- Maintainability: Systematic approach reduces complexity and technical debt
- Extensibility: Clear framework for adding capabilities without breaking existing patterns
- Ecosystem Growth: Provides foundation for third-party extensions and integrations
This framework enables:
- Advanced workflow automation
- Enhanced developer productivity features
- Consistent user experience across all
azdfunctionality - Integration of new Azure services and capabilities
- Third-party extension development
For core design principles that apply to all azd functionality, see guiding-principles.md.