/automations/{automation_id}Update an automationParameters
automation_idstring · uuidpathrequiredThe ID of the automation.
Request body
application/json
At least one of `name`, `status`, or `steps` and `connections` must be provided. When updating the workflow graph, both `steps` and `connections` must be provided together.
connectionsarray of objectThe connections between steps in the automation graph. Must be provided together with `steps`.
Show child attributes
Show array items
A connection between two steps in the automation graph.
fromstringrequiredThe `key` of the source step.
tostringrequiredThe `key` of the target step.
typestringThe type of connection. Defaults to `default`.
namestringThe name of the automation.
statusstringThe status of the automation.
stepsarray of objectThe steps that compose the automation workflow. Must be provided together with `connections`.
Show child attributes
Show array items
A step in an automation workflow. The `config` object varies based on the step `type`.
configobjectrequiredConfiguration for the step. Shape depends on `type`: - **trigger**: `{ event_name: string }` - **send_email**: `{ template: { id: string, variables?: object }, subject?: string, from?: string, reply_to?: string }` - **delay**: `{ duration: string }` — a human-readable duration (e.g. `"30 minutes"`) - **wait_for_event**: `{ event_name: string, timeout?: string, filter_rule?: object }` — `timeout` is a human-readable duration (e.g. `"1 hour"`) - **condition**: A rule tree with `type` (`rule`, `and`, `or`), `field`, `operator`, and `value` - **contact_update**: `{ first_name?: string|object, last_name?: string|object, unsubscribed?: boolean|object, properties?: object }` - **contact_delete**: `{}` - **add_to_segment**: `{ segment_id: string }`
keystringrequiredA unique key for this step within the automation graph.
typestringrequiredThe type of automation step.
{
"connections": [
{
"from": "string",
"to": "string",
"type": "default"
}
],
"name": "string",
"status": "disabled",
"steps": [
{
"config": {},
"key": "string",
"type": "add_to_segment"
}
]
}Responses
idstringThe ID of the updated automation.
objectstringType of the response object.
{
"id": "string",
"object": "automation"
}