# at.sovrn.mail.mailbox

> The mail folder a mirrored-mail space holds, after the JMAP Mailbox (RFC 8621 §2). One per space, written by sovrn as the user. The space key is only a readable slug; this record has the exact names.

- Kind: record
- Record key: literal:self
- Authority: mail.sovrn.at
- Lexicon: 1
- Published by [sovrn.at](https://lexicon.garden/identity/did:plc:54ba6vxrdbzi6nexczpk5xzb), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:54ba6vxrdbzi6nexczpk5xzb/at.sovrn.mail.mailbox)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:54ba6vxrdbzi6nexczpk5xzb/at.sovrn.mail.mailbox/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:54ba6vxrdbzi6nexczpk5xzb/at.sovrn.mail.mailbox/analytics)

## Record (`at.sovrn.mail.mailbox`)

Type: record · key literal:self

### Properties

- `address` (string): Primary address of the mailbox this folder belongs to.
  - Constraints: maxLength: 254
- `name` (string, required): The folder's own name (JMAP Mailbox name).
  - Constraints: maxLength: 1024, maxGraphemes: 256
- `path` (array, required): Names from the top-level folder down to this one; the last element is name.
  - Constraints: maxLength: 64
  - `items` (string)
    - Constraints: maxLength: 1024, maxGraphemes: 256
- `role` (string): The folder's IANA mailbox role (RFC 8457, RFC 6154), as in JMAP Mailbox role. Absent for user folders.
  - Constraints: maxLength: 64, knownValues: all | archive | drafts | flagged | important | inbox | junk | sent | subscribed | trash
- `sortOrder` (integer): JMAP Mailbox sortOrder: lower sorts first.
  - Constraints: minimum: 0
- `source` (ref)
  - Reference: `at.sovrn.mail.defs#mailboxSource`

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "main": {
      "description": "The mail folder a mirrored-mail space holds, after the JMAP Mailbox (RFC 8621 §2). One per space, written by sovrn as the user. The space key is only a readable slug; this record has the exact names.",
      "key": "literal:self",
      "record": {
        "properties": {
          "address": {
            "description": "Primary address of the mailbox this folder belongs to.",
            "maxLength": 254,
            "type": "string"
          },
          "name": {
            "description": "The folder's own name (JMAP Mailbox name).",
            "maxGraphemes": 256,
            "maxLength": 1024,
            "type": "string"
          },
          "path": {
            "description": "Names from the top-level folder down to this one; the last element is name.",
            "items": {
              "maxGraphemes": 256,
              "maxLength": 1024,
              "type": "string"
            },
            "maxLength": 64,
            "type": "array"
          },
          "role": {
            "description": "The folder's IANA mailbox role (RFC 8457, RFC 6154), as in JMAP Mailbox role. Absent for user folders.",
            "knownValues": [
              "all",
              "archive",
              "drafts",
              "flagged",
              "important",
              "inbox",
              "junk",
              "sent",
              "subscribed",
              "trash"
            ],
            "maxLength": 64,
            "type": "string"
          },
          "sortOrder": {
            "description": "JMAP Mailbox sortOrder: lower sorts first.",
            "minimum": 0,
            "type": "integer"
          },
          "source": {
            "ref": "at.sovrn.mail.defs#mailboxSource",
            "type": "ref"
          }
        },
        "required": [
          "name",
          "path"
        ],
        "type": "object"
      },
      "type": "record"
    }
  },
  "id": "at.sovrn.mail.mailbox",
  "lexicon": 1
}
```
