0

I am using the Overpass API in order to fetch all the amenities. All the amenities are listed on the OSM wiki: Amenities.

I cannot seem to get this to work. I first have tried "amenity"="pub;bar;restaurant". But this does not work and I need to type out all the types. I have also tried "amenity"="sustenance" and "amenity"="pub~restaurant~bar". But none of these return any values.

scai
  • 20,297
  • 4
  • 56
  • 72
Stephen
  • 913
  • 3
  • 24
  • 50

1 Answers1

1

See the OSM Wiki regarding Overpass QL, especially the section about Value matches regular expression. The syntax is a little bit different from the one you tried. Overpass API by Example is also often helpful and has multiple examples for using regular expressions with multiple values.

The correct query would be: highway~"^(pub|bar|restaurant)"

scai
  • 20,297
  • 4
  • 56
  • 72