cancel_instance
POST
/instances/{instance_id}/cancelForEach fan-out children and sub-workflow calls are independent runs; the cancel walks down to all of them and terminalizes the whole lineage in one transaction, so no surviving parent is ever left waiting on a cancelled child. Runs already terminal are counted, not touched.
AuthorizationBearer <token>
A service principal's credential, or a person's access token, AgentFlow's own or an installed app's. A service principal's effective permissions are its role permissions intersected with the credential's scopes.
In: header
Path Parameters
instance_id*string
Instance id
Format
uuidResponse Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X POST "https://example.com/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/cancel"{ "already_terminal": 0, "cancelled": 0, "status": "running"}