How to find nearby cities from a given city

最后都变了- 提交于 2019-12-24 11:14:23

问题


HERE has a lot of endpoints but I am struggling to find one that will take city name or coordinates and return nearby cities within radius (limited to cities/towns only).


回答1:


You didn't specify the API Product you are using, so I searched a solution for the JS HERE API.


Get Cities

Ref: here

Table 2. Filter by cities around a point location within a radius (all parameters need to be set).

This parameters are mandatory:

{ details: Integer, nearbyMax: Integer, radius: Integer, center: Double }

see more...




回答2:


Check out the HERE Reverse Geocoder. Use parameter level=city&mode=retrieveAreas

See the full doc at https://developer.here.com/documentation/geocoder/topics/resource-reverse-geocode.html



来源:https://stackoverflow.com/questions/51709608/how-to-find-nearby-cities-from-a-given-city

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