Skip to main content
Glama

Cancel a job

cancel_job
Destructive

Free. Cancels your own running render, song analysis or My audio listening and refunds whatever it charged (a render that already landed parts keeps only those). Never charges. A cancelled job still counts toward this token's daily limit until midnight UTC. AI clips, music tracks and voiceovers can't be cancelled once started.

Args: job_id: r_ (render), a_ (song analysis) or au_ (My audio).

Returns: {ok, cancelled, best_effort, message}: best_effort true = it is stopping; poll get_job until it ends.

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": {
      "job_id": "<job_id>"
    },
    "name": "cancel_job"
  }
}

Input Schema

NameRequiredDescriptionDefault
job_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Goes well beyond the destructiveHint annotation: refund semantics, that a partially landed render keeps delivered parts, that it never charges, that the job still consumes the daily quota until midnight UTC, and the best_effort stopping state. These are exactly the consequences an agent needs before invoking a destructive operation.

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 cost/effect statement, then constraints, then structured Args/Returns blocks. There is minor redundancy between 'Free.' and 'Never charges', but no sentence is wasted.

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?

No output schema exists, so the description supplies the return shape ({ok, cancelled, best_effort, message}) and explains how to interpret best_effort. Combined with the documented limits and exclusions, an agent has everything needed to call and follow up correctly.

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

Parameters5/5

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

Schema coverage is 0% and job_id has no description, so the description carries the full burden. It supplies the ID prefix convention (r_, a_, au_) that determines whether the job is cancellable at all, which is meaning the schema alone does not convey.

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 (cancels) plus the exact resources covered (your own render, song analysis, My audio listening) and scopes ownership with 'your own'. An agent can tell this apart from generation siblings such as generate_video_clip or get_job without opening the schema.

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?

Gives explicit when-not guidance ('AI clips, music tracks and voiceovers can't be cancelled once started') and tells the agent what to do after cancelling (poll get_job until it ends). It does not explicitly contrast with wait_for_job or say what to do if the job is already finished, but the context needed to choose this tool is clear.

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