Overview
V2 consolidates trip replay into a single paginated endpoint. EachTripDto covers one completed movement segment:
V2 uses a single
GET /v2/api/replay/{id} endpoint, where {id} is the public vehicle ID (deviceId). Each point carries both a UTC and an API-key-time-zone timestamp, so there is no separate user-time variant.Step 1 — Request a date range
Fetch trips for vehicle1000 over one week. Pass from and to as ISO 8601 UTC strings:
Step 2 — Inspect the response
The response is a paginated envelope. Each element initems is a TripDto (abridged below: one trip and one point shown):
Step 3 — Decode the encoded polyline
The encoded field uses the Google Polyline Algorithm format, supported by all major mapping SDKs. It covers only the first 400 entries of points; draw from points when a trip has more.
Step 4 — Render on a map
Fetching all pages
For long date ranges, iterate through all pages:Python
Google Static Maps thumbnail
Theurl field is a complete Google Static Maps URL. Use it server-side to generate a trip thumbnail without decoding the polyline. Use it exactly as returned — do not add parameters:
Python
Gotchas
- Distance unit:
distanceis in kilometres, measured inside the requested window, and can benull. - Duration format:
durationis a .NET TimeSpan string ([d.]hh:mm:ss[.fffffff]), not ISO 8601PT...format. - Single endpoint: V2 has one replay endpoint. Both UTC and API-key-time-zone fields are returned on each point.
encodedis partial: it covers the first 400 entries ofpoints. Draw frompointsfor the full path.