Exclude countries

The exclude[countries] parameter enables the user to calculate routes that avoid specific countries. Resulting route will never go through excluded country. If the only way is through such country, for example when origin is in it, then no route is returned. This is different from the avoid options and it is the reason that the parameter is in exclude, not avoid.

The following example route from Milan to Frankfurt is avoiding Switzerland.

curl -X GET \

The purple route represents a route without the exclude[countries] parameter. It is going through Switzerland. The blue route is the route from request above. Route excluding Switzerland

For a request with a failed detour calculation, see Fail a detour.

results matching ""

    No results matching ""