How to trigger WhatsApp Messages inside of Klaviyo
How can I trigger WhatsApp Messages from a Klaviyo flow?
It's easy to connect Coco Webhooks to Klaviyo to trigger a WhatsApp Message from an existing Klaviyo flow without any devs.
Step 1: Configure the Webhook in Coco
Navigate to the Webhook section of the Coco dashboard in the Left hand menu and click on Webhooks. Within the Webhooks page click the "Create Webhooks" button.
Step 2: Enter the Webhook information
Create a name for the webhook. Best practice is to name the webhook after what you are using it for (e.g. Klaviyo Browse Abandon Flow Recovery #3).
Select or Create a Template.
The Topic and Whitelisted integration will be preselected for the types of messages and integrations you can select.
Once you have selected a template click Create Webhook.
If you have already created a Flow or Campaign Template you can select it from the Dropdown. If you need to create a template you can do so with the "Create new template" button — it will open up the template editor.
Step 3: Add a Webhook to your Klaviyo flow
When you create the webhook in Coco this screen will appear with all of the information you need. Leave this page open so it's easy to copy and paste the information into Klaviyo.
Create a webhook action
Log into your Klaviyo flows page. Find the flow you want to integrate and click to edit it. On the left pane of the flow editor, find "Webhooks" from the list of available Actions and click+drag it to your flow.
Configure the webhook
Copy each field from the Coco pop up and place it in the same named field inside of the Klaviyo webhook.
Copy and paste the Destination URL.
You will need to create a 2nd Header (there should be 2 total).
Add
x-coco-idinto Header 1 andx-coco-secretinto Header 2.Add the Values for each into the corresponding Value section.
Copy and paste the JSON payload into the JSON Payload section. Remove the existing content and paste the below exactly as-is:
{ "phone_number": "{{ person.phone_number }}", "email": "{{ person.email }}"}
Don't forget to turn on the Block in Klaviyo!
Don't forget to turn on the send block to start sending messages between Klaviyo and Coco. Be careful when testing — you may have added customers to the flow in Coco that will be sent messages when the send block is enabled. To prevent this, clear any pending events in the flow prior to enabling the send block.