Skip to content
DutiesBook API
Open app

API overview

A powerful REST API for sending WhatsApp template messages from your backend systems. Build integrations that send automated messages, notifications, and broadcasts to your customers at scale.

The External API is a RESTful service that enables developers to programmatically send WhatsApp Business messages through their connected channels. Whether you need to send transactional notifications, marketing campaigns, or customer support messages, this API provides a simple and reliable way to reach your customers on WhatsApp.

The API handles all the complexity of WhatsApp Business Platform integration, template management, message delivery tracking, and contact management, allowing you to focus on building great customer experiences.

Credential verification

Test and validate your API credentials before integrating. Get instant feedback on authentication status.

Individual messages

Send personalized WhatsApp messages to individual recipients using approved templates with custom variables.

Bulk broadcasting

Send messages to up to 10,000 recipients at once. Perfect for campaigns, announcements, and mass notifications.

Template management

Retrieve and manage your WhatsApp message templates. Filter by status, category, and language.

Delivery tracking

Monitor message status in real-time. Track sent, delivered, read, and failed messages.

Contact management

Automatic contact creation and management. Send to new numbers without pre-registration.

Use cases

  • E-commerce: Order confirmations, shipping updates, delivery notifications
  • Appointments: Booking confirmations, reminders, cancellations
  • Marketing: Promotional campaigns, product launches, special offers
  • Customer Support: Support tickets, status updates, resolution notifications
  • Authentication: OTP codes, login verification, password resets
  • Alerts: System notifications, payment reminders, account updates

Authentication

All API requests require three custom headers for authentication. These credentials uniquely identify your organization and authorize access to your WhatsApp channels.

X-Account-Id: acc_xxxxxxxx Your organization identifier
X-Api-Key: pk_xxxxxxxxxxxxxxxxxx Public API key
X-Secret-Key: sk_xxxxxxxxxxxxxxxxxx Secret key - keep confidential!

Where to find: Organization → API Key

EndpointMethodDescription
/auth/verifyPOSTVerify API credentials
/channelsGETList accessible channels
/channels/:channelIdGETGet channel details
/channels/:channelId/templatesGETList channel templates
/channels/:channelId/templates/:templateIdGETGet template details
/messages/sendPOSTSend single message
/messages/bulkPOSTSend bulk messages
/messages/bulk/:bulkId/statusGETCheck bulk send status
/messages/bulk/:bulkId/recipientsGETList bulk send recipients

WhatsApp Flows

Templates with a WhatsApp Flow button can be sent via /messages/send and /messages/bulk — see Flow Events for the completion webhook contract.

200 OK
{
"success": true,
"data": {
// Response payload
}
}
4xx / 5xx
{
"success": false,
"error": {
"code": "AUTH_001",
"message": "Missing required credentials"
}
}

100 requests per minute

Each API key is limited to 100 requests per minute. Requests beyond the limit receive a 429 response with error code RATE_001.

Every response includes standard rate limit headers:

HeaderDescription
RateLimit-LimitMaximum requests allowed per window
RateLimit-RemainingRequests remaining in the current window
RateLimit-ResetSeconds until the window resets

A few errors — AUTH_007 (permission denied), VAL_007/VAL_008 (malformed JSON), RATE_001 (rate limit), SRV_001 (internal error) — can occur on any endpoint. See the Error Codes reference for the complete list.

Phone numbers must be in E.164 format:

  • Start with + followed by country code
  • 1-15 digits total
  • No spaces, dashes, or parentheses

Examples:

  • +1234567890 (US)
  • +447700900000 (UK)
  • +971501234567 (UAE)