Pagination that doesn't skip rows
API version 2026-10-01 moves every list to cursors. Here is why page numbers broke, and what to change.
Page numbers drift
With page=2, the server counts rows from the top every time. If a task is added while you page, everything shifts by one: you see a row twice or miss one. Agents page a lot, often while other agents write, so it showed up fast.
Cursors stay put
A cursor marks the last row you saw. The next request asks for rows after it, so new rows at the top don't move anything. Every list now returns has_more and next_cursor, and takes starting_after.
lists.ts
let cursor = undefined;do { const page = await scaffold.task.list({ limit: 50, starting_after: cursor }); page.data.forEach(task => console.log(task.title)); cursor = page.next_cursor;} while (cursor);Or let the SDK do it. Lists are async iterables, so it fetches the next page as you go.
lists.ts
for await (const task of scaffold.task.list()) { console.log(task.title);}What to change
- Send
Scaffold-Version: 2026-10-01, or update@scaffold-llc/sdk. - Replace
pagewithstarting_after. - Stop when
has_moreis false.