Hoppa till innehållet

Read a message

GET/v1/messages/{id}

TypeScript sendora.messages.get(messageId)

Python sendora.messages.get(message_id)

PHP $sendora->messages->get($messageId)

Java sendora.messages().get(messageId)

Key sk_… a server key

The message as the log holds it, its attachments described but not returned, and the events on its timeline, with what tracking recorded. Bodies are never returned.

Parameters

  • idin pathstring (uuid)required

    The message id.

Responses

Every field of a response is always present. A field that can be null says so in its type.

200The message with its attachments described and its timeline.

Example (98 lines)
{
  "messageId": "5f432ffd-c005-499b-aa3a-5b8a088ea20e",
  "streamId": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
  "broadcastId": null,
  "status": "injected",
  "from": "no-reply@example.se",
  "subject": "Your invoice for September",
  "tag": "invoice",
  "metadata": {
    "invoiceId": "2026-0912"
  },
  "submittedAt": "2026-09-15T12:00:00.000Z",
  "test": false,
  "recipients": [
    {
      "address": "anna@example.com",
      "kind": "to",
      "status": "delivered",
      "tracked": true,
      "opens": 2,
      "clicks": 1,
      "firstOpenAt": "2026-09-15T12:03:10.000Z",
      "firstHumanOpenAt": "2026-09-15T12:03:10.000Z"
    }
  ],
  "tracking": {
    "recordingOpens": true,
    "recordingClicks": true,
    "skipped": null
  },
  "attachments": [
    {
      "name": "invoice.pdf",
      "contentType": "application/pdf",
      "contentId": null,
      "size": 48213
    }
  ],
  "events": [
    {
      "recipient": "anna@example.com",
      "type": "Reception",
      "at": "2026-09-15T12:00:00.000Z",
      "code": 250,
      "details": null,
      "classification": null,
      "tracking": null
    },
    {
      "recipient": "anna@example.com",
      "type": "Delivery",
      "at": "2026-09-15T12:00:02.000Z",
      "code": 250,
      "details": "2.0.0 OK",
      "classification": null,
      "tracking": null
    },
    {
      "recipient": "anna@example.com",
      "type": "Open",
      "at": "2026-09-15T12:03:10.000Z",
      "code": null,
      "details": null,
      "classification": null,
      "tracking": {
        "automated": "unlikely",
        "agent": null,
        "reasons": [],
        "client": "apple_mail",
        "device": "mobile",
        "first": true,
        "firstHuman": true,
        "link": null
      }
    },
    {
      "recipient": "anna@example.com",
      "type": "Click",
      "at": "2026-09-15T12:03:40.000Z",
      "code": null,
      "details": null,
      "classification": null,
      "tracking": {
        "automated": "unlikely",
        "agent": null,
        "reasons": [],
        "client": "apple_mail",
        "device": "mobile",
        "first": true,
        "firstHuman": true,
        "link": {
          "index": 0,
          "url": "https://example.se/invoices/2026-0912"
        }
      }
    }
  ]
}
  • messageIdstring (uuid)
  • streamIdstring (uuid)

    The stream the message went on.

  • broadcastIdstring (uuid) or null

    The broadcast the message belongs to; null for a message sent on its own.

  • status"accepted" | "injected" | "failed"

    accepted until handed to the mail server, injected after; failed if that never worked.

  • fromstring
  • subjectstring
  • tagstring or null
  • metadatamap of string to string
  • submittedAtstring (date-time)
  • testboolean

    True when the message went through a test server: its events were simulated and nobody received it.

  • recipientsarray of object
    • addressstring
    • kind"to" | "cc" | "bcc"
    • status"queued" | "delivered" | "deferred" | "bounced" | "expired"

      queued until the receiver answers; deferred while it keeps saying try later.

    • trackedboolean

      Whether tracking applied to this recipient’s copy when it left. It does not say to opens, links or both, or that the HTML held a link to track.

    • opensinteger

      Opens recorded, machines’ included.

    • clicksinteger

      Clicks recorded, machines’ included.

    • firstOpenAtstring (date-time) or null

      The first open, or the first click that was likely a person’s. Null before that.

    • firstHumanOpenAtstring (date-time) or null

      The same, counting only what was likely a person. Null before that.

  • trackingobject

    Whether opens and clicks are recorded now, and why tracking may have stayed out.

    • recordingOpensboolean

      Whether new opens of this message are recorded now, by its own setting, then its broadcast’s, then its stream’s at this moment. This says nothing of what a copy already sent carries.

    • recordingClicksboolean

      The same for clicks on its links.

    • skipped"no_tracking_domain" | "gmail_clipping" or null

      Why tracking stayed out of at least one copy: no_tracking_domain when the from domain had no working tracking domain, gmail_clipping when tracked links would have taken the HTML past where Gmail clips it. Null otherwise. Each recipient’s tracked says whether its copy was tracked.

  • attachmentsarray of object
    • namestring
    • contentTypestring
    • contentIdstring or null
    • sizeinteger

      Bytes before encoding.

  • eventsarray of object

    Oldest first. Opens and clicks are capped as Limits says, while each recipient’s opens and clicks count them all.

    • recipientstring or null

      The recipient the event is about; null when it concerns the message as a whole.

    • type"Reception" | "Delivery" | "Bounce" | "TransientFailure" | "Expiration" | "AdminBounce" | "OOB" | "Feedback" | "AdminRebind" | "DeferredInjectionRebind" | "Rejection" | "Delayed" | "Open" | "Click"

      Reception when the mail server took it, Delivery, TransientFailure, Bounce, OOB for a bounce report received by mail, Feedback for a spam complaint, Open and Click for what tracking recorded.

    • atstring (date-time)
    • codeinteger or null

      The SMTP status code the receiver answered.

    • detailsstring or null

      The receiver’s response text.

    • classificationstring or null

      How a bounce was classified, such as InvalidRecipient.

    • trackingobject or null

      What tracking knows of an Open or a Click; null on any other event.

      • automated"likely" | "unlikely" | "unknown"

        Whether a machine rather than a person did it: likely, unlikely, or unknown where nobody can tell, as with Apple's privacy protection.

      • agent"apple_privacy" | "gmail_prefetch" | "gmail_proxy" | "yahoo_proxy" | "outlook_prefetch" | "proton_proxy" | "scanner" | "crawler" or null

        The proxy or machine it came through, where Sendora knows it.

      • reasonsarray of "privacy_proxy" | "prefetch_signature" | "delivery_timing" | "link_burst" | "scanner_network" | "bot_user_agent" | "many_networks"

        Why it was labelled a machine’s.

      • client"apple_mail" | "gmail" | "outlook" | "yahoo" | "thunderbird" | "proton" | "browser" | "other" or null

        The mail program, where Sendora knows it.

      • device"desktop" | "mobile" | "tablet" or null

        The kind of device, where Sendora knows it.

      • firstboolean

        The recipient’s first event of this kind.

      • firstHumanboolean

        The recipient’s first event of this kind that was likely a person’s.

      • linkobject or null

        The link clicked; null on an Open.

        • indexinteger

          The link’s position in the HTML, the same in every copy, counting from 0.

        • urlstring or null

          Where the link led; null once it has gone with the message’s text and HTML.

Errors

Every error answers error, the code, and message, a sentence for a person. A code that adds fields is shown in full below the table.

CodeStatusMeaning
unauthorized401The key is missing, malformed or revoked.
wrong_token_kind403The key is of the other kind: a server key (sk_) where an account key (ak_) is needed, or the reverse. The message names the kind the operation takes.
not_for_connections403A connected app called an operation that no tool of the MCP server calls. An API key can.
read_only_connection403A connected app may only read here: the account is read only through a connection, and a live server takes changes only if the person allowed them when connecting.
test_server_only403A connected app may create a secret, or do what cannot be undone, on a test server only.
not_found404No such message of this server.
  • WWW-Authenticateheader on 401"Bearer"

    Always Bearer: send the key as Authorization: Bearer <key>.