Avatar of LJG
LJG
 asked on

How to get google map api "typical minutes"

Talking about Google Map API & XML

My Question:

How do I get "Typical Minutes" (a range of minutes) from two addresses for a future date and time using the below Google Map APIs?


What can be done using a browser instead of Google Map APIs 

If I go to a browser and got to google.com/maps/   and enter two addresses eg

123 Main St, Kansas City, MO 6415 

123 E Main St, Gardner, KS 66030

You get directions and Travel time in minutes (I'm interested in Travel Time in minutes)

But if I change "Leave Now" to "Depart at" change the time to tomorrow at 4:30 PM I get a range "Typically 35-55 Minutes"


I use two different APIs 


maps.googleapis.com/maps/api/distancematrix/xml

https://maps.googleapis.com/maps/api/directions/xml
with the above you can get minutes

<duration>                   = 33

<duration_in_traffic> = 34

But from the browser you you would get between 35-55 minutes


Any ideas are greatly appreciated

Larry G

GoogleXML

Avatar of undefined
Last Comment
Scott Fell

8/22/2022 - Mon
David Johnson, CD

The API's give you the current average travel time.  Travel time depends upon road condition, congestion, distance etc
ASKER CERTIFIED SOLUTION
Scott Fell

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23