I'm trying to implement on my project the Directions API of Google Maps to calculate the travel time between two adresses by passing the route through two waypoints. I configured well the API Call with required parameters key, destination and origin, and finally the optional waypoints parameter. It works very well to pass just one address on waypoints parameter but impossible to pass two different adresses for the waypoints parameters.
Add two arguments for a parameter of an API Call
Database & APIs
I tried several things to fix the problem like define the waypoints parameter as a list but I don't know how to enter two different addresses for a same parameter as a list. When I use the Response&Test section, to write for example my two addresses like this : [address1 , address2], it just take the second address. When I define two parameters (waypoint1 and waypoint2) it doesn't recognise the waypoints parameter. Thanks a lot for your help. Lubin
Yes
1