User's Guide for BioLit RESTful URLs
1. RESTful URIs Overview
Base URL: http://biolit.ucsd.edu/ws/rest| Action | URI and Remarks | |
|---|---|---|
| GET | /articles/<IDTYPE>/<ID>/metadata | |
| Remarks and Values | Find all articles with the specified ID of IDTYPE IDTYPE can be pmcid,pmid,pdb,uniprot,ncbiID 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 Values | Find all <FILETYPE> files related to articles with the specified ID of IDTYPE IDTYPE can be pmcid,pmid,pdb,uniprot,ncbiID 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 Values | Find 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,ncbiID 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
| Action | Status | Status Remarks | Error Cause | Remarks |
|---|---|---|---|---|
| GET | SUCCESS | |||
| 404 | ERROR | BAD REQUEST | URL badly formed | |
| 500 | ERROR | Server Internal Errror | Server 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 Code | Definition |
|---|---|
| 1 | active term |
| 2 | do not display by default/unreviewed |
| 8 | false match |
| 16 | under review for status change |
This work is supported by grant DBI 0544575 from the National Science Foundation.