Skip to main content
Glama

get_file_blame

Read-only

Get git blame information for a file, returning commit details (id, author, date, message) for each line or specified line range.

Instructions

Get git blame for a file at a given ref. Each entry maps a contiguous range of source lines to the commit that last changed them (id, author, authored_date, message). Use range_start/range_end to limit blame to specific lines.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idNoProject ID or complete URL-encoded path to project
file_pathYesThe full path of the file to blame, relative to repo root
refYesThe name of branch, tag or commit (required by GitLab blame API)
range_startNoFirst line of the blame range (inclusive, 1-based). Both range[start] and range[end] must be set together.
range_endNoLast line of the blame range (inclusive, 1-based). Both range[start] and range[end] must be set together.
Behavior5/5

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

Annotations indicate readOnlyHint=true, and the description adds detail on output structure (each entry maps lines to commit info) and usage of range parameters. No contradictions with annotations.

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

Conciseness5/5

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

Two sentences conveying essential information without redundancy. The description is front-loaded with the main action and then adds output details and parameter usage.

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

Completeness5/5

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

Given the simple read-only tool with annotations and full schema coverage, the description provides sufficient context about output format and optional parameters. No output schema exists, but the description compensates.

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

Parameters4/5

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

The input schema already documents parameters with 100% coverage. The description reinforces the use of range_start/range_end for limiting blame, adding value beyond the schema.

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

Purpose5/5

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

The description clearly states 'Get git blame for a file at a given ref', specifying the action, resource, and context. It distinguishes from sibling tools like get_commit or get_file_contents by focusing on blame.

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

Usage Guidelines4/5

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

The description explains optional range parameters for limiting lines but does not explicitly state when to use this tool over alternatives or provide exclusions. The context is clear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zereight/gitlab-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server