What are webhooks

Webhooks are simple web calls which allow one system to send information to another system. A good example is to notify the Barilliance customer email provider to opt out an email address if this email address is opted out by unsubscribe link on Barilliance triggered emails.

Setting up the webhooks.

Go to Barilliance Settings page and scroll to the Webhooks page

Follow these steps:

  1. Paste the webhooks receiving URL of the target system in the Webhook URL
  2. Select the data format which works with the other platform.  See below for the supported formats.
    The right format depends on the other system which receives the webhook calls
  3. On Values to send, name the variable which will receive the unsubscribed email address.
  4. Optionally add other fixed variables (lines 2-4)
  5. Add a comment if needed and Save the changes and 

Supported formats

Set the following format based on the requirement of the other platform.
URL params - the data is passed as parameters in the url for example:
https://otherplatform.com/theurl?email=david@smith.com&otherdata=xxx

Post Param -  the data is passed as POST parameters in the call headers.

Json - data is passed as a json object containing the values in the call body.

{email} token in the webhook url - the token {email} can be added in the url of the webhook and it will be replaced by the email address.


Sending MD5 encoded value of the email

Some systems require sending the MD5 hash of the email address instead of the email itself. To support this requirement check the 'Send emails as MD5 encoded string' checkbox

 
Basic Authentication support

If the other platform require basic authentication, You can add username and password to the webhook url in this format:
https://username:password@otherplatform.com/webhook/endpoint/

How to Debug the webhooks

To debug the webhooks. 

  1. send yourself a test triggered email from Barilliance. It is recommended to use an email address you dont need since the test may unsubscribe you from your own lists and from Barilliance.
  2. Click the unsubscribe link on the email
  3. Wait for about 10 minutes
  4. Go to Barilliance Settings page and click the 'DEBUG LAST CALL' button. you will see the details of the webhook call.
  5. Check in your system that the email address has indeed opted out/blocked.
Did this answer your question?