List location orders
curl --request GET \
--url https://server.chataigne.ai/v1/locations/{location_id}/orders \
--header 'x-api-key: <api-key>'import requests
url = "https://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/orders")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://server.chataigne.ai/v1/locations/{location_id}/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_body{
"object": "list",
"data": [
{
"id": "<string>",
"object": "order",
"short_id": "<string>",
"location_id": "<string>",
"status": "received",
"status_version": 1,
"service_type": "delivery",
"channel": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"expected_time": "2023-11-07T05:31:56Z",
"expected_pickup_time": "2023-11-07T05:31:56Z",
"expected_delivery_time": "2023-11-07T05:31:56Z",
"customer": {
"first_name": "<string>",
"last_name": "<string>",
"phone": "<string>",
"email": "<string>",
"language": "<string>"
},
"fulfillment": {
"type": "<string>",
"address": {
"line_1": "<string>",
"line_2": "<string>",
"postal_code": "<string>",
"city": "<string>",
"country": "<string>",
"latitude": 123,
"longitude": 123
},
"customer_notes": "<string>",
"delivery_notes": "<string>",
"collection_code": "<string>"
},
"items": [
{
"type": "product",
"id": "<string>",
"name": "<string>",
"quantity": 2,
"unit_price": {
"amount": 12.5,
"currency": "EUR"
},
"customer_notes": "<string>",
"modifier_groups": [
{
"id": "<string>",
"name": "<string>",
"modifiers": [
{
"id": "<string>",
"name": "<string>",
"quantity": 2,
"unit_price": {
"amount": 12.5,
"currency": "EUR"
},
"free_quantity": 1
}
]
}
]
}
],
"discounts": [
{
"id": "<string>",
"name": "<string>",
"amount": {
"amount": 12.5,
"currency": "EUR"
}
}
],
"charges": [
{
"type": "delivery",
"amount": {
"amount": 12.5,
"currency": "EUR"
}
}
],
"payment": {
"status": "authorized",
"amount": {
"amount": 12.5,
"currency": "EUR"
}
},
"total": {
"amount": 12.5,
"currency": "EUR"
}
}
],
"has_more": true,
"url": "<string>"
}{
"error": {
"type": "invalid_request_error",
"code": "resource_missing",
"message": "<string>",
"request_id": "req_8f2c…",
"param": "<string>",
"details": {}
}
}Orders
List location orders
GET
/
v1
/
locations
/
{location_id}
/
orders
List location orders
curl --request GET \
--url https://server.chataigne.ai/v1/locations/{location_id}/orders \
--header 'x-api-key: <api-key>'import requests
url = "https://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/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://server.chataigne.ai/v1/locations/{location_id}/orders")
.header("x-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://server.chataigne.ai/v1/locations/{location_id}/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_body{
"object": "list",
"data": [
{
"id": "<string>",
"object": "order",
"short_id": "<string>",
"location_id": "<string>",
"status": "received",
"status_version": 1,
"service_type": "delivery",
"channel": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"expected_time": "2023-11-07T05:31:56Z",
"expected_pickup_time": "2023-11-07T05:31:56Z",
"expected_delivery_time": "2023-11-07T05:31:56Z",
"customer": {
"first_name": "<string>",
"last_name": "<string>",
"phone": "<string>",
"email": "<string>",
"language": "<string>"
},
"fulfillment": {
"type": "<string>",
"address": {
"line_1": "<string>",
"line_2": "<string>",
"postal_code": "<string>",
"city": "<string>",
"country": "<string>",
"latitude": 123,
"longitude": 123
},
"customer_notes": "<string>",
"delivery_notes": "<string>",
"collection_code": "<string>"
},
"items": [
{
"type": "product",
"id": "<string>",
"name": "<string>",
"quantity": 2,
"unit_price": {
"amount": 12.5,
"currency": "EUR"
},
"customer_notes": "<string>",
"modifier_groups": [
{
"id": "<string>",
"name": "<string>",
"modifiers": [
{
"id": "<string>",
"name": "<string>",
"quantity": 2,
"unit_price": {
"amount": 12.5,
"currency": "EUR"
},
"free_quantity": 1
}
]
}
]
}
],
"discounts": [
{
"id": "<string>",
"name": "<string>",
"amount": {
"amount": 12.5,
"currency": "EUR"
}
}
],
"charges": [
{
"type": "delivery",
"amount": {
"amount": 12.5,
"currency": "EUR"
}
}
],
"payment": {
"status": "authorized",
"amount": {
"amount": 12.5,
"currency": "EUR"
}
},
"total": {
"amount": 12.5,
"currency": "EUR"
}
}
],
"has_more": true,
"url": "<string>"
}{
"error": {
"type": "invalid_request_error",
"code": "resource_missing",
"message": "<string>",
"request_id": "req_8f2c…",
"param": "<string>",
"details": {}
}
}Authorizations
Location/organization API key.
Path Parameters
Query Parameters
Page size (1–100).
Required range:
1 <= x <= 100Return orders after this order id.
Return orders before this order id.
Return orders created after this ISO 8601 timestamp.
Return orders created before this ISO 8601 timestamp.
Return orders updated after this ISO 8601 timestamp. For reconciliation, combine it with one fixed updated_before high-water mark across every page.
Return orders updated before this ISO 8601 timestamp. Keep this high-water value unchanged while paginating a reconciliation scan.
Available options:
received, accepted, in_preparation, awaiting_shipment, awaiting_collection, in_delivery, completed, rejected, cancelled, delivery_failed Available options:
delivery, collection, eat_in