When you are building your use cases in AudienceStream, you might need to take into account offline visits when setting them up. In some cases, you might want to prevent offline data from interfering in your use cases. 

In this article:

Table of Contents Placeholder

Example

You are setting up an abandoned basket use case, with a delayed connector.  The requirement is:

  • After a visit that started the purchase process but didn't complete it,
  • If 3 days later, the visitor hasn't returned to your site, you want to send them an email.

Setup without consideration of offline visits

  1. A visitor string "Email Address" with enrichments:
    • Set to email_address
  2. A visitor boolean "Visit Abandoned [bln]" with enrichments:
    • Set to false on new visit
    • Set to true if the user adds a product to the cart
    • Set to false on the order confirmation page
  3. An Audience "Basket Abandoners" with conditions:
    • Visitor boolean "Visit Abandoned [bln]" is true, and
    • Visitor string attribute "Email Address" is assigned
  4. A connector that trigger a connector action if the user is in the Audience at the end of the visit, with a delay of 3 days.

Only vistor-level attributes can be sent in a delayed action. Visit-level attributes are out of scope by the time the connector action fires.

To simulate visit-level attributes, we could setup a visitor-level attributes and reset the attribute on new visit.

Issues without considering offline visits

If the user visits the site again during the 3 days and doesn't add to cart, the boolean would be false, and the user would leave the Audience, so the connector action will not be triggered.

Delayed action is triggered only if the visitor is still in the audience at the scheduled time.

However, if you also have an offline data import reguarlerly for all customers, using File Import or Collect API, your use case might not work.

Offline data coming in using File Import or Collect API also creates visits. When there is an offline visit,the visit boolean will reset to false, and the offline visit will not set it back to true as the enrichment requires online add to cart action.

This would mean that the visitor would leave the Audience on the next offline data import, and the delayed connector action will not be triggered.

Solution

  1. A visitor string "Email Address" with enrichments:
    • Set to email_address
  2. A visit boolean "Online visit [bln]" with enrichments:
    • Set to true on any event when the built in Current URL event attribute is assigned
      Online visit [bln].png
  3. A visitor boolean "Most Recent Online Visit Abandoned [bln]" with enrichments:
    • Set to false at the start of the visit if the "Online visit [bln]" is true
    • Set to true if the user adds a product to the cart
    • Set to false if there is order confirmation page/event
      Most Recent Online Visit Abandoned [bln].png
  4. An Audience "Basket Abandoners" with conditions:
    • Visitor boolean "Most Recent Online Visit Abandoned [bln]" is true, and
    • Visitor string attribute "Email Address" is assigned
  5. A connector that trigger a connector action if the user is in the Audience at the end of the visit, with a delay of 3 days.

"Most Recent Online Visit Abandoned [bln]" will remain true even if there is an offline visit for this user.

Version history
Last update:
‎02-26-2021 07:39 AM
Updated by: