The philoshopy behind fakeJSON is "Less work for developers". Our service is designed to be an always ready, always available, mock backend for your application. You can use the API for you frontend development, end to end testing, regression testing, rapid prototyping, data generation, and more. A serious mock backend solution for a serious developer. Use the API to iterate, update, and refresh your application for consistent and dependable mock data.
How do I start?
- Point your XMLHttpRequest or Fetch function directly to the
- Enter your desired response in the data field of the request payload.
- Enter your fakeJSON API token.
- Run the request
Wait, I don't need to login, create and design endpoints in the admin interface?
These four simple steps are all you need to get started. You don’t have to create every single endpoint one by one or populate them with data. fakeJSON does all that for you.
Let’s imagine that I am developing a new single-page application with jQuery (Yes, I know...). The designer that I am working with wants to see how user tables are populated in the app. Unfortunately, the backend isn’t ready and the designer wants to see it now so I’ll mock the user table in the frontend with data from fakeJSON.
My table has 3 columns: name, email, phone number. It supports pagination, done on the client side, so I’ll need at least 50 records to make it realistic. Luckily, this is trivial with fakeJSON. I'll make a request to the fakeJSON endpoint:
https://app.fakejson.com/q, complete with the data fields I want, together with my token to verify my use. Here’s what the code would look like:
I run the request and fakeJSON returns a perfectly build response of 300 users with the 3 data fields for each user. Done!