Pagination
Use pagination to efficiently navigate through datasets within OVOne
🗏 Pagination Parameters
When interacting with the OVOne API, you can utilize the following GET parameters for pagination:
page_number
This parameter specifies the page number you want to retrieve. The default value is 1page_size
This parameter sets the number of results returned per page. The default value is 10, and the maximum value allowed is 100.
💡 API Response
When you make a request to the API, the response includes a meta section that provides important information about the pagination state:
{
"meta": {
"current_page": 1,
"total_pages": 1706,
"items_per_page": 10,
"total_items": 17055
},
"items": {
....
}
}
Meta Information;
current_page
: The page number of the results returned.total_pages
: The total number of pages available for the data set.items_per_page
: The number of items displayed on each page.total_items
: The total number of items in the data set.
The items
element will contain the paged results.
The HTTP Response will also include a Pagination
header, containing the same content as the meta
JSON information, for example;
Pagination: {"currentPage":1,"itemsPerPage":10,"totalItems":17055,"totalPages":1706}
🪜Usage Example
To fetch the second page of results with 20 items per page, you would make a GET request like this:
GET /api/v1/sims?page_number=2&page_size=20
Updated 10 months ago