This Azure DevOps MCP server provides a standardized way for AI assistants to interact with Azure DevOps resources through the Model Context Protocol (MCP). It acts as a bridge between AI models and Azure DevOps APIs, enabling you to manage projects, work items, repositories, and more using natural language.
To integrate with Claude Desktop or Cursor AI, add one of the following configurations to your configuration file.
First, login to Azure CLI:
az login
Then add this configuration:
{
"mcpServers": {
"azureDevOps": {
"command": "npx",
"args": ["-y", "@tiberriver256/mcp-server-azure-devops"],
"env": {
"AZURE_DEVOPS_ORG_URL": "https://dev.azure.com/your-organization",
"AZURE_DEVOPS_AUTH_METHOD": "azure-identity",
"AZURE_DEVOPS_DEFAULT_PROJECT": "your-project-name"
}
}
}
}
{
"mcpServers": {
"azureDevOps": {
"command": "npx",
"args": ["-y", "@tiberriver256/mcp-server-azure-devops"],
"env": {
"AZURE_DEVOPS_ORG_URL": "https://dev.azure.com/your-organization",
"AZURE_DEVOPS_AUTH_METHOD": "pat",
"AZURE_DEVOPS_PAT": "<YOUR_PAT>",
"AZURE_DEVOPS_DEFAULT_PROJECT": "your-project-name"
}
}
}
}
The server supports multiple authentication methods for connecting to Azure DevOps APIs:
Key environment variables for configuration:
Variable | Description | Required | Default |
---|---|---|---|
AZURE_DEVOPS_AUTH_METHOD |
Authentication method (pat , azure-identity , or azure-cli ) |
No | azure-identity |
AZURE_DEVOPS_ORG_URL |
Full URL to your Azure DevOps organization | Yes | - |
AZURE_DEVOPS_PAT |
Personal Access Token (for PAT auth) | Only with PAT auth | - |
AZURE_DEVOPS_DEFAULT_PROJECT |
Default project if none specified | No | - |
AZURE_DEVOPS_API_VERSION |
API version to use | No | Latest |
AZURE_TENANT_ID |
Azure AD tenant ID (for service principals) | Only with service principals | - |
AZURE_CLIENT_ID |
Azure AD application ID (for service principals) | Only with service principals | - |
AZURE_CLIENT_SECRET |
Azure AD client secret (for service principals) | Only with service principals | - |
LOG_LEVEL |
Logging level (debug, info, warn, error) | No | info |
The MCP server provides numerous tools to interact with Azure DevOps resources:
get_me
: Get details of the authenticated userlist_organizations
: List all accessible organizationslist_projects
: List all projects in an organizationget_project
: Get details of a specific projectget_project_details
: Get comprehensive project detailslist_repositories
: List all repositories in a projectget_repository
: Get details of a specific repositoryget_repository_details
: Get detailed repository informationget_file_content
: Get content of a file or directoryget_work_item
: Retrieve a work item by IDcreate_work_item
: Create a new work itemupdate_work_item
: Update an existing work itemlist_work_items
: List work items in a projectmanage_work_item_link
: Add, remove, or update work item linkssearch_code
: Search for code across repositoriessearch_wiki
: Search for content across wiki pagessearch_work_items
: Search for work items across projectslist_pipelines
: List pipelines in a projectget_pipeline
: Get details of a specific pipelinetrigger_pipeline
: Trigger a pipeline run with parametersget_wikis
: List all wikis in a projectget_wiki_page
: Get content of a specific wiki pagecreate_pull_request
: Create a new pull requestlist_pull_requests
: List pull requests in a repositoryadd_pull_request_comment
: Add a comment to a pull requestget_pull_request_comments
: Get comments from a pull requestupdate_pull_request
: Update an existing pull requestCommon authentication issues include:
Adjust the LOG_LEVEL
environment variable to "debug" for more detailed logging information.
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > MCP and click "Add new global MCP server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"cursor-rules-mcp": {
"command": "npx",
"args": [
"-y",
"cursor-rules-mcp"
]
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explictly ask the agent to use the tool by mentioning the tool name and describing what the function does.