API reference/WhatsApp Messages/Send one template message
Send one template message
POST /client/v1/wp/message/send
Enqueues a single WhatsApp template send. This API does not call Meta Graph directly - ScaleBiss workers send via Graph.
The template must be APPROVED. The workspace comes from the template: with an API key the template must belong to the key's workspace (otherwise 404); with a Passport JWT the user must own the workspace or be a member of it.
Parameter keys (optional parameters object) use dotted names:
- header.<name> - header text variables
- body.<name> or body.<n> - body variables
- button.<index> - URL button suffix
Authentication (OTP) templates: send only the code in body.1; the copy-code button is filled with the same code.
Request body
| Field | Type | Details |
|---|---|---|
| to | string required | Recipient mobile with country code, 8–32 characters. Digits only (no +). |
| from | string required | Sender WhatsApp number in the workspace - Meta phone number id or the display phone number. |
| templateId | string required | Workspace template id (numeric). |
| parameters | object optional | Dotted keys mapped to template components (header.*, body.*, button.*). |
Content type: application/json
Responses
{
"success": true,
"message": "Template send accepted",
"data": {
"to": "919876543210",
"templateId": "42",
"templateName": "new_user",
"status": "accepted"
}
}{
"success": false,
"message": "WhatsApp template is not APPROVED",
"code": "TEMPLATE_NOT_APPROVED"
}{
"success": false,
"message": "API key is not valid",
"code": "API_KEY_INVALID"
}{
"success": false,
"message": "You do not have access to this workspace.",
"code": "WORKSPACE_ACCESS_DENIED"
}{
"success": false,
"message": "WhatsApp template not found",
"code": "TEMPLATE_NOT_FOUND"
}