Closed kilojarek closed 4 years ago
I found this on SO from 2017 that suggests it's not possible (multistage travel time or distance), unless you know the waypoints through which you want to travel (which I don't): https://stackoverflow.com/questions/47224665/can-google-maps-api-calculate-route-along-multiple-locations-or-journey-legs. But if someone could confirm, I'd be grateful.
I have tried to obtain a travel time value for a journey between two addresses in the UK that requires multiple stages by public transport (e.g. two trains, or a bus and a train), but I always get no output
Do you have example googleway
code I can use to test this "no output" issue?
But if someone could confirm, I'd be grateful.
That is also my understanding too.
Hi,
I am not sure if this is a bug actually, but Google Documentation and googleway documentation are not clear (https://developers.google.com/maps/documentation/distance-matrix/intro#travel_modes). I have tried to obtain a travel time value for a journey between two addresses in the UK that requires multiple stages by public transport (e.g. two trains, or a bus and a train), but I always get no output. If I switch to a travel_mode where the distance can be covered in one stage (e.g. walking or driving), I receive the output correctly for the same pair of addresses. This pair of addresses works for public transport when I use the Google Maps in the browser. I am not interested in routes, I only need travel time and distance.
So am I right in thinking that Distance Matrix API, and by extension googleway, only allows single-stage journeys? And if I am right, what would be best way to get travel time for multi-stage journeys?