I’m trying to parse the response of a routing request into a MapBox route. The following code produces as successful response and allows me to make use of the round trip feature of the routing API:
List<String> point = new ArrayList<>(); String coord = locations.getLatitude() + "," + locations.getLongitude(); point.add(coord); RoutingApi api = new RoutingApi(); RouteResponse res = api.routeGet( point, false, "[KEY]", "en", true, "foot", false, true, null, true, null, false, "round_trip", null, null, null, null, (int) 3, (long) 1, null, null, null, null);
However I cannot figure out how to turn this response into a route using the MapBox functions? Can anyone please point me in the right direction?