Part of Bettermile Route API responsible for tour management
Products
///
Get a sequence by ID
Tour Commander API (1.0.0)
Download OpenAPI description
Overview
E-mail
License
Languages
Servers
Dev API
https://dev.routes.bettermile.com/
Bodyapplication/jsonrequired
Mode which is used to create a sequence:
- FIXED_OPTIMIZATION instructs that ETAs of waypoints are to be re-calculated, while the order of the waypoints is mostly kept intact (waypoint may only be moved in certain special cases, like when the time frame changes for a waypoint)
- FULL_OPTIMIZATION instructs the backend to create an entirely new sequence, without attempts to maintain the previous order of waypoints
- RETURN_TO_PREVIOUS_WAYPOINT_ORDER can be used to return to a previously used order of waypoints, in a situation when results of running FULL_OPTIMIZATION need to be "undone"
- USE_PROVIDED instructs the backend to keep the order of the provided waypoint ids (time frames will be ignored)
Enum"FIXED_OPTIMIZATION""FULL_OPTIMIZATION""RETURN_TO_PREVIOUS_WAYPOINT_ORDER""USE_PROVIDED"
A pair of coordinates
List of waypoints IDs representing expected order of waypoints in the generated sequence. When provided, sequence creation mode must be 'USE_PROVIDED'.
- Dev API
https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences
- curl
- Java
- JavaScript
- Go
- Python
curl -i -X POST \
'https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences' \
-H 'Content-Type: application/json' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-d '{
"mode": "FIXED_OPTIMIZATION",
"coords": {},
"startTime": "08:00:00"
}'Response
application/json
{ "data": { "sequenceId": 0 } }
- Dev API
https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences
- curl
- Java
- JavaScript
- Go
- Python
curl -i -X GET \
'https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences' \
-H 'x-api-key: YOUR_API_KEY_HERE'Response
application/json
{ "data": [ { … } ] }
- Dev API
https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences/latest
- curl
- Java
- JavaScript
- Go
- Python
curl -i -X GET \
'https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences/latest' \
-H 'x-api-key: YOUR_API_KEY_HERE'Response
application/json
{ "data": { "sequenceId": 0, "mode": "FIXED_OPTIMIZATION", "coords": { … }, "startTime": "14:15:22Z", "sequenceIdWithPreviousWaypointOrder": 0, "created": "2019-08-24T14:15:22Z", "sequenceFidelity": 1, "destination": { … }, "openWaypoints": [ … ], "closedWaypoints": [ … ], "unassignedWaypoints": [ … ] } }
- Dev API
https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences/{sequenceId}
- curl
- Java
- JavaScript
- Go
- Python
curl -i -X GET \
'https://dev.routes.bettermile.com/v1/tours/{tourId}/sequences/{sequenceId}' \
-H 'x-api-key: YOUR_API_KEY_HERE'Response
application/json
{ "data": { "sequenceId": 0, "mode": "FIXED_OPTIMIZATION", "coords": { … }, "startTime": "14:15:22Z", "sequenceIdWithPreviousWaypointOrder": 0, "created": "2019-08-24T14:15:22Z", "sequenceFidelity": 1, "destination": { … }, "openWaypoints": [ … ], "closedWaypoints": [ … ], "unassignedWaypoints": [ … ] } }