Datasource sending is an integration feature that allows you to integrate our platform with your system, so you can have total freedom in terms of what data you personalise your messages with.

Enable the Datasource Integration Feature

To create a Datasource Integration, you first need to enable it. To do this:

  1. Hover over your username in the navigation and click Customer Profile*.
  2. In the Features tab, enable Datasource Sending.

You can now proceed to creating a Datasource Integration.

*If you can’t access this part of the platform, speak to your administrator.

Create a Datasource Integration

To create a datasource integration:

  1. Hover over your username in the navigation and click on Integrations.
  2. In the Contacts tab and select Datasource.
  3. Fill in the information for your integration:
    1. Title: The title used to identify your integration.
    2. URL: The URL of the external source where the data is retrieved (e.g.: your API endpoint).
    3. Username: The username used to authenticate requests to your external source.
    4. Identifier: This identifies the contact. It can be an email address, mobile number, or unique ID.
  4. Click Save. Your data source should now be added.

If you were to use a contact’s unique ID as an identifier (e.g.: ev-1), the structure of the data returned from your datasource would look something like this:


How to Use Datasource Integration

To use Datasource Integration in your messages:

  1. Select the element in your message that you want to personalise.
  2. Click on the personalisation icon (person icon).
  3. On the personalisation modal, select your datasource integration. This should show you a list of fields available from the integration.
  4. Select the field you want to use for the personalisation.
  5. Click Insert. This will personalise the field according to the data from your data source.

Create Your Own Datasource Endpoint Restful Route

To create your own data source endpoint, you’ll have to create a restful endpoint governed by Basic Auth. The endpoint will receive a POST request with a JSON body containing an array of 100 contact identifiers. A contact identifier is set up on our platform and can be one the contact’s email address, mobile number, or the unique id.

Here’s an example of a data source request making use of the contact’s unique ID in our platform:

curl --location --request POST 'local.everlytic.com/datasource.php' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \
--data-raw '["id_1","id_2", "id_3"]'

Your data source endpoint needs to return a structured JSON object. The JSON structure must include the following two properties:

  • Fields: This is an array of field names that are contained in the data source. Each field name needs to follow SQL databases column naming conventions.
  • Contacts: This is a list of contacts matching the request keyed by the identifier.

Expected response:

"contacts": { "datasource_identifier": {"contact_id" :"1", "contact_name": "lyall", "contact_lastname": "salkinder"}, "datasource_identifier": {"contact_id" :"1", "contact_name": "mike", "contact_lastname": "young"}