Pagination
Pagination
Querying resources and especially retrieving a lot of data can be potentially really expensive. Therefor, endpoints that retrieve a lot of results are paginated. Use page
and offset
query parameters to request a certain page of the result in GET endpoints. When using search endpoints (POST HTTP method), page
and offset
are part of the payload.
Page
You can request a certain page of the result using the page
query/ payload parameter.
Offset
You can set the maximum number of results to return using the offset
query/ payload parameter. The minimum value is 1
and the maximum can differ per API. This is specified in more details in endpoints that support pagination. The default offset
on most endpoints is 12
.
Response
This response retrieves 2 results in the data, the number of results per page is 2 and page requested is 1. total
is the number of records for the page requested, while itemsFound
is the total number of results.
{
"data": [
{
id: 56897
},
{
id: 36975
}
],
"messages": [
"Completed"
],
"start": 1,
"pages": 20,
"total": 2,
"offset": 2,
"itemsFound": 35,
"end": 2,
"page": 1
}