We are currently using the Directions API with traffic annotations and rendering routes in our Unity application. We have observed a discrepancy between the traffic information displayed in the Mapbox traffic-enabled map style (e.g., navigation-night-v1) and the traffic data returned by the Directions API.
The traffic visualization shown on the map tiles contains significantly more congestion information (orange/red segments) than what is available in the API response. In the Directions API annotations, we are primarily receiving low and moderate congestion levels, a few heavy congestion segments, and a large number of segments marked as unknown.
As a result, when we plot traffic overlays based on the API response, the rendered traffic does not match the traffic visualization visible in the Mapbox tiles.
Could you clarify:
- Why is there a difference between the traffic data displayed in the Mapbox traffic tiles and the traffic information returned by the Directions API?
- Are the traffic tiles and Directions API using different traffic data sources or update frequencies?
- Why are many route segments returned as
unknown congestion in the API while traffic is visibly displayed on the map tiles?
- Is there a way to access the same traffic data used by the Mapbox traffic tiles so that we can render traffic overlays that match the visualized traffic on the map?
- Are there any configuration options, API parameters, or products that provide more detailed traffic congestion information than what is currently returned in the Directions API annotations?
Any guidance on how to achieve consistency between the traffic shown on the map and the traffic returned by the API would be greatly appreciated.
We are currently using the Directions API with traffic annotations and rendering routes in our Unity application. We have observed a discrepancy between the traffic information displayed in the Mapbox traffic-enabled map style (e.g.,
navigation-night-v1) and the traffic data returned by the Directions API.The traffic visualization shown on the map tiles contains significantly more congestion information (orange/red segments) than what is available in the API response. In the Directions API annotations, we are primarily receiving low and moderate congestion levels, a few heavy congestion segments, and a large number of segments marked as
unknown.As a result, when we plot traffic overlays based on the API response, the rendered traffic does not match the traffic visualization visible in the Mapbox tiles.
Could you clarify:
unknowncongestion in the API while traffic is visibly displayed on the map tiles?Any guidance on how to achieve consistency between the traffic shown on the map and the traffic returned by the API would be greatly appreciated.