GitLab MCP Server
v3.2.0Developer-ready GitLab MCP server for CE and EE instances.
Values you need
| Variable | What it is | |
|---|---|---|
GITLAB_PERSONAL_ACCESS_TOKEN | required secret | GitLab Personal Access Token with api scope |
GITLAB_API_URL | optional | GitLab instance API URL (defaults to https://gitlab.com/api/v4) Default: https://gitlab.com/api/v4 |
GITLAB_READ_ONLY | optional | Enable read-only safety mode (true/false, default: false) Default: false |
GITLAB_EXPOSE_ALL_TOOLS | optional | Set to true to expose all 90 catalog actions directly on ListTools instead of the 5-tool hybrid surface Default: false |
MCP_OUTPUT_FORMAT | optional | Default output format: 'markdown' (default, compact tables) or 'json' Default: markdown |
npm (npx) discovery passed
Requires Node.js 18+
Run in a terminal
claude mcp add mcp-gitlab -e 'GITLAB_PERSONAL_ACCESS_TOKEN=<GITLAB_PERSONAL_ACCESS_TOKEN>' -- npx -y @sumirati/mcp-gitlab@3.2.0Add to
claude_desktop_config.json{
"mcpServers": {
"mcp-gitlab": {
"args": [
"-y",
"@sumirati/mcp-gitlab@3.2.0"
],
"command": "npx",
"env": {
"GITLAB_PERSONAL_ACCESS_TOKEN": "<GITLAB_PERSONAL_ACCESS_TOKEN>"
}
}
}
}Add to
~/.cursor/mcp.json{
"mcpServers": {
"mcp-gitlab": {
"args": [
"-y",
"@sumirati/mcp-gitlab@3.2.0"
],
"command": "npx",
"env": {
"GITLAB_PERSONAL_ACCESS_TOKEN": "<GITLAB_PERSONAL_ACCESS_TOKEN>"
}
}
}
}Add to
.vscode/mcp.json{
"inputs": [
{
"description": "GITLAB_PERSONAL_ACCESS_TOKEN",
"id": "gitlab-personal-access-token",
"password": true,
"type": "promptString"
}
],
"servers": {
"mcp-gitlab": {
"args": [
"-y",
"@sumirati/mcp-gitlab@3.2.0"
],
"command": "npx",
"env": {
"GITLAB_PERSONAL_ACCESS_TOKEN": "${input:gitlab-personal-access-token}"
},
"type": "stdio"
}
}
}Add to
~/.codex/config.toml[mcp_servers.mcp-gitlab]
command = "npx"
args = ["-y", "@sumirati/mcp-gitlab@3.2.0"]
env = { "GITLAB_PERSONAL_ACCESS_TOKEN" = "<GITLAB_PERSONAL_ACCESS_TOKEN>" }For AI agents
- Ask the user for: GITLAB_PERSONAL_ACCESS_TOKEN. Never invent or guess these values; secrets go into the client config, not into chat logs.
- Pick the user's MCP client and apply the matching config from the first install method (it is the one verified by the smoke test when available).
- Restart or reload the client so it starts the server.
- Verify: the server should expose these tools: gitlab_find_actions, gitlab_execute_action, get_file_contents, get_project, get_commit.
- If it fails, check that the required runtime is installed (Node.js 18+) and that the values above are set.
Machine-readable: install.md · manifest.json