Skip to main content
POST
/
message
/
{serviceId}
/
whatsapp
cURL
curl --request POST \
  --url https://api.belio.co.ke/message/{serviceId}/whatsapp \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "type": "TemplateSendToMany",
  "phoneNumberId": "<string>",
  "templateId": "<string>",
  "addresses": [
    "<string>"
  ],
  "params": [
    {
      "type": "BodyNamedParameter",
      "name": "<string>",
      "value": "<string>"
    }
  ]
}
'
{
  "result": {
    "type": "WhatsAppResponse",
    "requestId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "addresses": 123,
    "units": {}
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.belio.co.ke/llms.txt

Use this file to discover all available pages before exploring further.

Refer to Authentication for information on how to obtain a bearer token.This endpoint requires the message.whatsapp.send.oneway API client authorization scope to send one-way WhatsApp messages.You can configure scopes on the API Clients page.

Request Modes

The API supports two request modes:
  • TemplateSendToMany — Sends the same template message with shared parameters to multiple recipients.
  • TemplateSendToEach — Sends personalized template messages to individual recipients. Parameters can differ per recipient.

Template Parameters

Templates support dynamic parameters that are substituted into the template body or header when messages are sent.

Parameter Types

Parameter TypeRequired FieldDescription
BodyNamedParameternameSubstitutes a body placeholder referenced by name (e.g. {{name}})
BodyPositionalParameterpositionSubstitutes a body placeholder referenced by position (e.g. {{1}})
HeaderNamedParameternameSubstitutes a header placeholder referenced by name (e.g. {{name}})
HeaderPositionalParameterpositionSubstitutes a header placeholder referenced by position (e.g. {{1}})

Example

{
  "params": [
    {
      "type": "BodyNamedParameter",
      "name": "name",
      "value": "Alice"
    },
    {
      "type": "BodyPositionalParameter",
      "position": 1,
      "value": "Alice"
    },
    {
      "type": "HeaderNamedParameter",
      "name": "business",
      "value": "Belio Limited"
    },
    {
      "type": "HeaderPositionalParameter",
      "position": 1,
      "value": "Belio Limited"
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

serviceId
string
required

Unique identifier of the WhatsApp service

Body

application/json

WhatsApp template message send request

type
enum<string>
required

Must be "TemplateSendToMany"

Available options:
TemplateSendToMany
phoneNumberId
string
required

Phone number ID of the WABA sender. Must match a number registered on the service

templateId
string
required

ID of the approved WhatsApp template to send

addresses
string[]
required

Recipient phone numbers. Maximum 10 per request

Maximum array length: 10
params
object[]
required
receiptRequest
object

Delivery receipt callback configuration. When provided, both fields are required.

Response

Successful send request accepted and queued

result
object
required