agentleFS
gclmgclm/super-stack/skills/planning/api-design/SKILL.md

api-design

Skill0 starsChanged 7 months agoMITView on GitHub

Design or review API contracts for clarity, compatibility, validation, and caller ergonomics before implementation locks in the interface.

We split this skill into the rules it gives an agent

5 rules. 0 are common, 5 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 165 edited versions we read keep these.

  • 5

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when creating or revising an API surface such as REST endpoints, RPC handlers, webhook payloads, or SDK-facing …

    line 8
  2. Distinctive:

    keep response and error semantics consistent

    line 20
  3. Distinctive:

    Check naming, pagination, filtering, and mutation semantics.

    line 33
  4. Distinctive:

    Check backward compatibility and client impact.

    line 34
  5. Distinctive:

    Verify that validation and auth rules are explicit rather than implied.

    line 35

“Common” is measured: kept by at least 6 in 10 of the 165 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

API Design

Use this skill when creating or revising an API surface such as REST endpoints, RPC handlers, webhook payloads, or SDK-facing request/response contracts.

Read First

  • current routes, handlers, or client usage
  • request and response examples
  • validation and auth expectations
  • docs/reference/requirements.md and harness/state.md if they exist
  • harness/history.md if it exists

Goals

  • make the contract intuitive for callers
  • keep response and error semantics consistent
  • surface compatibility risks before implementation spreads
  • align validation, auth, and docs with the real API shape

Steps

  1. Define the caller goal in one sentence.
  2. Choose the surface shape:
    • endpoint or operation
    • method
    • request body or params
    • response shape
    • error model
  3. Check naming, pagination, filtering, and mutation semantics.
  4. Check backward compatibility and client impact.
  5. Verify that validation and auth rules are explicit rather than implied.
  6. Recommend the cleanest contract with trade-offs.

Output

Report:

  • caller goal
  • proposed contract
  • validation and error semantics
  • compatibility notes
  • caller impact
  • recommendation

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.

Reviews can't be read right now.

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.