Skip to content

workflow_run_cancel

Stop a run that has not finished and expire its waits.

Tool

workflow_run_cancel

Stop a run that has not finished and expire its waits.

Stop a run that has not finished and expire its waits. A run that already succeeded, failed or was cancelled is refused.

Behavior

HTTP
POST /workflow/runs/cancel

Arguments

Name
Type
Required
Description
run_id
string
•
No description in the catalog.

Response

Field
Type
Always
Description
id
string
•
test
boolean
•
Started by `workflow_run_test` to watch the workflow work. It executed for real; the flag is what separates it from the Product’s own traffic.
status
string
•
version
number
•
ended_at
string
•
created_at
string
•
started_at
string
•
held_reason
string
—
Structured `{ code, tool|name, hint }` while `status` is `held`; null otherwise.
subject_key
string
•
Who this run is about, rendered once from the definition’s `subject` at run start and frozen. Null when the workflow declares no subject.
workflow_id
string
•
trigger_event_id
string
•
replay_generation
number
•

Try it

Stop a run that has not finished and expire its waits.

When to use

Stop a run that has not finished and expire its waits. A run that already succeeded, failed or was cancelled is refused.

Example

Ask your agent something like this:

Stop a run that has not finished and expire its waits.

The agent will invoke workflow_run_cancel with these arguments:

{
  "run_id": "<run_id>"
}

Esc

Start typing to search the docs.

↑↓navigate↵select