Version | Date | Changes |
---|---|---|
2.2.0 | 01/31/2025 | 📌 Add reference and recipients attributes in the response of the message resource and add URL versioning (waba/1.1/json ) |
2.1.0 | 10/03/2024 | 👩🏻💻 Add interactive list and interactive button group for Whatsapp API. |
2.0.0 | 06/28/2024 | 📞 Start of the SMSBOX Documentation on github with our Whatsapp API documentation . |
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Text) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "text",
- "text": {
- "body": "Message sent via my WhatsApp Business agent."
}
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Audio) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "audio",
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Document) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "document",
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Image) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "image",
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Sticker) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "sticker",
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Video) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "video",
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (Location) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "location",
- "location": {
- "longitude": 6.075501230687077,
- "latitude": 43.08811078662267,
- "name": "SMSBOX",
- "address": "20 Av. Élie Gautier, 83320 Carqueiranne"
}
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (ReplyText) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "text",
- "context": {
- "message_id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx"
}, - "text": {
- "body": "Reply to a previous message."
}
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (ReplyReaction) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "reaction",
- "reaction": {
- "message_id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "emoji": "😀"
}
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
type required | string Value: "interactive" |
required | object |
{- "type": "interactive",
- "interactive": {
- "type": "list",
- "header": {
- "type": "text",
- "text": "string"
}, - "body": {
- "text": "string"
}, - "footer": {
- "text": "string"
}, - "action": {
- "button": "string",
- "sections": [
- {
- "title": "string",
- "rows": [
- {
- "id": "string",
- "title": "string",
- "description": "string"
}
]
}
]
}
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
recipients | Array of strings <= 5000 items |
object (OTPTemplateMessage) |
{- "recipients": [
- "+336XXXXXXXX"
], - "contentMessage": {
- "type": "template",
- "template": {
- "name": "otp",
- "language": {
- "code": "en"
}, - "components": [
- {
- "type": "body",
- "parameters": [
- {
- "type": "text",
- "text": "123456"
}
]
}, - {
- "type": "button",
- "sub_type": "url",
- "index": "0",
- "parameters": [
- {
- "type": "text",
- "text": "123456"
}
]
}
]
}
}
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
message_id | string Received message ID |
status | string Value: "read" |
{- "message_id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "status": "read"
}
{- "response": {
- "response_code": "202",
- "response_desc": "Request successfully queued."
}, - "details": "Request accepted for processing.",
- "reference": "XXXXXXXXXXXXXX",
- "recipients": [
- {
- "submitted": "+33xxxxxxxxx",
- "rewrited": "33xxxxxxxxx",
- "state": "ACCEPTED",
- "reason_code": "PROCESSING"
}
]
}
wabaId required | string WhatsApp Business Agent ID |
phoneID required | string WhatsApp Business Agent's Phone Number ID |
file_id required | string File ID received via webhook |
{- "file_id": "1234567890"
}
{- "response": {
- "response_code": "200",
- "response_desc": "Request successfully processed."
}, - "details": "Done.",
- "data": {
- "mime_type": "application/pdf",
- "sha256": "string",
- "file_size": "string",
- "caption": "string",
- "raw": "data:application/pdf;base64,xxxxxxxxxxxxxxxxxx"
}
}
Important:
When a client or user submits an image, video, or other file that does not comply with the WhatsApp Business limitations, the WhatsApp agent is notified via a text
type webhook with the details of the encountered error.
For example: Failed to download incoming media due to internal error.
Because a client attempted to submit a document larger than 100 MB.
It is recommended to monitor this type of webhook.
object | |
wabaId | string WhatsApp Business Agent ID |
phoneId | string WhatsApp Business Agent's Phone Number ID |
phoneNumber | string WhatsApp Business Agent's Phone Number |
clientId | integer SMSBOX user account ID |
requestProd | string Channel Value: "WABA" |
requestDate | string <date-time> Datetime of the sent message |
requestUUID | string <uuid> |
requestType | string Value: "incoming_message" |
{- "data": {
- "from": "33XXXXXXXXX",
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "timestamp": "1719576000",
- "text": {
- "body": "Hello 🙂"
}, - "type": "text",
- "is_error": "yes"
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "incoming_message"
}
object | |
wabaId | string WhatsApp Business Agent ID |
phoneId | string WhatsApp Business Agent's Phone Number ID |
phoneNumber | string WhatsApp Business Agent's Phone Number |
clientId | integer SMSBOX user account ID |
requestProd | string Channel Value: "WABA" |
requestDate | string <date-time> Datetime of the sent message |
requestUUID | string <uuid> |
requestType | string Value: "incoming_message" |
{- "data": {
- "from": "33XXXXXXXXX",
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "timestamp": "1719576000",
- "type": "document",
- "document": {
- "filename": "filename.pdf",
- "mime_type": "application/pdf",
- "sha256": "string",
- "id": "1234567890",
- "caption": "string"
}
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "incoming_message"
}
object | |
wabaId | string WhatsApp Business Agent ID |
phoneId | string WhatsApp Business Agent's Phone Number ID |
phoneNumber | string WhatsApp Business Agent's Phone Number |
clientId | integer SMSBOX user account ID |
requestProd | string Channel Value: "WABA" |
requestDate | string <date-time> Datetime of the sent message |
requestUUID | string <uuid> |
requestType | string Value: "incoming_message" |
{- "data": {
- "from": "33XXXXXXXXX",
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "timestamp": "1719576000",
- "type": "image",
- "image": {
- "mime_type": "image/jpeg",
- "sha256": "string",
- "id": "1234567890",
- "caption": "string"
}
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "incoming_message"
}
object | |
wabaId | string WhatsApp Business Agent ID |
phoneId | string WhatsApp Business Agent's Phone Number ID |
phoneNumber | string WhatsApp Business Agent's Phone Number |
clientId | integer SMSBOX user account ID |
requestProd | string Channel Value: "WABA" |
requestDate | string <date-time> Datetime of the sent message |
requestUUID | string <uuid> |
requestType | string Value: "incoming_message" |
{- "data": {
- "from": "33XXXXXXXXX",
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "timestamp": "1719576000",
- "type": "video",
- "video": {
- "caption": "string",
- "mime_type": "video/mp4",
- "sha256": "string",
- "id": "1234567890"
}
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "incoming_message"
}
object | |
wabaId | string WhatsApp Business Agent ID |
phoneId | string WhatsApp Business Agent's Phone Number ID |
phoneNumber | string WhatsApp Business Agent's Phone Number |
clientId | integer SMSBOX user account ID |
requestProd | string Channel Value: "WABA" |
requestDate | string <date-time> Datetime of the sent message |
requestUUID | string <uuid> |
requestType | string Value: "incoming_message" |
{- "data": {
- "from": "33XXXXXXXXX",
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "timestamp": "1719576000",
- "type": "reaction",
- "reaction": {
- "message_id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "emoji": "👍"
}
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "incoming_message"
}
object | |
wabaId | string WhatsApp Business Agent ID |
phoneId | string WhatsApp Business Agent's Phone Number ID |
phoneNumber | string WhatsApp Business Agent's Phone Number |
clientId | integer SMSBOX user account ID |
requestProd | string Channel Value: "WABA" |
requestDate | string <date-time> Datetime of the sent message |
requestUUID | string <uuid> |
requestType | string Value: "incoming_message" |
{- "data": {
- "from": "33XXXXXXXXX",
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "timestamp": "1719576000",
- "type": "location",
- "location": {
- "address": "20 Av. Élie Gautier, 83320 Carqueiranne",
- "latitude": 43.0875153,
- "longitude": 6.0754154,
- "name": "SMSBOX",
}
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "incoming_message"
}
Message status
required | object |
wabaId required | string WhatsApp Business Agent ID |
phoneId required | string WhatsApp Business Agent's Phone Number ID |
phoneNumber required | string WhatsApp Business Agent's Phone Number |
clientId required | integer SMSBOX user account ID |
reference required | integer Internal ID of the sent message |
requestProd required | string Channel |
requestDate required | string <date-time> Datetime of the sent message |
requestUUID required | string <uuid> |
requestType required | string Value: "status_update" |
{- "data": {
- "id": "wamid.xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
- "status": "failed",
- "timestamp": "1719576000",
- "recipient_id": "33XXXXXXXXX",
- "errors": [
- {
- "code": 131047,
- "title": "Title of the error.",
- "message": "Error message.",
- "error_data": {
- "details": "Detaiils of the error.",
}
}
]
}, - "wabaId": "xxxxxx",
- "phoneId": "xxxxxx",
- "phoneNumber": "xxxxxx",
- "clientId": 123456,
- "reference": 1234567890,
- "requestProd": "WABA",
- "requestDate": "2024-06-01T14:00:00+02:00",
- "requestUUID": "xxxxxx",
- "requestType": "status_update"
}