AgentHubAgentHub

gitlab-mcp

MCP ServerMCP Registry官方收录

io.github.zereight/gitlab-mcp · v2.1.19

GitLab MCP server for projects, merge requests, issues, pipelines, wiki, releases, and more.

概览

gitlab-mcp 是一个MCP Server,收录自 官方 MCP Registry。支持 stdio 传输。本页提供 Cursor、Claude Code 等客户端的安装配置片段。

安装

选择你的平台查看安装方式

{
  "mcpServers": {
    "gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@zereight/mcp-gitlab"
      ],
      "env": {
        "GITLAB_PERSONAL_ACCESS_TOKEN": "<GITLAB_PERSONAL_ACCESS_TOKEN>"
      }
    }
  }
}

环境变量

GITLAB_PERSONAL_ACCESS_TOKEN必填secret

GitLab personal access token for local stdio use. Create a token with the GitLab scopes needed by the tools you plan to use, such as api or read_api.

GITLAB_JOB_TOKEN可选secret

Optional GitLab CI job token to use instead of a personal access token when running inside GitLab CI.

GITLAB_AUTH_COOKIE_PATH可选

Optional path to a GitLab authentication cookie file for cookie-based authentication.

GITLAB_API_URL可选

GitLab API base URL. Use https://gitlab.com/api/v4 for GitLab.com or your self-managed GitLab API URL.

GITLAB_ALLOWED_PROJECT_IDS可选

Optional comma-separated list of GitLab project IDs that this server is allowed to access.

GITLAB_READ_ONLY_MODE可选

Set to true to expose only read-only tools and block write operations.

USE_GITLAB_WIKI可选

Set to true to enable GitLab wiki tools.

GITLAB_TOOLSETS可选

Optional comma-separated list of toolsets to enable, such as projects, issues, merge_requests, pipelines, releases, users, groups, wiki, or search.

GITLAB_TOOLS可选

Optional comma-separated list of individual tool names to add on top of enabled toolsets.

GITLAB_DENIED_TOOLS_REGEX可选

Optional regular expression used to hide matching tools from the server.

GITLAB_TOOL_POLICY_APPROVE可选

Optional comma-separated list of tool names that require explicit approval before execution.

GITLAB_TOOL_POLICY_HIDDEN可选

Optional comma-separated list of tool names to hide from tools/list.

NODE_TLS_REJECT_UNAUTHORIZED可选

Set to 0 only when you intentionally need to connect to a GitLab instance with invalid or self-signed TLS certificates.

GITLAB_CA_CERT_PATH可选

Optional path to a custom CA certificate file for self-managed GitLab instances.

相关资源

统一 Manifest

{
  "id": "io.github.zereight/gitlab-mcp",
  "type": "mcp-server",
  "version": "2.1.19",
  "displayName": "gitlab-mcp",
  "description": "GitLab MCP server for projects, merge requests, issues, pipelines, wiki, releases, and more.",
  "repository": {
    "url": "https://github.com/zereight/gitlab-mcp",
    "source": "github"
  },
  "distribution": {
    "packages": [
      {
        "registryType": "npm",
        "identifier": "@zereight/mcp-gitlab",
        "version": "2.1.19",
        "transport": "stdio",
        "environmentVariables": [
          {
            "name": "GITLAB_PERSONAL_ACCESS_TOKEN",
            "description": "GitLab personal access token for local stdio use. Create a token with the GitLab scopes needed by the tools you plan to use, such as api or read_api.",
            "isRequired": true,
            "isSecret": true
          },
          {
            "name": "GITLAB_JOB_TOKEN",
            "description": "Optional GitLab CI job token to use instead of a personal access token when running inside GitLab CI.",
            "isSecret": true
          },
          {
            "name": "GITLAB_AUTH_COOKIE_PATH",
            "description": "Optional path to a GitLab authentication cookie file for cookie-based authentication."
          },
          {
            "name": "GITLAB_API_URL",
            "description": "GitLab API base URL. Use https://gitlab.com/api/v4 for GitLab.com or your self-managed GitLab API URL."
          },
          {
            "name": "GITLAB_ALLOWED_PROJECT_IDS",
            "description": "Optional comma-separated list of GitLab project IDs that this server is allowed to access."
          },
          {
            "name": "GITLAB_READ_ONLY_MODE",
            "description": "Set to true to expose only read-only tools and block write operations."
          },
          {
            "name": "USE_GITLAB_WIKI",
            "description": "Set to true to enable GitLab wiki tools."
          },
          {
            "name": "GITLAB_TOOLSETS",
            "description": "Optional comma-separated list of toolsets to enable, such as projects, issues, merge_requests, pipelines, releases, users, groups, wiki, or search."
          },
          {
            "name": "GITLAB_TOOLS",
            "description": "Optional comma-separated list of individual tool names to add on top of enabled toolsets."
          },
          {
            "name": "GITLAB_DENIED_TOOLS_REGEX",
            "description": "Optional regular expression used to hide matching tools from the server."
          },
          {
            "name": "GITLAB_TOOL_POLICY_APPROVE",
            "description": "Optional comma-separated list of tool names that require explicit approval before execution."
          },
          {
            "name": "GITLAB_TOOL_POLICY_HIDDEN",
            "description": "Optional comma-separated list of tool names to hide from tools/list."
          },
          {
            "name": "NODE_TLS_REJECT_UNAUTHORIZED",
            "description": "Set to 0 only when you intentionally need to connect to a GitLab instance with invalid or self-signed TLS certificates."
          },
          {
            "name": "GITLAB_CA_CERT_PATH",
            "description": "Optional path to a custom CA certificate file for self-managed GitLab instances."
          }
        ]
      }
    ],
    "remotes": []
  },
  "dependencies": [],
  "installTargets": [
    "claude-code",
    "claude-desktop",
    "cursor",
    "vscode"
  ],
  "keywords": [],
  "provenance": {
    "origin": "official-mcp-registry",
    "originalId": "io.github.zereight/gitlab-mcp",
    "originalUrl": "https://registry.modelcontextprotocol.io/v0.1/servers/io.github.zereight%2Fgitlab-mcp/versions/latest",
    "isOfficial": true,
    "status": "active"
  }
}
gitlab-mcp — MCP Server 安装与配置 · AgentHub