Patch automation workflow

Partially update an automation workflow. Only the fields provided in the request body are updated.

Enabled automations cannot be patched. Disable the automation via POST /automations/{id}/disable, make changes, then re-enable via POST /automations/{id}/enable when ready. When disabling, contactsInWorkflow controls whether contacts already in the workflow continue through the remaining blocks (keep) or exit immediately (exit). Enable/disable state is controlled exclusively via the /automations/{id}/enable and /automations/{id}/disable endpoints.

trigger sub-fields (condition, audienceFilterGroup, inactivitySettings) are patched individually — each provided sub-field replaces the corresponding sub-field in full. exitConditions are replaced in full when provided. blocks are patched individually.

Scopes: automations.write

Audience filter group examples

The trigger.audienceFilterGroup field in PATCH requests replaces the existing audience filter group in full (or sets it for the first time). Omit it to leave the existing audience filter group unchanged.

Supported fields

FieldOperatorsValue shape
segmentIDeq, neqSegment ID string, e.g. "000000000000000000000001"
tageq, neqTag name, e.g. "vip"
dateAddedeq, neq, gt, ltISO-8601 date, e.g. "2025-03-15"
firstNameeq, neq, contains, notContainsFree string, e.g. "John"
lastNameeq, neq, contains, notContainsFree string, e.g. "Smith"
gendereq"m" or "f"
countryeq, neq, contains, notContainsISO-2 country code, e.g. "US"
stateeq, neq, contains, notContainsState / region name, e.g. "California"
cityeq, neq, contains, notContainsCity name, e.g. "New York"
postalCodeeq, neq, contains, notContainsPostal code string, e.g. "10001"

Where it fits

audienceFilterGroup sits inside trigger in the PATCH request body, alongside condition and inactivitySettings:

{
  "trigger": {
    "audienceFilterGroup": { ... }
  }
}

Each example below shows only the audienceFilterGroup value — slot it into the skeleton above.

Replace audience filter without touching trigger event or blocks
{
  "logicalOperator": "or",
  "filters": [
    {"field": "tag", "operator": "eq", "value": "vip"},
    {"field": "tag", "operator": "eq", "value": "beta"}
  ]
}
Narrow to US women
{
  "logicalOperator": "and",
  "filters": [
    {"field": "country", "operator": "eq", "value": "US"},
    {"field": "gender",  "operator": "eq", "value": "f"}
  ]
}
Swap a segment-based audience for a tag-based one
{
  "logicalOperator": "and",
  "filters": [
    {"field": "tag", "operator": "eq",  "value": "vip"},
    {"field": "tag", "operator": "neq", "value": "beta-churned"}
  ]
}
Path Params
string
required

Automation workflow ID (24 character hexadecimal)

Body Params

Fields to update

Patch automation workflow request. All fields are optional — only provided fields are updated. trigger fields are patched individually — only sub-fields within trigger that are provided are updated. exitConditions are replaced in full when provided; send null or [] to clear, omit to leave unchanged. blocks are patched individually by id — only fields within each block that are provided are updated.

blocks
array of objects

Automation workflow blocks. Each entry updates an existing block matched by id; fields within each block are applied as a partial update. The array does not reshape the block list — adding or removing blocks is not supported through this endpoint (use the dedicated block endpoints for that). An empty array ([]) is rejected with 400; omit the field to leave blocks unchanged.

blocks
exitConditions
array of objects

Exit condition list. Replaces all existing exit conditions when provided. Send null or an empty array ([]) to clear all exit conditions; omit to leave unchanged.

exitConditions
string

Automation workflow name

settings
object

Automation settings patch. Each sub-field follows partial-update semantics: omit to leave unchanged, send a value to replace. sendingThresholds does not accept null — sending null returns 400. frequencyLimiter accepts null to clear (disable) the existing limiter. overlapLimiter accepts null to clear the configured limiter (engine performs no overlap check).

trigger
object

Trigger configuration for PATCH. Tri-state per field — omit to leave unchanged, send a value to replace, send null to clear (where the schema marks the field nullable). Sending null for condition returns 400. When condition is provided, the entire trigger condition (event, origin, and filter groups) is replaced in full.

Headers
string
required
Defaults to 2026-03-15

API version that specifies the response format and behaviour

Responses

Language
Credentials
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json