react-native-mapbox-navigation
react-native-mapbox-navigation copied to clipboard
Custom directions API url
Hi guys,
we want to avoid of using Mapbox directions API, so we created our own directions API (with graphhopper and maphopper as proxy). Do you think that it would by possible to connect our api url to react-native-mapbox-navigation at the end? I tried to add our api url to baseUrl in MapboxNavigationView.kt for android, but RouteOptions builder creates different url format (we can create mapper for this url format in our maphopper). Do you think, that it would be possible to do same in swift? Also we want to customize vehicle type (foot, cycle...), at this point it is possible to navigate only with car as vehicle. With url prop for custom directions API url it would be possible to customize more options for directions routes (maybe?). Do you think, that it would be technically possible to create mapper for this url in react-native-mapbox-navigation?
Example url from maphopper:
http://localhost:3000/api/1/route?point=40.72,-74&vehicle=car&locale=en&key=[GH_ACCESSTOKEN]&points_encoded=false&point=40.733,-73.989&mapboxkey=[MB_ACCESS_TOKEN]
We really need this!
@rossmartin Any help would be heighly appreciated!