Developer Docs
10 endpoints
API Documentation
Complete REST API for branches, services, price quotation, order management, tracking, and webhooks. JSON request/response with Bearer token auth.
QUICK START
BASE URL
https://ext-api.onetraker.com/api/v1
https://ext-api.onetraker.com/api/v1
AUTH HEADER
Bearer Base64(id:secret)
Bearer Base64(id:secret)
VERSION
API v1.0 / Doc v1.8
API v1.0 / Doc v1.8
AUTHENTICATION
Generate base64 encoded value of 'client_id:client_secret' and pass as Bearer token.
JAVASCRIPT
window.btoa('access_key:secret_key')PYTHON
base64.b64encode(f'{api_key}:{secret_key}'.encode('utf-8')).decode('ascii')STATUS CODES
200Success
400Invalid request. Some field missing/invalid
401Authentication Error. Check client_id and/or client_secret
403Authorization Error. Operation/Action is not allowed
404Entity/Resource not found or does not exist
500Gateway error. Internal error of OTOM
ENDPOINTS
10 endpoints available
GET
Get Branches for Merchant
/otoms/merchant/branch/
No body
GET
Get Service
/otoms/service/
No body
GET
Get Slots for Service
/otoms/service/{service_id}/slots/
No body
POST
Price Quotation
/otoms/price/price_quotation
View payload
POST
Create Order
/otoms/order/
View payload
POST
Update Order
/otoms/order/update/
View payload
GET
Get Order Status
/otoms/order/{order_id}
No body
GET
Get Order Tracking Details
/otoms/order/{order_id}/tracking
No body
GET
Get Tags
/otoms/merchant/tags/
No body
POST
Get Invoice
/otoms/invoice/
View payload
WEBHOOK EVENTS
Real-time notifications
HTTP POST callbacks sent to your endpoint URL. Must respond 200 OK within 10 seconds. 10 retry attempts on failure.
consignment.placedOnce the consignment order is created.consignment.inprogressWhen order starts processing.consignment.pickupOnce an order is picked up by a driver agent.consignment.deliveredWhen an order is delivered to the user.consignment.cancelledIf the order is canceled.consignment.failedIf the order failed.SAMPLE PAYLOAD
Every webhook delivers the full order object with current status.
WEBHOOK POST BODY
{
"event_id": "evt_aaa111bbb222ccc333ddd444eee555",
"created_epoch": 1662706125.481716,
"created_datetime": "2022-09-09 06:48:45.481716",
"event_name": "placed",
"order": {
"id": "ord_sample123abc456def",
"name": "test",
"service": "LAST MILE",
"service_id": "svc_sample789ghi012jkl",
"status": "PLACED",
"delivery": {
"from_address": {},
"to_address": {},
"instruction": {},
"tracking": {
"tracking_code": "trk_sample111222333444555666",
"tracking_link": "",
"driver": {},
"do_history": {}
}
},
"price": {},
"payment": {}
}
}