Tutorial

Appointment Reminder Campaign Using New Wait Until Branching Logic

  • 2 February 2023
  • 0 replies
  • 488 views

Userlevel 2
Badge

In part one of this Wait Until series, we reviewed the new functionality added to Customer.io Wait Until actions and provided an example to leverage the new features in a dynamic abandoned cart campaign. If you haven’t done so, please review that article now to get familiar with what Wait Until can do and some special considerations for these types of campaigns. 

 

Appointment Reminder Campaign

With sophisticated branching in place, the Wait Until statement will become the centrepiece of our reminder campaign. When it comes to any given appointment, we are interested in waiting until one of three things happens. Either the client . . .

  • Reschedules the appointment

  • Cancels the appointment

  • Gets within three days of the scheduled appointment and receives a reminder

 

The campaign we design will take the appropriate action for each of the above scenarios.

 

Trigger

Here’s what the Trigger page could look like:

 

4lK3fHyEqmM4lQKaATwCjYdURoVu9JyIVBdBOc6px97yNFD9KDEUTkEW6dALTa4C7Ba2TLMGtZK-huQ-KW8cG1VqzzKUBKuYSTg_hGz3BMRgxMR-JqtyyaKEDfFWi7lYLORzMt5qE7UNC2v0tigfbpQ

 

In this example, we send an appointment_created event each time somebody either schedules a brand new appointment or reschedules an existing appointment. We also add a filter to ensure that only people who have engaged with our email messages in the last four months and have not been suppressed will enter and remain in the campaign. 

 

Below you can see the payloads for the appointment_created events. A rescheduled appointment adds two additional attributes to use in the campaign:

  1. appointment_rescheduled = boolean (value is true. Used for workflow branching and message personalization)

  2. original_appointment_date_time = timestamp (unix timestamp format, used in message personalization)

Event Example Payloads

New Appointment

Rescheduled Appointment

{

appointment_date_time: 1677703837

appointment_id: "aij1023"

appointment_location: "Downtown Office"

appointment_name: "Carolyn Lamersfeld"

appointment_type: "Career Coaching"

}

{

appointment_date_time: 1677790237

appointment_id: "aij1023"

appointment_location: "Downtown Office"

appointment_name: "Carolyn Lamersfeld"

appointment_rescheduled: true

appointment_type: "Career Coaching"

original_appointment_date_time: 1677703837

}

 

Since the campaign we are building gets triggered on each appointment_created event, and people might have multiple appointments scheduled during a given timeframe, we’ll need an attribute to match future events back to the original appointment made. In this example, we match back on the appointment_id unique identifier. 

 

Also note that times/dates for this campaign need to be specified as a Unix timestamp for our Wait Until logic to work properly.

 

Workflow

 

Here’s an overview of the entire Appointment Reminder campaign. Click the image or this link to download a PDF of the workflow.

 

9D6ruaqwiFiWN347EU4PNHVRZaybqACtll3_Nhx8sTvOCQ9iBNIuuKQ16QaHGCEKjoFWHjuvsjsrxORbOdVCKZnV_o10nTP7erfJ-KHfbSb2a2ictke7E2tSSsf1uFuv5ggkBMqj1ouaUIHxcpJwHiA

 

Appointment Confirmation Emails

We first want to send out an email confirming the new or rescheduled appointment. Since we’ve chosen to create a separate email for each flavor (new or rescheduled), we branch on whether the appointment_rescheduled event attribute is equal to true.


 

tgojChY-sLsNwmNnEDDS1mxpf0cekbqSsIDjWvymE1qjUTodaG2ykK1V4EwuVrdRQaoQZtYg_y9XSyPqoFtt0eRgiPRkEFNdTNRfTf3x9s2QRrY_lwvkre6MlilJpg7Up87udNCKsqSpEpbZKORaRbQ

 

Note, we could have skipped this branch and used Liquid logic and/or Drag & Drop Display Conditions to personalize the email content based on the appointment_rescheduled attribute instead. The Pro’s of the branch approach is that you can measure conversions of new vs. rescheduled appointments (see Adding a Conversion Goal below), while a single email makes for a simpler, more streamlined workflow.

 

Using the Wait Until Action to React to Future Events

As mentioned above, this campaign will get triggered every time a client creates a new or updated appointment. In the first path of our Wait Until, we handle this nuance by matching back on the appointment_id.

The first path waits for the appointment to be rescheduled. It does this by looking for the appointment_created event to fire again with the same appointment_id where the appointment_rescheduled event attribute is true. When it sees this, the journey exits.

 

1C4K5XYpLtjtTzQcICSvAnGk1axrU5EkdXyKb4HXf0mCiMwuY7Ge6iViuVyxOG9kwsCNdSx4fNhfW4yiwoiJfFU5s5XRIE_dAx5n71vzB2-V9qjI9rufbXbkMk4bpu30bCi-37xLeuNG4q8SKIsp8fU

 

You can think of the process like this:

  1. The appointment_created event fires to create a new appointment and a new campaign journey (journey #1).

    1. The campaign sends the New Appointment confirmation email and enters the Wait Until.

    2. Two days later, but more than three days before the appointment, the client reschedules the appointment. This fires the appointment_created event with appointment_rescheduled = true.

    3. Path one conditions are met, and this user’s journey #1 exits the campaign.

  2. When the appointment_created event fired with appointment_rescheduled = true above, it also created journey #2.

    1. Journey #2 sends the Updated Appointment confirmation email and enters the Wait Until.

    2. At this point, the appointment can be rescheduled again, cancelled, or get within three days, triggering the reminder messages. 

 

The other two Wait Until paths do the following:

 

Path 2 watches for this appointment to be cancelled. If it is, the journey sends a cancellation email and exits.

9Ro5IZvk8QMisEuFF2F00Ofxv2vOlGTRb7Y9phl8Vw9Xnq96cltmxjxxewsHFv5z6ZNonS4essm0rLmK2Fj4thahYZPZ1rsNsG0lRYDJcx8e_GqrqJ71L9eykaWzvgdB5ws1C9Ot2NbAmsk6xPbiHQI


 

If neither Path 1 nor Path 2 conditions are met before the journey hits 72 hours (3 days) before the appointment, the client goes down the third path. Here, email and SMS confirmation messages are sent out to the client, and they start a new Wait Until.

 

fXdSRuKh28xQOos-2h-DF2Pt4-b7DgzrtYNOQEmioonbBNjyT7wngM95GzrcuVgActUzTJHLFDPTIxPkssdqdFjFrhqM-rovkCtTH4sHKVZeQuU9nU_9HtSSqTW3oSj1892mHQ8HhlCvnj0COBjJC1M


 

This second Wait Until group mirrors the first, with the first two paths being exactly the same. 

1o_IJMPtuce5jlgMrAdfI8nFjYq8IJev3CEqMb945gXwHgLrtiyAw6-RsQI4DuvdU1sozA3HEm_BEtFp5vx8rH57nV6LYpMozxDID4imPaxN6WbAjJpiMV3PCRnKrvDc84xk8FEOV2f3cVr_2iJoHME

The third path in this group is now waiting long enough for the appointment date and time to pass, in case the client reschedules or cancels the appointment after the three-day reminders are sent but before the appointment takes place.

 

YKPmFaLQZSPdn7dx57v4Yt2HQxhIFD4V75JZRwtj9krp7zSaZcoOWy8Fw4_mCZE-lu3RSqNIdDt8TGRxq8bUOYfUDfKplxrAq0E0Du-lZbGmdOhLiU8kzCZYVqqo43m4DA4HVOSVDJh2bqJ0ED9Q20Y

 

Adding a Conversion Goal

We are measuring the success of this campaign based on a new or rescheduled appointment being kept within one week of opening a message from this campaign. For this example, we assume that keeping the appointment triggers a second campaign with a follow-up email.
 

 

And there you have it! If you use this recipe, be sure to let us know your experience below.

 

 


0 replies

Be the first to reply!

Reply