Name
List messages
Your organization’s messages in a range of days, or the ones that went to a number, one page at a time and without the text.
HTTP method and path
/ api/ v6/ sms/ messageshttps:
What happens when you run it
- Read only: it does not change your organization’s data.
- The call is not charged.
What it does
Returns the messages your organization sent (through the API, through Cloud or over SMPP), from the newest to the oldest, without the text. With to, only the ones that went to that number, which is searched in its three forms (3001234567, 573001234567 and +573001234567). The messages people wrote to you do not come here: they are in GET /.
One page at a time. The range goes from receivedFrom to receivedTo, Colombia days, both included: from 1 to 31 days and not after today. Without receivedTo it is today, and without receivedFrom, the seven days ending on receivedTo. Each page brings up to limit messages (50 if you do not send it, 200 at most) and, in nextCursor, the next page’s cursor. To continue, send cursor with the same to: the dates already go in the cursor. A page may bring fewer than the limit, or none, and continue: the listing ends when nextCursor comes as null.
Availability and prerequisites
- Published and available in the production API v6.
- Every path starts at
https:./ / developers. hablame. co - You need a Hablame API key to call it.
Authentication and permissions
- Send your API key in the
Authorizationheader with the Bearer scheme.
Who can call it: An API key with the sms service enabled.
Limits and operational notes
Usage limit: 50 requests per second.
- The message query, the message list and the message timeline share this quota: 50 requests per second among the three.
Path parameters
This endpoint has no path parameters.
Query parameters
| Name | Type | Description and rules |
|---|---|---|
receivedFromOptional | string | The first day ( Format: |
receivedToOptional | string | The last day ( Format: |
toOptional | string | Optional: only the messages that went to this number. Example: |
cursorOptional | string | The |
limitOptional | integer | How many messages the page brings, at most. Default value: |
HTTP headers
| Name | Type | Description and rules |
|---|---|---|
AuthorizationRequired | string | Your API key with the Bearer scheme. Example: |
Request body
This endpoint takes no request body.
Successful responses
200
A page of messages.
{
"success": true,
"data": {
"receivedFrom": "2026-11-01",
"receivedTo": "2026-11-07",
"to": "573001234567",
"items": [
{
"id": "0192f0c4-7a1b-7c3d-8e9f-001122334455",
"status": "delivered",
"finalStatus": "delivered",
"traffic": "bulk",
"channel": "bulk",
"origin": "api",
"batchId": "bat_3f1c0a9b2d7e4c58a6b1e0f9d2c3b4a5",
"index": 0,
"clientRef": "pedido-1",
"to": "573001234567",
"from": "890123",
"segments": 1,
"deliveredParts": 1,
"encoding": "GSM-7",
"cost": { "amountMicro": 30000000, "currency": "COP" },
"receivedAt": "2026-11-04T10:00:00.000-05:00",
"statusCode": 20,
"statusText": "Entregado al teléfono",
"certified": true
}
],
"nextCursor": null,
"completeThrough": "2026-11-07T15:42:05.120-05:00",
"ingestLagSeconds": 3
},
"meta": {
"requestId": "5d0f3a9c7b2e41a8",
"clientIp": "203.0.113.10",
"timestamp": "2026-10-26T10:30:00-05:00",
"responseTimeMs": 8.2
}
}The example values are illustrative.
Response fields
| Name | Type | Description and rules |
|---|---|---|
successAlways present | boolean | |
dataAlways present | object | A page of messages, from the newest to the oldest. |
data.Always present | string | The first day of the range (Colombia). Format: |
data.Always present | string | The last day of the range (Colombia). Format: |
data. | string | The searched number, with the country code: only if you searched by number. Example: |
data.Always present | array<object> | The page’s messages. It may come empty and continue: check |
data.Always present | string | Message identifier. Example: |
data.Always present | string | The message status. While it has not finished: Allowed values: |
data. | string | Why a |
data. | string | How it ended, like Allowed values: |
data. | string | Why it ended that way, with the |
data. | string | What kind of send it is. Allowed values: |
data. | string | Where it came in: |
data. | string | Where it was sent from: |
data. | string | The bulk send it belongs to, if any. |
data. | integer | Its position in the bulk send |
data. | string | Your reference, if you sent it. |
data.Always present | string | The destination. Example: |
data. | string | The sender it went out with. |
data. | string | The one you asked for, only if it went out with another one. |
data.Always present | integer | The parts it goes out in. |
data. | integer | How many parts the carrier confirmed as delivered, once it closed the message. |
data.Always present | string |
|
data. | object | What was charged, only if it was charged. |
data.Always present | integer | Amount in micros. Example: |
data.Always present | string | ISO 4217 currency code. Example: |
data.Always present | string | When Hablame received it, in Colombia time and with milliseconds. Format: |
data. | boolean |
|
data. | integer | The message status in its record, a code that never changes: Allowed values: |
data. | string | The status in words, in the language of your Example: |
data. | string | Why it ended in that status, in English: for example |
data. | boolean |
Example: |
data. | boolean |
|
data. | string | Only if your message history does not reach the start of the range: the first day the page brings, the oldest one you can query today. It comes in every page of the listing. The earlier days do not come and do not go in Format: |
data. | array<string> | The days of your history the page went through that could not be read here, because they already moved to the archive: their messages do not come. The days older than your history do not go here: check |
data. | array<string> | The days that do not allow searching by number yet: search them by range, without |
data.Always present | string | The next page’s cursor; May come as |
data. | string | Up to when the data is complete (in Colombia time): every message you sent one by one before this time is already in the query. What came after may still be missing. It does not cover the messages of a bulk send while it is being split among its destinations (its progress is in Format: |
data. | integer | How many seconds there are from Example: |
metaAlways present | object | Response metadata. |
meta.Always present | string | Unique request identifier (16 hexadecimal characters). It matches the Example: |
meta.Always present | string | IP the API saw your request come from. Useful if your API key only accepts certain networks. Example: |
meta.Always present | string | Date and time the response was built (ISO 8601 with offset). Format: |
meta.Always present | number | Time (ms) the server took to process the request. Example: |
Error codes
Every error response has the same shape: success set to false and an error object whose code says what happened. They are grouped here by kind, with the codes this endpoint can return.
Shape of an error response
| Name | Type | Description and rules |
|---|---|---|
successAlways present | boolean | Fixed value: |
metaAlways present | object | Response metadata. |
meta.Always present | string | Unique request identifier (16 hexadecimal characters). It matches the Example: |
meta.Always present | string | IP the API saw your request come from. Useful if your API key only accepts certain networks. Example: |
meta.Always present | string | Date and time the response was built (ISO 8601 with offset). Format: |
meta.Always present | number | Time (ms) the server took to process the request. Example: |
errorAlways present | object | |
error.Always present | string | Stable UPPER_SNAKE_CASE identifier. Clients branch on this value. Example: |
error. | integer | Legacy v5 numeric code, only when a bridge exists. Omitted for codes born in v6. Example: |
error.Always present | string | URL to the error documentation. Format: |
error.Always present | string | Human readable text, in English. It is for the developer log, not the end user: do not parse it. |
error.Always present | array<object> | Structured context (validation issues, affected resource). Empty array when there is no extra context. |
Validation
- 422The range is not valid (
SMS_INVALID_RANGE),tois not a phone number (SMS_INVALID_NUMBER),limitis not from 1 to 200 (SMS_INVALID_LIMIT) or thecursoris not the one of this query (SMS_INVALID_CURSOR).
The day range is not valid.
The search number is not a phone number.
The page limit is not valid.
The cursor is not the one of this query.
Authentication
- 401Invalid or missing credentials.
No Bearer token was sent, and every call requires one.
Message the API returns: Authentication is required. Send your API key as `Authorization: Bearer <token>`.
The API key is not recognized: wrong format, revoked or expired.
Message the API returns: The provided API key is invalid or has expired. Please verify the value sent in the `Authorization: Bearer` header.
Permissions
- 403The API key does not have the SMS service (
sms), the key cannot be used from the request network, the organization is not active (ACCOUNT_NOT_ACTIVE: closed or blocked) or the querying account could not be identified (SMS_ACCOUNT_NOT_IDENTIFIED). A suspended organization, or one with SMS turned off, can query: it does not get this403.
The key is not allowed to use the service behind this endpoint.
Message the API returns: This API key is not authorized to use the requested service.
The key only works from certain networks and your IP is not one of them.
Message the API returns: This API key cannot be used from this IP address. The address we saw is in `meta.clientIp`: call from one of the networks allowed for the key, or use a key that allows this one.
Your organization is suspended or closed.
Message the API returns: The organization associated with this API key is not active. Please contact support.
The send’s account could not be identified.
Usage limits
- 429Request limit exceeded.
You exceeded your organization quota for this endpoint.
Message the API returns: You have exceeded the allowed request rate for this endpoint. Please wait before retrying.
Resource not found
- 410The whole range is older than your message history (
SMS_OUTSIDE_HISTORY_WINDOW), with the oldest day you can query indetails[0].. A range only partly older answersoldestDay 200withwindowStart.
What you asked for is older than your message history.
Internal errors and availability
- 503It could not be queried right now (
SERVICE_UNAVAILABLE). Nothing changed in your sends: retry the same query afterRetry-After.
Generic 503: a service we depend on is not responding.
Other responses
This endpoint does not declare responses of this kind.
Special considerations
Days that bring no messages
If your message history does not reach the start of the range, the page brings from windowStart, the oldest day you can query today, and says so in every page of the listing; a range entirely older than your history answers 410 SMS_OUTSIDE_HISTORY_WINDOW. archivedDays says which days of your history already moved to the archive and could not be read here: their messages do not come. daysWithoutNumberSearch says which days do not allow searching by number yet: search them by range, without to.
Your message history
You query free of charge the messages from the last 3 months, date to date (89 to 92 days depending on the month); if your organization extended its message history in Hablame Storage, all the ones in that history. A history change applies at once. Anything from an earlier day answers 410 SMS_OUTSIDE_HISTORY_WINDOW, with the oldest day you can query in details[0].: it does not mean the message does not exist. The messages of a day that already moved to the archive, inside your history, come with archived:; if they cannot be read at that moment, the query by id answers 410 SMS_MESSAGE_ARCHIVED.
It also answers with the organization suspended
If your organization is suspended, or has SMS turned off, queries keep working with your key: you can see your messages, your bulk sends and what people wrote to you. What you cannot do is send: the three sends answer 403 (ACCOUNT_NOT_ACTIVE with the organization suspended, AUTH_SERVICE_NOT_ALLOWED with SMS turned off).