Automation API
Planned API for creating and managing workflow automations
Planned — not yet available. This page describes a planned capability.
The endpoints below do not exist yet and may change before release.
Automations can be built and managed inside the Coherence app today, and you
can ask an agent to act on records via POST /v1/agents/messages — but there
is no public REST API for automations yet.
The planned Automation API will let you define workflows programmatically that execute actions when triggers fire — streamlining repetitive tasks, enforcing business rules, and integrating with external systems.
Planned Model
An automation will consist of three parts:
- Trigger — what starts the automation (e.g., a record is created)
- Conditions — optional rules that determine whether it should run
- Actions — what happens when it executes
Endpoint Sketch (design preview)
| Method | Endpoint | Purpose |
|---|---|---|
| GET | /automations | List automations |
| GET | /automations/{id} | Get a single automation |
| POST | /automations | Create an automation |
| PATCH | /automations/{id} | Update an automation |
| DELETE | /automations/{id} | Delete an automation |
| POST | /automations/{id}/enable | Enable an automation |
| POST | /automations/{id}/disable | Disable an automation |
| GET | /automations/{id}/logs | Execution history |
Example (design preview)
Creating an automation will look like:
curl -X POST "https://api.getcoherence.io/v1/automations" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Welcome email for new contacts",
"trigger": {
"type": "record.created",
"module": "contacts"
},
"conditions": [
{ "field": "email", "operator": "is_not_empty" }
],
"actions": [
{
"type": "send_email",
"config": {
"to": "{{record.email}}",
"subject": "Welcome!",
"body": "Hi {{record.first_name}}, thanks for signing up."
}
}
]
}'and will return the created automation:
{
"automation": {
"id": "auto_def456",
"name": "Welcome email for new contacts",
"enabled": false,
"createdDateTime": "2026-01-17T09:00:00Z"
}
}Planned Trigger Types
| Trigger | Fires when |
|---|---|
record.created | A record is created in a module |
record.updated | Any field on a record changes |
record.deleted | A record is deleted |
field.changed | A specific field value changes |
schedule | A cron schedule elapses (e.g., 0 9 * * 1-5) |
manual | Triggered explicitly via API or a button in the UI |
Planned Action Types
| Action | What it will do |
|---|---|
update_record | Update fields on the triggering or a related record |
create_record | Create a record in any module |
send_email | Send an email with templated content |
send_notification | Send an in-app notification to a user |
call_webhook | Make an HTTP request to an external URL |
delay | Pause before the next action |
Actions will support template variables such as {{record.field_name}}, {{record.id}}, {{now}}, and {{user.email}} for dynamic content, plus filters like {{now | add_days: 7}}.
Conditions (design preview)
Conditions will filter execution; all conditions must pass. Planned operators include equals, not_equals, contains, greater_than, less_than, is_empty, is_not_empty, changed, changed_to, and changed_from.
Errors
Planned endpoints will use the standard Coherence error envelope (see Error Handling):
{
"error": {
"message": "Automation not found",
"statusCode": 404
}
}Related: API Overview | Webhooks (also planned) | Agents API