---
title: "Messages that have arrived for one mailbox"
method: GET
path: "/api/v1/mail/inbox"
tags: ["Desk"]
---

# Messages that have arrived for one mailbox

`GET /api/v1/mail/inbox`

## Request

- Base URL: `http://localhost:5180`
- URL: `http://localhost:5180/api/v1/mail/inbox`
- Auth: API key in cookie `better-auth.session_token`

Reads the objects written under this team's prefix for one address, in the store the mailbox was bound in. The prefix is derived from the team in the session and the address given, never taken from the caller, so no address can be used to read another team's mail. A page is at most 100 messages and an object that does not parse is counted rather than dropped.

## Query parameters

- `address` string, required
- `after` string
- `limit` integer

## Response `200`

One page of messages.

- object
  - `ok` unknown, required
  - `data` object, required
    - `messages` object[], required: Oldest first, so threading can be applied in order.
      - `uid` string, required
      - `messageId` string
      - `inReplyTo` string
      - `references` string[]
      - `from` object, required
        - `name` string
        - `address` string, required
      - `to` object[], required
        - `name` string
        - `address` string, required
      - `cc` object[]
        - `name` string
        - `address` string, required
      - `subject` string, required
      - `receivedAt` string, required
      - `body` string, required
      - `attachments` object[]
        - `name` string, required
        - `size` number, required
        - `contentType` string, required
        - `key` string
      - `outbound` boolean
    - `cursor` string: Pass as `after` for the next page. Absent when this page is the last one.
    - `unreadable` number, required: Objects under the prefix that are not a message we could read. Counted rather than dropped silently.
  - `meta` object, required
    - `requestId` string, required: Echoed in the x-request-id header. Quote it in a bug report.

## Other responses

- `400`: `address` or `limit` is out of range.
- `401`: No session. Sign in first.

---

[API](https://skmtc.dev/dardaris/apis/dardaris-api.md) · [All operations](https://skmtc.dev/dardaris/apis/dardaris-api/llms.txt) · [OpenAPI document](https://skmtc.dev/dardaris/apis/dardaris-api/revisions/4aff33835c73?raw)
