agent
Cancel agent run
Start asynchronous cancellation. A running AgentCore session enters CANCELLING until StopRuntimeSession is confirmed or the bounded stop policy records a terminal failure.
Required scope: `inference:run`
post/agent/runs/{run_id}/cancel
Path parameters
run_idstring required
Query parameters
principal_idstring
Scope by principal. If omitted, only a run with no principal (principal_id is null) is addressed; a run whose principal differs yields 404.
Response
Cancellation accepted. Active runs are returned in CANCELLING state.