Pagination and filtering
List endpoints return one page of results at a time, wrapped in a key named after the
resource, with a pagination object next to it:
{ "orders": [ { "object": "Order", "id": 90311, "…": "…" } ], "pagination": { "totalResultsCount": 213, "currentPage": 1, "nextPage": true, "prevPage": false, "resultOnPageCount": 25, "pageCount": 9 }}| Field | Meaning |
|---|---|
totalResultsCount |
Number of results across all pages, with your filters applied. |
currentPage |
The page returned, starting at 1. |
nextPage |
true when there is a page after this one. |
prevPage |
true when there is a page before this one. |
resultOnPageCount |
Number of results on this page. |
pageCount |
Number of pages. |
Page through a list
Section titled “Page through a list”| Parameter | Default | Rules |
|---|---|---|
page |
1 |
Asking for a page after the last one answers 404. |
limit |
Depends on the endpoint, see below | From 1 to 100. A larger value is lowered to 100. |
Default page sizes:
| Endpoint | Default limit |
|---|---|
| Admin API: listings, listing categories, users, orders, events, collections, variants, add-ons | 25 |
Admin API: GET /api/v1/shipping-rates |
1 (always pass limit) |
| Partners API: listings, orders | 25 |
| Partners API: stores | 50 |
| Partners API: shipping rates | 10 |
| Front API: listings, orders | 25 |
| Front API: wishlists | 20 |
Loop on nextPage rather than computing pages yourself: results can be added while you
read.
const base = 'https://acme.mykreezalid.com/api/v1';const auth = Buffer.from(`${process.env.KREEZALID_API_KEY}:${process.env.KREEZALID_API_SECRET}`).toString('base64');
async function* allOrders(params = {}) { for (let page = 1; ; page++) { const qs = new URLSearchParams({ ...params, page: String(page), limit: '100' }); const res = await fetch(`${base}/orders?${qs}`, { headers: { Authorization: `Basic ${auth}` } }); const body = await res.json(); yield* body.orders; if (!body.pagination?.nextPage) return; }}
for await (const order of allOrders({ status: 'new,accepted' })) { console.log(order.number, order.status);}<?phpfunction allOrders(array $params = []): Generator{ $base = 'https://acme.mykreezalid.com/api/v1'; for ($page = 1; ; $page++) { $qs = http_build_query($params + ['page' => $page, 'limit' => 100]); $ch = curl_init("$base/orders?$qs"); curl_setopt_array($ch, [ CURLOPT_USERPWD => getenv('KREEZALID_API_KEY') . ':' . getenv('KREEZALID_API_SECRET'), CURLOPT_RETURNTRANSFER => true, ]); $body = json_decode(curl_exec($ch), true); yield from $body['orders']; if (empty($body['pagination']['nextPage'])) { return; } }}
foreach (allOrders(['status' => 'new,accepted']) as $order) { echo $order['number'], ' ', $order['status'], PHP_EOL;}import os, requests
BASE = "https://acme.mykreezalid.com/api/v1"AUTH = (os.environ["KREEZALID_API_KEY"], os.environ["KREEZALID_API_SECRET"])
def all_orders(**params): page = 1 while True: body = requests.get(f"{BASE}/orders", auth=AUTH, params={**params, "page": page, "limit": 100}).json() yield from body["orders"] if not body.get("pagination", {}).get("nextPage"): return page += 1
for order in all_orders(status="new,accepted"): print(order["number"], order["status"])Paginated lists accept sort and direction:
GET /api/v1/listings?sort=modified&direction=descGET /api/v1/orders?sort=id&direction=ascsortnames a stored field of the resource, such asid,createdormodified. A name that is not one of the resource’s own stored fields is ignored and the default order applies.directionisasc(the default when you passsort) ordesc.- Without
sort, listings, users and events come newest first (by id), and orders by checkout date, most recent first.
Filter
Section titled “Filter”Each list endpoint has its own filters. Filters that take ids accept a single value, a
comma-separated list (user_id=12,57) or the array form (user_id[]=12&user_id[]=57).
Listings: GET /api/v1/listings
Section titled “Listings: GET /api/v1/listings”| Parameter | Example | Matches |
|---|---|---|
user_id |
user_id=4242,4243 |
Listings of these vendors. |
category_id |
category_id=812 |
Listings in these categories. |
status |
status=published,draft |
draft, published, archived. |
admin_status |
admin_status=waiting |
waiting, approved, rejected, blocked. |
order_type_id |
order_type_id=2 |
Listings of this order type. |
on_homepage |
on_homepage=1 |
Listings featured on the home page (1) or not (0). |
Listings of deleted, deactivated or blocked vendors are never returned by this endpoint.
Orders: GET /api/v1/orders
Section titled “Orders: GET /api/v1/orders”| Parameter | Example | Matches |
|---|---|---|
status |
status=new,accepted |
These statuses. Without status, every order except drafts. |
id |
id=90311,90312 |
These order ids. |
order_number |
order_number=R-1042,R-1043 |
These order numbers. |
customer_id |
customer_id=5120 |
Orders of these customers. |
supplier_id |
supplier_id=4242 |
Orders of these vendors. |
cart_id |
cart_id=7781 |
Orders created from these carts. |
start_on_date |
start_on_date=2026-11-02 |
Orders with an item booked to start on that date. |
Users: GET /api/v1/users
Section titled “Users: GET /api/v1/users”| Parameter | Example | Matches |
|---|---|---|
group_id |
group_id=3 |
Users of these groups. |
Exact-match search
Section titled “Exact-match search”GET /api/v1/listings/search and GET /api/v1/users/search match any stored field of the
resource exactly. They are the way to find an object by your own reference:
curl "https://acme.mykreezalid.com/api/v1/listings/search?external_id=JC-BIKE-0193" -u "$KEY:$SECRET"curl "https://acme.mykreezalid.com/api/v1/users/search?email=jane@example.com" -u "$KEY:$SECRET"GET /api/v1/events filters the same way, for instance ?type=order.status.new or
?object=Order&object_id=90311.
Select fields
Section titled “Select fields”Add fields with a comma-separated list of top-level fields to receive only those:
curl "https://acme.mykreezalid.com/api/v1/listings?fields=id,title,price,quantity,external_id" \ -u "$KEY:$SECRET"{ "listings": [ { "id": 645646, "title": "Steel road bike, 56 cm", "price": "480.00", "quantity": 1, "external_id": "JC-BIKE-0193" } ], "pagination": { "totalResultsCount": 37, "currentPage": 1, "nextPage": true, "prevPage": false, "resultOnPageCount": 25, "pageCount": 2 }}fields works on the lists of listings, users and orders, and on a single user
(GET /api/v1/users/{id}). It selects top-level fields only: you get the whole category or
none of it, not category.title. A field that is empty for an object is left out of that
object rather than returned as null.