GitLab MCP ServerServer

ZephyrDeng
GitHub
GitLabAPI IntegrationDeveloper Tools

Loading subscription status...

💡 Description

A Model Context Protocol server that enables AI assistants to interact with GitLab repositories, allowing tasks like managing merge requests, searching projects, and creating comments through RESTful API integration.

📝 JSON Entries

{
  "mcpServers": [
    {
      "@zephyr-mcp/gitlab-restful-api": {
        "args": [
          "-y",
          "@zephyr-mcp/gitlab-restful-api"
        ],
        "command": "npx"
      }
    }
  ]
}

🛠️ Tools

GitlabRestfulApiTool

Features

  • Integration with GitLab via RESTful API
  • Intelligent field mapping
  • Field filtering system
  • Support for multiple operations

💬 Example Queries

  • // Get current user tasks await mcp.runTool("gitlab_restful_api", { operation: "getCurrentUserTasks", includeAssignedMRs: "true", includeReviewMRs: "true", fields: ["id", "name", "username", "assigned_mrs"] });
  • // Search user and their projects await mcp.runTool("gitlab_restful_api", { operation: "searchUserWithProjects", username: "张三", fields: ["id", "name", "username", "project_names"] });
  • // Search project for details await mcp.runTool("gitlab_restful_api", { operation: "searchProjectWithDetails", projectName: "前端项目", fields: ["id", "name", "description", "branch_names", "member_names"] });
  • // Create a comment on a merge request await mcp.runTool("gitlab_restful_api", { operation: "createMRComment", projectId: "group/project-name", mergeRequestId: 123, comment: "代码看起来不错,已批准!", fields: ["id", "body", "created_at"] });
  • // Accept a merge request await mcp.runTool("gitlab_restful_api", { operation: "acceptMR", projectId: "group/project-name", mergeRequestId: 789, mergeOptions: { shouldRemoveSourceBranch: true }, fields: ["id", "state", "title"] });