Free temporary email API (disposable inboxes)
A free temporary email API for disposable inboxes you create and read over HTTP — test signups, read OTPs, and give agents throwaway addresses.
A temporary email API gives your code throwaway inboxes it creates and reads over HTTP — the programmatic version of a disposable-email site. It’s the right tool for testing signups, reading OTPs in CI, and handing an AI agent a one-off address.
Create a disposable inbox
curl -X POST https://login.ollastack.com/api/mailboxes \
-H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" \
-d '{"name":"throwaway","mode":"test"}'
# → { "id":"mbx_x", "address":"a1b2c3@test.ollastack.com" }
Use that address wherever you need a throwaway email. It’s a real, receiving address — not a black hole.
Read its mail
# block until the next message arrives
curl "https://login.ollastack.com/api/mailboxes/mbx_x/wait?timeout=60" \
-H "Authorization: Bearer $TOKEN"
# → { "from":"...", "subject":"...", "codes":["920184"], "links":["..."] }
Codes and links come extracted, so you read codes[0] instead of parsing HTML.
Never spam-filtered (on purpose)
A test inbox is unfiltered — it sees every message it was sent, even spam-shaped ones. That’s exactly what you want for testing: a strict transactional email never disappears from under your assertion. (Persistent agent inboxes are filtered — different job.)
Temporary vs persistent
- Temporary (test) — throwaway, unfiltered, for CI and one-offs.
- Persistent (agent) — a chosen handle that lasts and is spam-filtered, for an identity. See agent email identity.
Bulk-clear an inbox and set a retention window so test mail purges itself.
Isolate parallel test runs
When several tests run at once, each needs its own mail so they don’t read each other’s. Two ways:
- One inbox per test — create a fresh disposable mailbox at the start of each test and tear it down after. Cleanest isolation.
- Sub-addressing one inbox — append a
+tagto a shared address (a1b2c3+test42@test.ollastack.com) and filter received mail by the tag. Fewer inboxes, still isolated.
Either way, bulk-clear an inbox between runs and set a retention window so old test mail purges itself instead of piling up.
When NOT to use a temporary inbox
A disposable inbox is the wrong tool for a persistent identity — anything a real person will reply to over time, or an address that must survive across sessions. For that, use a persistent agent inbox (spam-filtered, a chosen handle). Temporary inboxes are for throwaway, single-use, and CI flows.
Where it fits
Disposable inboxes power OTP testing, CI email testing, and agent verifications. They’re part of the same email API — free, no credit card.
Create a temporary inbox — disposable, readable over HTTP, free.
Frequently asked questions
What is a temporary email API?
A temporary email API creates disposable inboxes on demand and lets you read their incoming mail over HTTP. Unlike a throwaway-email website, it's programmatic — your code or CI creates the inbox, reads the message, and moves on.
Is there a free temporary email API?
Yes. Ollastack's free tier includes disposable test inboxes you create and read over HTTP, with no credit card. They're never spam-filtered, so a test sees every message.
What's the difference from a persistent inbox?
A temporary (test) inbox is throwaway and unfiltered — for CI and one-off verifications. A persistent (agent) inbox is a chosen handle that lasts and is spam-filtered — for an identity your app or agent keeps using.
Can I read OTP codes from a temporary inbox?
Yes. Each message exposes extracted codes and links, so you read codes[0] for an OTP instead of scraping the email body.
Last updated June 21, 2026. Spotted something out of date? Email hello@ollastack.com.