Skip to main content
GET
/
messages
/
{message_id}
/
output
JavaScript
import Courier from '@trycourier/courier';

const client = new Courier({
  apiKey: process.env['COURIER_API_KEY'], // This is the default and can be omitted
});

const response = await client.messages.content('message_id');

console.log(response.results);
{
  "results": [
    {
      "channel": "string",
      "channel_id": "abc-123",
      "content": {
        "html": "string",
        "title": "Example Name",
        "body": "string",
        "subject": "string",
        "text": "string",
        "blocks": [
          {
            "type": "string",
            "text": "string"
          }
        ]
      }
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

message_id
string
required

A unique identifier associated with the message you wish to retrieve (results from a send).

Response

results
RenderOutput · object[]
required

An array of render output of a previously sent message.