Automation Rule: Update automation rule in Account
gapify_update_automation_ruleUpdate an existing automation rule in your Gapify account by changing its name, trigger event, conditions, or actions.
Instructions
Update an automation rule in the account [Automation Rule]
PATCH /api/v1/accounts/{account_id}/automation_rules/{id}
Auth: User API key (header api-access-token).
Body fields: name, description, event_name, active, actions, conditions. Extra fields can be passed via extra_body.
Text values may be written in Persian (Farsi) or any other language and are sent unchanged; IDs, numbers and phone numbers may use Persian or Arabic-Indic digits.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The ID of the automation rule to be updated. | |
| name | No | Rule name Example: "Add label on message create event" | |
| active | No | Enable/disable automation rule Example: false | |
| actions | No | Array of actions which you want to perform when condition matches, e.g add label support if message contains content help. Example: [{"action_name":"add_label","action_params":["support"]}] | |
| account_id | Yes | The numeric ID of the account | |
| conditions | No | Array of conditions on which conversation filter would work, e.g message content contains text help. Example: [{"attribute_key":"content","filter_operator":"contains","query_operator":"nil","values":["help"]}] | |
| event_name | No | Event that triggers the rule. One of: `conversation_created`, `conversation_updated`, `message_created`. Example: "message_created" | |
| extra_body | No | Additional JSON body fields to merge into the request (for keys not listed above). | |
| description | No | The description about the automation and actions Example: "Add label support and sales on message create event if incoming message content contains text help" |