Pagination
List endpoints in the GIFQ API are paginated. Use the page query parameter to navigate through results.
GET /api/orders?page=2
X-Api-Token: YOUR-API-KEY
Defaults and limits
| Parameter | Default | Max |
|---|---|---|
page | 1 | — |
limit | 10 | 20 |
Pass limit alongside page to control how many records are returned per request:
GET /api/orders?page=1&limit=20
X-Api-Token: YOUR-API-KEY
Reading pagination state from response headers
Each paginated response carries four headers:
| Header | Type | Description |
|---|---|---|
current-page | integer | Page returned in this response |
page-items | integer | Number of records in this response |
total-count | integer | Total records matching the query |
total-pages | integer | Total number of available pages |
Use total-pages to know when you have retrieved all results.
Endpoints that support pagination
| Endpoint | Default sort order |
|---|---|
GET /api/orders | Newest first |
GET /api/products | Brand name A–Z |
GET /api/transactions | — |
GET /api/campaigns | — |
GET /api/campaigns/:id/catalog | — |
GET /api/payout-orders | — |
GET /api/payouts | — |
Out-of-range pages
Requesting a page that does not exist returns HTTP 400:
{
"message": "Pagination error: expected :page in 1..5; got 999",
"status": "error"
}Updated 7 days ago