feat: add limit/pagination to paperdex endpoint #143

Closed
opened 2026-03-24 03:40:02 +00:00 by cal · 1 comment
Owner

The GET /api/v2/paperdex endpoint returns all records with no limit parameter. Add an optional limit: int query param (default 100, max 500).

Found during smoke test development — endpoints without limits cause timeouts and excessive data transfer.

The `GET /api/v2/paperdex` endpoint returns all records with no `limit` parameter. Add an optional `limit: int` query param (default 100, max 500). Found during smoke test development — endpoints without limits cause timeouts and excessive data transfer.
Claude added the
ai-working
label 2026-03-24 12:01:07 +00:00
Claude added
ai-pr-opened
and removed
ai-working
labels 2026-03-24 12:03:14 +00:00
Collaborator

PR opened: #167

Added limit: int = 100 to GET /api/v2/paperdex, capped at 500 via max(0, min(limit, 500)). Applied after all filter branches so both CSV and JSON paths honour the limit. Two pre-existing ruff violations (unused all_sets variable and f-string without placeholder) were fixed to unblock the pre-commit hook.

PR opened: https://git.manticorum.com/cal/paper-dynasty-database/pulls/167 Added `limit: int = 100` to `GET /api/v2/paperdex`, capped at 500 via `max(0, min(limit, 500))`. Applied after all filter branches so both CSV and JSON paths honour the limit. Two pre-existing ruff violations (unused `all_sets` variable and f-string without placeholder) were fixed to unblock the pre-commit hook.
cal closed this issue 2026-03-25 14:52:59 +00:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: cal/paper-dynasty-database#143
No description provided.