Some endpoints use pagination called Has more, which allows to go through limited pages.
The easiest way to determine if the endpoint uses this pagination is by checking result and if a key hasMore exists.
This key shows you if there are more available records to fetch.
{
"result": {
(...)
"hasMore": false/true
}
}
To use this pagination you need to add a parameter lastId in url query, which represents id of record.
The endpoint will fetch records after this specified id.
Let's assume that we have the endpoint /v1/example which uses this pagination with total 5 records and limit 3 per page.
/v1/example
{
"result": {
"rows": [
{
"id": 1
},
{
"id": 2
},
{
"id": 3
}
],
"hasMore": true
}
}
/v1/example?lastId=3
{
"result": {
"rows": [
{
"id": 4
},
{
"id": 5
}
],
"hasMore": false
}
}