This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

Does the API support specific areas delimitation?

0

This is related to my last question:

https://help.openstreetmap.org/questions/19938/how-to-detect-when-a-nominatim-request-is-not-precise

Since there is no way to see if Nominatim is being precise in the request, I thought about delimiting specific areas using OSM API. Then I save the delimited areas into a database and check to see if the point is inside those areas. If it is, then use Nominatim. Else, he redirects to another reverse geocoder.

Also, the user can have the possibility to map that area, so it uses Nominatim next time. So, is the API capable of doing what I want? Thanks.

asked 15 Feb '13, 21:20

gabriel_casado's gravatar image

gabriel_casado
41559
accept rate: 0%


One Answer:

3

The main api of OpenStreetMap is meant for editors. While it could do what you want, you shouldn't use it for that.

Luckily there is an alternative that you can use: The Overpass API. Look at the following two links for a solution for rectangular areas:

And the next one for areas with other shapes:

answered 15 Feb '13, 23:18

cartinus's gravatar image

cartinus
7.0k1066105
accept rate: 27%

Hey cartinus, thanks again for the quick response. I'll surely look into the Overpass API.

(16 Feb '13, 00:58) gabriel_casado

Source code available on GitHub .