Skip to main content

Pagination

Some list endpoints paginate and some return everything. The difference matters, so it is worth knowing which is which before you write a loop.

Paginated endpoints

GET /{workspace}/posts and GET /{workspace}/media are paginated and accept two query parameters:

ParameterDefaultNotes
limit50Page size. Values above 100 are silently clamped to 100.
page1The page to return.
curl -L -X GET 'https://example.com/api/3bbd0951-5b04-432b-b2a0-688588b0720e/posts?limit=25&page=2' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <token>'
The page-size parameter is limit, not per_page

per_page appears in the response metadata, but it is not accepted as an input. Sending ?per_page=20 has no effect — you will silently get the default 50 per page. Use limit.

The response wraps the collection in data and adds links and meta:

{
"data": [],
"links": {
"first": "https://example.com/api/{workspace}/posts?page=1",
"last": "https://example.com/api/{workspace}/posts?page=4",
"prev": null,
"next": "https://example.com/api/{workspace}/posts?page=2"
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 4,
"path": "https://example.com/api/{workspace}/posts",
"per_page": 50,
"to": 50,
"total": 187
}
}

To walk every page, follow links.next until it is null.

Both paginated workspace endpoints sort newest first by default, and every order breaks ties on id, so the order stays stable across requests — including the orders GET /{workspace}/media accepts through its sort parameter. Walking the pages of an unchanging collection never repeats or skips a record — but records created while you are walking still shift the pages under you, so a loop over a busy workspace should de-duplicate on uuid.

Non-paginated endpoints

GET /{workspace}/accounts and GET /{workspace}/tags return the complete set in one response. They accept no limit or page — both are ignored — and the body has no links or meta:

{
"data": []
}

Don't paginate these; you already have everything.

Enterprise panel endpoints

GET /panel/workspaces, GET /panel/users and GET /panel/receipts are paginated at a fixed 20 per page. They accept page, but the page size is hardcoded and limit is ignored.

Summary

EndpointPaginatedPage size
GET /{workspace}/postsyeslimit, default 50, max 100
GET /{workspace}/mediayeslimit, default 50, max 100
GET /{workspace}/accountsnoreturns all
GET /{workspace}/tagsnoreturns all
GET /panel/workspacesyesfixed 20
GET /panel/usersyesfixed 20
GET /panel/receiptsyesfixed 20