Azure DevOps MCP Server for Cline

适用于 Cline 的 Azure DevOps MCP 服务器

该模型上下文协议 (MCP) 服务器提供与 Azure DevOps 的集成,允许 Cline 与 Azure DevOps 服务进行交互。

先决条件

  • Node.js(v20 LTS 或更高版本)
  • npm(Node.js 附带)
  • Cline 安装
  • 具有访问令牌的 Azure DevOps 帐户

安装

通过 Smithery 安装

要通过Smithery自动为 Claude Desktop 安装 Azure DevOps Server:

npx -y @smithery/cli install @stefanskiasan/azure-devops-mcp-server --client claude

手动安装

  1. 克隆此存储库:
git clone https://github.com/stefanskiasan/azure-devops-mcp-server.git cd azure-devops-mcp-server
  1. 安装依赖项:
npm install
  1. 构建服务器:
npm run build

注意:构建输出( build/目录)不包含在版本控制中。您必须在克隆存储库后运行构建命令。

配置

1.获取 Azure DevOps 个人访问令牌(PAT)

  1. 转到 Azure DevOps 并登录
  2. 点击右上角的个人资料图片
  3. 选择“安全”
  4. 点击“新代币”
  5. 为您的令牌命名并选择所需的范围:
    • Code (read, write) - 用于拉取请求操作
    • Work Items (read, write) - 用于工作项管理
    • Build (read, execute) - 用于管道操作
    • Wiki (read, write) - 用于 Wiki 操作
    • Project and Team (read) - 有关项目和董事会的信息
  6. 复制生成的token

2. 配置 Cline MCP 设置

将服务器配置添加到您的 Cline MCP 设置文件:

  • 对于 VSCode 扩展: %APPDATA%/Code/User/globalStorage/rooveterinaryinc.roo-cline/settings/cline_mcp_settings.json
  • 对于 Claude 桌面应用程序: %LOCALAPPDATA%/Claude/claude_desktop_config.json

mcpServers对象添加以下配置:

{ "mcpServers": { "azure-devops": { "command": "node", "args": ["/absolute/path/to/azure-devops-server/build/index.js"], "env": { "AZURE_DEVOPS_ORG": "your-organization", "AZURE_DEVOPS_PAT": "your-personal-access-token", "AZURE_DEVOPS_PROJECT": "your-project-name" }, "disabled": false, "autoApprove": [] } } }

替换以下值:

  • /absolute/path/to/azure-devops-server :克隆此存储库的绝对路径
  • your-organization :您的 Azure DevOps 组织名称
  • your-project-name :您的 Azure DevOps 项目名称
  • your-personal-access-token :您在步骤 1 中生成的 PAT

可用工具

工作项目

  • get_work_item :通过 ID 获取工作项
  • list_work_items :使用 WIQL 查询工作项
  • create_work_item :创建一个新的工作项(Bug、任务、用户故事)
  • update_work_item :更新现有工作项

  • get_boards :获取项目中可用的板

管道

  • list_pipelines :列出项目中的所有管道
  • trigger_pipeline :执行管道

拉取请求

  • list_pull_requests :列出拉取请求
  • create_pull_request :创建一个新的拉取请求
  • update_pull_request :更新拉取请求
  • get_pull_request :获取拉取请求详细信息

维基百科

  • get_wikis :列出项目中的所有 wiki
  • get_wiki_page :获取 wiki 页面
  • create_wiki :创建一个新的wiki
  • update_wiki_page :创建或更新 wiki 页面

项目

  • list_projects :列出 Azure DevOps 组织中的所有项目

确认

  1. 添加配置后重启Cline(或VSCode)
  2. Azure DevOps MCP 服务器现在应该列在 Cline 的功能中
  3. 您可以使用 MCP Inspector 验证安装:
npm run inspector

故障排除

  1. 如果服务器未连接:
    • 检查 MCP 设置中的路径是否正确
    • 验证你的 Azure DevOps 凭据
    • 检查 Cline 日志中是否有任何错误消息
  2. 如果出现身份验证错误:
    • 确认您的 PAT 尚未过期
    • 确保 PAT 具有所有必要的范围
    • 仔细检查组织和项目名称
  3. 对于其他问题:
    • 运行检查工具来验证服务器是否正常工作
    • 检查服务器日志中是否有任何错误消息

发展

要修改或扩展服务器:

  1. src目录中进行更改
  2. 运行npm run watch进行开发
  3. 准备就绪后使用npm run build进行构建
  4. 使用检查器进行测试: npm run inspector

执照

MIT 许可证 - 详情请参阅许可证

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

local-only server

The server can only run on the client's local machine because it depends on local resources.

将 Cline 与 Azure DevOps 服务集成,从而能够通过可配置的 MCP 工具访问工作项、存储库和拉取请求。

  1. Prerequisites
    1. Installation
      1. Installing via Smithery
      2. Manual Installation
    2. Configuration
      1. 1. Get Azure DevOps Personal Access Token (PAT)
      2. 2. Configure Cline MCP Settings
    3. Available Tools
      1. Work Items
      2. Boards
      3. Pipelines
      4. Pull Requests
      5. Wiki
      6. Projects
    4. Verification
      1. Troubleshooting
        1. Development
          1. License

            Related MCP Servers

            • A
              security
              A
              license
              A
              quality
              A TypeScript-based MCP server that enables interaction with Azure Table Storage directly through Cline. This tool allows you to query and manage data in Azure Storage Tables.
              Last updated 4 months ago
              1
              0
              4
              JavaScript
              MIT License
            • A
              security
              A
              license
              A
              quality
              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
              Last updated a month ago
              96
              10
              TypeScript
              MIT License
            • -
              security
              F
              license
              -
              quality
              Provides tools for listing and querying Azure resources directly from any MCP client, allowing you to efficiently browse your Azure infrastructure and analyze costs without leaving your workflow.
              Last updated a month ago
              Python
              • Apple
              • Linux
            • -
              security
              A
              license
              -
              quality
              An MCP server that wraps the Azure CLI. As LLMs are very good at generating Azure CLI commands, this server allows your LLM to list resources, update/create/delete them, fix errors (by looking at the logs), fix security issues...
              Last updated 15 days ago
              57
              MIT License
              • Linux
              • Apple

            View all related MCP servers

            ID: jw1m3bd8lw