API response JSON examples
Last updated 2026-05-20
The most common API response shapes you will design against: list pagination, search + filter, login, validation errors, the full set of 4xx/5xx errors, and webhook payloads.
About this hub
Each page has a "When to use this" intro, a primary JSON shape with copy/download/format-toggle, and request examples in fetch / Axios / cURL / Node / Python. The error pages call the live /http/{code} endpoint so you can see the exact status code your client will receive.
Paginated list
Standard { items, total, skip, limit } envelope plus cursor and empty-page variations.
Search + filter
Matched items, applied filters, facets, and a sort field.
Login
Authenticated user + access token + refresh token in one response.
Validation error
Per-field error array plus a top-level message and code.
401 Unauthorized
"You are not logged in" with an authenticate hint.
403 Forbidden
"You are logged in but cannot do this."
404 Not found
Resource, id, and a not-found code.
422 Unprocessable
Business-rule violations after a successful parse.
429 Rate limit
retryAfter, limit, remaining, reset for proper backoff.
500 Server error
"Something went wrong" with a traceId for support.
Webhook payload
Event envelope, signature context, and a batch variation.