Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot get duration_in_traffic #150

Closed
dhageuk opened this issue Jul 28, 2018 · 1 comment
Closed

cannot get duration_in_traffic #150

dhageuk opened this issue Jul 28, 2018 · 1 comment

Comments

@dhageuk
Copy link

dhageuk commented Jul 28, 2018

	r := &maps.DistanceMatrixRequest{
		Origins:       strings.Split(origins, "|"),
		Destinations:  strings.Split(destinations, "|"),
		Language:      "en",
		DepartureTime: "now",
		Mode:          maps.TravelModeDriving,
		Units:         maps.UnitsMetric,
	}

	resp, err := client.DistanceMatrix(context.Background(), r)
	if err != nil {
		return c.JSON(http.StatusBadRequest, err)
	}

	return c.JSON(http.StatusOK, resp)
@domesticmouse
Copy link
Contributor

I'm looking at the documentation for Distance Matrix responses, and I'm not seeing a duration in traffic field per se. Can you be more explicit about what you are expecting? An example request to our API servers would be quite helpful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants