Valhalla turn by turn route API

553 views Asked by At

I am trying to get polyline for a route. I use valhalla turn-by-turn route API and pass multiple coordinates, but as a response I get encoded polyline for each leg, not for the whole route. Is there an option to get polyline for the route or to merge polylines of legs somehow? Thank you in advance.

1

There are 1 answers

1
Nane Petrosyan On

I found out that there are types for locations in valhalla API, such as break and through. When passing coordinates as a query string for the request, one must speicfy type trough if this is a transit location. By default all locations are of type break, which means valhalla creates a polyline for each leg.