home / mcp / gitlab mcp server
Fork with more tools and streaming http
Configuration
View docs{
"mcpServers": {
"atla-digital-mcp-gitlab": {
"url": "http://host.docker.internal:3001/mcp",
"headers": {
"PORT": "3000",
"NODE_ENV": "development",
"LOG_LEVEL": "info",
"X-GitLab-URL": "https://your-gitlab-instance.com",
"AXIOS_TIMEOUT": "30000",
"X-GitLab-Token": "YOUR_GITLAB_TOKEN",
"SESSION_MAX_AGE": "604800000",
"ENABLE_DETAILED_ERRORS": "false",
"ENABLE_REQUEST_LOGGING": "true",
"SESSION_CLEANUP_INTERVAL": "300000"
}
}
}
}You have an MCP Server that lets you interact with GitLab from a programmable interface. It provides structured workflows, code review actions, issue and project management, and full CI/CD integration, enabling you to automate and streamline GitLab development tasks with guided steps and consistent practices.
You connect an MCP client to the GitLab MCP Server and start performing GitLab operations through guided, workflow-driven commands. Typical tasks include listing projects, inspecting merge requests, retrieving diffs, adding comments or internal notes to reviews, and triggering pipelines. When paired with an MCP workflow, you follow established steps for each operation, ensuring consistency and traceability across your development process.
Choose your preferred deployment method and follow these steps.
# Option 1: Using Pre-built Docker Image (Recommended)
# Pull the latest image
docker pull ghcr.io/atla-digital/mcp-gitlab:latest
# Run the container
docker run -d -p 3001:3000 --name mcp-gitlab-server ghcr.io/atla-digital/mcp-gitlab:latestAccess the MCP endpoint at the address below to configure clients and automation scripts.
# Option 2: Using Docker Compose
# docker-compose.yml
services:
mcp-gitlab:
image: ghcr.io/atla-digital/mcp-gitlab:latest
ports:
- "3001:3000"
restart: unless-stopped
```
Then start the service with the following command.You can configure access and behavior through environment variables and explicit MCP connection endpoints. The server supports HTTP transport for remote access and can be connected via a standard MCP URL provided by your client tooling.
If you plan to connect Claude Code or similar tooling, you will use an HTTP MCP URL and pass necessary headers for GitLab access, such as your GitLab API token and GitLab URL. The server exposes an endpoint at the MCP path you deploy.
Configure the MCP client to point at the serverβs MCP endpoint and provide any required authentication headers. Typical integration steps include setting the MCP URL, the GitLab API token, and the GitLab instance URL. The server supports standard HTTP-based MCP connections and maintains session state for long-running workflows.
Keep the MCP endpoint reachable only to your trusted tooling and team members. Use access controls and tokens to guard GitLab credentials. Regularly rotate tokens and monitor logs for unusual activity. The server offers structured logging and error handling to assist with debugging and maintenance.
If you cannot connect to the MCP endpoint, verify that the container is running and that port 3001 is accessible from your client. Check that your GitLab token is valid and has the required API scopes. Review logs for authentication or network errors and confirm that the MCP URL matches your deployment.
Retrieve details for a specific merge request in a given project.
Fetch the changes/files touched by a merge request.
Create a line-specific discussion or comment on a merge request.
Query the current step in an MCP-Workflow guided process.
List projects accessible with the configured GitLab API token.