Set up an Optimizely Triggered Messages campaign

  • Updated

Each Optimizely Triggered Messages campaign must have an associated Email Service Provider (ESP) connection and ESP action (send mail, add to group, remove from group). Set up the ESP connection and the ESP action once, and these can act on all of your Triggered Messages campaigns. Furthermore, each Triggered Messages campaign must have an associated Email Product Recommendations campaign that uses an appropriate trigger strategy. See Set up a triggered Optimizely Email Product Recommendations campaign.

Creating a Triggered Messages campaign

Go to Triggered Messages in your Personalization Portal account. To create a new Triggered Messages campaign, click Create a new campaign and fill out the form as follows:

  1. Enter a name for your Triggered Messages campaign, such as Test SendMessage.
  2. Select an ESP action so that the trigger performs the desired action when it fires.
  3. Optionally, specify start and end dates for the campaign.
  4. If you have a site in Optimizely with more than one language, such as a Swiss site that has French and German languages, you can set the Locale to fire triggered messages based on the locale, which sends emails in the correct language.
  5. Custom contact frequency appears only if you select the Send message action. Set it to On if you want the campaign to limit the number of times a trigger can fire for each customer from this Triggered Messages campaign.

    If you turn on the Custom contact frequency, specify the maximum number of times that the trigger can be fired for each user by this campaign per day, per week, or per month.

    In the screen image, the new trigger campaign specifies that for any visitor, the trigger fires no more than 5 times per day, and no more than 20 times per week, and no more than 50 times per month (whichever limit is reached first).


  6. Under Strategies, select the type of trigger this campaign should use:
    • For In-session triggers, specify how long (in minutes) the visitor needs to be inactive on your site before the trigger can fire. Select a waiting time between 0 and 240 minutes.
    • Unless stated otherwise, Daily triggers monitor the last 30 days of data. As soon as the trigger criteria are satisfied, the trigger fires. The following Repurchase strategy sends an email when a visitor has not purchased a recurring product that was expected to be purchased by a given date, such as when paper supplies run out.


    • You can use Additional trigger actions alone or in combination with an In-session trigger. See Trigger action limits.
      • You can specify whether the customer must have visited a certain page type a specified number of times.
      • You can specify a URL (or a keyword from a URL) from your site that the customer must have visited.

        The order of additional trigger actions does not matter.

        To add a criterion, where the user must have NOT visited a certain page type or URL, you can enter the number of viewings as 0 (zero).In-session-triggers.pngTriggersSendMessage2.png

  7. Optionally, add any Expressions you want. Expressions let you further refine the criteria of a trigger, for example to fire only for special products, product categories, price thresholds or brands.


    • Expressions only apply for the trigger Strategies (In-session trigger and Daily trigger), not for Additional trigger actions.
    • A trigger fires only with products that match the Expressions filter. The following rules apply:
      • If none of the products for the trigger (for example an In-session trigger for abandoned basket products) match the expression, the trigger will not fire.
      • If only some products for the trigger (for example an In-session trigger for abandoned basket products) match the expression, the trigger will fire with only matching products.

      You may have products whose prices change very frequently. To avoid sending a discount email every time a price reduction occurs for these products, you can use Expressions to limit the trigger requirements to selected products.

  8. Click Save campaign when you have completed your specifications.
  9. The initial state of a newly created trigger is OFF. To activate it, go to the Campaigns overview page and click the play button play iconnext to the campaign name.

Set up an ESP connection

Optimizely must connect to the ESP’s API so that when Triggered Messages is fired, Optimizely can alert the ESP to perform an action.

  1. Go to ConfigurationTriggered Messages in your Personalization Portal account.
  2. Select ESP connections.
  3. Edit an existing connection or create a new one. To create a new connection, click Create an ESP connection. The Manage your ESP connections screen appears.


  4. To create a connection:
    1. Enter your API credentials for your ESP account (such as username, password, database, realm, API token).
    2. Click Test ESP connection to test the connection.
    3. Click Save ESP connection.

Set up an ESP action

  1. Go to ConfigurationTriggered Messages in your Personalization Portal account and open a new or existing campaign.
  2. Select ESP actions. You can either edit an existing ESP action or create a new one. Make sure it uses the connection that you require, for example, the one you created or edited in Setting up an ESP connection.
  3. To create a new action, click Create an ESP action.
  4. Choose your preferred ESP action type from the available options and enter the required details (such as Group ID, List ID, Message ID, Database); the values of which are available from your ESP portal.

    These fields are dynamic and differ depending on the chosen ESP connection and the chosen ESP action type.


    Available action types are as follows:

    Depending on the features supported by your ESP platform, some of these actions may not be available for your chosen connection.

    • Remove user from target group – Removes a user's email address from the group or list.
    • Add user to target group – A fired trigger tells the ESP to add a user’s email address to the email group or list with the specified Group ID or List ID. If there are ESP-level triggers on the list, are be activated by this step. This action just adds a user's email addresses to a list; it does not send those users any emails.
    • Send message to user – A fired trigger tells the ESP to send the message with the specified Message ID to the user.

      Depending on your ESP, Send message may not check whether the user has opted in to the emailing scheme, so use it with caution.

  5. After you created your ESP action, test it and save it.

Link to a specific basket

Optimizely can integrate links from an email recommendation to a particular basket of the recipient. To enable this feature, contact customer service.

For developer information, see Link to a specific basket.