Atlas / MCP servers / mehmetakinn / GitLab Code Review

GitLab Code ReviewSAFE

mcp/mehmetakinn/gitlab-code-review
Verdict
SAFE
Grade
B
Trust score
89 /100
Exposed tools
8 1r · 7w · 0d
Transport
stdio
License
MIT
Stars
45
01

Overview

From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.

[](https://www.python.org/downloads/) [](https://opensource.org/licenses/MIT)

This project is forked from cayirtepeomer/gerrit-code-review-mcp and adapted for GitLab integration.

An MCP (Model Context Protocol) server for integrating AI assistants like Claude with GitLab's merge requests. This allows AI assistants to review code changes directly through the GitLab API.

Features

  • Complete Merge Request Analysis: Fetch full details about merge requests including diffs, commits, and comments
  • File-Specific Diffs: Analyze changes to specific files within merge requests
  • Version Comparison: Compare different branches, tags, or commits
  • Review Management: Add comments, approve, or unapprove merge requests
  • Project Overview: Get lists of all merge requests in a project

Installation

Prerequisites

Quick Start

  1. Clone this repository:
git clone https://github.com/mehmetakinn/gitlab-mcp-code-review.git
cd gitlab-mcp-code-review
  1. Create and activate a virtual environment:
python -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
  1. Install dependencies:
pip install -r requirements.txt
  1. Create a .env file with your GitLab configuration (see .env.example for all options):
# Required
GITLAB_TOKEN=your_personal_access_token_here

# Optional settings
GITLAB_HOST=gitlab.com
GITLAB_API_VERSION=v4
LOG_LEVEL=INFO

Configuration Options

The following environment variables can be configured in your .env file:

Read from source at commit bd2815d02af3OBSERVED · 2026-10-08
Advertisement
02

Connect

Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control. Replace the environment placeholders with a token scoped to the least it needs.

claude-code
claude mcp add gitlab-mcp-code-review --env GITLAB_TOKEN=${GITLAB_TOKEN} -- uvx gitlab-mcp-code-review
claude-desktop
{
  "mcpServers": {
    "gitlab-mcp-code-review": {
      "command": "uvx",
      "args": [
        "gitlab-mcp-code-review"
      ],
      "env": {
        "GITLAB_TOKEN": "${GITLAB_TOKEN}"
      }
    }
  }
}
03

Exposed tools (8)

1 read · 7 write · 0 destructive.

ToolRiskDescription
add_merge_request_commentwrite
approve_merge_requestwrite
compare_versionsread
fetch_commit_diffwrite
fetch_merge_requestwrite
fetch_merge_request_diffwrite
get_project_merge_requestswrite
unapprove_merge_requestwrite
04

Trust audit

SAFEgrade B · trust 89/100 Nothing in the source contradicts what it says it does. Grade A is reserved for packages that have also passed the behavioural sandbox.

LayerWhat it checksResult
L0Provenance & inventoryPASS
L1Static analysis of the codePASS
L2Instruction surface (what it tells the agent)PASS
L3Class-specific surfacePASS
L4Behavioural (sandbox)SKIPPED

What the source does

Filesystem
none-observed
Network
declared (2 observation(s))
Shell
none-observed
Dependencies
not all pinned
Secrets in source
none-found

Findings (4)

LOWInventory / provenance · inv.hidden_file · CWE-1104
.flake8
.flake8
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWInventory / provenance · inv.hidden_file · CWE-1104
.pre-commit-config.yaml
.pre-commit-config.yaml
Why it matters. hidden member outside the usual dotfiles
Fix. review its purpose
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
requirements-dev.txt
pytest, pytest-cov, black, isort, mypy, pre-commit
Why it matters. 6 requirement(s) not pinned with ==
Fix. pin exact versions
LOWSupply chain · supply.unpinned · CWE-829, CWE-1357
requirements.txt
mcp, python-dotenv, requests
Why it matters. 3 requirement(s) not pinned with ==
Fix. pin exact versions

Gates applied: no_behavioural_pass.

Audited 2026-10-08 · audit v0.4.1 · source sha bd2815d02af3full audit observations/trust-audit/mcp-server/mehmetakinn__gitlab-code-review.json · Report an issue / request a re-scan
05

Audit history

Every audit this server has had. A grade with a past is a grade somebody is still checking.

DateSourceVerdictGradeScoreChange
2026-10-08bd2815d02af3SAFEB89first audit
06

Questions

What tools does GitLab Code Review expose?

8 in total: 1 read-only, 7 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.

Is GitLab Code Review safe to connect to an agent?

The audit found nothing in the source that contradicts what it says it does, and graded it B (89/100). Grade A is held back for packages that have also passed a sandboxed behavioural run, which is why a clean server reads B.

What credentials does GitLab Code Review need?

It reads GITLAB_TOKEN from the environment. Give it a token scoped to the least it needs — an agent that can be talked into calling a tool can be talked into calling it with your credentials.

How does GitLab Code Review run?

It speaks stdio, so it runs as a local process your client starts. It is published on PyPI as gitlab-mcp-code-review.

How current is this page?

The grade is for one exact copy of the source (bd2815d02af3), read on 2026-10-08. The repository is watched and re-audited when it changes.

Advertisement