A trigger is a specific event or condition that initiates a predefined action or set of actions within a system or application. It serves as the starting point for a particular workflow or process. In essence, a trigger "listens" for a specific occurrence and, once detected, activates the subsequent steps or actions that have been defined to follow it.


Triggers can be based on a wide range of events, including:

 

Event Type

Description

User Interactions

Clicking a button, submitting a form, or hovering over an element on a webpage

System Events

Like a webpage fully loading, a database update, or a scheduled time being reached

External Inputs

Receiving data from another system, a webhook activation, or detecting changes in an external environment.

 

Triggers play a crucial role in ensuring that specific actions are carried out in response to particular events, allowing for dynamic and responsive system behaviours


In simpler terms, think of a trigger as a "cause" that sets off a "reaction" within a system. Just as pulling a fire alarm trigger causes the alarm to sound, a software trigger causes a specific function or process to start.



Types of Triggers


External Event Received

This trigger activates when an event from an external source or system is detected. For example, it could be a notification from a third-party application, such as a webhook from a pAIment or Segment.

Button Click

This is one of the most common triggers on web interfaces. It activates when a user clicks on a button element. For instance, submitting a form, confirming an action, or navigating to another page.

Page Load

This trigger activates as soon as a web page has fully loaded and is ready for user interaction. It's often used to initiate actions like displaying pop-ups, starting animations, or fetching additional data.

Out of Focus

This trigger activates when a specific element or the entire webpage loses focus. For example, when a user clicks outside an input field or switches to a different browser tab.

Assign User ID

This trigger activates when a unique identifier is assigned to a user, typically during account creation, login, or when a visitor accesses a website for the first time. This can be used to personalize user experiences or track user behaviour.

Track

This trigger is activated when a specific event or action is tracked, often for analytics or monitoring purposes. For instance, tracking can be used to monitor user interactions with a website, such as clicks, page views, or conversions.

Each of these triggers serves as a starting point for various actions or sequences of events, allowing for dynamic and responsive interactions in engAIge.


Real life scenarios

 

Trigger

Scenario

Button Click

 

Jane visits an online clothing store and finds a dress she likes. She clicks the "Add to Cart" button to add the dress to her shopping cart. The button click trigger activates, and the dress is added to her cart, with a confirmation message displayed.

Page Load

 

Mike opens his favorite news website every morning. As soon as the homepage fully loads, a pop-up appears showcasing the top news story of the day. This is initiated by the page load trigger.

Out of Focus

 

Emily is filling out a feedback form on a restaurant's website. She starts typing her feedback but gets distracted and clicks outside the text box to check the menu. The out of focus trigger activates, and a small tooltip appears saying, "Don't forget to submit your feedback!"

Assign User ID

 

Alex decides to sign up for a new social media platform. After entering his details and clicking "Sign Up," the system assigns him a unique user ID. This trigger ensures that Alex's preferences, posts, and interactions are personalized and saved under his profile.

Track

 

Sarah, a digital marketer, launches a new advertising campaign for a product. She uses tracking triggers to monitor how many times the ad is clicked, how long users stay on the product page, and how many make a purchase. This data helps her understand the campaign's effectiveness and areas for improvement.

External Event Received

When a customer, Lisa, completes a purchase using pAIment, pAIment sends an external event notification to engAIge. engAIge activates a series of actions: confirming Lisa's order, sending her a thank-you email, and notifying the warehouse to prepare her books for shipment. This seamless integration ensures timely responses and enhances Lisa's experience.


Setting up the trigger

 

The below trigger shows as a default when a user begins a new workflow within the Automator


A white circle on a white background

Description automatically generated


Details of the trigger:

A screenshot of a computer

Description automatically generated

















Source Type can be Website or External Event


Website


A screenshot of a computer

Description automatically generated

A screenshot of a phone

Description automatically generated

A screenshot of a computer

Description automatically generated

  

External Event


A screenshot of a computer

Description automatically generated


A screenshot of a computer

Description automatically generated