Skip to main content

Production-ready GitLab MCP server exposing projects, merge requests, pipelines, and discussions

Reason this release was yanked:

Broken release, use 0.2.2+

Project description

qodev-gitlab-mcp

A Model Context Protocol (MCP) server for GitLab integration. Exposes projects, merge requests, pipelines, discussions, issues, releases, and more through a standardized interface for AI assistants like Claude.

Installation

pip install qodev-gitlab-mcp

Or run directly with uvx:

uvx qodev-gitlab-mcp

Configuration

Set the following environment variables:

# Required
GITLAB_TOKEN=glpat-YOUR-TOKEN-HERE

# Optional (defaults to https://gitlab.com)
GITLAB_URL=https://gitlab.com

Claude Code

Add to your MCP configuration:

{
  "mcpServers": {
    "gitlab": {
      "command": "uvx",
      "args": ["qodev-gitlab-mcp"],
      "env": {
        "GITLAB_TOKEN": "your-token-here",
        "GITLAB_URL": "https://gitlab.com"
      }
    }
  }
}

Features

  • Merge request management (create, comment, merge, close, inline comments)
  • Pipeline monitoring with wait_for_pipeline tool
  • Issue tracking (create, update, close, comment)
  • Release management
  • CI/CD variable management
  • File uploads with image support
  • Automatic "current" project/branch detection via MCP workspace roots

Tools

The server exposes the following MCP tools:

Merge Requests

Tool Description
create_merge_request Create a new merge request
update_merge_request Update MR title, description, labels, assignees, reviewers
merge_merge_request Merge a merge request
close_merge_request Close a merge request (with optional comment)
comment_on_merge_request Leave a comment on a merge request
create_inline_comment Add an inline comment on a specific line in a MR diff
reply_to_discussion Reply to an existing discussion thread
resolve_discussion_thread Resolve or unresolve a discussion thread

Pipelines

Tool Description
wait_for_pipeline Wait for a pipeline to complete and return results
download_artifact Download a job artifact to local filesystem
retry_job Retry a failed CI/CD job

Issues

Tool Description
create_issue Create a new issue
update_issue Update an existing issue
close_issue Close an issue
comment_on_issue Leave a comment on an issue

Releases

Tool Description
create_release Create a new release with tag, description, and assets

CI/CD Variables

Tool Description
set_project_ci_variable Create or update a CI/CD variable (upsert)

Files

Tool Description
upload_file Upload a file to GitLab for embedding in issues or MRs

All tools support project_id="current" to auto-detect the project from the current working directory. Merge request tools also support mr_iid="current" to detect the MR for the current branch.

Resources

The server exposes the following read-only MCP resources:

Projects

Resource URI Description
gitlab://projects/ List all accessible projects
gitlab://projects/{project_id} Get project details

Merge Requests

Resource URI Description
gitlab://projects/{project_id}/merge-requests/ List open merge requests
gitlab://projects/{project_id}/merge-requests/{mr_iid} Full MR overview (metadata, discussions, changes, commits, pipeline, approvals)
gitlab://projects/{project_id}/merge-requests/{mr_iid}/status Lightweight merge-readiness check
gitlab://projects/{project_id}/merge-requests/{mr_iid}/discussions MR discussion threads
gitlab://projects/{project_id}/merge-requests/{mr_iid}/changes MR diff/changes
gitlab://projects/{project_id}/merge-requests/{mr_iid}/commits MR commit history
gitlab://projects/{project_id}/merge-requests/{mr_iid}/approvals MR approval status
gitlab://projects/{project_id}/merge-requests/{mr_iid}/pipeline-jobs Jobs from the MR's latest pipeline

Pipelines & Jobs

Resource URI Description
gitlab://projects/{project_id}/pipelines/ List recent pipelines
gitlab://projects/{project_id}/pipelines/{pipeline_id} Get pipeline details
gitlab://projects/{project_id}/pipelines/{pipeline_id}/jobs List jobs in a pipeline
gitlab://projects/{project_id}/jobs/{job_id}/log Full job log output
gitlab://projects/{project_id}/jobs/{job_id}/artifacts List job artifacts
gitlab://projects/{project_id}/jobs/{job_id}/artifacts/{path} Read a specific artifact file

Issues

Resource URI Description
gitlab://projects/{project_id}/issues/ List open issues
gitlab://projects/{project_id}/issues/{issue_iid} Get issue details
gitlab://projects/{project_id}/issues/{issue_iid}/notes Get issue comments

Releases

Resource URI Description
gitlab://projects/{project_id}/releases/ List all releases
gitlab://projects/{project_id}/releases/{tag_name} Get release by tag

CI/CD Variables

Resource URI Description
gitlab://projects/{project_id}/variables/ List CI/CD variables (metadata only, values hidden)
gitlab://projects/{project_id}/variables/{key} Get variable metadata by key

Help

Resource URI Description
gitlab://help Server capabilities and usage guide

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

qodev_gitlab_mcp-0.2.1.tar.gz (132.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

qodev_gitlab_mcp-0.2.1-py3-none-any.whl (44.1 kB view details)

Uploaded Python 3

File details

Details for the file qodev_gitlab_mcp-0.2.1.tar.gz.

File metadata

  • Download URL: qodev_gitlab_mcp-0.2.1.tar.gz
  • Upload date:
  • Size: 132.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for qodev_gitlab_mcp-0.2.1.tar.gz
Algorithm Hash digest
SHA256 3b5b2b5f64a11d6806721e79119e77d62e71f4e1792a7594a13ef01076b60c1f
MD5 e0114aac20f0143d3076ccd68f0c2650
BLAKE2b-256 bacce48dd625bf24223e01be9a4841a162cf893b3b1b6212a3d9d716189ed424

See more details on using hashes here.

Provenance

The following attestation bundles were made for qodev_gitlab_mcp-0.2.1.tar.gz:

Publisher: publish.yml on qodevai/gitlab-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file qodev_gitlab_mcp-0.2.1-py3-none-any.whl.

File metadata

File hashes

Hashes for qodev_gitlab_mcp-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b0bc805a99c6496661fb13d338b86c67c92686e47998bc79ac03dd8f6a2ae033
MD5 1fde4fef3cb7f4a47bcc1a732a95dc47
BLAKE2b-256 7ac9bfb2306138ed7c6bcd94d123deebc89a6b52df87241a8aef68995d04b4ac

See more details on using hashes here.

Provenance

The following attestation bundles were made for qodev_gitlab_mcp-0.2.1-py3-none-any.whl:

Publisher: publish.yml on qodevai/gitlab-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page