# Channels, messages and sync

> Channel kinds, messages, attachments, embeds, and how members never miss anything.

## Channels

| Kind | What it is |
|---|---|
| `text` | messages, reactions, attachments, embeds |
| `announcement` | like text, usually posting-restricted |
| `voice` | voice chat (with text chat too) |
| `category` | groups channels; can pass permission overrides to them |

Channels have a topic, a position, optional **slowmode**, an optional **locked** flag, and a
retention and history policy the community chooses (for example, newcomers see only messages from
after they joined).

## Messages

A message has text (up to 4 000 characters), optional **embeds**, **attachments**, **mentions**
(named explicitly, never parsed from text) and reactions. Messages from bots can also carry
**components** (buttons, selects, layouts).

### Attachments

Files travel as SimpleX files over the same post-quantum connection; each is encrypted with a fresh
key. The host checks each file's size and SHA3-256 before keeping it, and is the archive: members
download from the host.

### Embeds

Embeds are rich cards (title, description, colour, fields, author, footer, image, thumbnail),
with one rule that matters: **pictures are attachments of the same message, never URLs**, so no reader's
app ever fetches an image from a third party (which would reveal its IP address).

## Nobody misses anything

Every channel's events are numbered. An app that was offline reconnects and asks for "everything
after number 41"; nothing is lost or doubled. Clients keep a cursor per channel and acknowledge
what they received, so the host knows what to resend.
