Transactions in event triggered campaigns

In a campaign, you add triggers that send messages to customers when the trigger's conditions are met. In the trigger, add conditions that point to a state of transaction. For example, choose a condition that triggers a message when a user makes a booking on your site, and the booking event is a part of transaction that you can identify using its transaction ID. This lets our platform link an event to a transaction. And when the event occurs, our platform can look up the entire transaction -- leading up to the event -- and trigger the linked message as a state of the transaction. 

For instance, you may want to send a booking review reminder only if the user has not reviewed already.

21bd4d4-event_tr.png
 

Example:

This is how a sample transaction event looks like, apart from appending the existing attributes from the event we infer some additional attributes too.

For each event we receive, we infer the following attributes:

  • status - lets you know whether your received an event Ex: purchase_status
  • timestamp - this is the timestamp when when you received an event Ex: purchase_timestamp
  • transaction_state - the most recent event received: Ex: cancelled

Sample use case

You can a look at the following use cases to model a hotel booking journey using transactions. There are multiple steps to an entire transaction that a user has with the booking of a hotel. In some cases, the steps are:

  1. Booking a hotel
  2. Cancelling a booking
  3. Checking in
  4. Checking out
  5. Escalations
  6. Customer feedback
Each of these steps is considered an event in Blueshift, and you can set up a notification (email, SMS, or push notification) when a user either performs this step or the user is about to. For example, when a user books a hotel, you can set up a campaign that sends an email to the user. Similarly, a few days before checking in, the campaign can send a reminder to the user. However, there has to be a common identifier that binds these events together. In this case, let's call it order ID. To do this binding, you have to enable a setting called Segmentation on transactions and provide a JSON that defines this binding. Get in touch with us on support@blueshift.com to get this done. This is how a JSON looks:
{
  “bookings”: {
    “events”: [
      “purchase”,
      “booking cancelled”,
      “checkin”,
      “escalations”,
      “checked out”,
      “customer_feedback”
    ],
    “identifier”: “bsft_transaction_uuid”
  }
}
Following steps describe how to set up campaigns that handle such a transaction.
  1.  On the Blueshift app, create an event triggered campaign. (On the campaigns page, click +CAMPAIGNS > Event Triggered > Specify a name for identification purpose and click Create Campaign.)
  2. On the campaign creation page, we specify that a campaign starts when a user adds a hotel booking to the cart.
  3. To send an email when a specific aspect of a transaction occurs, add a trigger to the campaign. The trigger sends an email when the following conditions are met:
    • When your customer checks out a booking, and
    • You specify that the transaction type is orders
      transaction_campaign.png
      In the trigger details, add the following conditions:
      transaction_id_trigger.png
      The transaction condition ensures that when a user enters performs a checkout, the event is linked to a transaction.
  4. Similarly, you can add multiple triggers to the campaign so that when a user performs something specific, the event that occurs is linked to the transaction. 
    abandoned_cart.png
    If you take a look at the conditions of the trigger, the transactions condition is added to it. You can add this trigger to the campaign in case a user adds a product to the cart but does not checkout. This ensures that the transaction you can use the transaction to contact the user if the user adds a product to the cart but does not purchase it. 

Using the transactions conditions, and specifying a transaction ID, you can link all the steps of a hotel booking journey to convert an interaction on your site to purchase. 

Following sections show the event JSON our platform receives when a user goes through the steps of booking on your site.  

1. Purchase Event

  • JSON
{
  "email": "test@test.com",
  "event": "purchase",
  "_bsft_transaction_uuid": "order-testxyz",
  "timestamp": "2017-05-15T05:18:35Z"
}

Inferred Transaction Event

  • JSON
{
  "email": "test@test.com",
  "event": "bookings",
  "_bsft_transaction_uuid": "order-testxyz",
  "purchase_status": true,
  "purchase_timestamp": "2017-05-12T04:18:35Z",
  "timestamp": "2017-05-12T04:18:35Z",
  "transaction_state": "purchase"
}
  • JSON
{
  "email": "test@test.com",
  "event": "cancelled",
  "_bsft_transaction_uuid": "order-testxyz",
  "timestamp": "2017-05-17T07:18:35Z"
}

Inferred Transaction Event

  • JSON
{
  "email": "test@test.com",
  "event": "bookings",
  "_bsft_transaction_uuid": "order-testxyz",
  "purchase_status": true,
  "cancelled_status": true,
  "purchase_timestamp": "2017-05-12T04:18:35Z",
  "cancelled_timestamp": "2017-05-17T07:18:35Z",  
  "timestamp": "2017-05-17T07:18:35Z",
  "transaction_state": "cancelled"
}

If you see, we receive the transaction ID in each event. Our platform sends the campaign email when the step of the campaign journey that meets the condition of the event (that's linked to a transaction) is triggered.  

Was this article helpful?
0 out of 0 found this helpful