What is a place or place_id (for testing purposes) in Google Places API that has associated html_attributions?
Asked Answered
O

1

7

We are using the Google Places Place Details API (more specifically, the Google Maps Javascript API). As part of the terms of use, we must display the value of html_attributions from the response if it exists.

However, in trying to test our implementation, I am having difficulty of finding a place for which the PlacesService.getDetails() response contains a non-empty value of html_attributions.

Is there a reference page for sample place_ids or places for which the Place Details API will return a non-empty html_attributions?

Okapi answered 4/11, 2016 at 6:39 Comment(2)
A related question would be: What kind of places generally have associated html_attributions?Okapi
Adding bounty to this because I am having the exact same issueShahjahanpur
W
2

As mentioned in the following docs, if you reproduce any content from the google it must contain three types of attributions.

  • Maps attribution
  • Powered by google attribution
  • And attribution for the third parties

Since you are getting the data from the google maps, they already show the map and the logo for it.

But you require the third party attributions if any for it. The html-attributions contain the third party listings as mention in the example

"html_attributions" : [
  "Listings by \u003ca href=\"http://www.example.com/\"\u003eExample Company\u003c/a\u003e"
]

Since almost all the places data do not require attribution since the data is retrieved by google itself therefore they don't contain any attributions.

A simple example to it would be the html_attributions required by the photos, since they are hosted by third party mostly hence their attribution is shown with all the locations.

Other details as to how to get the attributions are mentioned in the docs.

Wilmoth answered 15/1, 2017 at 14:47 Comment(2)
Good idea using the photo attributions to test. If nobody else can provide a better way to get a attribution. I will mark your answer as the accepted answer.Shahjahanpur
I also believe that "almost all the places data do not require attribution". I'm hoping for some authoritative proof that either none of them require third party attribution, or for a counterexample. Maybe the lack of a counterexample might be proof enough, but this question has only been viewed a hundred-or-so times. Photos are a good way to see how an attribution might look.Okapi

© 2022 - 2024 — McMap. All rights reserved.