agentleFS
divik-09divik-09/claude-skills-collection/skills/api-design-review/SKILL.md

api-design-review

Skill1 starsChanged 9 days agoMITView on GitHub

Review or design REST and HTTP JSON APIs for consistency, safety, and usability. Use whenever the user shares an OpenAPI spec, endpoint list, request/response examples, or asks how to design, name, version, paginate, or error-handle an API.

12 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use accessibility-audit and security-audit.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • GitHubSkill

    accessibility-audit

    Audits actual components and routes against applicable WCAG 2.2 A/AA criteria using consumer-owned design-system evidence and repository tools. Use when asked for an accessibility audit, a11y check, keyboard or focus review, contrast check, or screen-reader verification.

    Also in 3 projects that use this

  • CloudflareSkill

    security-audit

    Security guidance and vulnerability review for codebases, APIs, services, CLI tools, libraries, and daemons. Use for security questions, focused reviews, vulnerability research, security audits, or pen tests. Run the complete workflow only for explicit codebase audit or pen-test requests, full/comprehensive/end-to-end reviews, or requested report artifacts.

    Also in 3 projects that use this

The file

Files
SKILL.md

API Design Review

Checklist

Resources and naming

  • Plural nouns for collections (/orders), no verbs in paths. Actions that do not fit CRUD go to a sub-resource (POST /orders/{id}/cancellation).
  • Consistent casing (pick snake_case or camelCase for fields and stick to it).
  • IDs are opaque strings, not sequential integers exposed to clients.

Methods and status codes

  • GET safe and idempotent, PUT/DELETE idempotent, POST for create/non-idempotent actions.
  • 200 OK, 201 Created (with Location), 204 No Content, 400 malformed, 401 unauthenticated, 403 forbidden, 404 missing, 409 conflict, 422 validation, 429 rate limited, 5xx server fault.

Errors

  • One error shape everywhere, e.g. { "error": { "code": "invalid_amount", "message": "...", "field": "amount", "request_id": "..." } }.
  • Machine-readable code for programs, human message for people. Never leak stack traces.

Lists

  • Pagination on every collection. Prefer cursor-based for large or changing data; document default and max page size.
  • Filtering, sorting and field selection with predictable query params.

Safety and evolution

  • Idempotency keys for payment-like POSTs.
  • Versioning strategy stated (path /v1 or header). Additive changes are non-breaking; removing or retyping fields is breaking.
  • Rate limits with Retry-After and documented quotas.
  • AuthN/AuthZ on every endpoint, least-privilege scopes, no secrets in URLs.
  • Timestamps in ISO 8601 UTC. Money as integer minor units plus currency code, never floats.

Output

Findings table: Endpoint | Issue | Severity | Recommendation, followed by a corrected example request/response for the worst offender, and a short list of cross-cutting conventions to adopt. If designing from scratch, produce an endpoint table and one example per endpoint.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.