Get parsed message content and attachments
Returns decoded email headers, inline plain text and HTML bodies, and attachment metadata for a message.
bearerAuthAuthorizationBearer <token>Two credential kinds share this scheme; GET /api/v1/auth/whoami answers which one you hold and what it reaches.
oek_… API key (minted by POST /api/v1/api-keys; shown once at mint). role: account reaches the full account surface: the directory (domains, routes, patterns, api-keys, accounts, address lists) plus every mailbox the account owns. role: system additionally reaches the operator surface, which is documented separately.
oemp_… mailbox app password (minted by POST /api/v1/identities/{identityId}/credentials). Reaches ONE mailbox: its messages, labels, threads, search, sync, send, filters and PIM collections. Directory routes refuse it with 403 insufficient_scope.
Refusal vocabulary: a missing, malformed, expired, or revoked credential answers 401 unauthorized with a WWW-Authenticate: Bearer challenge; a VALID credential outside its scope answers 403 (insufficient_scope for an app password on a directory route, system_credentials_required where only the operator may call). The public routes (health, branding, token-in-path capabilities) declare security: [].
mailboxId*stringMailbox ULID identifier
messageId*stringMessage ULID identifier
if-none-match?stringRevalidation ETag from a previous response; on match the answer is 304
Parsed message body, headers, and attachments
application/json- response
attachments*array<>List of file attachments
headers*Message headers
html*|HTML body part, or null if message has no HTML
text*|Plain-text body part, or null if message has no plain text
curl -X GET 'https://api.open.email/api/v1/mailboxes/string/messages/string/content'{
"attachments": [
{
"contentId": null,
"contentType": "application/pdf",
"filename": "q3-report-draft.pdf",
"inline": false,
"section": "3",
"size": 44032
}
],
"headers": {
"cc": [],
"date": 1788081272,
"from": [
{
"email": "ada@example.com",
"name": "Ada Lovelace"
}
],
"inReplyTo": null,
"messageIdHeader": "<7f2a1c9e4b8d@mail.example.com>",
"replyTo": [],
"subject": "Q3 report draft",
"to": [
{
"email": "grace@acme.example",
"name": null
}
]
},
"html": {
"charset": "utf-8",
"content": "<div>Hi Grace,<br><br>attached is the Q3 report draft we discussed on Friday.<br><br>Ada</div>",
"section": "2",
"size": 95,
"truncated": false
},
"text": {
"charset": "utf-8",
"content": "Hi Grace,\n\nattached is the Q3 report draft we discussed on Friday.\n\nAda",
"section": "1",
"size": 74,
"truncated": false
}
}