Skip to content

Paging

Every list pages the same way. The request takes limit and cursor in the query string, and the reply is an object with items and nextCursor:

GET /v1/connected-apps?limit=2 HTTP/1.1
Host: api.voidfs.com
{
"items": [
{
"appId": "b3c39e4a90f6113318459b5ca1a1cea14ff03c79f236054ed75a15c7acbb9b92",
"name": "Laptop CLI",
"createdAt": "2026-11-27T10:15:00Z",
"expiresAt": null,
"lastUsedOn": "2026-11-27",
"revokedAt": null
}
],
"nextCursor": null
}
Name Where Meaning
limit Query How many items to return at most: a whole number from 1 to the operation’s maximum. Left out, it is the maximum. The reference gives the maximum for each list.
cursor Query The nextCursor of the page before. Left out, the list starts at its beginning.
items Reply The items of this page, in the list’s order.
nextCursor Reply A string to pass as cursor for the next page, or null on the last page.

Ask again with cursor set to the last reply’s nextCursor until it is null:

const items = [];
let cursor = null;
do {
const url = new URL("https://api.voidfs.com/v1/connected-apps");
if (cursor) url.searchParams.set("cursor", cursor);
const page = await (await send(url)).json();
items.push(...page.items);
cursor = page.nextCursor;
} while (cursor);

send stands for your own function that adds the credential. A connected app signs each page’s request on its own, because the signature covers the URL with its query: see Signing requests.

  • A cursor is opaque. Pass it back as you got it; do not build or change one. A cursor the service cannot read answers 400 with the error code invalid.
  • nextCursor ends the list. Stop when it is null; do not work out the end from the number of items.
  • A list stays correct while it changes. A cursor marks a position in the list’s order, so an item added or removed between two requests does not shift the following pages.
  • Unknown parameters are refused. ?page=2 or ?offset=50 answers 400.