Skip to main content
Glama

Cancel generation

cancel_generation
Destructive

Cancel a queued generation (refunded). A render already running at the provider may not be cancellable.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "generation_id": "<generation_id>"
    },
    "name": "cancel_generation"
  }
}

Input Schema

NameRequiredDescriptionDefault
generation_idYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

No schema history has been recorded yet.

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, so the mutation profile is known; the description adds the valuable detail that credits are refunded and that provider-side renders may be uncancellable. It still omits whether the call is idempotent and what the resulting generation state becomes, which matters for a destructive action.

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?

Two short sentences with the primary action front-loaded and the caveat second; nothing is wasted. The parenthetical refund note is slightly compressed but still readable.

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?

An output schema exists so return values need not be explained, and the description covers the key behavioral caveat and side effect. For a destructive single-parameter tool it is still thin: no idempotency, no post-cancel state, and no identification of the required generation_id.

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

Parameters2/5

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

There is one required parameter (generation_id) with 0% schema description coverage, so the description carries the full burden and says nothing about the parameter. It does not clarify what identifier is expected, where it comes from (e.g., list_generations or generate output), or what happens with a stale or already-cancelled id.

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?

Names a specific verb and resource ('Cancel a queued generation') and scopes it to queued work, which is concrete enough to act on. It does not distinguish itself from siblings such as get_generation or wait_for_generation, so an agent must infer that this is the only cancellation path.

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?

The parenthetical 'queued' and the note about already-running renders imply when this tool will and will not succeed, which is useful guidance. However, it never states an explicit precondition, an alternative for renders that cannot be cancelled, or what to do if cancellation fails.

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.

Resources