What is GitLab MCP Server?
A Model Context Protocol (MCP) server that allows AI assistants (like Claude) to interact with GitLab repositories. It provides comprehensive capabilities for managing projects, issues, merge requests, comments, labels, milestones, time tracking, and more. This enhanced implementation includes additional endpoints and improved error handling compared to the original MCP GitLab server.
How to use GitLab MCP Server?
Install globally (npm install -g @piatra-open-source/gitlab-mcp-server) or as a project dependency. Set the required environment variable GITLAB_PERSONAL_ACCESS_TOKEN (and optionally GITLAB_API_URL for self-managed instances). Run the server with gitlab-mcp-server or embed it in your application using the Node.js child process API.
Key features of GitLab MCP Server
- Project creation, update, deletion, forking, and search
- File operations: fetch, create/update, commit multiple files
- Issue management with filtering and time tracking
- Full CRUD for issue comments
- Label management: create, update, delete, attach/detach
- Milestone retrieval and creation
- User assignment and unassignment on issues
- Issue linking (relates_to, etc.) and link deletion
Use cases of GitLab MCP Server
- Create a project in a specific GitLab group with custom visibility
- Retrieve open issues with time tracking statistics
- Add spent time to an issue and update its attributes
- Manage comments (create, update, delete) on issues
- Create and assign labels and milestones to issues
- Link, unlink, and manage relationships between issues
- Automate repository administration (fork, delete, change visibility)
コメント