Send Text Message
Send simple text messages to your customers
Reading time: 1 minute
Send Text Message
The simplest way to send a text message to your customers.
POST
{{base_url}}/w/message/textQuery Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
phone_number_id | string | Yes | Phone number ID of the sender |
Request Body (JSON)
| Parameter | Type | Required | Description | Default |
|---|---|---|---|---|
phone | string | Yes | Recipient phone number in international format (96650000000) | - |
body | string | Yes | Message text (max 4096 characters) | - |
name | string | No | Contact name (for new contacts only) | - |
email | string | No | Email address (for new contacts only) | - |
reply_to | string | No | Message ID to reply to | - |
preview_url | boolean | No | Enable link preview | false |
Tip: When sending a message for the first time, include name and email to automatically create a new contact.
Example Request
Example Requestbash
curl -X POST "{{base_url}}/w/message/text?phone_number_id=123456" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "X-Awal-Signature-256: sha256=abc..." \
-H "X-Timestamp: 1704124800" \
-H "X-Domain: your-workspace" \
-H "X-Client-ID: your-client-id" \
-d '{
"phone": "96650000000",
"body": "Hello! Thank you for contacting us. How can we help you today?",
"name": "Ahmed Mohammed",
"preview_url": false
}'Example Response
Response200 OK
{
"status": true,
"message": {
"id": 12345,
"messageId": "wamid.HBgNOTY2NTA...",
"status": "sent",
"timestamp": 1704124800
}
}Related
ā Back to Messages
View Guide