Automations
Create an automation
Creates an automation in the authenticated workspace.
post/v1/automations
Request
- Base URL: https://api.mailrith.com
- URL: https://api.mailrith.com/v1/automations
- Auth: HTTP bearer
Headers
Idempotency-Keystring
Optional idempotency key to retry the request safely. It must not exceed 256 UTF-8 bytes.
Request body
Example request
{
"definition": {
"version": 2,
"trigger": {
"type": "tag_added",
"tagIds": [
"tag_welcome"
]
},
"steps": [
{
"id": "send-welcome-email",
"kind": "action",
"type": "send_email",
"config": {
"subject": "Welcome",
"previewText": "Thanks for joining",
"bodyDocument": {
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Welcome to Mailrith."
}
]
}
]
},
"replyToEmail": "",
"trackOpens": true,
"trackClicks": true,
"utmSource": "",
"utmMedium": "",
"utmCampaign": "",
"utmTerm": "",
"utmContent": ""
}
}
]
}
}Response
Automation created
Example response
{
"data": {
"definition": {
"version": 2,
"trigger": {
"type": "tag_added",
"tagIds": [
"tag_welcome"
]
},
"steps": [
{
"id": "send-welcome-email",
"kind": "action",
"type": "send_email",
"config": {
"subject": "Welcome",
"previewText": "Thanks for joining",
"bodyDocument": {
"type": "doc",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "Welcome to Mailrith."
}
]
}
]
},
"replyToEmail": "",
"trackOpens": true,
"trackClicks": true,
"utmSource": "",
"utmMedium": "",
"utmCampaign": "",
"utmTerm": "",
"utmContent": ""
}
}
]
}
}
}Changes
No recorded changes to this operation across all 1 revision of this API.