Chat History
Returns messages exchanged with a single contact, newest first. Identify the contact by either phone (must already exist in your contact directory) or contactId. Cursor-paginated via before + nextCursor.
GET/v2.0/chats/history
Query Parameters
Query
| Parameter | Type | Description |
|---|---|---|
| phone | string | Recipient phone in international format. Either this or contactId |
| contactId | string | Sendiee Contact id. Either this or phone |
| defaultCountryCode | string | Used with phone if it's a local number |
| limit | number | 1–100. Default 20 |
| before | string (ISO 8601) | Cursor — return messages older than this timestamp. Use the previous response's nextCursor |
Phone must exist as a contact
Sendiee requires a Contact record before returning chat history (so we can scope the query strictly to your org). If the phone is unknown the response is
404 CONTACT_NOT_FOUND — call Create / Update Contact first if needed.Example
curl -X GET "https://api.sendiee.com/v2.0/chats/history?phone=919876543210&limit=20" \
-H "Authorization: Bearer YOUR_API_KEY"Response
{
"success": true,
"data": [
{
"messageId": "664a...",
"wamid": "wamid.HBg...",
"direction": "outbound",
"status": "delivered",
"type": "template",
"text": null,
"media": null,
"components": {},
"reactions": {
"user": null,
"brand": null
},
"campaignId": "664c...",
"cost": {
"amount": 0.83,
"currency": "INR",
"category": "marketing"
},
"createdAt": "2026-04-29T05:18:42.000Z"
},
{
"messageId": "664b...",
"wamid": "wamid.HBh...",
"direction": "inbound",
"status": "received",
"type": "text",
"text": "Thanks!",
"media": null,
"components": null,
"reactions": {
"user": null,
"brand": null
},
"campaignId": null,
"cost": null,
"createdAt": "2026-04-29T05:18:00.000Z"
}
],
"pagination": {
"limit": 20,
"hasMore": true,
"nextCursor": "2026-04-29T05:18:00.000Z"
},
"contact": {
"phone": "919876543210"
}
}