Configure API pagination
ZTZenoti Docs Team Updated March 7, 2026 1 min readHow-to
Zenoti API list endpoints return paginated results. Pagination lets you retrieve large datasets in manageable chunks by specifying the page number and page size in your request.
Before you begin
- You need a valid API key or access token. See Set up API authentication.
Permission: Manage API Keys, Manage Apps, and Manage Automation (under Administrator) -- Required to create backend applications and generate API keys.
How pagination works
All Zenoti list endpoints accept two query parameters for pagination:
| Parameter | Type | Default | Range | Description |
|---|---|---|---|---|
| page | integer | 1 | 1 or higher | The page number to retrieve |
| size | integer | 10 | 1β100 | The number of records per page |
Example request
GET /v1/centers/{{center_id}}/products?page=1&size=20
This request retrieves the first 20 products for the specified center.
Response structure
Every paginated response includes a page_info object:
| Field | Type | Description |
|---|---|---|
| total | integer | Total number of records matching the query |
| page | integer | The current page number |
| size | integer | The number of records returned on this page |
Example response
{
"products": [...],
"page_info": {
"total": 85,
"page": 1,
"size": 20
}
}
Steps
Implement pagination in your application
- Make your initial request with
page=1and your desiredsize(up to 100). - Check the
page_info.totalvalue in the response to determine the total number of records. - Calculate the total number of pages:
total_pages = ceil(total / size). - Loop through subsequent pages by incrementing the
pageparameter until you have retrieved all records.
Handle pagination limits
- The maximum page size is 100 records per request. Requesting more than 100 returns a 422 error.
- If you need all records from a large dataset, iterate through pages rather than requesting a single large page.
- Use the
page_info.totalvalue to determine when you have retrieved all available records.
Tips
- Use the smallest page size that meets your needs to reduce response times and API call frequency.
- Cache paginated results when the underlying data does not change frequently to reduce API calls.
- Be aware of the rate limit (60 calls per minute) when iterating through many pages.
Was this article helpful?
Your feedback helps us improve our documentation.