delegations.cancelDelegation
POST
/v1/delegations/{delegationId}/cancel
const url = 'https://example.com/v1/delegations/example/cancel';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"commandKey":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/delegations/example/cancel \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "commandKey": "example" }'Asks the execution to stop this work and its child work. Observe the execution until its resources are released.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”delegationId
required
string
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
commandKey
required
string
Example generated
{ "commandKey": "example"}Responses
Section titled “Responses”Success
Media typeapplication/json
object
executionId
required
string
commandKey
required
string
sequence
required
integer
Example generated
{ "executionId": "example", "commandKey": "example", "sequence": 1}OrganizationRequired
Media typeapplication/json
object
_tag
required
string
Example
{ "_tag": "OrganizationRequired"}AuthenticationRequired
Media typeapplication/json
object
_tag
required
string
Example
{ "_tag": "AuthenticationRequired"}ExecutionForbidden | @nmnmcc/ability/Authorizer/Forbidden | MembershipRequired | ForbiddenOrigin
ExecutionNotFound | DelegationNotFound
ExecutionConflict | ExecutionKeyConflict | DelegationConflict | @nmnmcc/ability/Authorizer/Pending
RateLimited
Media typeapplication/json
object
_tag
required
string
retryAfterSeconds
required
integer
Example
{ "_tag": "RateLimited"}ExecutionUnavailable | DelegationStorageUnavailable | AuthenticationUnavailable | RequestFailed