Skip to main content
Glama

Cancel an aictrl workflow run

cancel_workflow_run
Destructive

Request cancellation of a queued, running, pausing, or paused workflow run; a run in any other status is rejected with conflict. Waiting and queued nodes are cancelled immediately. If nodes are still running, the run moves to cancelling while that work drains and becomes cancelled later; call get_workflow_run to observe completion. Cancellation does not promise to interrupt running work immediately and does not roll back effects that already completed. Only the run owner or an organization admin may cancel.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
reasonNoOptional cancellation reason.
run_idYesWorkflow run ID returned by start_workflow or list_workflow_runs.
organization_idYesAICtrl organization ID returned by list_organizations.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / run_id / description
      Previous value: -"Workflow run ID returned by start_workflow."New value: +"Workflow run ID returned by start_workflow or list_workflow_runs."
  2. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Despite destructiveHint=true, the description adds substantial context: nodes in waiting/queued are cancelled immediately, running nodes drain to a 'cancelling' state, cancellation is not an immediate interrupt, and completed effects are not rolled back. It also states the authorization rule (owner or org admin). This is exactly the kind of nuance annotations cannot carry.

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, each front-loaded with a key behavioral fact. No repetition of schema fields, no boilerplate. Every sentence earns its place.

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?

Covers eligibility, immediate vs deferred cancellation semantics, non-interrupt caveat, no-rollback caveat, observability path, and authorization. With no output schema, this is complete for an agent to call correctly and interpret the result.

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 schema already documents all three parameters including the reason field. The description adds no parameter-level detail beyond what is in the schema, so baseline 3 is appropriate.

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 (cancel) and resource (workflow run) and enumerates the statuses from which cancellation is valid. Distinguishes clearly from sibling get_workflow_run, which is only referenced for observation.

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?

Explicitly says which statuses are acceptable and that any other status is rejected with conflict. Also names get_workflow_run as the way to observe completion, giving the alternative for a follow-up need.

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