3 Steps to migrate to the WhatsApp API:
It is important to prepare a backup of your current webhook setting before you switch to the WhatsApp API in our system.
Send GET /v1/configs/webhook
and store url address from response.
Send POST /v1/configs/webhook
with your webhook endpoint:
{"url": "https://www.example.com/webhook"}
Webooks will be sent as described in WhatsApp Business API
Webhooks & callbacks mapping from Messaging & Conversations v1 API (old) to WhatsApp API (new): Messaging & Conversations v1 API (old) → WhatsApp API (new)
In the new WhatsApp API only https code 200
is allowed in webhook response. Any other code (including 201
) will be interpreted as not delivered, and message will be sent again.
Switch to use new WhatsApp API instead of current API.
Please remember that WhatsApp API calls are compatible with WhatsApp Business API and are not backward compatible with previous API version.
Sending a WhatsApp free text message Messaging & Conversations v1 API (old) → Whatsapp API (new)
Sending a WhatsApp template-based message Messaging & Conversations v1 API (old) → Whatsapp API (new)
Sending a message with an image Messaging & Conversations v1 API (old) → Whatsapp API (new)
Sending a message with file attachments Messaging & Conversations v1 API (old) → Whatsapp API (new)
Sending a WhatsApp Contacts message Messaging & Conversations v1 API (old) → Whatsapp API(new)
Sending a WhatsApp static location message Messaging & Conversations v1 API (old) → Whatsapp API (new)
Retrieving file attachments Messaging & Conversations v1 API (old) → Whatsapp API (new)
Uploading file attachments Messaging & Conversations v1 API (old) → Whatsapp API (new)
Webhooks & callbacks Messaging & Conversations v1 API (old) → Whatsapp API (new)
Configs Messaging & Conversations v1 API (old) → No longer valid.
In case a revert will be needed:
Just switch the webhook to the previously saved url via POST /v1/settings/webhook
(Set webhook url). And revert your system to use old API version.