[GIS] How to query Overpass API with Postman

openstreetmapoverpass-apioverpass-turborest

I'm learning Open Street Map in order to try to retrieve a list of all cinemas in the world, in a country or in a city

I would like to know if I can do that with a REST query in Postman.

On overpass-turbo.eu I can see there is a way to do that. I see the informations I want to retrieve but I cannot tell how to create the query for Postman

enter image description here

On harrywood.co.uk it seems I can create the query but I must be doing something wrong. Dammit! I feel I'm so close!

enter image description here

I can see there are other questions like mine, but they are not about Postman, so I don't really see how can I use those information.

But I know what I want to do is possible because I can see the outcome at this URL:

enter image description here

I now know that there are 23.743 cinemas in the worls and if it's possible I would like to retrieve those information.

Best Answer

  • If you want to learn fishing: Go to https://overpass-turbo.eu/ Then enter the overpass query (QL/XML doesn't matter) that you like to check. Before running the query, open your browser network tab from its developers tools and then press run. You'll see how the data is posted.

  • If you just want the fish: Open post man, create a POST request to https://overpass-api.de/api/interpreter, and then if you want to use QL select x-www-form-urlencoded as the body type, add a key called data and set its value to be your QL query. If you want XML, select raw and set it to XML

Related Question