Mock API & Data Generator
A complete client-side Mock API and synthetic data generator. Define custom field schemas or pick presets (Users, E-Commerce, Blog Posts, Subscriptions), simulate REST endpoints with latency and error status codes, and export server files for json-server, MSW (Mock Service Worker), Express.js, or in-memory fetch mocks.
How to Generate & Test Mock APIs
A Mock API Generator allows frontend developers, mobile engineers, and testers to create realistic REST API endpoints and datasets before backend services are ready.
1. Schema Definition & Data Generation
- Custom Field Types: Define fields using generative types like Auto-increment IDs, UUID v4, Full Names, Emails, Phone Numbers, Price Ranges, Dates, Avatars, and Custom Enums.
- Deterministic Seeding: Control data randomness using a seed integer so team members generate identical datasets across test runs.
- Preset Schemas: Instantly initialize common data structures such as User Directories, E-Commerce Products, Blog Articles, or SaaS Subscriptions.
2. In-Browser Simulated Testing
- Test endpoints directly in your browser with simulated HTTP verbs (
GET,POST,PUT,DELETE). - Simulate custom HTTP response status codes (
200 OK,201 Created,400 Bad Request,404 Not Found,500 Server Error). - Add artificial response latency (0ms to 1500ms) to test frontend loading spinners and UI skeleton states.
- Test client-side search filtering (
?search=term) and pagination (?page=1&limit=10).
3. Server & Code Export Options
json-server(db.json): Export schema compatible withnpx json-server db.jsonfor rapid local mock backend development.- MSW (Mock Service Worker): Generate ready-to-use
handlers.tsfor intercepting network requests in React, Vue, or Next.js applications. - Express.js Backend: Copy a complete, zero-dependency Node.js Express server script with CORS and memory CRUD endpoints.
- In-Memory Client Fetch Mock: Get a clean client-side async helper function for prototype demos and offline development.
Frequently Asked Questions
Is my data saved on a remote server?
No. DevToolkit runs 100% in browser memory. All generated datasets, custom schemas, and server snippets remain private on your local device.
Can I filter or paginate generated data?
Yes. When testing GET endpoints in the interactive tester, search strings and pagination parameters dynamically filter and slice your generated dataset.
Related Tools
Offline Fake Data Set Generator
Build high-fidelity mock datasets containing custom fields in JSON, CSV, and SQL insert scripts.
JSON Formatter
Pretty print, format, and sort keys of your JSON data.
cURL Command Builder & Request Generator
Visually construct, parse, test, and convert cURL commands into multi-language code snippets.
JWT Debugger & Signature Validator
Decode JSON Web Tokens, customize headers or payloads, and validate HMAC signatures locally.
