Notify
WhatsApp Notification API — Send Transactional Messages
The WhatsApp notification API allows you to send automated, one-way transactional WhatsApp messages to customers at scale. With 99.9% delivery success rates and rich media support, it is the ideal channel for time-sensitive notifications that need to be seen.
Use Cases
- Transaction confirmations and payment receipts
- Order shipped / delivery status updates
- Appointment reminders
- Fraud alerts and account security warnings
- Service interruption and maintenance alerts
- Account activity notifications
Send a WhatsApp Notification
Endpoint
POST https://api.dexatel.com/v1/messagesRequest Parameters
from
Type: string
Required: Yes
Your WhatsApp sender name (unique identifier)
to
Type: array
Required: Yes
Array of recipient phone numbers as digits only, beginning with the country dialing code (e.g. 14155552671)
channel
Type: string
Required: Yes
Must be WHATSAPP
type
Type: string
Required: Yes*
Message type. Required for non-template sends. Accepted values: text, image, video, document
text
Type: string
Required: Yes*
Message text (up to 1,000 characters). Required for type: text. Only available within an active 24-hour session window when sending without a template
template
Type: string (UUID)
Required: No
ID of an approved WhatsApp template to use. Required for outbound messages outside an active session window
variables
Type: array
Required: No
Variable values to substitute into template placeholders, in order of appearance
url
Type: string
Required: Yes*
URL of the media file. Required when type is image, video, or document
button_type
Type: string
Required: No
Button type. Only accepted value: quick_reply. Must be provided together with button_text
Text Message Example
curl -X POST "https://api.dexatel.com/v1/messages" \
-H "X-Dexatel-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"data": {
"channel": "WHATSAPP",
"from": "MyBusiness",
"to": ["14155552671"],
"type": "text",
"text": "Your order #12345 has shipped! Expected delivery: Jan 18. Track at: https://track.example.com/12345"
}
}'Rich Media — Image Notification
curl -X POST "https://api.dexatel.com/v1/messages" \
-H "X-Dexatel-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"data": {
"channel": "WHATSAPP",
"from": "MyBusiness",
"to": ["14155552671"],
"type": "image",
"url": "https://cdn.example.com/order-receipt.jpg",
"text": "Your order is on the way!"
}
}'Notification with Button
curl -X POST "https://api.dexatel.com/v1/messages" \
-H "X-Dexatel-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"data": {
"channel": "WHATSAPP",
"from": "MyBusiness",
"to": ["14155552671"],
"type": "text",
"text": "We noticed unusual activity on your account.",
"button_type": "quick_reply",
"button_text": "Review Activity"
}
}'Template-Based Notification
For outbound messages to users who have not messaged you in the last 24 hours, you must use a pre-approved WhatsApp message template. All WhatsApp message templates are submitted via the Dexatel API and reviewed by Meta before use. Reference the template by UUID and supply variable values:
curl -X POST "https://api.dexatel.com/v1/messages" \
-H "X-Dexatel-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"data": {
"channel": "WHATSAPP",
"from": "MyBusiness",
"to": ["14155552671", "19175550100"],
"template": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"variables": ["John", "Order #12345"]
}
}'WhatsApp Media Limits
Image
Max Size: 5 MB
Formats: JPG, PNG
Video
Max Size: 16 MB
Formats: MP4
Document
Max Size: 100 MB
Formats: PDF
Retrieve a Message
GET https://api.dexatel.com/v1/messages/{id}curl -X GET "https://api.dexatel.com/v1/messages/b2c3d4e5-f6a7-8901-bcde-f12345678901" \
-H "X-Dexatel-Key: YOUR_API_KEY"List Messages
GET https://api.dexatel.com/v1/messages# Filter by channel and status
GET /v1/messages?filter[channel]=WHATSAPP&filter[statuses]=delivered,read# Filter by date range
GET /v1/messages?filter[created_date_start]=2024-01-01 00:00:00&filter[created_date_end]=2024-01-31 23:59:59Updated about 2 hours ago