kopfrechner/gitlab-mr-mcp logo

kopfrechner/gitlab-mr-mcp

Free

无缝地与 GitLab 项目的 Issues 和 Merge Requests 交互。

FreeFree tier
Type
Open Source

About kopfrechner/gitlab-mr-mcp

GitLab MR MCP is a Model Context Protocol (MCP) server that enables AI agents to interact with GitLab repositories. It provides a set of tools for managing merge requests and issues, including listing open merge requests, fetching detailed information and comments, adding general or line-specific comments to merge requests, retrieving diffs, and getting issue details. The server also supports setting merge request titles and descriptions. Installation can be done manually via Node.js or automatically via Smithery for Claude Desktop. Configuration requires a GitLab personal access token and the GitLab host URL. This open-source project is ideal for automating code review workflows and integrating AI assistants with GitLab.

Key Features

List GitLab projects accessible with your token
List open merge requests in a project
Get detailed merge request information
Retrieve and add comments to merge requests (general and line-specific)
Get merge request diffs
Fetch issue details
Set merge request title and description
Easy installation via Smithery or manual setup
Uses the Model Context Protocol (MCP) for AI agent integration

Pros & Cons

Pros
  • Open-source and free to use
  • Provides a comprehensive set of tools for merge request and issue interactions
  • Supports line-specific commenting on diffs
  • Simple installation via Smithery or manual configuration
  • Uses the standardized Model Context Protocol for interoperability with MCP clients
  • Actively maintained with 130 commits and community contributions
Cons
  • Requires Node.js and a GitLab personal access token with API access
  • Only supports GitLab, not other version control platforms
  • Limited to merge request and issue interactions; does not cover other GitLab features like pipelines or wikis
  • May encounter 403 permissions errors if token scopes or user access are misconfigured

Best For

Automate code review workflows by having AI agents fetch MR details and add commentsIntegrate GitLab project management with AI assistants for status updates and notificationsStreamline the review process by automatically setting MR titles or descriptionsProvide developers with AI-driven insights on merge request diffs and discussions

FAQ

What is GitLab MR MCP?
It is an MCP (Model Context Protocol) server that allows AI agents to interact with GitLab repositories, specifically for managing merge requests and issues.
How do I install GitLab MR MCP?
You can install it automatically via Smithery using 'npx -y @smithery/cli@latest install @kopfrechner/gitlab-mr-mcp' or manually by cloning the repository and running 'npm install'.
What prerequisites are needed?
Node.js, a GitLab personal access token with API (or read_api) scope, and the GitLab host URL for your instance.
What tools are available?
Available tools include get_projects, list_open_merge_requests, get_merge_request_details, get_merge_request_comments, add_merge_request_comment, add_merge_request_diff_comment, get_merge_request_diff, get_issue_details, set_merge_request_title, and set_merge_request_description.
Can I add line-specific comments to code in a merge request?
Yes, the add_merge_request_diff_comment tool allows adding comments to specific lines in a file within a merge request diff.