Skip to content

Update target run command information.
Stable

Request

Updates a Target Run's device command, currently supporting cancellation.

Sets the request_status of the specified command to cancelled, stopping further execution of that device-level command.

About Target Run Command Each Target Run corresponds to a command dispatched to a device. This endpoint is the mechanism for cancelling that command mid-flight, most commonly used to stop a stuck or unwanted device operation without waiting for it to time out.

Key Fields / Query Parameters

  • stage_run_id — UUID of the parent Stage Run
  • target_run_id — UUID of the Target Run
  • command_id — UUID of the specific command to update
  • request_status — Currently only supports the value cancelled
Security
pipelines_SCAPIAuthToken
Path
stage_run_idstringrequired

ID of the stage run

target_run_idstringrequired

Id of the target run

command_idstringrequired

Id of the command

Bodyapplication/jsonrequired
request_statusstring
Value:"cancelled"
cURL
curl -i -X PUT \
  'https://develop-api.esper.io/_mock/openapi/pipelines/v0/stageruns/{stage_run_id}/targetruns/{target_run_id}/command/{command_id}/' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "request_status": "cancelled"
  }'

Responses

Command processor request status

Bodyapplication/json
codeinteger
messagestring
contentobject(pipelines_CommandResponse)
Response
{ "code": 0, "message": "string", "content": { "target_run_id": "0f2ab1df-1de3-4f85-b0b8-63282bf0d88f", "operation_id": "cb4ede3c-a5d1-45e3-a9d2-fe83accbce52", "enterprise_id": "2dbe425a-b3bc-4170-8bae-9e5391aafea6", "command": "string", "command_type": "DEVICE", "device_type": "all", "device_id": "3bafab7b-4400-4bcf-8e6e-09f954699940", "schedule": "IMMEDIATE", "args": {}, "request_id": "266ea41d-adf5-480b-af50-15b940c2b846", "request_status": "string", "request_status_reason": "string" } }