Skip to main content

SMS API

SMS masking rides on an existing masking session. There is no send-SMS API endpoint — you do not push messages through Relavoi with an API call. Instead, when an end user texts a proxy number, the telephony provider delivers it to POST /v1/webhooks/cpaas/sms, Relavoi matches it to the active session, and forwards it to the other party from the same proxy. Replies follow the same path in reverse.

The only tenant-facing SMS endpoint lists the records of those exchanges. See SMS masking for the full flow.

:::note Privacy SMS records never contain the message body or content. Relavoi stores only routing and delivery metadata (direction, status, provider ids, timestamps). Message text is forwarded but not retained. :::

Endpoints​

MethodPathSummary
GET/v1/sessions/:id/smsList SMS records exchanged within the session

GET /v1/sessions/:id/sms​

Auth: Bearer JWT (tenant). Returns SMS records for the session, newest first, with cursor pagination.

Path paramTypeRequiredDescription
idstringyesSession id
QueryTypeRequiredDescription
limitintegernoDefault 50, max 200
afterstringnoCursor — sentAt timestamp of the last row from the previous page

Request

curl "https://api.relavoi.com/v1/sessions/5661962a-d7ad-4aea-88a0-210388e1285b/sms" \
-H "Authorization: Bearer $RELAVOI_JWT"

Response (empty session)

{
"data": [],
"pagination": {
"count": 0,
"after": null
}
}

Response (with records)

{
"data": [
{
"id": "9c1f2b3a-4d5e-6f70-8a9b-0c1d2e3f4a5b",
"sessionId": "5661962a-d7ad-4aea-88a0-210388e1285b",
"direction": "A_TO_B",
"status": "DELIVERED",
"sentAt": "2026-07-15T12:38:00.000Z",
"deliveredAt": "2026-07-15T12:38:02.000Z"
}
],
"pagination": {
"count": 1,
"after": null
}
}

Note the absence of any body / message-content field — see the privacy note above.


Errors

Errors follow RFC 7807 Problem Details (application/problem+json):

{
"type": "https://api.relavoi.com/errors/not-found",
"title": "Not Found",
"status": 404,
"detail": "Session not found."
}
StatusType slugWhen
400validationInvalid limit / after
401unauthorizedMissing or invalid JWT
404not-foundUnknown session (or not owned by tenant)