Search docs
Docs searchValidation rule
Back to Rule CatalogAP-API-010API DesignMissing pagination on collection endpoint
Flags collection endpoints that do not expose clear pagination or bounded result controls.
warningviolationNo auto-fix
How to fix
- Add limit/cursor or page parameters.
- Document defaults and maximum page size in the API contract.
- Return pagination metadata when clients need it.
What it means
An API endpoint returns a collection without documented limit, cursor, or page controls.
Why it matters
Collection endpoints need bounded behavior for reliability and predictable client usage.
Common causes
- A list endpoint was added as a simple array response.
- Pagination exists in code but not in the contract.
- A small collection grew into a high-cardinality resource.
Example bad pattern
GET /repositories returns every repository in the organization with no limit parameter.Example good pattern
GET /repositories?limit=50&cursor=... returns a bounded page and next cursor.Related files/config
contracts/openapi.yamlapps/api/src
Related CLI commands
archpilot validatearchpilot validate --ci
Related docs