> ## Documentation Index
> Fetch the complete documentation index at: https://upstash-vector.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Message

> This endpoint returns the complete message with the given ID.

## Request

<ParamField path="messageId" type="string" required>
  The unique id of the message.
</ParamField>

## Response

<ResponseField name="body" type="string">
  Base64 encoded request body
</ResponseField>

<ResponseField name="createdAt" type="int" required>
  The time when the message was created in milliseconds.
</ResponseField>

<ResponseField name="destinationType" type="string" required>
  Either `topic` or `url`
</ResponseField>

<ResponseField name="endpointId" type="string">
  The endpoint Id the message was sent to. Only available if the message was
  sent to an endpoint.
</ResponseField>

<ResponseField name="header" type="Record<string, string>">
  The HTTP headers sent to your API.
</ResponseField>

<ResponseField name="messageId" type="string">
  The unique message Id
</ResponseField>

<ResponseField name="scheduleId" type="string">
  The unique schedule Id
</ResponseField>

<ResponseField name="settings" type="Settings">
  <Expandable title="Settings">
    <ResponseField name="deadline" type="int">
      The time at which message should be delivered at the latest.
    </ResponseField>

    <ResponseField name="delay" type="int">
      The delay in seconds before the message is delivered.
    </ResponseField>

    <ResponseField name="notBefore" type="int">
      The time before which the message should not be delivered.
    </ResponseField>

    <ResponseField name="retries" type="int">
      The number of retries that should be attempted in case of delivery
      failure.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="topicName" type="string">
  The topic name the message was sent to

  Only available if the message was sent to a topic.
</ResponseField>

<ResponseField name="topicName" type="string">
  The topic Name the message was sent to

  Only available if the message was sent to a topic.

  This might be outdated if you have since changed the topic name. In that case, please rely on the topic id instead because it is guaranteed to be consistent.
</ResponseField>

<ResponseField name="url" type="string">
  The url where this message is being sent to.
</ResponseField>

<RequestExample>
  ```shell curl
  curl https://qstash.upstash.io/v1/messages/msg_123 \
    -H "Authorization: Bearer <token>"
  ```
</RequestExample>

<ResponseExample>
  ```json 200
  {
    "messageId": "msg_123",
    "topicId": "tpc_123",
    "url":"https://example.com",
    "method": "POST",
    "header": {
      "My-Header": "my-value"
    },
    "body": "{\"foo\":\"bar\"}",
    "createdAt": 1620000000000
  }
  ```
</ResponseExample>
