Architecture
How Sypnia Mail is built: its parts, where Rust runs, and how they connect.
- Your app calls the API, or an SMTP client talks to the relay.
- The engine checks, renders and queues the e-mail in Postgres.
- The sender hands it to Amazon SES (or SMTP) at the allowed pace.
- Delivery events and inbound mail come back and are recorded and sent to your webhooks.
Read this diagram as text
Apps call the Mail API; older apps use the SMTP relay. The engine is one Rust binary with the API, the SMTP relay, the template renderer, the queue, the sender, the event receiver, the webhook dispatcher, the inbound parser and the MCP server. It keeps domains, templates, e-mails, events and suppressions in Postgres and attachments and raw messages in S3-compatible storage. The transport is Amazon SES or any SMTP server.
| Part | Language | Open source |
|---|---|---|
| Mail engine: API, SMTP relay, renderer, queue, sender, events, inbound, MCP | Rust (axum, lettre, mail-parser); templates rendered with a Handlebars-compatible engine | yes |
@sypnia/mail and its React components | TypeScript | yes |
| Deliverability guardrails and abuse review in Sypnia Cloud | Rust and TypeScript | the guardrail rules, yes; the review tools, no |
| Console | TypeScript (React) | no |
A send, a bounce and an inbound message, step by step.
The sypnia_mail schema: domains, templates, e-mails, events, suppressions, webhooks and inbound.
Reference implementation on AWS
Every AWS service Mail uses in Sypnia Cloud, and how.
What happens when SES, the database or your webhook fails, and how Mail grows.
How the open-source repository is organized.