Database index




The xref/wr website is a cross-reference web redirection service, primarily for bioinformatics databases. It is a simple alternative to LSID and PURL.

This website allows traditional access for humans using a browser. Simultaneously, it exposes a web resource interface that follows REST principles for a web service allowing programmatic access. It has been designed according to the Resource-Oriented Architecture.


Give the xref in the format 'xdb:xkey', and your browser will be redirected to the appropriate external database web page. The 'xdb' part is not sensitive to character case, while the 'xkey' may be, depending on the external database.

For example, type the xref PDB:1CRP into the search box to the left, and your browser will be redirected to the entry 1CRP in the Protein Data Bank. Similarly, the xref UNIPROT:P01112 will redirect to the P01112 entry in UniProt.

This website can be used programmatically if your programming language has a HTTP library that supports redirection. Use a URL of the form


where {xdb} is the designation of the external database, and {xkey} is the key for the entry in the external database. The response will be a HTTP redirect to the resolved URL. If your HTTP library software knows how, it will go to the new URL. Otherwise, your code will have to deal with this explicitly.

As an example, the programming language Python, provides the standard package urllib2, which is able to deal automatically and transparently with HTTP redirect responses:

import urllib2 urltemplate = '' url = urltemplate % 'PDB:1CRP' resource = urllib2.urlopen(url) print resource.geturl()

This script retrieves the resolved URL for the entry 1CRP in the Protein Data Bank (PDB), the database of macromolecular three-dimensional structures. The 'resource' instance is normally used to read the data, but in this case we wish to print out the resolved URL as returned by the HTTP redirect response from xref/wr.