perch

perch

2 min read Original article ↗

perch is open source under MIT-0, but it requires an mxRaven workspace to handle the public edge. mxRaven's free plan includes one workspace with 1,000 inbound and 1,000 outbound emails a month, with no card required.

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.

Give your agent a real inbox.

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

  • Install the Skill your harness
  • 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

Read the agent guide →

# Install the agent skill
$ npx skills add https://github.com/synqronlabs/perch \
    --skill perch

# 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