Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Get reviews from google map api

I have to get reviews from Google map API. details are on this page.

https://developers.google.com/places/documentation/details#PlaceDetailsResults

the details will fetch from this page:-

https://maps.googleapis.com/maps/api/place/details/json?reference=CmRYAAAAciqGsTRX1mXRvuXSH2ErwW-jCINE1aLiwP64MCWDN5vkXvXoQGPKldMfmdGyqWSpm7BEYCgDm-iv7Kc2PF7QA7brMAwBbAcqMr5i1f4PwTpaovIZjysCEZTry8Ez30wpEhCNCXpynextCld2EBsDkRKsGhSLayuRyFsex6JA6NPh9dyupoTH3g&sensor=true&key=AddYourOwnKeyHere

My problem is I can't find what is reference in request. and how I find this parameter value from my Google plus page.

like image 351
Himanshu Pandey Avatar asked May 07 '13 09:05

Himanshu Pandey


People also ask

How do I get more than 5 reviews on Google places API?

Save this answer. Show activity on this post. In order to have access to more than 5 reviews with the Google API you have to purchase Premium data Access from Google. That premium plan will grant you access to all sorts of additional data points you have to shell out a pretty penny.

Is Google Maps API no longer free?

You won't be charged until your usage exceeds $200 in a month. Note that the Maps Embed API, Maps SDK for Android, and Maps SDK for iOS currently have no usage limits and are at no charge (usage of the API or SDKs is not applied against your $200 monthly credit).


1 Answers

A more recent way to do this:

https://maps.googleapis.com/maps/api/place/details/json?placeid={place_id}&key={api_key}

  • place_id: https://developers.google.com/places/place-id
  • api_key: https://developers.google.com/places/web-service/get-api-key

Response:

{   "html_attributions": [],   "result": {     ...     "rating": 4.6,     "reviews": [       {         "author_name": "John Smith",         "author_url": "https://www.google.com/maps/contrib/106615704148318066456/reviews",         "language": "en",         "profile_photo_url": "https://lh4.googleusercontent.com/-2t1b0vo3t-Y/AAAAAAAAAAI/AAAAAAAAAHA/0TUB0z30s-U/s150-c0x00000000-cc-rp-mo/photo.jpg",         "rating": 5,         "relative_time_description": "in the last week",         "text": "Great time! 5 stars!",         "time": 1508340655       }     ]   } } 

Reviews are limited to the 5 latest.

like image 56
JM-AGMS Avatar answered Sep 20 '22 09:09

JM-AGMS