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

How can I request the API marked IATA?

1

Moved from https://help.openstreetmap.org/questions/1989/load-data-from-sqlserver-and-display-markers-on-map:

Hello! How can I request the API marked IATA? I need a base: Airport name in Russian, English , IATA- Code . Can I help with your service obtain the necessary information ?

asked 22 Mar '16, 10:54

Evgeniya_VN's gravatar image

Evgeniya_VN
16111
accept rate: 0%

converted to question 22 Mar '16, 16:44

stephan75's gravatar image

stephan75
12.6k556210


One Answer:

3

Overpass API is one way to retrieve such data. Overpass Turbo is a nice front end for working out a query, here I've used the Overpass Turbo Wizard to find all the airports inside the current map view:

http://overpass-turbo.eu/s/fbO

And then here I've used the wizard again, this time further limiting the results to airports with an iata tag:

http://overpass-turbo.eu/s/fbP

Whether you get Russian and English names will of course depend on what is present in the data. Here I've edited the second query to output a delimited file with just the chosen tags:

http://overpass-turbo.eu/s/fbQ

Consult the documentation to see about changing the area that results are pulled from:

wiki.openstreetmap.org/wiki/Overpass_API/Overpass_QL

There can also be no bounding box, a global bounding box, or there is support for selecting an area from the OSM database and restricting the results to be inside that area. Queries that need a lot of resources may time out, restricting the are of the query helps avoid this.

answered 22 Mar '16, 19:31

maxerickson's gravatar image

maxerickson
12.7k1083176
accept rate: 32%

edited 22 Mar '16, 19:39

2

For the last query (CSV output), I'd recommend to replace out; by out center;, otherwise there will be no lat/lon values for ways and relations in the response.

(25 Mar '16, 11:34) mmd