Stop mocking OTPs. Stop wrestling with MailSlurp regex. Get real OTP codes and magic links in one line — from any auth flow, any framework, any CI.
No credit card. Works with Playwright, Cypress, Vitest, Puppeteer.
signup.spec.ts
Browser
Waiting for test to start…
Sandbox
empty
The problem
Your CI passes because you hardcoded “123456”. Then a real user hits a bug your test never covered.
30 minutes of setup, custom regex, $49/mo — for a job that should be one line.
Twilio-based test runs add up fast. Carrier delays make tests slow and flaky. Rate limits break CI.
Two testers hit the same inbox. OTP expires before the second one reads it. Test fails. QA rage-refactors.
Developer-first
Works with any auth provider. Same SDK for Playwright, Cypress, and Vitest.
import { SandboxClient } from '@otpmagiclink/playwright'
const sandbox = new SandboxClient({
apiKey: process.env.OTP_API_KEY,
})
test('signup with email OTP', async ({ page }) => {
await page.goto('/signup')
await page.fill('[name=email]', 'test@yourapp.com')
await page.click('button[type=submit]')
const otp = await sandbox.waitForOtp('test@yourapp.com')
await page.fill('[name=otp]', otp)
await expect(page).toHaveURL('/dashboard')
})import { SandboxClient } from '@otpmagiclink/cypress'
const sandbox = new SandboxClient({
apiKey: Cypress.env('OTP_API_KEY'),
})
it('signs up with magic link', () => {
cy.visit('/signup')
cy.get('[name=email]').type('test@yourapp.com')
cy.get('button[type=submit]').click()
sandbox.waitForMagicLink('test@yourapp.com').then((link) => {
cy.visit(link)
cy.url().should('include', '/dashboard')
})
})await sandbox.waitForOtp(email). No inbox setup, no regex parsing, no timeouts.
OTPs available in milliseconds. No 30-second email polling. No flaky tests.
Run tests in parallel without collision. Each test session gets isolated storage.
Better Auth, Clerk, Auth.js, Supabase, or custom. Test the flow, not the vendor.
Sandbox never sends real emails or SMS. Run thousands of tests without carrier bills.
Works out of the box in GitHub Actions, CircleCI, GitLab. Just add your API key.
Works with any auth stack
We don't care what auth provider you use. Your app sends the OTP or magic link, we catch it, your test reads it. Same API everywhere.
Free tier that's actually useful. Paid tiers if you scale.
Pro
Most popular$19/mo
For teams and power users
Need more volume or team seats? Get in touch — we'll sort something out.