谷歌地点API按城市搜索

6
我想搜索纽约所有的咖啡馆和餐厅。当然,我可以使用文本搜索,就像这里建议的那样 - Google Places API Search for Keyword and City 但是如果我像这样发出请求: https://maps.googleapis.com/maps/api/place/textsearch/json?query=cafe+New+York+food&sensor=false&key=MY_KEY 我得到的第一个元素是

"formatted_address" : "316 Victoria Avenue, Chatswood NSW, Australia",

真的没有办法通过城市筛选数据吗?这些数据存在于地址中,为什么只能通过关键词筛选而无法优雅地按城市筛选?
1个回答

6

1
不是很理想,因为在指定的半径范围内可能会有更多的城市。 - Velda

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接