POST /v1/runs/{id}/cancel
Cancel a running or waiting run
POST
/v1/runs/{id}/cancel
Cancel a running or waiting run
Path Parameters
id
string
required
path
Run ID
Responses
200
OK
application/jsoncode
integer
data
object
executionState
object
finishedAt
string
id
string
isDustTest
boolean
isSimulation
boolean
organizationId
string
propValues
object
simulationForks
object[]
Array of:
chainId
integer
forkId
string
rpcUrl
string
simulationMode
string
sourceRunId
string
startedAt
string
status
string
Enum:
running, waiting, success, failure, cancelledtotalCu
number
triggerSource
string
triggeredBy
string
workflowDefinition
object
Definition is the full workflow graph to execute. Must contain a
"root" node with type "manual". All action nodes referenced in
children arrays must be present.
blockExpansions
object
Set on run snapshots only (not workflow DB)
inputSchema
object[]
Array of:
description
string
key
string
required
boolean
type
string
"string", "number", "boolean", "object", "array"
nodes
object
REQUIRED
workflowId
string
workflowVersion
integer
message
string
requestId
string
404
Not Found
409
Conflict
curl -X POST 'https://api.example.com/v1/runs/string/cancel' \ -H 'Authorization: Bearer YOUR_API_TOKEN'
const response = await fetch('https://api.example.com/v1/runs/string/cancel', { method: 'POST', headers: { "Authorization": "Bearer YOUR_API_TOKEN" }});const data = await response.json();console.log(data);
import requestsheaders = { 'Authorization': 'Bearer YOUR_API_TOKEN'}response = requests.post('https://api.example.com/v1/runs/string/cancel', headers=headers)print(response.json())
package mainimport ( "fmt" "io" "net/http")func main() { req, _ := http.NewRequest("POST", "https://api.example.com/v1/runs/string/cancel", nil) req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN") resp, _ := http.DefaultClient.Do(req) defer resp.Body.Close() result, _ := io.ReadAll(resp.Body) fmt.Println(string(result))}
200
Response
{ "code": 200, "data": { "executionState": "<object>", "finishedAt": "<string>", "id": "<string>", "isDustTest": true, "isSimulation": true, "organizationId": "<string>", "propValues": "<object>", "simulationForks": [ { "chainId": 123, "forkId": "<string>", "rpcUrl": "<string>" } ], "simulationMode": "<string>", "sourceRunId": "<string>", "startedAt": "<string>", "status": "running", "totalCu": 123, "triggerSource": "<string>", "triggeredBy": "<string>", "workflowDefinition": { "blockExpansions": "<object>", "inputSchema": [ { "description": "<string>", "key": "<string>", "required": true, "type": "<string>" } ], "nodes": "<object>" }, "workflowId": "<string>", "workflowVersion": 123 }, "message": "success", "requestId": "abc-123"}
API Playground
Try this endpoint
POST
/v1/runs/{id}/cancel
