Skip to main content
Glama

Comment on a pull request about threats

comment_threat_on_change
Destructive

For a completed pipeline scan of a pull request: post, or update, one comment per threat whose linked code the pull request changes. A re-run with nothing changed makes no calls. Returns each comment's status (posted, updated, skipped with the reason, failed). Public repositories are skipped with the reason 'public repository'. Error codes: permission_missing, role_missing, destination_not_found, already_filed, rate_limited, assignee_unmapped, no_route, no_entry, not_found, invalid, no_company, tracker_error, filed_unrecorded, outcome_unknown, not_attempted, not_configured, tracker_unreachable, unsupported. filed_unrecorded and outcome_unknown mean the ticket may already exist in the tracker; not_attempted means the item was not sent.

Input Schema

NameRequiredDescriptionDefault
scan_idYesPipeline scan id (uuid)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.4/5.0
Behavior5/5

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

Well beyond the annotations (readOnlyHint=false, destructiveHint=true, openWorldHint=true), it discloses idempotency, the public-repository skip with its literal reason string, the per-comment return statuses (posted/updated/skipped/failed), and a full error-code vocabulary. It even disambiguates the ambiguous codes: 'filed_unrecorded and outcome_unknown mean the ticket may already exist in the tracker; not_attempted means the item was not sent.'

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?

Core behavior, skip rules, and return semantics are front-loaded in the first two sentences, with the error vocabulary batched at the end where it belongs. The error-code enumeration is long but most of it is load-bearing; a couple of the codes receive no gloss and pad the list slightly.

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?

With no output schema, the description correctly takes on the burden of explaining return values, and it does so by enumerating per-comment statuses and the reason strings for skips and failures. Combined with the destination rules and error glossary, an agent has everything needed to call and interpret this tool.

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% for the single scan_id parameter, so the schema already carries the parameter documentation and 3 is the baseline. The description adds only that the id must reference a completed pipeline scan of a pull request, a modest amount of context beyond the schema's 'Pipeline scan id (uuid)'.

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 states a precise verb pair (post, or update) against a precisely scoped resource (one comment per threat whose linked code the pull request changes), plus the precondition of a completed pipeline scan. That scope distinguishes it cleanly from siblings such as file_threat_tickets and get_threat_tickets without needing to name them.

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?

It gives a clear activation condition ('For a completed pipeline scan of a pull request') and calls out idempotent re-run behavior ('a re-run with nothing changed makes no calls'), which is exactly the guidance an agent needs before retrying. It does not, however, name an alternative tool or state when not to use this one versus the ticket-filing siblings.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.