The spec, not a vague memory
Your agent has read a hundred API styles and mixes them. These skills send it to spec.md, the sections that apply, before it writes a line.
Tools · For AI agents · draft 6
Skills for agentsTeach your agentTwo skills in the SKILL.md format: one to design or change an API so it follows Restep, one to review a change against it. They carry the specification, restep-check and the schemas, and work offline.
Claude Code, Codex, Cursor and other agents · SKILL.md
Your agent has read a hundred API styles and mixes them. These skills send it to spec.md, the sections that apply, before it writes a line.
restep-design is not done until restep-check exits with 0, and it tells you which warnings stay and why.
restep-review reports each finding with its section, MUST or SHOULD, the file and line, what the API does and what the section asks. Breaking changes included.
Each skill carries the specification and the schemas, so it reads offline; the checker comes from npm. The SKILL.md format works in Claude Code, Codex, Cursor and others.
An agent reads the description of every installed skill and loads the one that fits the request. restep-design comes in when you mention Restep or ask to make an API’s errors, pagination, filtering, retries or concurrency consistent. restep-review, when you ask whether an API follows Restep or to review one against it. You can also ask for either by name.
restep-design: build or change an APIcore always; query if it filters or paginates, writes for retries or concurrent edits, cache for caching, relations for nested or linked resources, sync for clients that keep a local copy, with their dependencies. Then it reads, in full, sections 3 to 5 of spec.md and the section of each chosen profile.core and then each profile, from its section. The skill adds a checklist of the rules most often missed: next always present, unsupported_parameter instead of silence, decimals as strings, limit rejected rather than clamped, strong ETags, idempotency keys kept 24 hours, Cache-Control on every read, and so on.npx restep-check http://localhost:3000/ --writes against a local server with test data. It fixes every FAIL, fixes each WARN or explains why it stays, and finishes when the checker exits with 0.restep-review: review a changeLink: rel="profile" headers. Without a discovery document it assumes core and reports the missing document.--writes only against a test environment, and only if you agree.Both skills are on GitHub, in restep-spec/skills, so an agent can install and update them:
# Claude Code, Codex, Cursor and others, with the skills CLI
npx skills add restep-spec/skills
npx skills add restep-spec/skills --skill restep-design # just one
# Claude Code, as a plugin
/plugin marketplace add restep-spec/skills
/plugin install restep@restep
To run the checker, the agent needs Node 18 or later: it calls npx restep-check.
| File | What it is |
|---|---|
SKILL.md | The instructions: when to use the skill and its steps. restep-design (7.5 KB) also has the checklist; restep-review is under 2 KB |
spec.md | The whole specification in Markdown, the same as /1/spec.md when the skill was published |
schema/discovery.json, schema/problem.json | The JSON Schemas, for the API’s own tests |
The skill tells the agent that the copy of spec.md is the reference offline, and that with network access the published one is the latest.
Things to ask, and what happens.
| You ask | Skill | What the agent does |
|---|---|---|
| “Make this Express API follow Restep.” | restep-design | Lists resources and methods, proposes core plus the profiles the API already needs, reads their sections, adds the discovery document and problem+json errors, and runs restep-check until it passes |
“Add filtering and pagination to /orders.” | restep-design | Adds query: declares filters, sort keys and max_limit in discovery, signed cursors, invalid_parameter for a limit out of range |
| “Two people editing the same invoice overwrite each other.” | restep-design | Adds writes: strong ETags, If-Match checked atomically, 412 precondition_failed |
| “Review this pull request against Restep.” | restep-review | Reads what the API announces and checks only the touched endpoints against those sections |
“We renamed total_price to total. Is that fine?” | restep-review | Flags a breaking change under 5.5: a renamed field has to be retired first, through deprecations, or wait for a new major version |
“Does openapi.yaml follow Restep?” | restep-review | Reviews the document as if it were the API, and lists what only a running server can show |
A finding from restep-review has this shape (an illustration, not a real report):
6.4 MUST · GET /orders · src/routes/orders.js:42
Does: limit=500 is clamped to 100 and answered with 200.
Requires: a limit outside 1..max_limit gives 400 invalid_parameter, never a silent clamp.
The specification is one file: /1/spec.md (and in Spanish). /llms.txt lists everything here for a model to find. A line in your AGENTS.md is enough to start:
This API follows Restep 1 (https://restep.wubytes.com/1/spec.md): read the sections of the
profiles it announces before changing an endpoint, and run restep-check before finishing.
spec.md they carry. The agent can still answer you in your language.core, query, writes, cache and relations, subcollections and the actions, oauth and inherit extensions. For sync and the other extensions, the agent has only the text of the specification to go on.restep-check in CI.