Skip to main content
Glama

cancel_job

Cancel a pending or running operation by providing its operation ID. The operation is marked cancelled, stops polling, and any in-flight work is discarded.

Instructions

Cancel a pending or running job/operation. Flips it to cancelled and stops it from being polled. Note: work already in flight may still finish server-side, but its result is discarded. Already-finished jobs cannot be cancelled. Pass the operationId (from list_jobs pollUrl / get_job).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
brandIdNoBrand ID; defaults to active brand
operationIdYesOperation ID to cancel
Behavior5/5

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

No annotations are provided, so the description carries the full burden. It discloses side effects: flips to cancelled, stops polling, in-flight work may finish but result discarded, finished jobs cannot be cancelled. This is thorough and adds significant 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?

Three sentences, front-loaded with verb and object, then consequences, then usage tip. Every sentence contributes and there is no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a cancellation tool, the description addresses lifecycle states and polling behavior. It does not describe the response format, but no output schema exists; given the simplicity, this is acceptable. The optional brandId is left to the schema, which is sufficient.

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?

The input schema covers 100% of parameters with descriptions, so the baseline is 3. The description adds context for operationId source ('from list_jobs pollUrl / get_job') but no new semantics beyond schema. brandId is only described in the schema.

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 clearly states the tool's function: 'Cancel a pending or running job/operation' with specific behavior ('Flips it to `cancelled` and stops it from being polled'). It distinguishes from sibling tools like cancel_post by targeting jobs/operations.

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?

Provides clear context: applies to pending or running jobs, not already-finished ones. Instructs to pass operationId from list_jobs pollUrl or get_job. Lacks explicit alternative names, but the context implies this is the dedicated cancellation tool for operations.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/bitsandtea/postking-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server