How can we help?

Welcome message

Overview

A welcome message is an automated message that's sent when a customer signs up for your email list, newsletter, loyalty, or rewards program. The message can be configured so it's sent to a contact once they perform a particular action, such as submitting a form or clicking a button on your site.

The welcome message is an important initial communication between you and your customer. It should set expectations about the value and cadence of the communications they'll receive. The welcome message strategy can be a single message or a series of messages.

Implement the trigger

In order for a welcome message to send, there needs to be data sent to the system that will trigger the automation. In the following example, we'll trigger a welcome message when a contact is added to a list. Learn more about how to create list attributes here.

There are two implementations you can use to send the data to Cordial:

The list attribute strategy utilizes one primary piece of data.

  • Purpose: Used to flag a contact as "in" or "out" of a specific segment, newsletter subscription, loyalty program, rewards program, or interest group. We recommend that you enable "Date Tracking" for the list. This setting tells the system to record the date a contact is added.
  • Data type: A list is a type of contact attribute. This value is passed as a boolean true/false value.

JavaScript Listener implementation

The following function should be executed when a customer provides their email address and expresses interest in receiving promotional messages via a form or checkout process.

Note: This article assumes you have implemented JavaScript Listener v2. We have also included examples applicable to JavaScript Listener v1 in the event you are not using v2 at this time.
var auth_data = {
	email: 'fred@example.com'
}
var contact_data = {
    'channels': {
        'email': {
            'subscribeStatus': 'subscribed',
        }
    },
    'list_name': true
};

crdl('contact', auth_data, contact_data);

In JS listener v1, the cordial.identify sets the cookie and the cordial.contact adds or updates the contact record.

cordial.identify(fred@example.com);
cordial.contact({
	'$list_name': true,
	'channels': {'email': {'subscribeStatus': 'subscribed'}}
});

Learn more about the crdl(contact) method here.

REST API implementation (server-side alternative to JavaScript)

Note: The REST API implementation is an alternative method to the Embedded JavaScript Listener. This is a server-side approach to sending the data to Cordial.

Method to call when subscribing a contact to a list:

  • POST v2/contacts (adds a new contact record or updates an existing contact record)
{
  "channels": {
    "email": {
      "address": "fred@example.com",
      "subscribeStatus": "subscribed"
    }
  },
  "$list_name": true
}

Create the automated message

Now that we have the appropriate data (passed by either the JavaScript listener or the REST API) we can set up the event triggered automation template.

1. From the Cordial Dashboard, navigate to Message Automation > Create New Automation.

2. In the left panel under Sending Method, select Event Triggered.

3. For Trigger event, choose When a contact is added to a list and select the name of the list you would like to target.

4. For Delivery time select Send Immediately. You have the option to delay the message, but in most cases an immediate response is appropriate.

5. For "How often can this message be sent to an individual" select "Once only."

6. Save the trigger setting.

7. Once this is saved and the message content is published, you can Enable the message. As soon as a message is enabled the triggers are active and will send the message according to the rules applied.

In the next article, you can learn how to set up a welcome series.

Comments

0 comments

Article is closed for comments.