What Are Automations?
An automation is a workflow with three parts:- Trigger - The event that starts the automation
- Conditions - Optional rules that must be true for the automation to run
- Actions - What happens when the automation runs
Example Automations
Here are some common automation use cases:| Trigger | Condition | Action |
|---|---|---|
| New email received | From specific domain | Add sender to contacts |
| New email received | Subject contains “urgent” | Send notification |
| Contact created | Has company name | Create business record |
| New email received | From unknown sender | Label as “New lead” |
Triggers
Triggers define when an automation starts. Available triggers include:| Trigger | Description |
|---|---|
| Message received | A new incoming message arrives |
| Message sent | An outgoing message is sent |
| Contact created | A new contact is added |
| Contact updated | An existing contact is modified |
| Customer created | A new customer record is created |
More triggers are being added. Check the Automations page in your dashboard for the current list.
Conditions
Conditions let you filter when an automation runs. Without conditions, the automation runs every time the trigger fires.Condition Types
| Type | Example |
|---|---|
| Sender/recipient | From a specific email or domain |
| Content | Subject or body contains text |
| Labels | Message has specific label |
| Contact fields | Contact has specific company |
Combining Conditions
You can combine multiple conditions:- All must match (AND) - The automation runs only if every condition is true
- Any must match (OR) - The automation runs if at least one condition is true
Actions
Actions define what happens when an automation runs. Available actions include:| Action | Description |
|---|---|
| Create contact | Add a new contact with specified fields |
| Update contact | Modify an existing contact |
| Add label | Apply a label to a message |
| Send notification | Alert you or a team member |
| Run code | Execute custom JavaScript |
| AI instruction | Have an AI agent process the message |
Custom Code Actions
For advanced use cases, you can write JavaScript code that runs when the automation triggers:Custom code runs in a sandboxed environment with access to ShingleAI APIs. See the API Reference for available methods.
AI Instructions
Instead of writing code, you can provide natural language instructions for an AI agent:Creating an Automation
1
Open Automations
Navigate to Automations in the sidebar.
2
Create new
Click Create Automation.
3
Choose trigger
Select what event should start the automation.
4
Add conditions
Optionally add conditions to filter when the automation runs.
5
Define actions
Choose what should happen when the automation runs.
6
Save and enable
Give your automation a name and enable it.
Automation Status
Automations can be in different states:| Status | Description |
|---|---|
| Active | Running and processing events |
| Paused | Temporarily disabled, can be resumed |
| Completed | Finished (for automations with execution limits) |
| Expired | Past its expiration date |
Monitoring Automations
Track how your automations perform:Execution History
Each automation shows its recent executions:- When it ran
- What triggered it
- Whether it succeeded or failed
- Any errors that occurred
Execution Limits
You can set limits on automations:- Max executions - Stop after running N times
- Expiration date - Disable after a specific date
Best Practices
Start simple. Create basic automations first, then add complexity as needed.
Test with conditions. Use narrow conditions initially to limit the impact while you verify the automation works correctly.
Monitor executions. Check the execution history regularly to catch errors early.
Use descriptive names. Name your automations clearly so you remember what they do.