Skip to content
Get started
Esc
Retrieve a message

Messages

GET /v1/messages/{id}

A message of the workspace by id: its status, and the reason's code if it did not go.

Returns the message object.

Path parameters

id string required
The message's id, from the response to the send or from a webhook event.

Errors

CodeHTTPWhat it means
not_found404Nothing found. A key sees only the messages of its own workspace and its own mode, live or test.

Any request can also get the codes on Errors, such as unauthenticated and rate_limited.

Code language
// npm install @airboxhq/api
// AIRBOX_API_KEY=YOUR_API_KEY node get_message.mjs
import { Airbox } from "@airboxhq/api";

const client = new Airbox(process.env.AIRBOX_API_KEY);

const { data, error } = await client.messages.get("0199c5e2-7b3a-7c51-9f0e-3a1d2b4c5e6f");

if (error) {
  throw new Error(`${error.code}: ${error.message} (${error.requestId})`);
}

console.log(data);
Response 200
{
    "id": "0199c5e2-7b3a-7c51-9f0e-3a1d2b4c5e6f",
    "to": "+77011234567",
    "contact_id": "0199c5e2-1f0a-7a42-8d1e-5b7c9a2e4f10",
    "channel": "whatsapp",
    "type": "text",
    "text": {
        "body": "Hello! Your order #1042 is ready, and you can pick it up today until 8 pm."
    },
    "status": "delivered",
    "error": null,
    "sent_by": "api",
    "created_at": "2026-10-09T09:30:00+00:00",
    "sent_at": "2026-10-09T09:30:00+00:00",
    "delivered_at": "2026-10-09T09:30:02+00:00",
    "read_at": null
}