# GitLab MCP

> GitLab MCP connects your AI agent directly into your entire DevSecOps workflow. You can manage projects, track issues, monitor merge requests, and audit CI/CD pipelines—all through natural conversation. Use this MCP on Vinkius to get a single pane of glass view of your codebase's health without opening any dashboards.

## Overview
- **Category:** industry-titans
- **Price:** Free
- **Tags:** ci-cd, pipeline-automation, version-control, merge-requests, devsecops

## Description

Think about how much time you lose clicking between project boards, issue trackers, and pipeline status pages. This MCP lets your AI client bypass the manual dashboard navigation entirely. It connects directly to your GitLab instance, making everything from core repository files to user profiles available through natural chat commands.

Need to check if a feature branch is ready for review? Ask your agent instead of navigating to the Merge Request section. Want to audit who has access to which project? Your agent can pull that data instantly. Whether you're checking build failures using the list_project_pipelines tool or opening an issue with create_project_issue, the process happens in conversation. By connecting through Vinkius, your AI client gains immediate access to this massive catalog of tools, letting you manage complex development lifecycles from one spot.

## Tools

### verify_api_connection
Checks if your AI agent has successfully connected and authenticated with GitLab.

### create_project_issue
Opens a new issue in a specific project using the chat interface.

### get_repository_file
Reads and retrieves the actual text content of any file within your repository.

### get_my_gitlab_profile
Fetches detailed information about the user identity currently logged into GitLab.

### create_merge_request
Initiates a new merge request between specified branches, requiring you to provide a title.

### get_merge_request
Retrieves all the current details for one specific merge request using its public MR number.

### list_branches
Lists every branch that exists inside a given project repository.

### list_project_members
Shows all user accounts who are listed as members of the project.

### get_project_details
Gets high-level metadata about a specific GitLab project, like its name and ID number.

### list_visible_groups
Lists all groups that your AI agent has access to view within the instance.

### list_project_issues
Pulls a list of existing issues related to a specific project.

### list_merge_requests
Lists all open and closed merge requests associated with a project.

### list_project_pipelines
Retrieves the list of CI/CD pipelines that have run for a given project.

### list_project_forks
Lists all copies or forks of the main repository within your instance.

### list_visible_projects
Displays a list of all projects that are accessible to your AI agent.

### search_gitlab_global
Runs a powerful search query across the entirety of GitLab for users, issues, or projects.

## Prompt Examples

**Prompt:** 
```
List the last 5 open merge requests for project 'my-group/my-app'.
```

**Response:** 
```
Retrieving merge requests... I found 5 recent open MRs, including 'Fix auth bug' and 'Add new dashboard'. Would you like the details for any of them?
```

**Prompt:** 
```
Check the status of the latest pipelines for project ID '12345'.
```

**Response:** 
```
Fetching pipelines... The latest pipeline for project 12345 'Success' 10 minutes ago. Previous pipeline 'Failed' due to a linting error.
```

**Prompt:** 
```
Search GitLab for issues containing 'security patch'.
```

**Response:** 
```
Searching issues... I found 3 issues matching 'security patch', including 'Patch for CVE-2024-001' in the 'Infra' project. Would you like to see the description?
```

## Capabilities

### View and Manage Project Details
List all accessible projects or fetch deep configuration metadata for a specific project using get_project_details.

### Track Development Artifacts
Read the contents of files within any repository, list available branches (list_branches), and monitor fork activity with list_project_forks.

### Oversee Issue and Review Status
List open issues or merge requests, track their status changes using list_project_issues, and programmatically create new records via create_project_issue or create_merge_request.

### Monitor Deployment Health
Get a list of CI/CD pipelines (list_project_pipelines) to check build status and view the most recent pipeline results.

### Search Across the Instance
Perform powerful, global searches across projects, users, issues, and other development artifacts using search_gitlab_global.

## Use Cases

### Finding out why a feature broke in production
A DevOps Engineer needs to know if the latest deployment failed. Instead of logging into the CI/CD dashboard, they prompt their agent: 'What was the result of the last pipeline for Project X?'. The MCP uses list_project_pipelines and tells them whether it succeeded or failed due to a specific error.

### Getting review status on a critical bug fix
A developer finishes a hotfix branch. They ask their agent to check the MR details using get_merge_request, which immediately shows if it's waiting for approval or if testing is still needed.

### Auditing project access rights
A Project Manager needs to confirm who has permissions on a sensitive repository. They use list_project_members and get_my_gitlab_profile to verify the team structure without needing admin dashboard access.

## Benefits

- Check status without clicking: Instead of manually checking the CI/CD dashboard, you ask your agent for a list of project pipelines. It tells you build success or failure instantly.
- Audit code bases fast: If you need to understand how a feature works, use get_repository_file to read the contents of specific files right from chat, instead of navigating the file tree.
- Keep track of everything: Use search_gitlab_global to pull up an issue or project name across all groups. It's faster than running manual keyword searches on multiple dashboards.
- Automate basic tasks: Don't manually create tickets; use create_project_issue to open a new issue and assign it directly from your chat interface.
- Understand the scope: With list_visible_projects, you get an instant map of all development work happening across your entire organization.

## How It Works

The bottom line is you tell your AI what you need, and it executes the complex API calls necessary to get that data back in plain English.

1. Subscribe to this MCP via Vinkius and enter your GitLab Base URL and Personal Access Token.
2. Your AI client authenticates the connection, giving it permission to read project metadata and initiate actions on your behalf.
3. You prompt your agent with a natural language request, like 'What's the status of the latest pipeline for Project X?' and receive immediate answers.

## Frequently Asked Questions

**How do I list all available projects using GitLab MCP?**
You use the list_visible_projects tool to get a comprehensive list of every project accessible through your account. This helps you figure out which scope you need for further actions.

**Can I create an issue with GitLab MCP?**
Yes, the create_project_issue tool lets you open new issues in a target project directly via chat, saving you the steps of navigating to the issue board and filling out forms.

**Does GitLab MCP help me track merge requests?**
Absolutely. You can list all open merge requests with list_merge_requests or get specific details for one using get_merge_request, letting you track its status without manual dashboard checks.

**What if I need to check a file's content? Is it part of the MCP?**
Yes. The get_repository_file tool allows your agent to read and retrieve the actual contents of any specified file within any repository, so you don't have to manually download code snippets.

**Can GitLab MCP find global information across my company?**
The search_gitlab_global tool executes powerful searches across all projects, issues, and users in your instance. This is much broader than standard project-level searching.