api-postman-collection
Use when creating or modifying API endpoints (Rails controllers, engine routes, API actions). Requires generating or updating a Postman Collection (JSON v2.1) so the new or changed endpoints can be tested. Trigger words: endpoint, API route, controller action, Postman, API collection, request collection. --- # API Postman Collection Use this skill when you add or change an API endpoint so that a Postman-compatible collection is generated or updated for testing. **Core principle:** Every API surface (Rails app or engine) has a single Postman Collection JSON file that stays in sync with its endpoints. All names, descriptions, and variable labels in the collection must be in **English**. ## Quick Reference | Aspect | Rule | |--------|------| | When | Create or update collection when creating or modifying any API endpoint (route + controller action) | | Format | Postman Collection JSON v2.1 (`schema` or `info.schema` references v2.1) | | Location | One file per app or engine, e.g. `docs/postman/<app-or-engine-name>.postman_collection.json` or `spec/fixtures/postman/` | | Language | All request names, descriptions, and variable names in the collection in **English** | | Per request | method, URL (with variables for base URL), headers (Content-Type, Authorization if needed), body example when applicable | ## HARD-GATE: Generate on Endpoint Change ``` When you create or modify a REST API endpoint (new or changed route and controller action), you MUST also create or update the corresponding Postman Collection JSON file so the flow can be tested. Do not leave the collection missing or outdated.
Changelog: Source: GitHub https://github.com/igmarin/rails-agent-skills
No comments yet. Be the first one!