Automations
Update messaging automation
Update an existing messaging automation's configuration. Changes to an enabled automation affect subsequent triggered sends.
PATCH
/v1/agencies/{agencyId}/automations/{automationId}Update an existing messaging automation's configuration. Changes to an enabled automation affect subsequent triggered sends.
Authorization
bearerAuth AuthorizationBearer <token>
In: header
Path Parameters
agencyId*string
Length
1 <= lengthautomationId*string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://example.com/v1/agencies/string/automations/string" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "data": {} }'{ "data": { "notifyEmployees": [ { "id": "string", "createdAt": "2019-08-24T14:15:22Z", "employeeId": "string", "automationId": "string" } ], "sequences": [ { "messages": [ { "medias": [ { "id": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "position": 0, "isPreview": true, "mediaId": "string", "messageId": "string" } ], "gif": null, "id": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "position": 0, "price": null, "sequenceId": "string", "content": null, "aiGenerated": true, "delay": 0 } ], "name": "string", "id": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "position": 0, "automationId": "string" } ], "enabled": true, "creatorId": "string", "name": "string", "id": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "endDate": null, "trigger": "FAN_BIRTHDAY", "keywords": [ "string" ], "keywordMatchType": "CONTAINS", "fanListsIncluded": [ "string" ], "fanListsExcluded": [ "string" ], "totalSpendMin": null, "totalSpendMax": null, "tipsReceivedMin": null, "tipsReceivedMax": null, "subscriptionDurationMin": null, "subscriptionDurationUnit": null, "onlineStatusOnly": true, "excludeRecentlyMessaged": true, "excludeRecentlyMessagedTime": null, "excludeMediaViewers": true, "excludeUnreadMessages": true, "excludeCreatorAccounts": true, "frequency": "SEND_EVERY_TIME", "effectiveType": "IMMEDIATELY", "randomDelayMin": null, "randomDelayMax": null, "scheduledDate": null, "scheduledTime": null, "expiryType": "NEVER_EXPIRE", "expiryDate": null, "expiryTime": null, "unsendMessages": true, "unsendAfter": null, "stopMessageOnReply": true, "actionSendMessage": true, "actionStopAI": true, "actionNotifyEmployee": true, "actionAddToList": true, "actionFollowFan": true, "followFanDailyCap": null, "followFanExcludeChargebacks": true, "notifyEmployeeMessage": null, "targetListIds": [ "string" ], "createdByEmployeeId": null, "stoppedByEmployeeId": null, "stoppedAt": null, "totalSent": 0, "totalEarned": "string", "amountPurchased": 0 }, "meta": { "requestId": "string", "operationId": "3051932a-fdd2-48fa-b330-7e7d41535969", "status": "COMPLETED" }}