How to get started with sandbox
Get a Test API Key
To get a test API-KEY you can:
Send a WhatsApp message from your phone to the phone number
4930609859535with the contentSTART(STARTmust be in all UPPERCASE)Use this link: https://wa.me/4930609859535?text=START
Use this QR code:

As a response, you will receive your TestAPIKEY.This API-KEYis associated with your phone WhatsApp number. Now you are able to use the 360dialog WhatsApp API.
Set your Sandbox Webhook URL
Use the following call:
POST https://waba-sandbox.360dialog.io/v1/configs/webhook
Inbound messages sent by you to your WhatsApp Phone Number will be sent to your Webhook. You can use an external service (such as requestbin.com) to test webhook responses, or you can create your own webhook server for tests. In the case you want to test with localhost, you may use an external service (such as ngrok).
Use the API-KEY as authorization, with the value D360-API-KEY.
Headers
D360-API-KEY (string)
1234567_sandbox
7IuLe3Tiy8Rc
Request Body
url (string)
Your webhook URL
ZJNvBEj2kIZR
{
"url": "https://your-webhook-url"
}Respond using the Sandbox API
Send response message
POST https://waba-sandbox.360dialog.io/v1/messages
You can send a response message (or a message template) to your phone WhatsApp number with the above request URL and the body parameters as described below. Use the API-KEY as authorization, with the value D360-API-KEY.
Headers
D360-API-KEY
(string)
1234567_sandbox
u2IZcEqtU5HE
Request Body
recipient_type
(string)
individual
OdwjcoBby9EN
to
(number)
Your number
cj7rYJ4iOSLl
type
(string)
text (default)
dHlp6k07AtU2
text
(object)
contains body field
70HnBRIrmj12
{
"messages": [
{
"id": "message_id"
}
],
"meta": {
"api_status": "stable",
"version": "2.31.5"
}
}{
"messaging_product": "whatsapp",
"recipient_type": "individual",
"to": "your-number",
"type": "text",
"text": {
"body": "Hello, dear customer!"
}
}Send a Template Message (optional)
There are 3 templates available to test in the Sandbox. There is no possibility to add or edit a Sandbox templates, you must use the predefined templates. Templates are:
disclaimerUsing this template will just send a regular text message, which can’t be edited.first_welcome_messsageThis is an example of a template with a personalization possibility (you can personalize the receiver's name).interactive_template_sandboxThis template contains 2 buttons for which you can pass customer URLs.
Last updated
Was this helpful?