API Overview

rsimon edited this page Aug 9, 2011 · 24 revisions

All Graph Explorer functionality is exposed via an HTTP API. It's a read-only API, so GET requests are the only ones which have any effect. The result format is JSON.

For testing purposes, feel free to play with the API of our development server, available under the http://api-pelagios.apigee.com/graph-explorer base URI.

The three resource types the Graph Explorer is dealing with are Datasets, Places and GeoAnnotations.

Datasets

Places

  • http://{base URI}/places/search?q={prefix} provides basic place search functionality. It returns a JSON-formatted list of places whose label starts with the specified prefix. E.g. a search for aeg will return Aegae, Agyptium Mare, Aegyptus, etc. (JSON Format) (view sample)
  • http://{base URI}/places/referencesTo?place={place-uri} returns JSON-formatted information about the datasets that reference the specified place. The Place needs to be specified by its (URL-escaped) Pleiades URI. (JSON Format) (view sample)
  • http://{base URI}/places/intersect?set1={dataset-name}&set2={dataset-name} computes the place-wise intersection between the two specified datasets. (JSON Format) (view sample)
  • http://{base URI}/places/shortestPaths?from={place-uri}&to={place-uri} computes the shortest paths between two places in the graph. Places need to be specified by their (URL-escaped) Pleiades URIs. (JSON Format) (view sample)

GeoAnnotations

  • http://{base URI}/annotations?place={place-uri}&dataset={dataset-name} returns the GeoAnnotations referencing the specified place, in the specified dataset. (JSON Format) (view sample)