Azure DevOps MCP server

Integrates with Azure DevOps to enable AI-driven management of projects, work items, repositories, pull requests, branches, and pipelines for enhanced DevOps workflows and automation.
Back to servers
Provider
Tiberriver256
Release date
Feb 28, 2025
Language
TypeScript
Stats
102 stars

The Azure DevOps MCP server enables AI assistants to interact with Azure DevOps resources through the Model Context Protocol, acting as a bridge between AI models and Azure DevOps APIs. This server allows you to access projects, work items, repositories, and execute DevOps workflows through natural language.

Prerequisites

Before installing the server, ensure you have:

  • Node.js (v16+)
  • npm or yarn
  • Azure DevOps account with appropriate access
  • Authentication credentials (Personal Access Token, Azure Identity credentials, or Azure CLI login)

Installation and Setup

Using NPX

The easiest way to use the Azure DevOps MCP server is by running it with NPX. You'll need to configure it based on your preferred authentication method.

Configuration with Claude Desktop/Cursor AI

Add one of the following configurations to your configuration file:

Azure Identity Authentication

First, log in 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"
      }
    }
  }
}

Personal Access Token (PAT) Authentication

{
  "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"
      }
    }
  }
}

Authentication Methods

The server supports multiple authentication methods:

  1. Personal Access Token (PAT) - Simple token-based authentication
  2. Azure Identity (DefaultAzureCredential) - Flexible authentication using the Azure Identity SDK
  3. Azure CLI - Authentication using your Azure CLI login

Environment Variables

Here are the key environment variables you can configure:

Variable Description Required Default
AZURE_DEVOPS_AUTH_METHOD Authentication method (pat, azure-identity, 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

Available Tools

The server provides various tools to interact with Azure DevOps resources:

User Tools

  • get_me: Get details of the authenticated user

Organization Tools

  • list_organizations: List all accessible organizations

Project Tools

  • list_projects: List all projects in an organization
  • get_project: Get details of a specific project
  • get_project_details: Get comprehensive project details

Repository Tools

  • list_repositories: List all repositories in a project
  • get_repository: Get details of a specific repository
  • get_repository_details: Get detailed repository information
  • get_file_content: Get content of a file or directory

Work Item Tools

  • get_work_item: Retrieve a work item by ID
  • create_work_item: Create a new work item
  • update_work_item: Update an existing work item
  • list_work_items: List work items in a project
  • manage_work_item_link: Manage links between work items

Search Tools

  • search_code: Search for code across repositories
  • search_wiki: Search for content across wiki pages
  • search_work_items: Search for work items across projects

Pipelines Tools

  • list_pipelines: List pipelines in a project
  • get_pipeline: Get details of a specific pipeline
  • trigger_pipeline: Trigger a pipeline run with parameters

Wiki Tools

  • get_wikis: List all wikis in a project
  • get_wiki_page: Get content of a specific wiki page

Pull Requests Tools

  • create_pull_request: Create a new pull request
  • list_pull_requests: List and filter pull requests
  • get_pull_request_comments: Get comments from a pull request
  • add_pull_request_comment: Add a comment to a pull request

Troubleshooting

Common authentication issues include:

  • Invalid or expired credentials
  • Insufficient permissions
  • Network connectivity problems
  • Configuration errors

How to add this MCP server to Cursor

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.

Adding an MCP server to Cursor globally

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"
            ]
        }
    }
}

Adding an MCP server to a project

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.

How to use the MCP server

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.

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later