Skip to main content
Glama

get_merge_request_changes

Inspect GitLab merge request code diffs and modified files. Filter by file, prune lockfiles, or return a token-saving summary of changes.

Instructions

Inspect code diffs and modified files in an MR (supports token-saving summary, file filtering, and lockfile pruning)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_pathNoFilter diffs to a specific single file path
project_idYesProject numeric ID (e.g. 31) or namespace path (e.g. 'group/project-name'). URL-encoding is handled automatically.
summary_onlyYesIf true, returns only the manifest of changed files without raw diff strings (saves tokens)
max_diff_linesYesMaximum lines of diff per file to return before truncating (default: 500)
ignore_lockfilesYesIf true, automatically filters out dependency lockfiles (e.g. package-lock.json, poetry.lock)
merge_request_iidYesMerge request IID (e.g. 5 for !5) to get diffs for

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It does disclose useful behavioral traits (token-saving summary mode, file filtering, lockfile pruning) and 'Inspect' implies a read operation, but it says nothing about return format, truncation semantics, or pagination behavior beyond what the schema already encodes.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single front-loaded sentence with no filler; the capabilities are packed into one compact parenthetical. Efficient, though the parenthetical is a slight feature dump rather than prose that prioritizes.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 6-parameter, 5-required read tool with no output schema, the description is thin: it never describes the shape of the returned diffs/manifest or how filtering, truncation, and pruning interact. The fully documented schema compensates for parameters, but return-value expectations are left implicit.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so every parameter is already documented in the schema. The description's parenthetical (summary, file filtering, lockfile pruning) merely restates those parameters without adding syntax, formats, or interaction rules, so baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Inspect code diffs and modified files in an MR'), which an agent can clearly separate from siblings like get_merge_request or list_merge_request_discussions. It stops short of explicitly naming the sibling it complements, so it is clear but not sibling-differentiating in the strongest sense.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is implied by the resource (viewing an MR's diffs) and the parenthetical hints at the token-saving path, but there is no explicit when-to-use vs alternative (e.g. get_merge_request, create_diff_discussion) or any prerequisite guidance. Adequate but with clear gaps.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.