Documentation menu

ApiMocker free API

Predictable JSON for the interface you are building.

Use realistic shared data, complete CRUD endpoints, search, filtering, pagination, relationships, delays, and intentional errors. No signup or API key is required.

Base URLhttps://api.apimocker.comTest it

Quick start

Make your first request

Send a standard HTTP request from a browser, terminal, API client, or server. The API accepts cross-origin requests from any origin.

JavaScript
const response = await fetch('https://api.apimocker.com/users');
const { data, pagination } = await response.json();

console.log(data);
console.log(pagination.total);

Service health

Check availability

The health endpoint confirms that the API process is running. It returns the current server timestamp and process uptime in seconds.

cURL request
curl 'https://api.apimocker.com/health'

200 response
{
  "status": "OK",
  "timestamp": "2026-07-22T18:25:14.477Z",
  "uptime": 21107.49
}

Resources

Four connected datasets

Each resource supports reads, writes, filtering, and per-resource search.

Response format

Collections include pagination

List endpoints return a data array and a pagination object. Single-resource endpoints return the resource directly. The total count is also available in the X-Total-Count response header.

JSON
{
  "data": [
    { "id": 1, "name": "John Doe", "username": "johndoe" }
  ],
  "pagination": {
    "page": 1,
    "limit": 10,
    "total": 10,
    "totalPages": 1,
    "hasNext": false,
    "hasPrev": false
  }
}

Conventions

What every client should know

01

JSON in and out

Send JSON request bodies with Content-Type: application/json.

02

Numeric IDs

Resource and relationship IDs are positive integers.

03

Normal HTTP status codes

Creates return 201, successful deletes return 204, and invalid input returns 400.

04

Temporary writes

POST, PUT, PATCH, and DELETE change shared data only until the daily reset.

Go deeper

Build the state you need