List a contact's recent messages
GET/api/v1/contacts/{id}/activity
GET /contacts/{id}/activity
curl -X GET 'https://www.unitpost.com/api/v1/contacts/con_123/activity' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'User-Agent: my-app/1.0'Response · 200
{
"object": "list",
"has_more": false,
"data": [
{
"object": "contact_activity",
"message_id": "message_123",
"channel": "string",
"direction": "outbound",
"subject": "Welcome to Acme",
"status": "queued",
"campaign_id": "campaign_123",
"created_at": "2026-01-01T00:00:00.000Z",
"sent_at": "2026-01-01T00:00:00.000Z",
"error": "string",
"error_code": "string"
}
]
}The contact's most recent messages across channels, newest first: the emails sent to them, and texts both ways. Emails also require emails:read and texts sms:read; without one, those rows are left out. Returns up to limit (1–100, default 25) with no cursor: for the full history page List sent emails or List SMS messages with contact_id. The {id} accepts a contact id or email. Requires the contacts:read capability.
Parameters2 fields
| Field | Type | Description |
|---|---|---|
idrequired | string · path | — |
limit | integer · query | How many recent messages (1–100, default 25). |
Response · 200 fields11 fields
| Field | Type | Description |
|---|---|---|
objectrequired | string | — |
message_idrequired | string | An email (`email_…`) or text (`sms_…`) id; read it with its own get operation. |
channelrequired | string | `email` or `sms`. |
directionrequired | enumoutbound | inbound | — |
subjectrequired | string | null | An email's subject, or the start of a text. |
statusrequired | string | The message's `status` as its own object reports it (`GET /email/{id}`, `GET /sms/{id}`). |
campaign_idrequired | string | null | — |
created_atrequired | string | — |
sent_atrequired | string | null | — |
errorrequired | string | null | Texts only: why it wasn't delivered, in plain words. |
error_coderequired | string | null | — |
200401403404422