Cancel agent run
cancel_agent_runCancels an open (Ready or Working) agent run: a Ready run is no longer offered to runners, and the runner working on a Working run sees it is no longer Working and stops. Cancelling also unlocks the issue for editing. Returns false when the run had already finished or was cancelled. Requires canEdit on the issue.
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": {
"runId": "<runId>"
},
"name": "cancel_agent_run"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| runId | Yes | The run's id, from list_agent_runs or get_issue's latestAgentRun. |