Open source inbox for you, your agent, or your application in 1 file.

A single-binary IMAP + SMTP server with a POSIX CLI

$ go install github.com/synqronlabs/perch/cmd/perch@latest

Mail infrastructure without the infrastructure.

perch is a mailbox server, a mail client, and a small automation surface in one binary. mxRaven handles the public edge: MX, SPF/DKIM/DMARC, IP reputation, and spam filtering.

1 file, zero sidecars

A CGO-free Go binary with embedded SQLite and FTS5. No Postfix, Dovecot, Rspamd, or container orchestra.

No public IP required

Inbound mail arrives over an outbound WebSocket. Works behind NAT, CGNAT, or a homelab router.

Your storage, your rules

Keep compressed mail in SQLite or offload raw .eml files to S3/R2 while metadata and search stay local.

Agent-ready CLI

POSIX commands with NDJSON, raw .eml, mbox, Maildir, and real exit codes. Easy to wire into an agent loop.

Standard protocols

IMAP and authenticated SMTP. Use Thunderbird, Apple Mail, mutt, or your own application client.

Private by default

Self-hosted mail with zero inbound SMTP ports. mxRaven does not retain your messages.

Built for agents and harnesses

Give your agent a real inbox.

No browser sessions, no scraping, no vendor-specific mailbox API. Your agent gets normal email plus a clean command-line interface designed for scripts and tool calls.

  • Search and list messages as NDJSON for structured context
  • Fetch raw .eml for RAG, summarization, or archival
  • Send replies and attachments with one command
  • Use mbox or Maildir when a pipeline expects files
  • Works locally or against any remote IMAP/SMTP server
# Give the agent structured context
$ perch mail search -q 'unseen from:alice' --json

# Fetch the full message $ perch mail fetch --uids 42 > message.eml
# Reply with an attachment $ perch mail send --to alice@example.com \ --subject 'Report ready' \ --body 'See attached.' \ --attach report.pdf