Docs · Reference
Self-hosting
Run Mailroom, the engine behind Agentboxd, on your own server.
Agentboxd runs on Mailroom: Node, TypeScript, Express, PostgreSQL, Redis and BullMQ, packaged with Docker Compose. You can run the same engine yourself, with your own domain.
#Local stack
cp .env.example .env
docker compose up -d --build
docker compose exec api npm run create-key -- --org "Default" --name "local"Mailpit at http://localhost:8025 catches outbound mail in development.
#Receiving and sending
- Built-in MX on port 25 (
INBOUND_PROVIDER=smtp): accepts mail only for existing inboxes, checks SPF, DKIM and DMARC, supports STARTTLS. - Direct transport (
OUTBOUND_TRANSPORT=direct): DKIM-signed delivery straight to each recipient’s MX. - Or use Amazon SES or Mailgun for either direction. The adapters are pluggable.
#DNS
npm run dns-setup -- --ip <VPS IPv4> --dmarc-email you@example.com creates the DKIM key and prints every record: A for the MX host, MX, SPF, DKIM, DMARC, and the reverse DNS to set in your provider’s panel. Start DMARC at p=none and tighten it after a few weeks of clean reports.
The full guide, including SES setup, backups and VPS deployment, is in the repository README.