Orders
Add an order note
Adds a note to the order's timeline in the merchant dashboard (the customer doesn't see it).
POST
https://elmatajer.com/api/v1/vendor/orders/{id}/notesPermission:
orders.writePath parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | integer | Yes | The order id. |
Request body
| Name | Type | Required | Description |
|---|---|---|---|
note | string | Yes | Up to 1,000 characters. |
Request
curl -X POST "https://elmatajer.com/api/v1/vendor/orders/4904/notes" \
-H "Api-Key: YOUR_API_KEY" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{"note":"Picked up by the courier — AWB 778201"}'
const res = await fetch("https://elmatajer.com/api/v1/vendor/orders/4904/notes", {
method: "POST",
headers: {
"Api-Key": process.env.ELMATAJER_API_KEY,
"Accept": "application/json",
"Content-Type": "application/json"
},
body: JSON.stringify({
"note": "Picked up by the courier — AWB 778201"
})
});
const data = await res.json();
$ch = curl_init("https://elmatajer.com/api/v1/vendor/orders/4904/notes");
curl_setopt_array($ch, [
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => ["Api-Key: " . getenv('ELMATAJER_API_KEY'), "Accept: application/json", "Content-Type: application/json"],
CURLOPT_POSTFIELDS => json_encode([
'note' => 'Picked up by the courier — AWB 778201'
]),
]);
$data = json_decode(curl_exec($ch), true);
Response 200
{
"status": "ok",
"data": {
"id": 322,
"order_id": 4904,
"note": "Picked up by the courier — AWB 778201"
}
}