4 Commits

Author SHA1 Message Date
karti-ai abce753ba8 Architecture v3: pluggable MailBackend; competitive positioning; relay-first
- Confirm stack: Go, single binary, embed Mox + pluggable backend (chosen after
  landscape research).
- Add MailBackend interface: relay (v1 default) / imap_smtp (BYO mailbox) /
  embedded (go-smtp + mox smtpclient/dane/mtasts, flagship). Deliverability
  becomes opt-in; useful on day 1.
- Add competitive positioning (§0.1): closest competitor agenticmail is TS +
  Stalwart(AGPL) Docker sidecar; OpenMail differentiates as single binary,
  all-MIT, in-process. agentic-inbox is Cloudflare-locked.
- Reorder milestones backend-first: relay loop before embedded SMTP.
- State scope: self-hostable app, not a SaaS — no billing/Stripe.
- README: pluggable backends + positioning. Repo layout: internal/mail/*.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21 12:42:32 -07:00
karti-ai 551739baa3 Milestone 1 scaffold: binary skeleton, schema, deploy, Mox spike
- Confirmed core bet via spike/mimecheck: mox/message parses a messy multipart
  message standalone (envelope, MIME tree, attachment, body) with only an
  io.ReaderAt — no mox store/config. Option B is viable.
- cmd/openmail single binary: serve|migrate|smtpd|sender|version subcommands.
- internal/api: chi router, constant-time bearer auth, /healthz, stubbed v0
  AgentMail-shaped routes (501 until core services land).
- internal/store: pgxpool + embedded, idempotent, tracked SQL migrations.
- internal/store/migrations/0001_init.sql: full native schema (pods, inboxes,
  threads, messages, attachments, drafts, api_keys, webhooks, outbox, events,
  domains) with FTS + GIN indexes. Validated end-to-end against Postgres 16.
- deploy/: docker-compose (postgres+minio+openmail+caddy), Caddyfile, DNS.md
  (MX/SPF/DKIM/DMARC/DANE/MTA-STS). Makefile, .gitignore.
- Verified: go vet clean; build OK; health/auth smoke tests; migrate idempotent.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21 12:16:51 -07:00
karti-ai aab2a8558e Architecture v2: embed Mox (MIT) as a library; native Postgres agent layer
- Choose Option B: single binary embedding Mox's stateless protocol/crypto/
  delivery packages (dkim, spf, dmarc, dane, mtasts, message, smtpclient, junk,
  dsn, anti-abuse) while owning server loop (go-smtp) + Postgres data model.
- Boundary rule: never import mox smtpserver/imapserver/queue/store/config
  (bbolt/global-config coupled) — that's the line between embed and fork.
- Add MIT LICENSE; reframe README as a real MIT OSS product.
- Deliverability moat leans on mox smtpclient+dane+mtasts; relay fallback.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21 12:07:37 -07:00
karti-ai 9812e25973 Architecture: self-hosted AI-native mailbox for agents
Design of record for OpenMail — one Go binary (smtpd/core/sender/mcp) + Postgres
+ object storage on a VPS. Covers inbound SMTP/MIME/threading, outbound
deliverability (relay-default, self-host opt-in), data model, AgentMail-shaped
v0 API + MCP server, and an MVP milestone path.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-21 11:47:01 -07:00