Sending Proactive Messages via webhook triggers through Hubspot
Using our proactive message endpoint, it is possible to initiate WhatsApp conversations through webhooks integrated with Hubspot. These webhooks can be fed with Hubspot's database information, making the message dynamically contextual.
π When to use this integration?
Use this flow when you want to:
-
Automatically send a WhatsApp message (using a Meta-approved template) via Cloud Chat triggered by an action in HubSpot
-
Personalize the message with contact properties from HubSpot (name, order number, status, among others)
-
Create automated follow-up, billing, onboarding, or status update flows
β Prerequisites
Before configuring the endpoint, you need:
-
Have your WhatsApp number connected to Cloud Chat and possess the corresponding inbox_id.
Refer to the FAQ: Master Guide β How to connect your WhatsApp number to Cloud ChatThe inbox_id can be found by accessing the inbox settings in Cloud Chat. The URL will follow this pattern:
https://cloudchat.cloudhumans.com/app/accounts/{{account_id}}/settings/inboxes/{{inbox_id}} -
Have an approved template on Meta registered in Cloud Chat.
Access the FAQ: How to create WhatsApp templates in Cloud Chat (creation, editing, and approval). -
Have your Cloud Chat API Key ready.
Visit the following FAQ to obtain the key and token: API: Send proactive message via WhatsApp.
Step 1: Create the Workflow in HubSpot
To create a proactive trigger webhook in a HubSpot workflow, follow the steps below.
In the main HubSpot sidebar, hover over the automation icon and then click on Workflows to be redirected to the workflows dashboard:

Once in the dashboard, click on Create workflow and then select From scratch:

Choose the options that will trigger this event:

Step 2: Configure Webhook Sending
With the initial workflow setup complete, now we need to build the payload to be sent in the webhook.
To start configuring the webhook, click the add action button (+):

On the left panel, click Data Operations and then select Send a webhook:

In the method selector, choose POST:

Next, fill in the webhook URL and API key information:
URL: https://{CLOUDCHAT_DOMAIN}/api/v1/accounts/{ACCOUNT_ID}/conversations/create_proactive_whatsapp_conversation

To set up the API Key, click Add secret. A window will appear requesting the Secret Name and Secret Value.

Fill in the Secret Name with api_access_token and in the Secret Value field, enter the Cloud Chat API Key previously saved.
Payload Structure
Finally, fill in the body (payload) of the request to perform the trigger, including:
-
template_name (required) β static value matching the exact name of the approved template in Cloud Chat.
-
inbox_id (required) β static value that identifies the Cloud Chat inbox.
-
phone_number (required) β dynamic field using HubSpot variable
{{contact.phone}}. -
Template variables β When registering the template in Cloud Chat, the configured variables must have exactly the same name as the properties sent by HubSpot in the payload.
This means the variable name in the template must be identical to the field name sent in the webhook (respecting spelling, case sensitivity, and underscores), to ensure proper value substitution at the time of firing.
Below is an example of a payload:

Note: The variables used above, as well as the URL for the webhook and API key information, are discussed in the proactive API messaging section.