Pagination¶
Our lists endpoints support cursor-based pagination. It allows you to get the first results, let you know if there is more and you can get the total number of results.
How it works¶
When you send a request to a REST endpoint that support cursor-based pagination, the response body returns the first page of results, based on the limit parameter you passed in the query parameters.
A boolean called has_more tells you if there are more results to your request.
Response example¶
{
"data": [...],
"has_more": true,
"object": "list",
"total": 12000
}
Get list parameters¶
Your request contains the parameters allowing you to control how to get your results
limitnumber : the maximum number of results to be returned.with_totalboolean : If you set this to false, thetotalin the response will be null (default true). Some list endpoints doesn’t implement this parametersstarting_after: the object ID from which the resulting array should start. If no more objects are available, the resulting array will be empty. This request should never return an error.ending_before: the object ID from which the resulting array should end. If no more objects are available, the resulting array will be empty. This request should never return an error.
Supported endpoints¶
Cyclists
Passes sans contact (NFC)
Trajets
Vehicules
Stations
Zones de rendu