API design review
For engineers
REST and RPC styles, versioning, errors, idempotency and pagination, reviewed as the person who signs off on generated APIs
110 questions across four stages: Understand, Apply, Solve and Judge.
Try 5 questions
Practice items, not counted towards your mastery. No account needed.
Check yourself · 1 of 5
An assistant generates GET /orders/17/cancel. What is the main problem?
Check yourself · 2 of 5
Which change to a JSON response is usually non-breaking?
Check yourself · 3 of 5
Why should an API error carry a stable type or code as well as a message?
Check yourself · 4 of 5
Which HTTP method is not idempotent by definition?
Check yourself · 5 of 5
A generated GET /orders returns every order in one array. What is the main risk?
Topics
- Choosing REST, RPC or GraphQL styles4 min read · Resources versus actions, HTTP method and status semantics, and keeping a generated endpoint consistent with the API it joins
- Versioning and backward-compatible changes4 min read · Breaking versus additive changes, deprecation windows, and URL or header versioning
- Consistent, actionable API error responses4 min read · One error shape with stable codes (RFC 9457 problem details), correct status codes and no stack traces or internals
- Idempotency keys and safe retries5 min read · Idempotent methods, idempotency keys on create and payment calls, and retries from clients, queues and agents
- Pagination, limits and OpenAPI contracts4 min read · Cursor versus offset pagination, bounded list sizes, filtering, and the OpenAPI spec as the contract that tests check
Start here
- Google API Improvement Proposals (AIP) (opens in a new tab)DocsFree
A large, consistent rulebook for resource naming, standard methods, pagination, errors and compatibility.
- RFC 9457: Problem Details for HTTP APIs (opens in a new tab)StandardFree
The standard JSON error shape with type, title, status, detail and instance members.
- Idempotent requests (Stripe API reference) (opens in a new tab)DocsFree
A widely copied idempotency-key design: key reuse, parameter mismatch and key expiry.
Scenarios
110 questions · last verified 2026-12