By using Replypad, you agree to our Cookie Policy.

Understanding triggers

What are triggers?

Triggers are a set of user defined rules (triggers) that get executed when an Event occurs. An event can be a conversation being created or a conversation being updated. Each Trigger has a condition and actions. When the condition is met – the actions are executed.
For example:
  • Event: Conversation is Created
  • Condition: If mailbox=”Support”
  • Action: Set conversation’s Team to “Support”
The order of the triggers matters! See below how triggers work to understand the importance of the order of the rules.

Triggers usage examples

Examples:
  • Set default Team to “Support” for new conversations that are automatically created from emails that were sent to the Support mailbox. Example: ‘Support’ team for email messages sent to ‘support@123computer.com’.
  • Set default Assignee for new conversations that are automatically created from emails that were sent to the billing mailbox. Example: Set ‘Dan’ as the assignee for conversations sent to mailbox: Billing@123computer.com.
  • Send an auto-response message when a message arrives at support@123computer.com with the response: “we will assist you shortly”.
  • Set default Team for new conversations opened by specific team members / specific Account, etc.
  • Set Label “VIP” when a conversation arrived from a specific Account.
  • Add Follower ‘Dan’ if Subject contains “Urgent”
  • and so on…

How do triggers work?

Triggers are like a small programs that are executed each time an event occurs.

An Event can be:
  • Conversation created
  • Conversation updated – such as status change, new reply, team change, and so on.
Trigger evaluation process:
  1. When an event occurs for a specific conversation, the systems evaluates all active triggers (ones that aren’t paused), one after the other from top to down.
  2. When there is an event match, the condition of each trigger is evaluated against the relevant conversation data.
  3. In case the condition is met, all actions defined for the trigger are executed. Such actions may change the conversation’s data, which may create more events.
  4. When trigger actions are executed, the trigger is marked “executed” and the system restarts the trigger evaluation process from the top, taking into account the new events that may have been added in the previous step (see explanation below).
  5. Each trigger uses the most up-to-date conversation details. So if a previous trigger has updated the conversation – the current trigger condition is evaluated against the latest conversation data.
  6. Triggers marked as “executed” are always skipped. This means that a trigger can only get executed once, during a execution process.
What happens when a trigger creates more events?
  • The triggers list is executed in a loop, meaning that after an event is evaluated and executed, the trigger is marked as “executed” and the list is scanned again from the beginning.
  • “Conversation created” events are executed first until finishing all the triggers that match. If the trigger execution creates more update events, they are accumulated and executed later, in the next step.
  • “Conversation update” events that may have occurred in the previous loop due to data updates in the triggers, are now executed.

Execution order example

  • Trigger #1 if “Mailbox is Support” then “Add Label = Support”
  • Trigger #2 If “Label is Support” then “Set Team = Support”.
Now let’s say an event occurs, and a new conversation is received with Mailbox is Support.
In the above example, rule #1 will execute, setting the label with the value Support.
Rule #2 will follow, using the latest Label value that was updated in rule #1, thus setting Team to Support.

Had the order of the rules been the other way around, then the the rule checking the label value wouldn’t have produced the same results and the conversation would not have been set with Team = Support.

Yes, this is much like coding, and the order of your commands is important!

Trigger fields

  • Name: Each Trigger has a name describing its essence, like “Set new conversations sent to sales with the “Sales Department” team.
  • Event: What happens in the app that triggers this rule. Events can be conversation creation, conversation update and catch-all events.
  • Status: A trigger has a status, that’s basically Active or Paused.
  • Condition: A defined criteria that need to met in order for the Actions to execute.
  • Actions: The actual actions/changes that need to be performed when the Conditioin is met.

Trigger condition

The trigger’s condition is a defined criteria that need to met in order for the Actions to execute.
Each condition consists of three parts:
  • Field: one of the following types:
    • Conversation data fields – such as account, assignee, subject, etc.
    • Initial message fields – field from the first message that was sent for this conversation
    • Newest message fields – fields from the newest message for this conversation, meaning the current message that is being processed by this condition.
    • Mailbox – the email address that is being used to send and receive messages for this conversation
  • Operator and Value: The operator depends on the type of field that is selected. Possible types are:
    • Text – allows you to search an exact text or find word/s in the field
    • Select value – allows you to select from the list.
See Triggers for step-by-step instructions for setting conditions.

Trigger action

Action is the actual actions or changes that need to be performed when the condition is met.
Important things to know about actions:
  • The actions can be one of the actions listed below.
  • Each action changes data or adds data to the conversation.
  • For each action you should set the value you want to apply when performing the action. Each field has values that apply to this field. For example, “Add label” allows you to choose a label. “Post internal note” allows you to add a text or use a saved response, and so on.
See Triggers for a complete list of possible actions and step-by-step instructions.

Managing triggers

Only workspace administrators can create and manage triggers. Triggers are managed from a dedicate page. To open the triggers go to the gear icon in the top-right corner and select Triggers.

The Triggers page lists all existing triggers and admins can:
  • Add a new trigger.
  • Edit existing one.
  • Pause /Activate a trigger.
  • Change the order of triggers (up/down).
See Managing triggers for step-by-step instructions for managing triggers.
Previous: Saved responses
Next: Keyboard shortcuts