Orders
Optimise Orders Sequence
This API is used to optimise the orders sequence in a Route
This API is used to optimise the orders sequence in a Route
AuthorizationBasic <token>
In: header
Path Parameters
route_handle*string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/orders/routes/string/optimise" \ -H "Content-Type: application/json" \ -d '{}'{ "route_handle": "route-1", "ops_group_handle": "SAN_JOSE_WH", "plan_mode": "manual", "status": "completed", "completed_at": "2023-03-14T23:55:00Z", "worker_handle": "James", "version": 1, "estimate": { "start_by": "2023-03-14T23:20:00Z", "distance": 1000, "duration": 600, "polyline": { "type": "LineString", "coordinates": [ [ 77.72123, 12.89617 ], [ 77.72169, 12.89595 ], [ 77.72214, 12.89572 ] ] }, "start_location": { "type": "Point", "coordinates": [ -121.8924515, 37.4124516 ] }, "end_location": { "type": "Point", "coordinates": [ -121.8984515, 37.5124516 ] } }, "orders": [ { "order_handle": "order-101", "fulfillment_attempt": 1, "status": "completed", "completed_at": "2023-03-14T23:55:00Z", "ops_group_handle": "store-sjc", "worker_handle": "James", "device_id": "2F659D4D-B524-45F0-A6E2-093CF2BB5574", "created_at": "2023-03-14T23:00:00Z", "scheduled_at": "2023-03-14T23:50:00Z", "scheduled_after": "2023-03-14T23:20:00Z", "metadata": { "customerId": "1223344" }, "region": { "city": "Fremont", "state": "California", "country": "United States of America" }, "destination": { "geometry": { "type": "Point", "coordinates": [ -121.8984515, 37.5124516 ] }, "radius": 50, "address": "Mission Peak, Fremont CA 94539" }, "risk_status": false, "expected_service_time": 600, "product_type": [ "plumber" ], "type": "drop", "capacity_used": 5 } ], "device_id": "2F659D4D-B524-45F0-A6E2-093CF2BB5574", "metadata": { "customerId": "4255534", "zone": 4 }, "embed_url": "https://embed.hypertrack.com/dkdkddnd"}{ "detail": {}, "message": "string"}{ "detail": {}, "message": "string"}{ "detail": { "<location>": { "<field_name>": [ "string" ] } }, "message": "string"}Reassign Route POST
Reassign the route to a different worker. Please provide either a worker_handle or the device_id of the new worker to whom the route needs to be assigned.
Update Order Task PATCH
Updates the details of a specific task associated with an order. This endpoint is used to modify the status and details of a task by its ID.