Skip to main content
Glama
Azure DevOps MCP Server

Azure DevOps MCP Server

Azure DevOps MCP Server

A Model Context Protocol (MCP) server implementation for Azure DevOps, allowing AI assistants to interact with Azure DevOps APIs through a standardized protocol.

Looking for the official server? Microsoft maintains a product-supported Azure DevOps MCP at microsoft/azure-devops-mcp. If you use Azure DevOps Services (cloud), start there.

This community server remains a good fit when you need Azure DevOps Server (on-premises) support — especially older versions that may not work with Microsoft's MCP — or features not yet available in the official server. See Discussion #237 for more context. See ROADMAP.md for where this server differentiates and what is planned.

Overview

This server implements the Model Context Protocol (MCP) for Azure DevOps, enabling AI assistants like Claude to interact with Azure DevOps resources securely. The server acts as a bridge between AI models and Azure DevOps APIs, providing a standardized way to:

  • Access and manage projects, work items, repositories, and more

  • Create and update work items, branches, and pull requests

  • Execute common DevOps workflows through natural language

  • Access repository content via standardized resource URIs

  • Safely authenticate and interact with Azure DevOps resources

Related MCP server: Azure DevOps MCP Server

Server Structure

The server is structured around the Model Context Protocol (MCP) for communicating with AI assistants. It provides tools for interacting with Azure DevOps resources including:

  • Projects

  • Work Items

  • Repositories

  • Pull Requests

  • Branches

  • Pipelines

Core Components

  • AzureDevOpsServer: Main server class that initializes the MCP server and registers tools

  • Feature Modules: Organized by feature area (work-items, projects, repositories, etc.)

  • Request Handlers: Each feature module provides request identification and handling functions

  • Tool Handlers: Modular functions for each Azure DevOps operation

  • Configuration: Environment-based configuration for organization URL, PAT, etc.

The server uses a feature-based architecture where each feature area (like work-items, projects, repositories) is encapsulated in its own module. This makes the codebase more maintainable and easier to extend with new features.

Getting Started

Prerequisites

  • Node.js (v16+)

  • npm or yarn

  • Azure DevOps account with appropriate access

  • Authentication credentials (see Authentication Guide for details):

    • Personal Access Token (PAT), or

    • Azure Identity credentials, or

    • Azure CLI login

Running from npm (npx)

If you just want to run the published server package, you do not need to clone or build this repository:

npx -y @tiberriver256/mcp-server-azure-devops

Running locally (from source)

From a checkout of this repository:

npm ci
cp .env.example .env   # then edit values
npm run build
npm start              # runs: node dist/index.js

For iterative development (auto-reload):

npm run dev            # runs src/index.ts via tsx watch

Usage with Claude Desktop/Cursor AI

To integrate with Claude Desktop or Cursor AI, add one of the following configurations to your configuration file.

Azure Identity Authentication

Be sure you are logged in to Azure CLI with az login then add the following:

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

Azure DevOps Server (on-prem) requires PAT authentication. Example:

{
  "mcpServers": {
    "azureDevOps": {
      "command": "npx",
      "args": ["-y", "@tiberriver256/mcp-server-azure-devops"],
      "env": {
        "AZURE_DEVOPS_ORG_URL": "https://server:8080/tfs/DefaultCollection",
        "AZURE_DEVOPS_AUTH_METHOD": "pat",
        "AZURE_DEVOPS_PAT": "<YOUR_PAT>",
        "AZURE_DEVOPS_DEFAULT_PROJECT": "your-project-name"
      }
    }
  }
}

For detailed configuration instructions and more authentication options, see the Authentication Guide.

Authentication Methods

This server supports multiple authentication methods for connecting to Azure DevOps APIs. For detailed setup instructions, configuration examples, and troubleshooting tips, see the Authentication Guide.

Supported 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

Example configuration files for each authentication method are available in the examples directory.

Azure DevOps Server (on-prem) supports PAT authentication only. Azure Identity and Azure CLI are supported for Azure DevOps Services.

Environment Variables

For a complete list of environment variables and their descriptions, see the Authentication Guide.

Key environment variables include:

Variable

Description

Required

Default

AZURE_DEVOPS_AUTH_METHOD

Authentication method (pat, azure-identity, or azure-cli) - case-insensitive

No

azure-identity

AZURE_DEVOPS_ORG_URL

Full URL to your Azure DevOps organization or Server collection (e.g., https://server:8080/tfs/DefaultCollection)

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

REST api-version for the tools that call the REST API directly (per-release values)

No

7.1

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

Troubleshooting Authentication

For detailed troubleshooting information for each authentication method, see the Authentication Guide.

Common issues include:

  • Invalid or expired credentials

  • Insufficient permissions

  • Network connectivity problems

  • Configuration errors

Authentication Implementation Details

For technical details about how authentication is implemented in the Azure DevOps MCP server, see the Authentication Guide and the source code in the src/auth directory.

Available Tools

The Azure DevOps MCP server provides a variety of tools for interacting with Azure DevOps resources. For detailed documentation on each tool, please refer to the corresponding documentation.

User Tools

  • get_me: Get details of the authenticated user (id, displayName, email) (Azure DevOps Services only)

Organization Tools

  • list_organizations: List all accessible organizations (Azure DevOps Services only)

Project Tools

  • list_projects: List all projects in an organization

  • get_project: Get details of a specific project

  • get_project_details: Get comprehensive details of a project including process, work item types, and teams

Repository Tools

  • list_repositories: List all repositories in a project

  • get_repository: Get details of a specific repository

  • get_repository_details: Get detailed information about a repository including statistics and refs

  • get_file_content: Get content of a file or directory from a repository

  • get_repository_tree: List a repository's file tree from any path and depth

  • create_branch: Create a new branch from an existing one

  • create_commit: Commit multiple file changes to a branch using unified diffs or search/replace instructions

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: Add, remove, or update links between work items

  • create_work_item_attachment: Upload and attach a file to a work item

  • get_work_item_attachment: Download an attachment from a work item

  • delete_work_item_attachment: Delete an attachment from a work item

Search Tools

  • search_code: Search for code across repositories in a project

  • search_wiki: Search for content across wiki pages in a project

  • search_work_items: Search for work items across projects in Azure DevOps

Pipelines Tools

  • list_pipelines: List pipelines in a project

  • get_pipeline: Get details of a specific pipeline

  • list_pipeline_runs: List recent runs for a pipeline with optional filters

  • get_pipeline_run: Get detailed run information and artifact summaries

  • download_pipeline_artifact: Download a single artifact file as text

  • pipeline_timeline: Retrieve the stage and job timeline for a run

  • get_pipeline_log: Retrieve raw or JSON-formatted log content

  • trigger_pipeline: Trigger a pipeline run with customizable parameters

Wiki Tools

  • get_wikis: List all wikis in a project

  • get_wiki_page: Get content of a specific wiki page as plain text

Pull Request Tools

For comprehensive documentation on all tools, see the Tools Documentation.

Contributing

Contributions are welcome! Please see CONTRIBUTING.md for contribution guidelines.

Star History

Star History Chart

License

MIT

Available Tools

49 tools
add_pull_request_commentB

Add a comment to a pull request (repositoryId optional; derived from pullRequestId when omitted)

Inputs: content (required), pullRequestId (required), status, filePath, +6 more.

create_branchB

Create a new branch from an existing one

Inputs: newBranch (required), repositoryId (required), sourceBranch (required), projectId, +1 more.

create_commitA

Create a commit on an existing branch using file changes.

  • Provide plain branch names (no "refs/heads/").

  • ⚠️ Each file path may appear only once per commit request—combine all edits to a file into a single change entry.

  • Prefer multiple commits when you have sparse or unrelated edits; smaller focused commits keep review context clear.

🎯 RECOMMENDED: Use the SEARCH/REPLACE format (much easier, no line counting!).

Option 1: SEARCH/REPLACE format (EASIEST) Simply provide the exact text to find and replace:

{
  "changes": [{
    "path": "src/api/services/function-call.ts",
    "search": "return axios.post(apiUrl, payload, requestConfig);",
    "replace": "return axios.post(apiUrl, payload, requestConfig).then(r => { processResponse(r); return r; });"
  }]
}

The server fetches the file, performs the replacement, and generates the diff automatically. No line counting, no hunk headers, no context lines needed!

Option 2: UNIFIED DIFF format (Advanced) If you prefer full control, provide complete unified diffs:

  • Each patch MUST have complete hunk headers: @@ -oldStart,oldLines +newStart,newLines @@

  • CRITICAL: Every @@ marker MUST include line numbers. Do NOT use @@ without line ranges.

  • Include 3-5 context lines before and after changes.

  • For deletions: --- a/filepath and +++ /dev/null

  • For additions: --- /dev/null and +++ b/filepath

Example unified diff:

{
  "changes": [{
    "patch": "diff --git a/file.yaml b/file.yaml\n--- a/file.yaml\n+++ b/file.yaml\n@@ -4,7 +4,7 @@ spec:\n spec:\n   type: ClusterIP\n   ports:\n-    - port: 8080\n+    - port: 9090\n       targetPort: http\n"
  }]
}

Inputs: changes (required), branchName (required), repositoryId (required), commitMessage (required), +2 more.

create_pull_requestB

Create a new pull request, including reviewers, linked work items, and optional tags

Inputs: title (required), repositoryId (required), sourceRefName (required), targetRefName (required), +8 more.

create_wikiC

Create a new wiki in the project

Inputs: name (required), type (required), mappedPath (required), projectId, +2 more.

create_wiki_pageA

Create a new page in a wiki. If the page already exists at the specified path, it will be updated.

Inputs: wikiId (required), content (required), pagePath (required), comment, +2 more.

create_work_itemC

Create a new work item

Inputs: title (required), workItemType (required), tags, areaPath, +8 more.

create_work_item_attachmentA

Upload a file and attach it to a work item. The file is read from the local filesystem, uploaded to Azure DevOps, and linked to the specified work item.

Inputs: filePath (required), workItemId (required), comment, fileName.

delete_work_item_attachmentA

Delete an attachment from a work item. The attachment ID can be obtained from the work item relations.

Inputs: workItemId (required), attachmentId (required).

download_pipeline_artifactB

Download a file from a pipeline run artifact and return its textual content

Inputs: runId (required), artifactPath (required), projectId, pipelineId.

get_all_repositories_treeB

Displays a hierarchical tree view of files and directories across multiple Azure DevOps repositories within a project, based on their default branches

Inputs: depth (required), pattern, projectId, organizationId, +1 more.

get_file_contentC

Get content of a file or directory from a repository

Inputs: path (required), repositoryId (required), version, projectId, +2 more.

get_meA

Get details of the authenticated user (id, displayName, email)

Inputs: no named parameters.

get_pipelineC

Get details of a specific pipeline

Inputs: pipelineId (required), projectId, pipelineVersion.

get_pipeline_logC

Retrieve a specific pipeline log using the timeline log identifier

Inputs: logId (required), runId (required), format, endLine, +3 more.

get_pipeline_runC

Get details for a specific pipeline run

Inputs: runId (required), projectId, pipelineId.

get_projectC

Get details of a specific project

Inputs: projectId, organizationId.

get_project_detailsC

Get comprehensive details of a project including process, work item types, and teams

Inputs: includeTeams (required), includeFields (required), includeProcess (required), expandTeamIdentity (required), +3 more.

get_pull_requestA

Get a pull request by ID (no repositoryId required; best for Azure DevOps Server where PR IDs are project-scoped)

Inputs: projectId (required), pullRequestId (required), organizationId.

get_pull_request_changesA

Get the files changed in a pull request, their unified diffs, source/target branch names, and the status of policy evaluations

Inputs: repositoryId (required), pullRequestId (required), projectId, organizationId.

get_pull_request_checksA

Summarize the latest status checks and policy evaluations for a pull request.

  • Surfaces pipeline and run identifiers so you can jump straight to the blocking validation.

  • Pair with pipeline tools (e.g., get_pipeline_run, pipeline_timeline) to inspect failures in depth.

Inputs: repositoryId (required), pullRequestId (required), projectId, organizationId.

get_pull_request_commentsC

Get comments from a specific pull request

Inputs: repositoryId (required), pullRequestId (required), top, threadId, +3 more.

get_repositoryB

Get details of a specific repository

Inputs: repositoryId (required), projectId, organizationId.

get_repository_detailsC

Get detailed information about a repository including statistics and refs

Inputs: includeRefs (required), repositoryId (required), includeStatistics (required), projectId, +3 more.

get_repository_treeB

Displays a hierarchical tree view of files and directories within a single repository starting from an optional path

Inputs: path (required), depth (required), repositoryId (required), projectId, +1 more.

get_wiki_pageB

Get the content of a wiki page

Inputs: wikiId (required), pagePath (required), projectId, organizationId.

get_wikisC

Get details of wikis in a project

Inputs: projectId, organizationId.

get_work_itemC

Get details of a specific work item

Inputs: workItemId (required), expand.

get_work_item_attachmentB

Download an attachment from Azure DevOps and save it to the local filesystem. The attachment ID can be obtained from the work item relations.

Inputs: outputPath (required), attachmentId (required).

get_work_item_commentsC

Get comments and discussion history for a specific work item

Inputs: order (required), expand (required), workItemId (required), top, +3 more.

list_commitsB

List recent commits on a branch including file-level diff content for each commit

Inputs: branchName (required), repositoryId (required), top, skip, +2 more.

list_organizationsA

List all Azure DevOps organizations accessible to the current authentication

Inputs: no named parameters.

list_pipeline_runsC

List recent runs for a pipeline

Inputs: top (required), orderBy (required), pipelineId (required), state, +6 more.

list_pipelinesB

List pipelines in a project

Inputs: top, orderBy, projectId.

list_projectsC

List all projects in an organization

Inputs: top, skip, stateFilter, organizationId, +1 more.

list_pull_requestsC

List pull requests in a repository

Inputs: top (required), repositoryId (required), skip, status, +6 more.

list_repositoriesC

List repositories in a project

Inputs: projectId, includeLinks, organizationId.

list_wiki_pagesC

List pages within an Azure DevOps wiki

Inputs: wikiId (required), projectId, organizationId.

list_work_itemsC

List work items in a project

Inputs: top, skip, wiql, fields, +4 more.

pipeline_timelineC

Retrieve the timeline of stages and jobs for a pipeline run, to reduce the amount of data returned, you can filter by state and result

Inputs: runId (required), state, result, projectId, +2 more.

search_codeC

Search for code across repositories in a project

Inputs: top (required), skip (required), searchText (required), includeContent (required), +4 more.

search_wikiC

Search for content across wiki pages in a project

Inputs: top (required), skip (required), searchText (required), includeFacets (required), +3 more.

search_work_itemsC

Search for work items across projects in Azure DevOps

Inputs: top (required), skip (required), searchText (required), includeFacets (required), +4 more.

trigger_pipelineC

Trigger a pipeline run

Inputs: pipelineId (required), branch, projectId, variables, +2 more.

update_pull_requestB

Update an existing pull request with new properties, manage reviewers and work items, and add or remove tags

Inputs: repositoryId (required), pullRequestId (required), title, status, +11 more.

update_pull_request_thread_statusA

Update the status of a comment thread in a pull request (repositoryId optional; derived from pullRequestId when omitted)

Inputs: status (required), threadId (required), pullRequestId (required), projectId, +2 more.

update_wiki_pageC

Update content of a wiki page

Inputs: wikiId (required), content (required), pagePath (required), comment, +2 more.

update_work_itemC

Update an existing work item

Inputs: workItemId (required), tags, state, title, +8 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.9/5.0

    Scored across 49 tools

    Disambiguation3/5

    Many tools are distinct by resource and action (repositories, work items, PRs, wikis, pipelines), but several overlapping pairs create ambiguity: get_project_details vs get_project, get_repository_details vs get_repository, get_file_content vs tree tools, and create_wiki_page (which also updates) vs update_wiki_page. Descriptions help clarify, but the boundaries are not consistently sharp.

    Naming Consistency4/5

    Most tools follow a predictable snake_case verb_noun pattern (list_repositories, get_work_item, create_pull_request, update_wiki_page). Minor deviations exist, such as pipeline_timeline lacking a verb and get_wikis vs list_wiki_pages, but the overall convention is readable and mostly consistent.

    Tool Count2/5

    49 tools is excessive for a single MCP server, far beyond the 3-15 well-scoped range and even beyond the 16-25 heavy range. Azure DevOps is broad, but this surface would benefit from consolidation or grouping.

    Completeness3/5

    The server covers many core read/write operations across repositories, work items, PRs, wikis, and pipelines. However, notable lifecycle gaps remain: no delete_work_item, no PR merge/abandon/complete operation, no repository create/delete, no wiki page delete, and no pipeline cancel/update.

    Maintenance

    ActivityActive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      This server provides a convenient API for interacting with Azure DevOps services, enabling AI assistants and other tools to manage work items, code repositories, boards, sprints, and more. Built with the Model Context Protocol, it provides a standardized interface for communicating with Azure DevOps
      164 npm
      60
      MIT
    • -
      license
      Not graded
      quality
      Not graded
      maintenance
      A reference server implementation for the Model Context Protocol that enables AI assistants to interact with Azure DevOps resources and perform operations such as project management, work item tracking, repository operations, and code search programmatically.
      7
      -
    • A
      license
      A
      quality
      D
      maintenance
      A Model Context Protocol server that enables AI assistants to interact with Azure DevOps services, allowing users to query work items with plans to support creating/updating items, managing pipelines, handling pull requests, and administering sprints and branch policies.
      21
      55 PyPI
      79
      MIT
    • F
      license
      A
      quality
      D
      maintenance
      A Model Context Protocol server that enables AI assistants to interact with Azure DevOps services, providing capabilities for work item management, project management, and team collaboration through natural language.
      21
      -