Create a trigger for a triggered experiment
How to select an event or create a custom event to run the triggered experiment (Sitecore Personalize).
You can select an event or create a custom event to run the experiment. When the event is raised, if the event type and logic conditions both return true, Sitecore Personalize triggers the experiment.
If you want to also run custom logic against any attributes within the event type, you can define the logic using JavaScript. If you select or create a new event, you can choose it when you build a real-time audience.
Creating a custom event enables you to apply triggers to any type of online guest behavior.
You can also reference the selected trigger when you apply a real-time audience.
To create a trigger:
From the Build screen, click the Add button in the Trigger block.
The Trigger slider modal displays. The Trigger radio button is selected by default.
To use a non-custom event as the trigger to execute the experiment, select one of the following from the Trigger drop-down list:
Guest Created - Triggers the experiment after the creation of a guest profile.
Guest Modified - Do not use. Sitecore Personalize is in the process of retiring this trigger.
Order Created - Triggers the experiment after the order is created. For example, if the guest creates an order, you can trigger an email that contains the details of the order.
Order Updated - Triggers the experiment after the guest's order has been updated. For example, if an ancillary (order item) is added to the order, you can trigger an email confirming the updated order.
Session Closed - Triggers the experiment after the guest's session closes. The session close could be due to the guest abandoning their session, network latency, or the guest being inactive for the session to timeout and close. The amount of time that a guest's session will close due to inactivity is configured for your organisation's website, by your organization.
Guest Modified Custom - Triggers the experiment after the guest profile is modified by a guest attribute that is custom for your organization. For example, if the value of a guest's data extension is modified. A data extension is a custom attribute that you can pass to Sitecore Personalize, which is not part of the data model. For example, you might want to trigger an experiment that sends an email to the guest if they have enough points to qualify for the next loyalty member tier.
Abandoned cart - Triggers the experiment if the guest has items in their virtual shopping cart and the session closes. The session close could be due to the guest abandoning their session, network latency, or the guest being inactive for the session to timeout and close. The amount of time that a Guest's session will close due to inactivity is configured for your organization's website, by your organization.
To create a custom trigger, select the Custom Trigger option and complete the following:.
Event Name - Enter the event type. For example,
ADD_TO_CART
. The event will be available as an attribute in the guest context service, which is an internal service.Description - Enter a description of the event.
Event Identifier - Select an operator and enter a value for the event identifier:
Equals - Select Equals if you want the experiment to trigger when the specified event is an exact match. Enter the name of the event in the the text field.
Regex - Select Regex if you want the experiment to trigger when the event and conditions match the specified Regular Expression (RegEx) pattern. This is useful if you need to use more than one contains conditions because you can match different events with just one regular expression. Enter the RegEx characters in the field. For more details on how to write RegEx characters, see https://www.regular-expressions.info.
Starts With - Select Starts With if you want to trigger the experiment if the event starts with the specified string. Enter the string in the text field.
To add additional event identifiers, click Add identifier.
When finished, click Save.
You return to the Build screen.