REST API Generator Skill for Paginated Resources
Scaffold a local resource from OpenAPI and verify stable list pagination, lookup, and missing-resource handling.
中文Install in Claude Code
Use a local HTTP framework, OpenAPI document, and test client. The example uses in-memory books ordered by stable ID.
- Get the complete `plugins/api-development/rest-api-generator/skills/generating-rest-apis` directory from the pinned GitHub commit.
- Copy it into the target project's `.claude/skills/`. Check `.claude/skills/generating-rest-apis/SKILL.md`, start Claude Code at the project root, and call `/generating-rest-apis`.
Example task
Add b1, b2, and b3. Verify /books?page=2&limit=2 only returns b3. Request /books/b2 and /books/missing to check lookup and 404.What to check
Pagination is reproducible from the fixture. Successful and missing lookups match their contracts, and existing tests still pass.
Original SKILL.md on GitHub · Updated
Frequently asked question
Do pagination tests need an explicit sort order?
Use stable ordering so a record cannot land on a different page between otherwise identical test runs.