Run a Resend-compatible email API on your own server
Scribase Mail is AGPL-3.0 code you can deploy with Docker: the dashboard, the Resend-compatible API, domains, contacts, broadcasts, webhooks and inbound mail. Your resend SDK code points at your own host.
Last checked October 8, 2026.
What you need
If you would rather send through another provider, the upstream project this fork is based on, useSend, is also open source under the AGPL-3.0 and uses a different sending provider.
- A server that runs Docker. Web, Postgres and Redis fit in about 1.5 GB of RAM.
- An Oracle Cloud tenancy with Email Delivery enabled. This fork sends through it: SMTP for sending, its API for domains, DKIM, approved senders and suppressions.
- A domain you can add DNS records to (DKIM CNAME and SPF).
- Optional: port 25 reachable from the internet if you want inbound mail.
Set it up
Step 1
Get the code and the env file
All settings live in one env file.
sh git clone https://github.com/caelum0x/scribase-mail-studio.git cd scribase-mail-studio cp .env.selfhost.example .envStep 2
Fill in sending, database and app values
SMTP credentials and an API signing key from the Oracle Cloud console, a FROM_EMAIL on a domain already set up there (for sign-in codes), and a random NEXTAUTH_SECRET.
env SMTP_HOST="smtp.email.<region>.oci.oraclecloud.com" SMTP_PORT="587" SMTP_USER="..." SMTP_PASS="..." OCI_REGION="<region>" OCI_TENANCY="ocid1.tenancy.oc1..." OCI_USER="ocid1.user.oc1..." OCI_FINGERPRINT="..." OCI_PRIVATE_KEY="-----BEGIN PRIVATE KEY-----\n...\n-----END PRIVATE KEY-----" FROM_EMAIL="Mail <noreply@mail.example.com>" NEXTAUTH_URL="https://mail.example.com" NEXTAUTH_SECRET="$(openssl rand -base64 32)"Step 3
Start it
The compose file builds the image and runs the web app, Postgres and Redis on one host. The web port binds to 127.0.0.1 only, so put a reverse proxy with TLS in front of it. deploy/DEPLOY.md walks through the full production setup, including inbound MX.
sh docker compose -f deploy/compose.scribase-mail.yml --env-file .env up -d --buildStep 4
Point the resend SDK at your host
Create an API key in your dashboard and use your own hostname as the base URL.
ts const resend = new Resend(process.env.MAIL_KEY, { baseUrl: 'https://mail-api.example.com' })
What the AGPL asks of you
Running it for your own products needs nothing extra. If you modify it and let other people use it over a network, you must offer them the source of your modified version. The app already links to its source from the sidebar, the login page and unsubscribe pages; change that link to your fork.
When the hosted plan is simpler
Self-hosting means you own deliverability: warming up a new sending domain, watching bounces and complaints, and keeping the server patched. If you only want the API, the hosted service runs the same code with a free tier of 3,000 emails a month.
| Plan | Price | Emails a month | Daily cap | Domains | Over the quota |
|---|---|---|---|---|---|
| Free | $0 | 3,000 | 100 | 1 | Sending stops |
| Pro | $20 | 50,000 | None | 10 | $0.90 per 1,000 |
| Scale | $90 | 100,000 | None | 1,000 | $0.90 per 1,000 |
Questions people ask
Is it really Resend-compatible?
The API layer is tested with the official resend SDK and was checked live on 2026-10-07: an email sent through it was delivered, and its Svix-signed webhooks verified with the svix library.
Can I run it without Oracle Cloud?
Not this fork: its sending provider layer is built for Oracle Cloud Email Delivery. useSend, the upstream project, uses a different provider.
Does it include marketing email?
Yes. Contacts, contact books, segments, topics, broadcasts with a campaign editor, double opt-in and one-click unsubscribe.