Automations
Run steps when a Record changes, on a schedule, or on an incoming message.
An Automation is a trigger followed by steps, drawn as a graph in the builder. Each step runs as a background job, so a run survives a node restart and continues on another node.
Example: welcome a new lead
Trigger: CRM Lead, New
→ Condition: doc.source == "Website"
true → Send email to doc.email_id, template "Lead Welcome"
→ Wait 2 days for a reply
reply → Assign to sales@acme.com
timeout → Create record: ToDo "Call {{ doc.lead_name }}"
false → Notify the lead ownerTriggers
| Trigger | Starts a run when | Needs a RecType |
|---|---|---|
| New, Save, Submit, Cancel | A Record is inserted, saved, submitted or cancelled | Yes |
| Value Change | A named field changes | Yes |
| Workflow State | A Record enters a workflow state | Yes |
| Date Offset | A date field is N days before or after today | Yes |
| Communication | An email or Telegram message arrives on a Record | Yes |
| Schedule | A five-field cron matches, in the site's time zone. 0 9 * * 1 is Monday 09:00 | No |
| Webhook | Another system calls the automation's signed URL | No |
| Manual | A user runs it | No |
Steps
| Step | Does |
|---|---|
| Condition | Branches on an expression, true or false |
| Set field | Sets one field of the trigger's Record |
| Create record | Inserts a Record and outputs its name |
| Assign | Gives the Record a ToDo for each user |
| Send email | Queues a mail from an Email Template, or from a subject and body |
| Send Telegram | Messages each linked user who can read the Record |
| Notify | Adds a bell notification for each user who can read the Record |
| Call webhook | Sends a Webhook's signed request |
| Wait | Pauses for a number of minutes |
| Wait for reply | Waits up to a number of hours for an incoming message on the Record |
Installed apps can add more steps.
Inputs read the Record as doc.<field> and earlier steps as steps.<node>.<output>. Text inputs can be templates such as New lead: {{ doc.title }}.
Build one
Create an Automation at /desk/automation/new with a Title, Trigger and RecType. Save it.
Open the builder at /desk/automation/<name>/builder. Drag steps from the palette and wire them on the canvas. The inspector's Setup tab edits the selected step.
Open the Test tab to dry-run the graph on a sample Record. The dry run rolls back everything it did. Email, Telegram and webhook steps show a preview instead of sending.
Tick Enabled and save.
Checks on save
The save refuses a graph that has a cycle without a wait, more than 50 nodes, or a step the owner has no right to run. It also refuses literal values that name a missing or disabled User, or a Select value outside its options. A run that could re-trigger itself is shown as a warning.
Who it runs as
Steps run as the automation's owner, with the owner's permissions. Copying an automation makes you the owner and leaves the copy disabled. Automation Manager and System Manager can build automations.
Runs and their steps are recorded in Automation Run. A run that nests more than three levels deep stops with an Error Log.