Skip to main content

Get Automation Run

Retrieve one run of an automation: what started it, and each step it has been through. A step is completed, skipped (with the reason a message was not sent) or failed.

Endpoint​

GET /automations/:id/runs/:run_id

Returns: 200 OK

Headers​

HeaderValueRequired
AuthorizationBearer <your-api-key>Yes

Path Parameters​

ParameterTypeDescription
idstringThe automation ID
run_idstringThe run ID

Response​

{
"id": "01957e40-1a2b-7c3d-8e4f-5a6b7c8d9e0f",
"status": "completed",
"contact_id": "01957e3a-4b5c-7d8e-9f0a-1b2c3d4e5f6c",
"current_step_key": null,
"failure": null,
"started_at": "2026-03-08T12:00:00.000Z",
"completed_at": "2026-03-08T16:00:02.000Z",
"trigger": {
"event": "custom_event",
"event_name": "cart_abandoned",
"timestamp": "2026-03-08T12:00:00.000Z"
},
"steps": [
{
"key": "trigger",
"type": "trigger",
"status": "completed",
"outcome": "default",
"skip_reason": null,
"error": null,
"completed_at": "2026-03-08T12:00:00.000Z"
},
{
"key": "wait_for_order",
"type": "wait_for_event",
"status": "completed",
"outcome": "timeout",
"skip_reason": null,
"error": null,
"completed_at": "2026-03-08T16:00:00.000Z"
},
{
"key": "reminder_email",
"type": "send_email",
"status": "completed",
"outcome": "default",
"skip_reason": null,
"error": null,
"completed_at": "2026-03-08T16:00:01.000Z"
},
{
"key": "reminder_sms",
"type": "send_sms",
"status": "skipped",
"outcome": "default",
"skip_reason": "no_phone",
"error": null,
"completed_at": "2026-03-08T16:00:02.000Z"
}
]
}

The run fields are described in List Automation Runs. A run also carries:

FieldTypeDescription
trigger.eventstringThe trigger event that started the run, such as custom_event. See Trigger events.
trigger.event_namestring | nullFor a custom_event trigger, the event's name
trigger.timestampstringWhen the trigger event happened (ISO 8601)
stepsarrayThe steps the run has been through, in order, starting with the trigger. A step the run is waiting on is added once the wait ends.

Each entry in steps:

FieldTypeDescription
keystringThe step's key
typestringThe step's type
statusstringcompleted, skipped or failed
outcomestring | nullThe connection the run left by: default, or the branch a condition or wait_for_event took. null when the step failed.
skip_reasonstring | nullWhy a send step sent nothing, such as no_email, no_phone, suppressed or smart_sending. null unless status is skipped.
errorstring | nullWhat went wrong. null unless status is failed.
completed_atstringWhen the step finished (ISO 8601)

A skipped step does not stop the run: it carries on to the next step.


Examples​

curl "https://api.arsel.sa/v1/automations/01957e3a-4b5c-7d8e-9f0a-1b2c3d4e5f6b/runs/01957e40-1a2b-7c3d-8e4f-5a6b7c8d9e0f" \
-H "Authorization: Bearer $ARSEL_API_KEY"

Error Responses​

{
"status_code": 403,
"name": "forbidden",
"message": "Automations are not available for this organization"
}

When the automation itself does not exist, the 404 message is Automation not found.