mcp-server-gitlab

MIT License
67
2

Integrations

  • Utilizes Bun as the JavaScript runtime environment for building and running the MCP server.

  • Provides tools for interacting with GitLab's RESTful API, enabling searching users and projects, managing tasks, creating and updating merge requests, adding comments, and executing custom API calls.

English Version

mcp-gitlab MCP 服务器 (英文)

基于 fastmcp 框架构建的 GitLab 集成服务器,提供丰富的 GitLab RESTful API 工具。支持与 Claude、Smithery 等平台集成。

特征

  • GitlabSearchUserProjectsTool :按用户名搜索用户及其活跃项目
  • GitlabGetUserTasksTool :获取当前用户的待处理任务
  • GitlabSearchProjectDetailsTool :搜索项目和详细信息
  • GitlabCreateMRCommentTool :向合并请求添加注释
  • GitlabAcceptMRTool :接受并合并合并请求
  • GitlabUpdateMRTool :更新合并请求受让人、审阅者、标题、描述和标签
  • GitlabCreateMRTool :与受让人和审阅者创建新的合并请求
  • GitlabRawApiTool :使用自定义参数调用任何 GitLab API

快速入门

# Install dependencies bun install # Build the project bun run build # Start the server bun run start

环境变量

GITLAB_API_URL=https://your-gitlab-instance.com GITLAB_TOKEN=your_access_token # Optional: Provide a mapping from usernames to user IDs (JSON string) # This can reduce API calls, especially when referencing the same users frequently # Example: '{"username1": 123, "username2": 456}' GITLAB_USER_MAPPING={"username1": 123, "username2": 456} # Optional: Provide a mapping from project names to project IDs (JSON string) # Project IDs can be numbers or strings (e.g., 'group/project') # This can reduce API calls and ensure the correct project is used # Example: '{"project-name-a": 1001, "group/project-b": "group/project-b"}' GITLAB_PROJECT_MAPPING={"project-name-a": 1001, "group/project-b": "group/project-b"}

使用示例

有关每个工具参数的详细示例,请参阅USAGE.md

项目结构

src/ ├── server/ │ └── GitlabMCPServer.ts # MCP server entry point ├── tools/ │ ├── GitlabAcceptMRTool.ts │ ├── GitlabCreateMRCommentTool.ts │ ├── GitlabGetUserTasksTool.ts │ ├── GitlabRawApiTool.ts │ ├── GitlabSearchProjectDetailsTool.ts │ ├── GitlabSearchUserProjectsTool.ts │ └── gitlab/ │ ├── FieldFilterUtils.ts │ ├── GitlabApiClient.ts │ └── GitlabApiTypes.ts ├── utils/ │ ├── is.ts │ └── sensitive.ts smithery.json # Smithery config USAGE.md # Usage examples package.json tsconfig.json

一体化

Claude 桌面客户端

添加到您的配置:

{ "mcpServers": { "@zephyr-mcp/gitlab": { "command": "npx", "args": ["-y", "@zephyr-mcp/gitlab"] } } }

锻造工艺

直接在 Smithery 平台上使用:

smithery add @zephyr-mcp/gitlab

或者在 Smithery UI 中搜索“@zephyr-mcp/gitlab”并添加到您的工作区。

环境变量:

  • GITLAB_API_URL :GitLab API 的基本 URL
  • GITLAB_TOKEN :GitLab API 身份验证的访问令牌

相关链接

You must be authenticated.

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

基于MCP框架构建的GitLab集成服务器,提供多种GitLab RESTful API工具,支持项目搜索、任务管理、合并请求创建与审核等功能,帮助开发团队高效协作。

  1. 特征
    1. 快速入门
      1. 环境变量
        1. 使用示例
          1. 项目结构
            1. 一体化
              1. Claude 桌面客户端
              2. 锻造工艺
            2. 相关链接

              Related MCP Servers

              • A
                security
                A
                license
                A
                quality
                MCP Server for the GitLab API, enabling project management, file operations, and more.
                Last updated -
                9
                1,630
                44,109
                JavaScript
                MIT License
                • Linux
                • Apple
              • A
                security
                A
                license
                A
                quality
                gitlab mcp
                Last updated -
                13
                983
                75
                JavaScript
                MIT License
                • Linux
                • Apple
              • -
                security
                A
                license
                -
                quality
                GitLabとの連携機能を提供するModel Context Protocol (MCP) サーバーです。GitLabの特定のプロジェクトからパイプラインの失敗情報やマージリクエストへの指摘事項を取得し、AIアシスタントに提供します。
                Last updated -
                Python
                MIT License

              View all related MCP servers

              ID: x6a0een21s