Skip to main content
Glama

opencode_cancel_run

Destructive

Cancel a running or queued agent run.

Instructions

Cancel a running or queued agent run.

Return Format

{"success": bool, "message": str, "data": {"job_id": str}}

Examples

opencode_cancel_run(job_id="abc123")

Input Schema

NameRequiredDescriptionDefault
job_idYesJob ID to cancel

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.2.11
    • changedOutput schema / (root)
      Previous value: -{
      -  "additionalProperties": true,
      -  "type": "object"
      -}New value: +null
  2. First observedv0.2.3

TDQS

A3.6/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 safety profile is known. The description adds a return format and example, but does not explain irreversibility, permissions, or what happens if the run is already completed or missing.

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 short and front-loaded with the action. The return format and example are compact and do not add unnecessary prose.

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 simple one-parameter destructive cancel tool, the description covers the action, return shape, and an example. It could be more complete by noting failure conditions or what happens when a run cannot be cancelled, but the core invocation context is present.

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%, and the sole job_id parameter is fully documented in the schema. The example shows an identifier format, but the description adds no semantic detail beyond the schema.

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?

The description states a specific verb and resource: cancel an agent run, scoped to running or queued runs. It is clear what the tool does, though it does not explicitly differentiate itself from sibling status/list tools.

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 phrase 'running or queued agent run' implies when cancellation is applicable, but there is no explicit guidance on when not to use it or which sibling to use to inspect run status first.

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