Skip to main content
added 7 characters in body
Source Link
winnewoerp
  • 1.6k
  • 12
  • 23

To query a specific attraction like the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is one of the way to gosolutions here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.

To query all the tourist attractions at once, you certainly won't find a very simple query in your case, as the tourist attractions have very different tags and types. Just use a filter by Geocode area for Toronto, then add the objects you need as single query parts. As long as they are of the same type, you can search for all names using name~"name 1|name 2".

[out:json][timeout:25];
{{geocodeArea:Toronto}}->.a;
(
  nwr[tourism=attraction][name="CN Tower"](area.a);
  nwr[tourism=aquarium][name="Ripley's Aquarium of Canada"](area.a);
  nwr[leisure=park][name="High Park"](area.a);
);
out geom;

To find all the tourist spots in Toronto, you could use

[out:json][timeout:25];
{{geocodeArea:Toronto}};
nwr[tourism~"attraction|aquarium|museum|zoo"](area);
out geom;

and add additional values from the list provided here in the OSM Wiki. However, this does not include features like parks for example.

To query a specific attraction like the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is the way to go here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.

To query all the tourist attractions at once, you certainly won't find a very simple query in your case, as the tourist attractions have very different tags and types. Just use a filter by Geocode area for Toronto, then add the objects you need as single query parts. As long as they are of the same type, you can search for all names using name~"name 1|name 2".

[out:json][timeout:25];
{{geocodeArea:Toronto}}->.a;
(
  nwr[tourism=attraction][name="CN Tower"](area.a);
  nwr[tourism=aquarium][name="Ripley's Aquarium of Canada"](area.a);
  nwr[leisure=park][name="High Park"](area.a);
);
out geom;

To find all the tourist spots in Toronto, you could use

[out:json][timeout:25];
{{geocodeArea:Toronto}};
nwr[tourism~"attraction|aquarium|museum|zoo"](area);
out geom;

and add additional values from the list provided here in the OSM Wiki. However, this does not include features like parks for example.

To query a specific attraction like the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is one of the solutions here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.

To query all the tourist attractions at once, you certainly won't find a very simple query in your case, as the tourist attractions have very different tags and types. Just use a filter by Geocode area for Toronto, then add the objects you need as single query parts. As long as they are of the same type, you can search for all names using name~"name 1|name 2".

[out:json][timeout:25];
{{geocodeArea:Toronto}}->.a;
(
  nwr[tourism=attraction][name="CN Tower"](area.a);
  nwr[tourism=aquarium][name="Ripley's Aquarium of Canada"](area.a);
  nwr[leisure=park][name="High Park"](area.a);
);
out geom;

To find all the tourist spots in Toronto, you could use

[out:json][timeout:25];
{{geocodeArea:Toronto}};
nwr[tourism~"attraction|aquarium|museum|zoo"](area);
out geom;

and add additional values from the list provided here in the OSM Wiki. However, this does not include features like parks for example.

added more examples
Source Link
winnewoerp
  • 1.6k
  • 12
  • 23

To query a specific attraction like the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is the way to go here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.

To query all the tourist attractions at once, you certainly won't find a very simple query in your case, as the tourist attractions have very different tags and types. Just use a filter by Geocode area for Toronto, then add the objects you need as single query parts. As long as they are of the same type, you can search for all names using name~"name 1|name 2".

[out:json][timeout:25];
{{geocodeArea:Toronto}}->.a;
(
  nwr[tourism=attraction][name="CN Tower"](area.a);
  nwr[tourism=aquarium][name="Ripley's Aquarium of Canada"](area.a);
  nwr[leisure=park][name="High Park"](area.a);
);
out geom;

To find all the tourist spots in Toronto, you could use

[out:json][timeout:25];
{{geocodeArea:Toronto}};
nwr[tourism~"attraction|aquarium|museum|zoo"](area);
out geom;

and add additional values from the list provided here in the OSM Wiki. However, this does not include features like parks for example.

To query the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is the way to go here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.

To query a specific attraction like the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is the way to go here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.

To query all the tourist attractions at once, you certainly won't find a very simple query in your case, as the tourist attractions have very different tags and types. Just use a filter by Geocode area for Toronto, then add the objects you need as single query parts. As long as they are of the same type, you can search for all names using name~"name 1|name 2".

[out:json][timeout:25];
{{geocodeArea:Toronto}}->.a;
(
  nwr[tourism=attraction][name="CN Tower"](area.a);
  nwr[tourism=aquarium][name="Ripley's Aquarium of Canada"](area.a);
  nwr[leisure=park][name="High Park"](area.a);
);
out geom;

To find all the tourist spots in Toronto, you could use

[out:json][timeout:25];
{{geocodeArea:Toronto}};
nwr[tourism~"attraction|aquarium|museum|zoo"](area);
out geom;

and add additional values from the list provided here in the OSM Wiki. However, this does not include features like parks for example.

Source Link
winnewoerp
  • 1.6k
  • 12
  • 23

To query the CN Tower in Toronto, just find a tag combination that is sufficient to only query the single object you want data for. man_made=tower is the way to go here.

[out:json][timeout:25];
way[man_made=tower][name="CN Tower"];
out geom;

With out geom; you get the geometry returned in the "Map" tab, as well as all data including coordinates in the "Data" tab.