List orders
Orders, as a sync list (customer contact data needs customers.read)
GET
https://s.zo.sa/api/public/v1 /orders Scope
orders.readRequest
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
per_page | integer | Rows per page, 1 to 100 (default 50; more is capped at 100). Default 50 At least 1 | |
cursor | string | The meta.next_cursor of the previous page. Opaque. Up to 200 characters | |
updated_since | string (date-time) | Only rows updated at or after this time (ISO 8601, inclusive to the second; no offset means UTC). | |
created_since | string (date-time) | Only rows created at or after this time (ISO 8601, inclusive to the second; no offset means UTC). | |
filter[status] | string | One of awaiting_payment, under_review, in_progress, ready, shipping, delivered, completed, cancelled, return_in_progress, returned | |
filter[payment_status] | string | One of pending, paid, refund_due, refunded | |
filter[customer_id] | integer |
cURL
curl -sS "https://s.zo.sa/api/public/v1/orders" \
-H "Authorization: Bearer $ZO_API_KEY" \
-H "Accept: application/json"JavaScript
const response = await fetch('https://s.zo.sa/api/public/v1/orders', {
headers: {
Authorization: `Bearer ${process.env.ZO_API_KEY}`,
Accept: 'application/json',
},
});
console.log(response.status, await response.json());PHP
<?php
$ch = curl_init('https://s.zo.sa/api/public/v1/orders');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('ZO_API_KEY'),
'Accept: application/json',
],
]);
$body = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
echo $status, PHP_EOL, $body, PHP_EOL;Python
import os
import requests
response = requests.get(
"https://s.zo.sa/api/public/v1/orders",
headers={
"Authorization": f"Bearer {os.environ['ZO_API_KEY']}",
"Accept": "application/json",
},
timeout=30,
)
print(response.status_code, response.json()){
"data": [
{
"id": 1042,
"number": "1042",
"status": "in_progress",
"payment_status": "pending",
"payment_method": "cod",
"source": "storefront",
"currency": "SAR",
"totals": {
"subtotal": 5000,
"discount": 0,
"shipping": 2500,
"tax": 978,
"total": 7500
},
"customer": {
"id": 2187,
"name": "Sara Ahmed",
"mobile": "+966501234567",
"email": "sara@example.com"
},
"customer_note": null,
"shipping_address": {
"name": "Sara Ahmed",
"mobile": "+966501234567",
"country": "SA",
"city": "Riyadh",
"district": "Al Olaya",
"street": "King Fahd Road",
"building": "12",
"postal_code": "12211",
"details": null
},
"items": [
{
"id": 3301,
"product_id": 501,
"variant_id": 811,
"sku": "TSHIRT-BLUE-M",
"name": {
"ar": "...",
"en": "Blue T-shirt"
},
"quantity": 2,
"unit_price": 2500,
"total": 5000,
"options": null
}
],
"created_at": "2026-11-23T06:01:53Z",
"updated_at": "2026-11-23T07:15:20Z"
}
],
"meta": {
"per_page": 50,
"next_cursor": "MjAyNi0xMS0yM1QwNzoxNToyMC4wMDAwMDArMDA6MDB8MTA0Mg"
}
}Example. Shortened to one row of the page, for a key with customers.read. next_cursor is opaque: pass it back as cursor.
Responses
200A page of orders.
Response schema
dataarray of objectsrequired14 fields
idintegerrequirednumberstringrequiredThe order number the merchant and the shopper see.statusstringrequiredpayment_statusstringrequiredpayment_methodstringrequiredsourcestringrequirednullableWhere the order came from: storefront, manual (typed in the dashboard), api (created through this API), or a marketplace (trendyol, amazon).currencystringrequiredtotalsobjectrequiredHalalas. shipping includes the cash-on-delivery fee; tax is the VAT already included in total. total may also hold paid order options.5 fields
subtotalintegerrequireddiscountintegerrequiredshippingintegerrequiredtaxintegerrequiredtotalintegerrequired
customerobjectrequiredWho placed the order. Without the customers.read scope only id and name are present; with it, mobile and email are added.4 fields
idintegerrequirednullableThe customer record (GET /customers/{id}).namestringrequirednullablemobilestringnullablePresent only with customers.read. E.164 for Saudi numbers.emailstringnullablePresent only with customers.read.
customer_notestringnullableWhat the shopper wrote with the order. Present only with customers.read (free text that may hold contact details).shipping_addressobjectnullable9 fields
namestringrequirednullableThe recipient (the customer unless the address names someone else).mobilestringrequirednullablecountrystringrequiredISO 3166-1 alpha-2; SA unless the address says otherwise.citystringrequirednullableThe city's name as the shopper reads it.districtstringrequirednullablestreetstringrequirednullablebuildingstringrequirednullablepostal_codestringrequirednullabledetailsstringrequirednullableAddress details the shopper typed (landmark, floor and so on).
itemsarray of objectsrequired9 fields
idintegerrequiredproduct_idintegerrequirednullableNull when the line is not tied to a product.variant_idintegerrequirednullableskustringrequirednullablenameobjectrequired2 fields
arstringrequirednullableenstringrequirednullable
quantityintegerrequiredunit_priceintegerrequiredHalalas.totalintegerrequiredHalalas.optionsobjectrequirednullableThe chosen option values as one text (for example "Red / L"); null for a product without options.2 fields
arstringrequirednullableenstringrequirednullable
created_atstring (date-time)requiredWhen the order was placed.updated_atstring (date-time)required
metaobjectrequired2 fields
per_pageintegerrequirednext_cursorstringrequirednullablePass as cursor for the next page; null on the last page.
401Missing, unknown, revoked or expired key.
An error object: {"error": {"code", "message", "fields"}}.
402The store's plan does not include this feature (error code feature_locked, with the feature and the plan that has it). Every operation answers it with feature public_api when the key's store is not on the Pro plan.
An error object: {"error": {"code", "message", "fields"}}.
403The key lacks the scope (code insufficient_scope, naming it in scope), the caller's address is not allowed (ip_not_allowed), or the store is suspended (store_suspended: reads stay allowed, every write answers this).
An error object: {"error": {"code", "message", "fields"}}.
422A query parameter is invalid (code validation_failed, with fields).
An error object: {"error": {"code", "message", "fields"}}.
429Too many requests (code rate_limited); see Retry-After.
An error object: {"error": {"code", "message", "fields"}}.