Get the FREE Ultimate OpenClaw Setup Guide →

gitlab

EGMA: Enhanced GitLab MCP API Server, comes with 143+ tools for AI-powered GitLab integration, MCP server that connects AI assistants to GitLab with intelligent context awareness, URL deduction, and specialized tools for projects, issues, MRs, pipelines, and repository operations. Works with Claude Desktop, Amazon Q, Cursor

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio 13shivam-gitlab-mcp-server docker run --rm -i --env GITLAB_URL=https://gitlab.com --env GITLAB_TOKEN=your_token_here --env MCP_TRANSPORT=stdio --env GITLAB_TIMEOUT=30 --env GITLAB_SSL_VERIFY=false --env READ_ONLY_MODE=true --env CACHE_TTL=300 --env RATE_LIMIT_REQUESTS=100 --env RATE_LIMIT_WINDOW=60 --env LOG_LEVEL=INFO s13dc/gitlab-mcp-server:latest \
  --env CACHE_TTL="300" \
  --env LOG_LEVEL="INFO" \
  --env GITLAB_URL="https://gitlab.com" \
  --env GITLAB_TOKEN="your_token_here" \
  --env MCP_TRANSPORT="stdio" \
  --env GITLAB_TIMEOUT="30" \
  --env READ_ONLY_MODE="true" \
  --env GITLAB_SSL_VERIFY="false" \
  --env RATE_LIMIT_WINDOW="60" \
  --env RATE_LIMIT_REQUESTS="100"

How to use

EGMA: Enhanced GitLab MCP API Server is a Python-based MCP server that exposes 143+ specialized GitLab tools via the MCP protocol. Built on the official python-gitlab SDK, it enables AI assistants to perform read-only or constrained write operations against GitLab data, including projects, issues, merge requests, pipelines, and repository actions, with intelligent context handling, URL deduction, and caching for responsive interactions. Clients such as Claude Desktop or Amazon Q can connect to the server through the MCP transport (stdio) and leverage the tools through natural language queries. Use the provided tool registry to access analytics, search, code navigation, and project management workflows with contextual continuity across conversations.

How to install

Prerequisites

  • Docker (for the recommended containerized run) or Python 3.10+ for native development
  • GitLab Personal Access Token with read_api and read_repository scopes

Recommended (Containerized) Installation

  1. Ensure Docker is installed and running.
  2. Run the MCP server using the provided Docker command template:

{}

Notes:

  • Replace GITLAB_URL and GITLAB_TOKEN with your GitLab instance URL and a valid token.
  • Adjust READ_ONLY_MODE, CACHE_TTL, RATE_LIMIT_REQUESTS, and RATE_LIMIT_WINDOW as needed for your environment.

Alternative Local Development (Python)

  1. Clone the repository: git clone https://github.com/13shivam/gitlab-mcp-server.git
  2. Create and activate a virtual environment: python3 -m venv .venv source .venv/bin/activate # Windows: .venv\Scripts\activate
  3. Install the package in editable mode: pip install -e .
  4. Create and populate a .env file with your GitLab credentials (GITLAB_TOKEN, GITLAB_URL, etc.).
  5. Run the server: python -m src.server

Advanced (UV) user workflow

  • If you prefer UV for faster development, install UV and run similarly: uv venv source .venv/bin/activate uv pip install -e . python -m src.server

Additional notes

Environment tips:

  • Keep READ_ONLY_MODE=true in non-production environments to prevent unintended writes.
  • Tune CACHE_TTL and RATE_LIMIT_* values to balance latency and API usage against your GitLab instance.
  • Ensure GITLAB_SSL_VERIFY is set to false only if you are certain about your network security; otherwise keep it true.
  • When using MCP clients, ensure the client configuration points to the correct transport (stdio) and that the cwd is set to your server path if using local execution. Common issues:
  • Invalid or missing GITLAB_TOKEN: Verify token scopes and that the token is active.
  • Network/connectivity errors to GitLab: Check GITLAB_URL, firewall rules, and SSL verification settings.
  • Dependency issues: Use Python 3.10+ and install with dev extras if you plan to run tests or development tools.

Related MCP Servers

Sponsor this space

Reach thousands of developers