G

Gitlab MCP

by structured-world · io.github.structured-world/gitlab-mcp

Full-coverage GitLab MCP server with 44 tools across 18 resource types. Agent-optimized CQRS design — one tool call handles complete multi-step operations. Supports OAuth 2.1, read-only mode, stdio/SSE/StreamableHTTP transports, and GraphQL-native work items with full hierarchy (epics,issues,etc)

npm Local · stdio GlamaOfficial MCP Registry High confidence

Install

Add to ~/Library/Application Support/Claude/claude_desktop_config.json

Windows / Linux path
Windows: %APPDATA%\Claude\claude_desktop_config.json
Linux: ~/.config/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "io-github-structured-world-gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@structured-world/gitlab-mcp"
      ],
      "env": {
        "GITLAB_TOKEN": "<YOUR_VALUE>",
        "GITLAB_API_URL": "https://gitlab.com",
        "GITLAB_READ_ONLY_MODE": "<VALUE>",
        "PORT": "<VALUE>",
        "USE_MRS": "true",
        "USE_REFS": "true",
        "USE_FILES": "true",
        "USE_LABELS": "true",
        "USE_SEARCH": "true",
        "USE_MEMBERS": "true",
        "USE_PIPELINE": "true",
        "USE_RELEASES": "true",
        "USE_SNIPPETS": "true",
        "USE_WEBHOOKS": "true",
        "USE_MILESTONE": "true",
        "USE_VARIABLES": "true",
        "USE_WORKITEMS": "true",
        "USE_ITERATIONS": "true",
        "USE_GITLAB_WIKI": "true",
        "USE_INTEGRATIONS": "true"
      }
    }
  }
}

Restart Claude Desktop to activate the new server.

Add to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)

Windows / Linux path
Windows: .cursor\mcp.json (project) or %USERPROFILE%\.cursor\mcp.json (global)
Linux: .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)
{
  "mcpServers": {
    "io-github-structured-world-gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@structured-world/gitlab-mcp"
      ],
      "env": {
        "GITLAB_TOKEN": "<YOUR_VALUE>",
        "GITLAB_API_URL": "https://gitlab.com",
        "GITLAB_READ_ONLY_MODE": "<VALUE>",
        "PORT": "<VALUE>",
        "USE_MRS": "true",
        "USE_REFS": "true",
        "USE_FILES": "true",
        "USE_LABELS": "true",
        "USE_SEARCH": "true",
        "USE_MEMBERS": "true",
        "USE_PIPELINE": "true",
        "USE_RELEASES": "true",
        "USE_SNIPPETS": "true",
        "USE_WEBHOOKS": "true",
        "USE_MILESTONE": "true",
        "USE_VARIABLES": "true",
        "USE_WORKITEMS": "true",
        "USE_ITERATIONS": "true",
        "USE_GITLAB_WIKI": "true",
        "USE_INTEGRATIONS": "true"
      }
    }
  }
}

Cursor usually picks up config changes automatically; if the server does not appear, reload the window.

Add to .mcp.json (project) or ~/.claude.json (global)

Windows / Linux path
Windows: .mcp.json (project) or %USERPROFILE%\.claude.json (global)
Linux: .mcp.json (project) or ~/.claude.json (global)
{
  "mcpServers": {
    "io-github-structured-world-gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@structured-world/gitlab-mcp"
      ],
      "env": {
        "GITLAB_TOKEN": "<YOUR_VALUE>",
        "GITLAB_API_URL": "https://gitlab.com",
        "GITLAB_READ_ONLY_MODE": "<VALUE>",
        "PORT": "<VALUE>",
        "USE_MRS": "true",
        "USE_REFS": "true",
        "USE_FILES": "true",
        "USE_LABELS": "true",
        "USE_SEARCH": "true",
        "USE_MEMBERS": "true",
        "USE_PIPELINE": "true",
        "USE_RELEASES": "true",
        "USE_SNIPPETS": "true",
        "USE_WEBHOOKS": "true",
        "USE_MILESTONE": "true",
        "USE_VARIABLES": "true",
        "USE_WORKITEMS": "true",
        "USE_ITERATIONS": "true",
        "USE_GITLAB_WIKI": "true",
        "USE_INTEGRATIONS": "true"
      }
    }
  }
}

The server will be available in the next Claude Code session.

Add to .vscode/mcp.json

Windows / Linux path
Windows: .vscode\mcp.json
Linux: .vscode/mcp.json
{
  "servers": {
    "io-github-structured-world-gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@structured-world/gitlab-mcp"
      ],
      "env": {
        "GITLAB_TOKEN": "<YOUR_VALUE>",
        "GITLAB_API_URL": "https://gitlab.com",
        "GITLAB_READ_ONLY_MODE": "<VALUE>",
        "PORT": "<VALUE>",
        "USE_MRS": "true",
        "USE_REFS": "true",
        "USE_FILES": "true",
        "USE_LABELS": "true",
        "USE_SEARCH": "true",
        "USE_MEMBERS": "true",
        "USE_PIPELINE": "true",
        "USE_RELEASES": "true",
        "USE_SNIPPETS": "true",
        "USE_WEBHOOKS": "true",
        "USE_MILESTONE": "true",
        "USE_VARIABLES": "true",
        "USE_WORKITEMS": "true",
        "USE_ITERATIONS": "true",
        "USE_GITLAB_WIKI": "true",
        "USE_INTEGRATIONS": "true"
      }
    }
  }
}

Reload the VS Code window to activate.

Add to ~/.codeium/windsurf/mcp_config.json

Windows / Linux path
Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
Linux: ~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "io-github-structured-world-gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@structured-world/gitlab-mcp"
      ],
      "env": {
        "GITLAB_TOKEN": "<YOUR_VALUE>",
        "GITLAB_API_URL": "https://gitlab.com",
        "GITLAB_READ_ONLY_MODE": "<VALUE>",
        "PORT": "<VALUE>",
        "USE_MRS": "true",
        "USE_REFS": "true",
        "USE_FILES": "true",
        "USE_LABELS": "true",
        "USE_SEARCH": "true",
        "USE_MEMBERS": "true",
        "USE_PIPELINE": "true",
        "USE_RELEASES": "true",
        "USE_SNIPPETS": "true",
        "USE_WEBHOOKS": "true",
        "USE_MILESTONE": "true",
        "USE_VARIABLES": "true",
        "USE_WORKITEMS": "true",
        "USE_ITERATIONS": "true",
        "USE_GITLAB_WIKI": "true",
        "USE_INTEGRATIONS": "true"
      }
    }
  }
}

Restart Windsurf (or refresh its MCP servers panel) to activate the new server.

Windsurf Next uses ~/.codeium/windsurf-next/mcp_config.json. Devin Desktop (the Windsurf rebrand) uses ~/.config/devin/mcp_config.json and imports the Windsurf file.

Add to ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json

Windows / Linux path
Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
Linux: ~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
{
  "mcpServers": {
    "io-github-structured-world-gitlab-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@structured-world/gitlab-mcp"
      ],
      "env": {
        "GITLAB_TOKEN": "<YOUR_VALUE>",
        "GITLAB_API_URL": "https://gitlab.com",
        "GITLAB_READ_ONLY_MODE": "<VALUE>",
        "PORT": "<VALUE>",
        "USE_MRS": "true",
        "USE_REFS": "true",
        "USE_FILES": "true",
        "USE_LABELS": "true",
        "USE_SEARCH": "true",
        "USE_MEMBERS": "true",
        "USE_PIPELINE": "true",
        "USE_RELEASES": "true",
        "USE_SNIPPETS": "true",
        "USE_WEBHOOKS": "true",
        "USE_MILESTONE": "true",
        "USE_VARIABLES": "true",
        "USE_WORKITEMS": "true",
        "USE_ITERATIONS": "true",
        "USE_GITLAB_WIKI": "true",
        "USE_INTEGRATIONS": "true"
      }
    }
  }
}

Cline reloads cline_mcp_settings.json automatically; if the server does not appear, reload the VS Code window.

Open it from Cline's MCP Servers panel → Configure. Roo Code uses a different file and format.

Configuration

Environment variables this server reads. Secrets stay on your machine.

NameRequiredDescription
GITLAB_TOKEN secret Yes Your GitLab Personal Access Token.
GITLAB_API_URL No The base URL of the GitLab API (default is https://gitlab.com). Default: https://gitlab.com
GITLAB_READ_ONLY_MODE No Enable read-only mode (disable all manage_* write operations)
PORT No The port to use when running in HTTP/SSE transport mode.
USE_MRS No Enable/disable merge request tools. Default: true
USE_REFS No Enable/disable branch and tag management tools. Default: true
USE_FILES No Enable/disable file operation tools. Default: true
USE_LABELS No Enable/disable label management tools. Default: true
USE_SEARCH No Enable/disable cross-project search tools. Default: true
USE_MEMBERS No Enable/disable team member management tools. Default: true
USE_PIPELINE No Enable/disable pipeline and CI/CD tools. Default: true
USE_RELEASES No Enable/disable release management tools. Default: true
USE_SNIPPETS No Enable/disable code snippet tools. Default: true
USE_WEBHOOKS No Enable/disable webhook management tools. Default: true
USE_MILESTONE No Enable/disable milestone tools. Default: true
USE_VARIABLES No Enable/disable CI/CD variable management tools. Default: true
USE_WORKITEMS No Enable/disable issues, epics, and task tools. Default: true
USE_ITERATIONS No Enable/disable iteration planning (sprints) tools. Default: true
USE_GITLAB_WIKI No Enable/disable wiki management tools. Default: true
USE_INTEGRATIONS No Enable/disable integration tools. Default: true

Similar servers