Update StopStatus (v2)
The Update StopStatus endpoint lets you update the status (arrived, completed and canceled) of a given stop in the trip. This version (v2) mimics the legacy StopStatus endpoint but uses the unique stopID
provided by the Trip Management service to help more easily identify stops.
POST /trip/stopStatus
Resource URL
https://tripmanagement.trimblemaps.com/api/v2/trip/stopStatus
Request Fields
Field | Description | Type | Required |
---|---|---|---|
tripId
| The alkTripId returned when you planned the trip. Note: If no trip is found with the given alkTripId , then an error message will be returned. If the tmsTripId in your planning system is also supplied in the body of this request, then the alkTripId will be ignored irrespective of whether it is valid or not and the trip corresponding to the provided tmsTripId will be updated. In this case, if no trip is found with the given tmsTripId , then an error message will be returned.
|
integer | Yes if tmsTripId is not supplied.
|
tmsTripId
| The tmsTripId of your previously generated route. Note: Even if tripId , which is the alkTripId , is also supplied with this request, it will be ignored and only a trip corresponding to the given tmsTripId will be updated. If no trip is found with the given tmsTripId , then an error message will be returned.
|
string | Yes if tripId is not supplied.
|
stopId
| The unique stopId assigned to the stop by the Trip Management service at the time the trip was planned.
|
integer | Yes |
stopState
| The status that the stop is being updated to.
|
integer | Yes |
actualArrivalTime
| The date and time of arrival at the stop. The value must be in ISO-8601 format. |
date | Yes, if the stopState is Arrived(1). No, otherwise |
actualDepartureTime
| The date and time of departure at the stop. The value must be in ISO-8601 format. |
date | Yes, if the stopState is Completed(2). No, otherwise |
arrivalStatus
| The state at which the stop was arrived.
|
integer | Yes, if the stopState is Arrived(1). No, otherwise |
stopDuration
| Number of minutes spent at the stop. This is the difference between actual arrival and departure time |
integer | No |
Sample Requests
{
"tripId": 136,
"stopId": 0,
"stopState": 1,
"actualArrivalTime": "2017-09-06T19:05:16+00:00",
"arrivalStatus": 2
}
{
"tripId": 136,
"stopId": 0,
"stopState": 2,
"actualDepartureTime": "2017-09-06T19:37:16+00:00",
"stopDuration": 32
}
Sample Response
{
"success": true,
"message": null
}