Prerequisites
- Azure subscription with access to Azure OpenAI Service
- Deployed model in your Azure OpenAI resource
- API key from your Azure OpenAI resource
Quick Setup
1. Set Your API Key
Add your Azure OpenAI API key to your.env file:
2. Configure the Base URL
SetazureBaseURL in your .taskmaster/config.json under the global section:
3. Set Azure as Your Provider
Supported Models
Task Master supports Azure OpenAI models that use the Chat Completions API:| Model | Notes |
|---|---|
gpt-4o | Recommended for most use cases |
gpt-4o-mini | Cost-effective option |
gpt-4-1 | GPT-4 Turbo |
The
modelId should match your Azure deployment name exactly. Azure deployment names are case-sensitive.Configuration Examples
Basic Configuration
Role-Specific Base URLs
You can set different base URLs per role if you have deployments in different regions:MCP Server Configuration
For Claude Code integration, include your Azure configuration in.mcp.json:
Troubleshooting
”Azure endpoint URL is required”
Make sure you’ve set either:global.azureBaseURLin configmodels.[role].baseURLfor the specific role
”Invalid API key”
Verify yourAZURE_OPENAI_API_KEY is correct and has access to the deployment.
”Resource not found” (404)
- Ensure the
modelIdmatches your Azure deployment name exactly - Verify your base URL format is correct (should be
https://your-resource.openai.azure.com)
Getting Your Azure Credentials
Azure Portal
- Go to Azure Portal
- Navigate to your Azure OpenAI resource
- Under Keys and Endpoint, copy:
- One of the API keys
- The endpoint URL
Creating a Deployment
- In your Azure OpenAI resource, go to Model deployments
- Click Manage Deployments to open Azure AI Studio
- Create a new deployment and note the deployment name - this is your
modelId