Skip to main content
Glama

Cancel one unfinished job

cancel_job
DestructiveIdempotent

Stops one job that is pending or processing: it becomes cancelled, is not charged, and cannot be resumed; a render already under way may finish, but its result is discarded. A job that already finished is left as it is. Other jobs in its batch keep rendering; to stop them all use cancel_batch. A jobId that is not in this workspace returns Job not found. Needs batches:create on the connection and renders:create in the user's workspace role.

Input Schema

NameRequiredDescriptionDefault
jobIdYesJob ID from get_batch_jobs

Output Schema

NameRequiredDescriptionDefault
cancelledYesJobs this call cancelled; 0 when they had all finished
stoppedMessagesYesQueued renders removed before they started

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / jobId / pattern
      Added value: +"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$"
    • addedOutput schema / properties / cancelled / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / stoppedMessages / maximum
      Added value: +9007199254740991
  2. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Beyond annotations, the description explains that the job becomes cancelled, is not charged, cannot be resumed, and that an in-progress render may finish with its result discarded. It also covers the no-op behavior for finished jobs, the fact that sibling jobs keep rendering, the not-found error, and the required permissions.

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?

The description is front-loaded with the core effect and then efficiently layers edge cases, sibling behavior, errors, and permissions. Every sentence adds actionable information without repetition or filler.

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?

For a destructive, idempotent mutation with a simple single-parameter schema and an output schema, the description covers side effects, irreversibility, edge cases, error behavior, and authorization requirements. Nothing material is missing for correct invocation.

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%, so the jobId parameter and its UUID format are already fully documented in the schema. The description adds only that an unknown workspace jobId returns 'Job not found,' which is useful but does not substantially deepen parameter semantics.

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 specific verb and resource: stopping one pending or processing job. It clearly scopes the operation to a single job and explicitly distinguishes it from cancel_batch, which stops all jobs in a batch.

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

Usage Guidelines5/5

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

It explains exactly when to use this tool: for a job that is pending or processing but not one already finished. It also names the alternative cancel_batch for stopping the whole batch, giving the agent explicit routing guidance.

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