Borrowing it
Nothing to install: this file belongs to ngpestelos/readwise-mcp-server. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/ngpestelos/readwise-mcp-server/master/.claude/skills/api-pagination-debugging/SKILL.mdgit clone --depth 1 https://github.com/ngpestelos/readwise-mcp-serverWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/ngpestelos/readwise-mcp-server/api-pagination-debugging)<a href="https://agentmods.dev/skills/ngpestelos/readwise-mcp-server/api-pagination-debugging"><img src="https://agentmods.dev/badge/skills/ngpestelos/readwise-mcp-server/api-pagination-debugging/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/ngpestelos/readwise-mcp-server/api-pagination-debugging"><img src="https://agentmods.dev/badge/skills/ngpestelos/readwise-mcp-server/api-pagination-debugging.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00093 | $0.03928 |
| Opus 5.5 | $0.00037 | $0.01571 |
| Sonnet 5.5 | $0.00019 | $0.00786 |
| Haiku 4.5 | $0.00009 | $0.00393 |
Grade A, and why
API Pagination Debugging scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
curl -s API_ENDPOINT | jq 'keys' How it starts
The opening of the file, as written. The whole thing — 592 lines — stays where its author put it; the contents beside it link to each section on GitHub.
API Pagination Debugging
Purpose: Systematically diagnose and fix pagination failures that prevent complete data import from APIs
Core Principles
1. Verify API Response Structure Before Assuming
Never assume pagination fields based on documentation or other endpoints. Always test actual responses:
curl -s API_ENDPOINT | jq 'keys'
Different API versions or endpoints may use different pagination patterns even within the same service.
2. Match Pagination Logic to API Design
APIs use distinct pagination patterns that require different implementations:
- Cursor-based:
{nextPageCursor, results}- use cursor param - Page-based:
{page, total_pages, results}- use page number param - Offset-based:
{offset, limit, total}- use offset/limit params - Link-based:
{next, previous, results}- follow next URL
Using the wrong pattern causes pagination to stop after first page.
3. Optimize Page Size for Efficiency
Most APIs support configurable page sizes (e.g., 50-1000 items per page). Using maximum page_size:
- Reduces total API calls (20x fewer calls with 1000 vs 50)
- Decreases network overhead
- Minimizes rate limit exposure
- Speeds up bulk imports
4. Test Pagination Flow Before Implementation
Before implementing pagination logic:
- Fetch page 1 and inspect response structure
- Manually fetch page 2 to confirm field values
- Verify cursor/page advancement works correctly
- Check termination condition (null cursor, empty results, etc.)
Systematic Debugging Workflow
Step 1: Reproduce the Issue
Symptoms of pagination failure:
- Import stops after exactly 1 page
- Returns same results repeatedly
- Status shows "completed_all_pages" but dataset incomplete
- Missing data compared to known totals
Example:
Expected: 74,386 highlights
Actual: 463 files (< 1% of total)
Status: "completed_all_pages" after 1 page
Step 2: Inspect Actual API Response
Don't trust assumptions - verify response structure:
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2mo ago First seen · 592 lines · 93 tokens per session scan A 586a1376e860
API Pagination Debugging is a skill published in the GitHub repository ngpestelos/readwise-mcp-server (0 stars, last pushed 1mo ago), licensed MIT. It adds 93 tokens to every session and 3,928 once invoked, about $0.0004 per session on Opus 5.5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
API Pagination Debugging compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| API Pagination Debuggingngpestelos/readwise-mcp-server | Skill | 0 | 1mo ago | MIT | A | 93 | Claude Code |
| api-integration-architectsickn33/agentic-awesome-skills | Skill | 49k | yesterday | MIT | A | 33 | Claude Code |
| printing-press-amendmvanhorn/cli-printing-press | Skill | 4.9k | yesterday | MIT | A | 222 | Claude Code |
| convex-performance-auditopenclaw/clawhub | Skill | 9.5k | yesterday | MIT | A | 38 | Codex |
| convex-insightsopenclaw/clawhub | Skill | 9.5k | yesterday | MIT | A | 45 | Claude Code, Codex |
| axiom-networkingCharlesWiltgen/Axiom | Skill | 1.3k | yesterday | MIT | A | 37 | Claude Code |
| platform-apex-anonymous-runforcedotcom/sf-skills | Skill | 1.1k | 2d ago | Apache-2.0 | A | 119 | Claude Code |