Spatial RESTful services are provided by the Dirt-Simple PostGIS HTTP API and are exposed at http://lancasteruad.oxfordarchaeology.com/pgrest/.
See http://lancasteruad.oxfordarchaeology.com/pgrest/index.html for available functions.
All spatial tables are in EPSG:27700 (British National Grid). Their geometry type is given below:
The ws_geo_listlayers endpoint will provide you with this list in json format:
http://lancasteruad.oxfordarchaeology.com/pgrest/v1/ws_geo_listlayers.php
The ws_listfields endpoint will provide information on the fields/columns for a particular table in json format. Call it like so:
http://lancasteruad.oxfordarchaeology.com/pgrest/v1/ws_listfields.php?table=tablename
PGRest assumes that the coordinate system (srid) is EPSG:4326 and that the geometry column (geometryfield) is called the_geom. This is incorrect for the Lancaster UAD- so you will need to explicitly state the srid and geometry_field whenever you do a spatial query. The URLs below show the correct format to use:
http://lancasteruad.oxfordarchaeology.com/pgrest/v1/ws_geo_getextent.php?table=monsint_polys&srid=27700&geometryfield=wkb_geometry
http://lancasteruad.oxfordarchaeology.com/pgrest/v1/ws_geo_getcentroid.php?table=monspres_polys&srid=4326&geometryfield=wkb_geometry¶meters=monid=%27531%27