Build your frontend with production-ready API calls from day one. When your backend is ready, just change the host. No refactoring. No "remove mock code" commits.
Traditional mock APIs force you to maintain two codebases
// Development - mock data
if (DEV_MODE) {
return mockData
}
// Production - real API
const response = await fetch('/api/users', {
body: JSON.stringify({ user_id })
})
// Maintain two codepaths forever π©
// Identical code in dev AND production!
const response = await fetch(`${API_HOST}/users`, {
body: JSON.stringify({
user_id: 191, // β Real payload
__instructions: { // β Ignored in prod
body: { users: { __repeat: 10 } }
}
})
})
Real payload outside. Mock response inside __instructions.
{
"user_id": 191, // β Production payload
"filters": { "active": true }, // β Backend sees this
"__instructions": { // β Gets ignored in prod
"body": {
"users": {
"__repeat": 10,
"name": "?name",
"email": "?email"
}
}
}
}
Everything you need to ship faster
Real payload outside. Mock response in __instructions. Backend sees exactly what it'll get in productionβno placeholder pollution.
Use __repeat to generate 1 or 1000 items. Perfect for testing infinite scroll, pagination, and data grids.
Add delays, custom status codes, and headers with __instructions. Test loading states and error handling properly.
Names, emails, addresses, prices, dates, UUIDs, and more. Realistic data makes better UI decisions.
Backend team sees exactly what shape you're sending. No "wait, what format?" conversations.
Change API_HOST and you're done. Backend ignores your placeholders. Zero refactoring needed.
No installation. No configuration. Just make requests.
Join developers who ship features, not refactoring PRs.