Unlock

Questions?

Project Blog

|

Contact Us envelope image
Home > Unlock Places > Example Queries

Example Queries

The most basic query is the name search, which will return a list of matching features:

            http://unlock.edina.ac.uk/ws/nameSearch?name=Edinburgh
            

Example Queries

To try out any of the example queries below simply click on the icon next to the query description. Links open in a new window.

nameSearch Web Service

Search for the name 'Edinburgh' from the OS gazatteer and format the results as XML.

http://unlock.edina.ac.uk/ws/nameSearch?name=Edinburgh&gazetteer=os&format=xml

Search for the names 'Edinburgh' & 'Glasgow' from the OS and GeoNames gazetteers and format the results as GeoJSON.

http://unlock.edina.ac.uk/ws/nameSearch?name=Edinburgh,Glasgow&gazetteer=os,%20geonames&format=json

nameAndFeatureSearch Web Service

Search for the names 'Edinburgh' & 'Glasgow' with feature type 'cities' from the OS gazetteer and format the results as KML.

http://unlock.edina.ac.uk/ws/nameAndFeatureSearch?name=Edinburgh,Glasgow&featureType=cities&gazetteer=os&format=kml

Search for the name 'Edinburgh' with feature type 'farm' from the GeoNames gazetteer and format the results as GeoRSS.

http://unlock.edina.ac.uk/ws/nameAndFeatureSearch?name=Edinburgh&featureType=farm&gazetteer=geonames&format=georss

postCodeSearch Web Service

Search for the post code 'EH9 1PR' from the Unlock gazetteer and format the results as Comma-separated Text.

http://unlock.edina.ac.uk/ws/postCodeSearch?postCode=EH91PR&gazetteer=unlock&format=txt

spatialNameSearch Web Service

Search for the name 'Craiglockhart' within Edinburgh's bounding box, from the OS gazetteer and format the results as XML.

http://unlock.edina.ac.uk/ws/spatialNameSearch?name=Craiglockhart&minx=-3.35081720352173&miny=55.87272644042972&maxx=-2.01274991035461&maxy=55.9947509765625&format=xml&operator=within&gazetteer=os

Search for the names 'Portobello' & 'Musselburgh' within Edinburgh's bounding box, from the OS & GeoNames gazetteers and format the results as GeoJSON.

http://unlock.edina.ac.uk/ws/spatialNameSearch?name=Portobello,Musselburgh&minx=-3.35081720352173&miny=55.87272644042972&maxx=-2.01274991035461&maxy=55.9947509765625&format=json&operator=within&gazetteer=os,geonames

Search for the name 'Craiglockhart' intersecting Edinburgh's bounding box, from the OS gazetteer and format the results as KML.

http://unlock.edina.ac.uk/ws/spatialNameSearch?name=Craiglockhart&minx=-3.35081720352173&miny=55.87272644042972&maxx=-3.01274991035461&maxy=55.9947509765625&operator=intersect&format=kml&gazetteer=os

spatialFeatureSearch Web Service

Search for features with feature type 'hotel' within Edinburgh's bounding box, from the GeoNames gazetteer and format the results as GeoRSS.

http://unlock.edina.ac.uk/ws/spatialFeatureSearch?featureType=hotel&minx=-3.35081720352173&miny=55.87272644042972&maxx=-3.01274991035461&maxy=55.9947509765625&operator=within&format=georss&gazetteer=geonames

Search for feature types 'hotel' & 'rivers' within Edinburgh's bounding box, from the OS & GeoNames gazetteers and format the results as Comma-separated Text.

http://unlock.edina.ac.uk/ws/spatialFeatureSearch?featureType=hotel,rivers&minx=-3.35081720352173&miny=55.87272644042972&maxx=-3.01274991035461&maxy=55.9947509765625&operator=within&format=txt&gazetteer=os,geonames

Search for feature types 'rivers' intersecting Edinburgh's bounding box, from the OS gazetteer and format the results as XML.

http://unlock.edina.ac.uk/ws/spatialFeatureSearch?featureType=rivers&minx=-3.35081720352173&miny=55.87272644042972&maxx=-3.01274991035461&maxy=55.9947509765625&operator=intersect&format=xml&gazetteer=os

footprintLookup Web Service

Retrieve the footprint for Edinburgh (identifer 9656) from the OS gazetteer and format the results as GeoRSS.

http://unlock.edina.ac.uk/ws/footprintLookup?identifier=9656&gazetteer=os&format=georss

Retrieve the footprints (points) for Edinburgh & Glasgow, from the GeoNames gazetteer and format the results as GeoJSON.

http://unlock.edina.ac.uk/ws/footprintLookup?identifier=5823266,5823268&gazetteer=geonames&format=json

supportedFeatureTypes Web Service

Note: The supportedFeatureTypes web service only accepts xml, json and txt format parameters.

Retrieve the supported feature types thesaurus from the OS & GeoNames gazetteers and format the results as XML.

http://unlock.edina.ac.uk/ws/supportedFeatureTypes?&gazetteer=os,geonames&format=xml

featureLookup Web Service

Search for feature number 9656 (Edinburgh) from Ordnance Survey gazetteer and format the results as Comma-separated Text.

http://unlock.edina.ac.uk/ws/featureLookup?id=9656&gazetteer=os&format=txt

closestMatchSearch Web Service

Search for the closest match for 'Edinburgh from the GeoNames gazetteer and format the results as GeoJSON.

http://unlock.edina.ac.uk/ws/closestMatchSearch?name=Edinburgh&gazetteer=geonames&format=json

uniqueNameSearch Web Service

Search for the name 'Edinburgh', returning a single result per feature, from the OS gazetteer and format the results as XML.

http://unlock.edina.ac.uk/ws/uniqueNameSearch?name=Edinburgh&gazetteer=os&format=xml