Skip to main content
Glama

cancel_extraction

Cancel a queued or running extraction job to release held credits. Queued jobs stop at once; running jobs stop after the current step and cost nothing.

Instructions

Cancel one job. A queued job stops at once; a running job stops after its current step. Credits held for a cancelled job are released. A cancelled job keeps no results and costs nothing. Safe to repeat; a job that already finished is left as it is. Returns the job record with its new status.

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_extraction"
  }
}

Input Schema

NameRequiredDescriptionDefault
job_idYesJob id: job.id from create_extraction, job_id from extract_now, or an id listed by list_extractions, get_batch, get_schedule or get_plan.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.1.1
    • addedInput schema / properties / job_id / description
      Added value: +"Job id: job.id from create_extraction, job_id from extract_now, or an id listed by list_extractions, get_batch, get_schedule or get_plan."
  2. First observedv0.1.0

TDQS

A4.5/5.0
Behavior5/5

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

With no annotations, the description carries the full behavioral burden and does so thoroughly: queued jobs stop immediately, running jobs stop after the current step, credits are released, no results are kept, no cost is incurred, repeat calls are safe, and finished jobs remain unchanged. It also states the return value.

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 action and then proceeds through state-specific behavior, idempotency, and return value. Every sentence adds operational information without repetition or waste.

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?

Although there are no annotations and no output schema, the description fully covers the mutation's side effects, safety profile, repeat-call behavior, and return shape. An agent has enough information to invoke it correctly and understand the consequences.

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%, so the job_id parameter is already fully documented in the schema. The description adds no additional meaning about the parameter beyond what the schema provides, which is the baseline for this dimension.

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 opens with a specific verb and resource: 'Cancel one job.' The scope word 'one' distinguishes it from a batch-cancel sibling, and an agent can identify the operation 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?

It gives clear context for when cancellation applies by explaining queued, running, and already-finished jobs. It does not explicitly route the agent to an alternative such as a batch cancellation tool, but the single-job scope is stated.

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