-
Notifications
You must be signed in to change notification settings - Fork 4
Geosorting and Locationfilter usage
latitude
: GeoFilter Latitude Format ex. '46.624975'
longitude
: GeoFilter Longitude Format ex. '11.369909'
radius
: Radius to Search in Meters. Only Object withhin the given point and radius are returned and sorted by distance.
example call # https://tourism.opendatahub.com/v1/ODHActivityPoi?latitude=46.624975&longitude=11.369909&radius=2000
Note: An active geofilter overwrites a rawsort Parameter
polygon
: Pass a valid GPS Polygon to filter data. Available options WKT Format/Custom Format/Using the Open Data Hub GeoShapes api
examples #
- By using the shapes api
Check out https://tourism.api.opendatahub.com/v1/GeoShapes
Pass the desired polygon in format Country.Type.Id OR Country.Type.Name
'polygon=it.municipality.Bolzano/Bozen'
Example: https://tourism.api.opendatahub.com/v1/ODHActivityPoi?polygon=it.municipality.Bolzano/Bozen
- By using WKT Format
polygon=POLYGON((11.026805 46.688285,11.083110 46.690169,11.081394 46.660723,11.035045 46.655775,11.026805 46.688285))
polygon=LINESTRING(11.026805 46.688285,11.083110 46.690169,11.081394 46.660723,11.035045 46.655775,11.026805 46.688285)
polygon=MULTIPOLYGON(((11.026805 46.688285,11.083110 46.690169,11.081394 46.660723,11.035045 46.655775,11.026805 46.688285)),((11.483016 46.537154,11.582580 46.517785,11.557174 46.481863,11.483016 46.537154)))
It is possible to add a custom SRID by adding ;SRID=4326 at the end of the passed string
polygon=POLYGON((11.026805 46.688285,11.083110 46.690169,11.081394 46.660723,11.026805 46.688285));SRID=4326
Information: The Size of the passed polygon Parameter could hit the GET Parameter Max Length if the passed polygon is too large
- By bbc/bbi syntax (known from the timeseries api)
polygon=bbc(11.026805 46.688285,11.083110 46.690169,11.081394 46.660723,11.035045 46.655775,11.026805 46.688285,11.026805 46.688285)
It is possible to add a custom SRID by adding ;SRID=4326 at the end of the passed string
polygon=bbc(11.026805 46.688285,11.083110 46.690169,11.081394 46.660723,11.035045 46.655775,11.026805 46.688285,11.026805 46.688285);SRID=4326
Information: The Size of the passed polygon Parameter could hit the GET Parameter Max Length if the passed polygon is too large
Get all available locations
https://tourism.opendatahub.com/v1/Location?showall=true
Use typ
+ id
and pass as locfilter
example call
Get all ODHActivityPois in Tourismarea Ritten
https://tourism.opendatahub.com/v1/ODHActivityPoi?locfilter=tvs522822D451CA11D18F1400A02427D15E
Special Case on ODHActivityPoi it is also possible to filter on areas and skiareas
This wiki contains additional information about the Open Data Hub alongside the Open Data Hub - Official Documentation 🔗 .