This page is not yet translated. Showing English content.
Order Tracking
POST
/channel/api/v1/order/trackingAuth: request-token (channel_partner)
Return logistics tracking events for an order. You may query by either order_id (preferred) or tracking_number. When both are sent, order_id wins and tracking_number is ignored. The partner's shop scope is enforced in both cases.
Request Headers
| Header | Required | Description |
|---|---|---|
request-token | yes | Channel partner app token |
Content-Type | yes | application/json |
Request Body
Provide at least one of the following:
| Field | Type | Required | Description |
|---|---|---|---|
order_id | integer | no* | Order ID (preferred). When > 0 the order is queried directly |
tracking_number | string | no* | Tracking number. Used to reverse-lookup the order |
Response
json
{
"code": 200,
"msg": "success",
"data": [
{
"id": 1,
"tracking_number": "1Z999AA10123456784",
"carrier": "UPS",
"event_time": "2026-08-13 14:30:00",
"event_description": "Shipped",
"event_location": "",
"raw_data": {
"stage": "delivered",
"sub_status": null,
"barcode": null,
"event_id": "evt-1"
}
}
]
}Behavior Notes
- By
order_id: The order is loaded and itsshop_idis verified against the partner's bound set; a missing or out-of-scope order returns403. - By
tracking_number: The system looks up the order package, resolves the order, and verifies shop scope. If the tracking number does not exist or the order is out of scope, an empty array (200) is returned instead of403, so tracking numbers cannot be used to probe other partners' orders. - Event order: Events are flattened in the order returned by the carrier and are not re-sorted by time; sort by
event_timeyourself when you need a timeline. - Fields:
carriermay benullwhen the carrier record is missing;event_locationis always an empty string;raw_datakeeps the originalstage/sub_status/barcode/event_idvalues. pickup_nois not supported — it can link orders across shops and has no clear single-partner semantics.
Error Codes
| code | Meaning |
|---|---|
| 909 | Missing/invalid token, disabled app, or non-channel_partner type |
| 403 | order_id points to an order outside the partner's shop scope |
| 400 | Neither order_id nor tracking_number was provided |
| 200 (empty array) | Tracking number not found, or no events yet |
cURL
curl -X POST 'https://apigate.e2c-energy.com/channel/api/v1/order/tracking' \
-H 'request-token: YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"order_id": 456
}'