All the resources on PubAnnotation can be accessed through its REST API, which is now the most standard way of accessing resources on the Web.

Note that most of modern programming languages support the REST access and also there are many standalone REST clients.

For example, cURL is a versatile command-line tool you can use as a REST client in major OS environments, e.g., UNIX, iOS, Windows.

To give it a simple try, you can give one of the RESTful URLs as an argument of the cURL command as follows:

Then, it will “get” you the resource represented by the URL: the document, PubMed:25314077, in this case.

PubAnnotation maintains three types of resources

  • a document is a piece of text which is a sequence of characters.
  • annotations are statements attached to documents.
    • See Format for more details of annotation.
  • a project is a collection of documents and annotations attached to them.

Accessing documents

Following examples show various ways of accessing documents in PubAnnotation. We hope you may figure out the composing rules of URIs while browsing the examples.

Document list

A specific document

A specific span

Various formats

Various encoding

Accessing annotations