User's Guide for BioLit RESTful URLs

1. RESTful URIs Overview

Base URL: http://biolit.ucsd.edu/ws/rest

ActionURI and Remarks
GET/articles/<IDTYPE>/<ID>/metadata
Remarks and ValuesFind all articles with the specified ID of IDTYPE

IDTYPE can be pmcid,pmid,pdb,uniprot,ncbi
ID can be an ID from the specified types: PubMed Central ID, PubMed ID, PDB ID, UniProtKB ID, GenBank ID
Examples /articles/pmcid/1483839/metadata [Try]
/articles/pmid/16674828/metadata [Try]
/articles/pdbid/1HIV/metadata [Try]
GET/files/<IDTYPE>/<ID>/<FILETYPE>
Remarks and ValuesFind all <FILETYPE> files related to articles with the specified ID of IDTYPE

IDTYPE can be pmcid,pmid,pdb,uniprot,ncbi
ID can be an ID from the specified types: PubMed Central ID, PubMed ID, PDB ID, UniProtKB ID, GenBank ID
FILETYPE can be formulae,figures,biolitxml. formulae returns images of MathML formulae in the article. figures returns the full-size figure images from the article. biolitxml returns the BioLit-enhanced full-text XML-formatted article.
Examples /files/pmcid/1483839/formulae [Try]
/files/pmcid/1483839/figures [Try]
/files/pmcid/1483839/biolitxml [Try]
GET/terms/<IDTYPE>/<ID>
Remarks and ValuesFind all terms and database IDs found in the article with ID of IDTYPE
OR
all terms and database IDs associated with a specified database ID of IDTYPE. Some terms are not included by default because they may be spurious matches or have been identified as false matches; a list of all terms can be retrieved by appending /all to the end of the URL.

IDTYPE can be pmcid,pmid,pdb,uniprot,ncbi
ID can be an ID from the specified types: PubMed Central ID, PubMed ID, PDB ID, UniProtKB ID, GenBank ID
Examples /terms/pmcid/1483839 [Try]
/terms/ncbi/U14680 [Try]
/terms/uniprot/Q94222 [Try]

2. Request /Response Specification

ActionStatusStatus RemarksError CauseRemarks
GETSUCCESS
404ERRORBAD REQUESTURL badly formed
500ERRORServer Internal ErrrorServer Error such as a database is down and etc.

3. Sample Results

Empty result from successful query:

<success> <data> <list> </list> </data> </success>

Result from successful /articles/<IDTYPE>/<ID>/metadata queries:

<success> <data> <list> <searchterm>/1483839</searchterm> <article> <journal-meta> <journal-id journal-id-type="nlm-ta">BMC Bioinformatics</journal-id><journal-title>BMC Bioinformatics</journal-title> </journal-meta> <article-meta> <article-id pub-id-type="doi">10.1186/1471-2105-7-242</article-id> <article-id pub-id-type="pmid">16674828</article-id> <article-id pub-id-type="pmcid">1483839</article-id> <article-id pub-id-type="uid">41046</article-id> <article-title><title-group>Multipolar representation of protein structure</title-group></article-title> <contrib-group> <contrib contrib-type="author">Apostol Gramada, Philip E Bourne</contrib> </contrib-group> <pub-date><day>04</day><month>05</month><year>2006</year></pub-date> <volume>7</volume> <issue></issue> <fpage>242</fpage> </article-meta> </article> </list> </data> </success>

Result from successful /files/<IDTYPE>/<ID>/<FILETYPE> query:

<success> <data> <list> <searchterm>pmcid/1483839</searchterm> <article> <files> <file>http://biolit.ucsd.edu/ws/formulae/41046-M1.png</file> </files> </article> </list> </data> </success>

Result from successful /terms/<IDTYPE>/<ID> query:

<success> <data> <list> <term> <named-content content-type="biolit" id="term='1BOL';pmcid=1483839;position=77570;range=4;"> 1BOL </named-content> </term> </list> </data> </success>

4. Attribute Values

In /terms/<IDTYPE>/<ID>/all queries, the term status will be included:
<named-content content-type="biolit" id="term='1BOL';position=77570;range=4;status=1;">

Status CodeDefinition
1active term
2do not display by default/unreviewed
8false match
16under review for status change
This work is supported by grant DBI 0544575 from the National Science Foundation.