Appearance
Message History
GET /v1/whatsapp/messages
Returns a paginated list of all WhatsApp messages (both inbound and outbound) for the authenticated user. You can filter by session, direction, status, and date range.
Authentication
| Header | Type | Required | Description |
|---|---|---|---|
Authorization | string | Yes | Bearer sk_live_YOUR_API_KEY |
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
session_id | integer | No | Filter to a specific session ID. |
direction | string | No | in for received, out for sent. |
status | string | No | queued, sent, delivered, read, failed. |
from_date | string | No | ISO 8601 date (e.g., 2026-03-01). |
to_date | string | No | ISO 8601 date (e.g., 2026-03-31). |
page | integer | No | Page number (default: 1). |
per_page | integer | No | Results per page (default: 25, max: 100). |
bash
curl "https://sendapi.co/v1/whatsapp/messages?direction=out&status=delivered&per_page=50" \
-H "Authorization: Bearer sk_live_123456789"javascript
const messages = await client.whatsapp.messages.list({
direction: 'out',
status: 'delivered',
per_page: 50
});python
messages = client.whatsapp.messages.list(
direction="out",
status="delivered",
per_page=50
)Response
json
{
"success": true,
"data": [
{
"id": 14,
"wa_session_id": 8,
"direction": "out",
"recipient": "447700900000",
"type": "text",
"content": "Hello! How can our support team assist you today?",
"status": "delivered",
"external_id": "3EB0C5E64689ED4B8C686E",
"created_at": "2026-03-09T14:30:00.000000Z",
"updated_at": "2026-03-09T14:30:22.000000Z"
}
],
"meta": {
"current_page": 1,
"per_page": 25,
"total": 1402,
"last_page": 57
}
}Get a Single Message
GET /v1/whatsapp/messages/{id}
Returns the full details of a single message.
bash
curl https://sendapi.co/v1/whatsapp/messages/14 \
-H "Authorization: Bearer sk_live_123456789"Response
json
{
"success": true,
"data": {
"id": 14,
"wa_session_id": 8,
"direction": "out",
"recipient": "447700900000",
"type": "text",
"content": "Hello! How can our support team assist you today?",
"status": "read",
"external_id": "3EB0C5E64689ED4B8C686E",
"cost": "0.0000",
"created_at": "2026-03-09T14:30:00.000000Z",
"updated_at": "2026-03-09T14:31:05.000000Z"
}
}Status timeline
The status field reflects the latest known state. SendAPI does not record per-step timestamps for sent/delivered/read on the message — subscribe to webhook events if you need a delivery audit trail.
Message Statuses
| Status | Description |
|---|---|
queued | Message accepted by SendAPI, pending dispatch |
sent | Delivered to WhatsApp servers |
delivered | Received on recipient's device (double checkmark) |
read | Opened by recipient (blue checkmark) |
failed | Delivery failed |