List business orders
curl --request GET \
--url https://api.khaime.com/api/v1/analytics/orders \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.khaime.com/api/v1/analytics/orders"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.khaime.com/api/v1/analytics/orders', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.khaime.com/api/v1/analytics/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.khaime.com/api/v1/analytics/orders"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.khaime.com/api/v1/analytics/orders")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.khaime.com/api/v1/analytics/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyStore Data
List business orders
The business’s orders, newest first.
GET
/
api
/
v1
/
analytics
/
orders
List business orders
curl --request GET \
--url https://api.khaime.com/api/v1/analytics/orders \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.khaime.com/api/v1/analytics/orders"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.khaime.com/api/v1/analytics/orders', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.khaime.com/api/v1/analytics/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.khaime.com/api/v1/analytics/orders"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.khaime.com/api/v1/analytics/orders")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.khaime.com/api/v1/analytics/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_bodyThe business’s orders, newest first. Orders contain customer information, so show them only behind a login.
Call this from your server with a
pk_ key. See Store data overview for keys, errors and how to read empty values.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
payment_status | string | No | unpaid, attempted, paid, failed or refunded. |
delivery_status | string | No | pending, processing, shipped, out_for_delivery, delivered, cancelled or returned. |
since | string | No | Orders placed on or after this YYYY-MM-DD. |
until | string | No | Orders placed on or before this YYYY-MM-DD. |
limit | integer | No | How many rows, 1 to 50. Default 20. |
Request
curl -H "X-API-Key: $KHAIME_API_KEY" \
"https://api.khaime.com/api/v1/analytics/orders?payment_status=paid&limit=20"
Response
{
"message": "Orders retrieved",
"success": true,
"status": true,
"data": {
"environment": "live",
"total": 38,
"items": [
{
"id": 9012,
"order_number": "KH-9012",
"amount": {
"minor": 8200,
"currency": "USD"
},
"payment_status": "paid",
"delivery_status": "shipped",
"customer_id": 771,
"created_at": "2026-10-31T14:03:11.000Z"
}
]
}
}
Read it correctly
amount.minoris in hundredths ofamount.currency.amountisnullwhen no amount was recorded. That does not mean the order was free.totalcounts every match. To read past the limit, makeuntilearlier.
