Skip to content
Mock APIs

Getting started

Introduction

Mock APIs is a free public REST API that serves realistic, synthetic data. Use it to learn HTTP, build front-end prototypes, write tutorials, and test API clients without running your own backend.

Base URL

All endpoints live under a single versioned prefix. No API key or signup is required, and CORS is enabled for every origin.

Base URL
https://test.naimulhassan.me/api/v1

What you get

  • Eight related resources with deterministic seed data: users, products, posts, comments, todos, carts, recipes, and quotes.
  • Real query features: pagination with totals, sorting, field selection, search, and filters. See Pagination & query params.
  • Simulated CRUD: POST, PUT, PATCH, and DELETE validate input and return realistic responses, but never modify the shared data.
  • Demo authentication with login, register, refresh, and protected routes that return real 401 and 403 errors. See Authentication.
  • HTTP testing utilities to echo requests, delay responses, and return any common status code. See HTTP testing utilities.
  • Consistent errors with a machine-readable code and request ID. See Errors.
  • An OpenAPI 3 document at https://test.naimulhassan.me/openapi.json, generated from the same source as the API. See OpenAPI spec.

Resources

Available resources
ResourceRecordsWritesDescription
/users100SimulatedFictional user profiles with contact details, address, company, and role. Users own posts, todos, comments, carts, and recipes.
/products100SimulatedA fictional product catalog across categories with pricing, discounts, ratings, and stock levels.
/posts100SimulatedShort blog-style posts written by seeded users, with tags, reactions, and view counts.
/comments300SimulatedComments left by users on posts. Every comment references an existing post and user.
/todos200SimulatedSimple to-do items that belong to users. Ideal for practicing list rendering and toggling state.
/carts50Read-onlyShopping carts that reference seeded users and products, with computed totals and discounts.
/recipes50Read-onlyRecipes with ingredients, step-by-step instructions, timings, and nutrition information.
/quotes50Read-onlyOriginal, fictional quotes with fictional authors. Read-only.

Good uses (and bad ones)

Mock APIs is built for learning and testing:

  • Practicing fetch, Axios, Dio, or requests in a course or bootcamp.
  • Prototyping lists, detail pages, search, infinite scroll, and forms.
  • Testing loading, empty, error, and slow-network states in your UI.
  • Demonstrating API concepts in blog posts and videos.

Not for production

Do not use Mock APIs as the backend of a real product, for load testing, or to store real personal data. The demo authentication is intentionally simple and must never protect a real application. There is no uptime guarantee and requests are rate limited.

Next steps

Send your first request in the Quickstart, read Getting started for the conventions every endpoint follows, or experiment in the Playground.