This app is currently in beta. Expect ongoing updates and improvements. Your feedback is appreciated to enhance the app’s functionality.
To move to the 360Dialog Cloud API from the on-premise API, refer to the 360Dialog documentation.
The WhatsApp 360Dialog app (Cloud API) is an integration for Rocket.Chat in partnership with 360Dialog, an official WhatsApp Business API provider offering message templates, automation, support, and data protection services. It is a paid subscription and costs you $39 per month. Alternatively, you can use the WhatsApp Cloud app, which connects Rocket.Chat directly to WhatsApp without any third-party service.
Rocket.Chat’s 360Dialog (cloud API) app allows you to integrate your WhatsApp conversations with your Rocket.Chat workspace. You can send and receive text and media messages, send template messages, and register webhooks to receive messages. This document guides you through the app configuration details.
Prerequisites
A Rocket.Chat workspace with Omnichannel enabled. Livechat agents and managers must also be assigned.
A 360Dialog account; create a 360Dialog account if you don’t have one.
Add numbers to the account.
From 7.0, the WhatsApp 360Dialog app (Cloud API) requires a subscription add-on. Contact the sales team to get the required add-on.
Before you proceed, keep the following points in mind about the data storage region:
Our 360Dialog Cloud API architecture uses Meta for default data storage, hosted in the US. Depending on your location, this could involve an international data transfer. Even if you opt to change the storage location, our omnigateway remains situated in the US, necessitating an international data transfer. Refer to our Privacy Policy for information on data transfers.
If you are a current 360Dialog customer and considering to transition from the on-premise API to the Cloud API, you can proceed independently. However, we recommend ensuring compliance with privacy regulations relevant to your jurisdiction.
If you have any questions or require support, contact our privacy team.
Install the WhatsApp 360Dialog app (Cloud API)
Go to Administration > Apps > Marketplace.
Search for the WhatsApp 360Dialog (Cloud API) app.
Click Subscribe.
If you don’t have the required add-on, a warning is displayed for you to contact sales to get the add-on.
Click Install and accept the needed permissions. Complete the purchase and the app bot will then send you a message with the setup instructions in the #omnichannel-whatsapp-cloud-api-setup private channel.
Configure the WhatsApp 360Dialog app (Cloud API)
After installing the app, you can update the app settings according to your requirements. To do this, follow these steps:
On the App Info page of the app, go to the Settings tab.
Enter the values for the following fields:
Field | Description |
---|---|
Agents Display Info | Select the agent information that would be added to every agent's message. The options are as follows:
|
File Uploads Enabled | Select this option to enable file upload in the conversations. By default, file upload is enabled. |
Maximum File Upload Size (in bytes) | Enter the maximum file size that can be uploaded. Set it to |
Accepted Media Types | Enter the file media types that you want to accept. This is a comma-separated list of media types. Leave it blank to accept all media types. By default, the value is |
Allow Quote Messages | If this option is enabled, agents can see the message when the contact quotes or replies to a message on WhatsApp. |
Template Message Metadata Refresh Interval(in Minutes)* | For a better user experience, the app will cache some template messages’ meta-data information. This setting defines the duration the app will automatically refresh its cache. Send template messages using the Send a template message endpoint. |
Message Status Endpoint URL | Enter an endpoint URL where you want to receive the status of each message that is exchanged. |
Filter Message Status | Select the statuses you want to receive at the Message Status Endpoint URL endpoint based on the message type. The options are as follows:
By default, the value is All. |
Allow List options for Quick Replies | If this option is enabled, then messages with more than three quick reply options will be rendered as list options. Note that the maximum limit for list options is ten. By default, this option is enabled. |
Custom label for all List Option button* | Enter the custom label message you want to display on all quick reply options that are sent as a list. By default, the message is Show Options. |
Preferred Language* | Select the preferred language for this app. We'll try to show system messages in this language. If it is not available, then English will be used. By default, English is selected. |
Connect WhatsApp numbers
After installing and configuring the app, connect verified WhatsApp numbers in the #omnichannel-whatsapp-cloud-api-setup private channel to enable communication. The bot sends the message Do you currently have a 360Dialog account? - If you don't we'll create one
. Click No if you don’t have a 360Dialog account. Create an account first, then proceed with the following steps. If you have an account, click Yes and follow these steps:
Click Connect WhatsApp Number and enter the following details according to your requirements:
Field | Description | Example |
---|---|---|
API Key* | Enter the API key that you generated in your 360Dialog account. |
|
Phone Number* | Enter the WhatsApp number that you have added to the 360Dialog account. |
|
Department | Select the department from the drop-down menu. Ensure that departments are created and agents are assigned to the departments. |
|
Welcome Message (optional) | Enter the message that your customers receive automatically when they message you. |
|
Conversation Finished Message (optional) | Enter the message that your customers receive automatically when an agent closes the conversation. |
|
Default message for offline service (optional) | Enter the message that your customers receive automatically when no agent is available for the conversation. |
|
Once you have entered the details, click Connect.
You receive a success message that your WhatsApp number is now connected! Now, anyone in your organization can receive messages from this number and reply via Rocket.Chat. If your business has not yet been verified by Facebook, you need to start the business verification process within the Facebook Business Manager.
If you get an error message, check the app’s Logs tab to find the cause. If the issue is related to an invalid token, contact the Rocket.Chat support team for assistance.
Manage connected WhatsApp numbers
After the number has successfully been connected to Rocket.Chat, you can click Edit to modify the details.
Click Disconnect to remove the connected number.
App slash commands
Enter the slash command /whatsapp-360d-cloud
to use the following shortcuts:
/whatsapp-360d-cloud connect
: Connect a new WhatsApp number./whatsapp-360d-cloud numbers
: View and edit all connected WhatsApp numbers./whatsapp-360d-cloud view-templates
: See all template messages. The information displayed includes the name, the WhatsApp number connected, and the languages used. Click Refresh Templates to sync the 360Dialog template messages with Rocket.Chat./whatsapp-360d-cloud send-template
: Send a template message./whatsapp-360d-cloud support
: Get support information./whatsapp-360d-cloud help
: See the list of shortcuts.
API endpoints
The available endpoints are displayed on the Details tab of the App Info page.
Get success message
The GET authSuccess
endpoint is called when 360Dialog’s authentication process is successful. After registering an account on 360Dialog, 360Dialog automatically calls this endpoint and redirects back to the workspace upon successful authentication. You don’t need to take any action from your end.
For example, the request looks like this:
curl -X GET https://{workspace-url}/api/apps/private/87cf50f2-2db4-4e05-a8fd-135ad24f9c08/6683e1680f160e8654ffd46b/authSuccess
Incoming message
The POST incoming
endpoint is used by the app to receive messages from WhatsApp. You generally don’t need to take action with this endpoint.
For example, the request looks like this:
curl -X POST https://{workspace-url}/api/apps/private/87cf50f2-2db4-4e05-a8fd-135ad24f9c08/6683e1680f160e8654ffd46b/incoming
Send a template message
You must use the POST templateMessage
endpoint to send template messages. For more details, refer to the developer guide on sending template messages in Rocket.Chat and the 360dialog template messages guide.
For example, the request looks like this:
curl -X POST https://{workspace-url}/api/apps/private/87cf50f2-2db4-4e05-a8fd-135ad24f9c08/6683e1680f160e8654ffd46b/templateMessage
The request body should look something like this:
"phoneNumbers": [
"xxxxxxxxxxxxx"
],
"connectedWhatsAppNo": "555195251xxx",
"template": {
"name": "boarding_pass",
"language": {
"code": "en",
"policy": "deterministic"
},
"components": [
{
"type": "header",
"parameters": [
{
"type": "text",
"text": "halo"
}
]
},
{
"type": "body",
"parameters": [
{
"type": "text",
"text": "abc"
},
{
"type": "text",
"text": "xyz"
}
]
}
]
}
}
Get the sidebar icon
You can use the GET get-sidebar-icon
endpoint to get the WhatsApp conversation room icons displayed in the Chats in Progress section on the left-hand menu.
For example, the request looks like this:
curl -X GET https://{workspace-url}/api/apps/public/87cf50f2-2db4-4e05-a8fd-135ad24f9c08/get-sidebar-icon