Skip to main content
Glama

Get a commit

get_commit
Read-only

Fetch a single commit by owner/repo/SHA to inspect its details and signature verification status, including verified, unverified, or unsigned.

Instructions

Get one commit (owner/repo/sha), slimmed to the same fields as list_commits. Use it to check whether a commit was signed and whether the forge could verify it: signature is "verified", "unverified" or "unsigned", with signer on a verified one and reason (a gpg.error.* key) on an unverified one. Note that Gitea reports gpg.error.no_gpg_keys_found both for a key it does not hold and for one it holds but has not verified, so that reason does not distinguish the two.

Input Schema

NameRequiredDescriptionDefault
shaYesThe commit to fetch. A full id is safest; a branch or tag name also resolves.
repoYesRepository name.
ownerYesRepository owner — user or organization.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.22.0

TDQS

A4.1/5.0
Behavior4/5

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

Annotations only declare readOnly and openWorld, so the description must carry the return-shape burden and largely does: it enumerates the signature states, names `signer` and `reason`, and flags a real caveat that gpg.error.no_gpg_keys_found is ambiguous. It stops short of stating error behavior for a missing sha or the rest of the returned fields.

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?

Front-loaded with the verb, resource, and keying triple, then the use case, then the caveat — a sensible ordering with no filler. The final sentence is long and dense but each clause carries distinct information.

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

Completeness4/5

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

For a read-only fetch with no output schema, the description covers the field set by reference ('slimmed to the same fields as list_commits') plus the signature-specific fields an agent most needs. Slight gap in not covering not-found behavior or fields unique to this view.

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 coverage is 100% and the schema already explains that a branch or tag name resolves as well as a full id. The description only restates the owner/repo/sha triple, adding no meaning beyond the schema, so the baseline 3 applies.

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?

States a specific verb and resource ('Get one commit') with the keying triple (owner/repo/sha) and a scoping note that ties it to list_commits. That contrast is enough for an agent to distinguish it from list_commits and the status-oriented siblings.

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?

Explicitly names the primary use case ('use it to check whether a commit was signed and whether the forge could verify it'), which is real routing guidance. It lacks explicit when-not/alternative phrasing (e.g., versus get_commit_statuses or list_commits for bulk), so it falls short of a 5.

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