Documentation Index
Fetch the complete documentation index at: https://docs.relaycli.com/llms.txt
Use this file to discover all available pages before exploring further.
Why read this? You don’t need to memorize every RFC to use Relay, but a 5-minute tour of the landscape helps you debug faster — and impress friends at parties.
Standards & Governance
IETF
Internet Engineering Task Force – the community that writes the open specifications powering e-mail, HTTP, TLS, etc. All core mail specs are “RFCs” (Request for Comments) published by the IETF.RFC
A numbered document that defines a protocol. Example: RFC 5322 specifies e-mail headers. Every server and client that follows the same RFC can inter-operate – that’s why you can fetch Gmail via Apple Mail.Anatomy of an email
- Headers: key-value pairs describing sender, recipients, threading
- Body: one or more “parts” (plain text, HTML, PDF, images)
email example
Email Protocols
- (RFC 3501) — read & organize mail.
- IDLE (RFC 2177) — real-time notifications.
- (RFC 1939) — download and delete mail.
- (RFC 5321) — send mail.
- (RFC 8620) — modern JSON read/send.
From Server to App: Who Does What?
| Layer | Acronym | Example software | What it does |
|---|---|---|---|
| Mail Transfer Agent | MTA | Postfix, Exim | Routes SMTP traffic between domains. |
| Mail Delivery Agent | MDA | Dovecot, Courier | Saves incoming mail to the user’s mailbox. |
| Mail User Agent | MUA | Outlook, Thunderbird | that people click. |
| Relay | - | (open-core) | Sits between MUA and IMAP, giving dev-friendly JSON + webhooks. |
Providers vs. Clients
- Provider = organization hosting an MTA/MDA (Gmail, Outlook, Proton, your own VPS).
- Client = anything that logs in to read or send mail (iOS Mail, Superhuman, your script).
Email APIs vs. Delivery APIs
Both provide programmable access to email-related operations.| Category | Examples | Focus |
|---|---|---|
| Delivery APIs | Resend, SendGrid, SES | High-volume outbound (newsletters, receipts). |
| Interaction APIs | Relay | Read, search, tag, reply, build full apps. |
Key Terminology in Relay
| Term | Short definition |
|---|---|
| Email account | IMAP/SMTP credential set you connect |
| Message | A single e-mail, defined by its Message-ID or IMAP UID. |
| Thread | All messages sharing References/In-Reply-To headers |
| Label | User-defined tag saved server-side; survives new messages. |