Paging
With paging query parameters you can change the size of response data array and iterate response loading.
Paging query parameters
Examples: page=1
, page=1&limit=20
Query parameter | Description | Default | Range |
page | Selected page | 1 | (1, ...) |
limit | Max items on a page (step). | 20 | (1, 100) |
Paging response structure
currentPage
Int
The current page.
perPage
Int
Maximum items (limit) on a page.
totalItemsOnPage
Int
Number of items on the actual page.
totalItemsCount
Int?
Total items count for the whole data. It may be null for some entities [1].
firstPage
Int
The first page. It should always be equal to 1.
lastPage
Int?
The last page. It can be null for some entities [1].
It will be equal to 0 in the future if there are no data but now the API2 returns HTTP 404 Not Found.
nextPage
Int?
The next page or null if on the last page.
prevPage
Int?
The previous page or null if on the first page.
data
List
The list of entities.
[1] Some endpoints do not count all the records because it would negatively impact the performance. Endpoints for the following entities return totalItemsCount=null
and lastPage=null
currently (but it can change in the future):
In such situations you can advance to the next page and repeat until you get a result with totalItemsOnPage < perPage
or an HTTP error 404 Not Found.
Paging examples
Description | Page query parameters |
Page 2, data per 20 items |
|
Page 3, default limit |
|
Last updated