For QA & test automation
Test the failures production rarely shows you
Rate limits, expired tokens, outages, timeouts and empty states on demand, repeatable in CI.
Free forever plan · No credit card required
test('shows a retry banner when rate limited', async ({ page }) => {
await page.setExtraHTTPHeaders({
'X-MockAPI-Scenario': 'rate-limited',
})
await page.goto('/checkout')
await expect(page.getByText('Too many requests')).toBeVisible()
})Flaky shared staging
Tests fail because someone changed data or a dependency is down.
Untestable edge cases
You cannot make a real payment provider time out on cue.
Slow, brittle fixtures
Stubbing every request in every test is tedious and drifts over time.
What you get
Named scenarios
Create presets like token-expired or upstream-down and select them with X-MockAPI-Scenario.
Latency profiles
Add realistic or extreme latency to catch race conditions and missing spinners.
Real rate limiting
Per-minute limits return 429s with Retry-After and X-RateLimit headers.
Stable URLs for CI
The same endpoints work locally, in pipelines and in preview environments.
Request logs
See exactly what your client sent when a test fails.
Contract drift detection
Know when mocks no longer match the OpenAPI spec under test.
Get started in three steps
- 01
Define scenarios
Create named presets with status, body and delay overrides per endpoint.
- 02
Select per request
Send the X-MockAPI-Scenario header from your test, or set a default.
- 03
Assert on behaviour
Verify your UI and clients handle every failure gracefully.
FAQ
Common questions
Which test frameworks work with MockAPI?
Any that can make HTTP requests or set headers: Cypress, Playwright, Selenium, Jest, Vitest, Postman/Newman, k6 and more.
Are responses repeatable?
Scenario responses return exactly what you saved, and stateful records stay until you change them, reset them or the project's data TTL runs out (1 day by default), so test runs are repeatable. Without stateful mode, generated values change on every call.
Do scenario requests count toward rate limits?
Yes. Rate limiting runs before scenario evaluation, so every mock request counts toward the configured limit.
Build against a mock API that behaves like your real one
Create your first endpoint in under two minutes.
Free forever · No credit card required