## Mail of an email entry: headers, recipients, delivery, attachments and the HTML body sanitised for display (desk:read)

`GET /api/desk/v1/items/{ref}/entries/{entryId}/mail`

Module: Desk · operationId: `getItemEntryMail` · Tag: Mail · Auth: access token (`Authorization: Bearer <accessToken>`)

### Parameters

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `images` | query | boolean |  | Load remote images (they can track the reader); default false |
| `ref` | path | string | yes | Item id or number |
| `entryId` | path | string | yes |  |

### Responses

- **200** Mail (`application/json`)

Fields of the 200 answer:

- `blockedImages` (integer): Remote images left out
- `html` (string): Sanitised HTML body; inline images point to the attachment download
- `mail` (object): The mail of the entry
  - `attachments` (array of object): Attachments of the mail, also those that were not stored
    - `contentType` (string): MIME type
    - `documentId` (string): DMS document of the stored file (empty when skipped)
    - `inline` (boolean): An inline image of the HTML body
    - `name` (string): File name
    - `reason` (string): Why the file was skipped
    - `size` (integer): Size in bytes
    - `skipped` (boolean): Not stored (blocked type
  - `cc` (array of Address): Recipients in copy
    - `address` (string): E-mail address
    - `name` (string): Display name (may be empty)
  - `classification` (string): What desk classified a received mail as
  - `deliveryState` (string): Delivery state of a sent mail (draft, queued, sent, delivered, …)
  - `direction` (string): in: received; out: sent (one of `in`, `out`)
  - `entryId` (string): Entry of the mail
  - `from` (Address)
    - `address` (string): E-mail address
    - `name` (string): Display name (may be empty)
  - `hasHtml` (boolean): The mail has an HTML body
  - `inReplyTo` (string): In-Reply-To header
  - `isAuto` (boolean): Automatic answer (out of office)
  - `mailboxId` (string): comms mailbox the mail came in or went out through
  - `mainText` (string): Received mails: the text without quoted history and signature (missing when nothing was cut)
  - `messageId` (string): Message-ID header
  - `receivedAt` (string (date-time)): When the mail was received
  - `references` (array of string): References header (message ids)
  - `sentAt` (string (date-time)): When the mail was sent
  - `subject` (string): Subject
  - `to` (array of Address): Recipients
    - `address` (string): E-mail address
    - `name` (string): Display name (may be empty)
  - `trimMethod` (string): How mainText was found: rules (heuristic) or the AI (one of `heuristic`, `ai`)

Example 200 answer:

```json
{
  "blockedImages": 0,
  "html": "\u003cp\u003eGuten Morgen Frau Stadler,\u003c/p\u003e\u003cp\u003edanke für die Meldung. Wir prüfen die Access Points im 2. OG per Fernzugriff und melden uns bis 10 Uhr.\u003c/p\u003e",
  "mail": {
    "attachments": [],
    "cc": [],
    "deliveryState": "delivered",
    "direction": "out",
    "entryId": "1b8c9d0e-2f3a-4b4c-9d6e-8f9a0b1c2d02",
    "from": {
      "address": "support@muster-it.example",
      "name": "Sophie Huber (Muster IT)"
    },
    "hasHtml": true,
    "mailboxId": "3f0a1b2c-4d5e-4f6a-9b8c-0d1e2f3a4b01",
    "messageId": "\u003c1b8c9d0e-2f3a-4b4c-9d6e-8f9a0b1c2d02@muster-it.example\u003e",
    "references": [],
    "sentAt": "2026-11-17T07:20:04Z",
    "subject": "[#1] WLAN in den Gästezimmern 2. OG fällt immer wieder aus",
    "to": [
      {
        "address": "katrin.stadler@alpenhotel-seeblick.example",
        "name": "Katrin Stadler"
      }
    ]
  }
}
```

### Example request

```bash
curl -X GET 'https://api.mbcom.cloud/api/desk/v1/items/string/entries/string/mail' \
  -H "Authorization: Bearer $ACCESS_TOKEN"
```
