Get the google plus URL based on place_id of Google Places API?

情到浓时终转凉″ 提交于 2019-12-10 17:18:33

问题


How can I get the plus.google URL page of the corresponding google place based on the place_id I obtain from the json the maps.googleapis.com/maps/api/place returns?


回答1:


Perhaps you can use the Place Details api using the place_id?

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




回答2:


This seems old post now but wanted to add some more details. 'places' details API provides google plus URL:

Quoting from https://developers.google.com/places/documentation/details:

url contains the URL of the official Google page for this place. This will be the establishment's Google+ page if the Google+ page exists,

You once you have place_id, use:

https://maps.googleapis.com/maps/api/place/details/json?key=your_key&placeid=interested_place_id

And look for 'url' key.

Its a different question if you want to extract details from that page. I do not know if google has API for this.



来源:https://stackoverflow.com/questions/25561481/get-the-google-plus-url-based-on-place-id-of-google-places-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!