BIOSERVICES: access to biological web services programmatically

https://badge.fury.io/py/bioservices.svg https://github.com/cokelaer/bioservices/actions/workflows/ci.yml/badge.svg Documentation Status https://raw.githubusercontent.com/cokelaer/bioservices/master/doc/bioservices.png
Python_version_available:
 BioServices is tested for Python 3.6, 3.7, 3.8
Contributions:Please join https://github.com/cokelaer/bioservices and share your notebooks https://github.com/bioservices/notebooks/
Issues:Please use https://github.com/cokelaer/bioservices/issues
How to cite:Cokelaer et al. BioServices: a common Python package to access biological Web Services programmatically Bioinformatics (2013) 29 (24): 3241-3242
Documentation:RTD documentation.

Bioservices is a Python package that provides access to many Bioinformatices Web Services (e.g., UniProt) and a framework to easily implement Web Services wrappers (based on WSDL/SOAP or REST protocols).

The primary goal of BioServices is to use Python as a glue language to provide a programmatic access to several Bioinformatics Web Services. By doing so, elaboration of new applications that combine several of the wrapped Web Services is fostered.

One of the main philosophy of BioServices is to make use of the existing biological databases (not to re-invent new databases) and to alleviates the needs for expertise in Web Services for the developers/users.

BioServices provides access to 43 Web Services. For a quick start, look at some notebooks here github cokelaer/bioservices and here github bioservices.

Here is a small example using the UniProt Web Service to search for the zap70 specy in human organism:

>>> from bioservices import UniProt
>>> u = UniProt(verbose=False)
>>> data = u.search("zap70+and+taxonomy:9606", frmt="tab", limit=3,
...                 columns="entry name,length,id, genes")
>>> print(data)
Entry name   Length  Entry   Gene names
ZAP70_HUMAN  619     P43403  ZAP70 SRK
B4E0E2_HUMAN 185     B4E0E2
RHOH_HUMAN   191     Q15669  RHOH ARHH TTF

More examples and tutorials are available in the On-line documentation

Here is the list of services available and their testing status (non exhaustive). Not all services are currently tested (WIP, july 2021)

Service CI testing
arrayexpress https://github.com/cokelaer/bioservices/actions/workflows/arrayexpress.yml/badge.svg
bigg https://github.com/cokelaer/bioservices/actions/workflows/bigg.yml/badge.svg
biocarta https://github.com/cokelaer/bioservices/actions/workflows/biocarta.yml/badge.svg
biodbnet https://github.com/cokelaer/bioservices/actions/workflows/biodbnet.yml/badge.svg
biogrid https://github.com/cokelaer/bioservices/actions/workflows/biogrid.yml/badge.svg
biomart https://github.com/cokelaer/bioservices/actions/workflows/biomart.yml/badge.svg
biomodels https://github.com/cokelaer/bioservices/actions/workflows/biomodels.yml/badge.svg
chebi https://github.com/cokelaer/bioservices/actions/workflows/chebi.yml/badge.svg
chembl https://github.com/cokelaer/bioservices/actions/workflows/chembl.yml/badge.svg
chemspider https://github.com/cokelaer/bioservices/actions/workflows/chemspider.yml/badge.svg
clinvitae https://github.com/cokelaer/bioservices/actions/workflows/clinvitae.yml/badge.svg
cog https://github.com/cokelaer/bioservices/actions/workflows/cog.yml/badge.svg
dbfetch https://github.com/cokelaer/bioservices/actions/workflows/dbfetch.yml/badge.svg
ena https://github.com/cokelaer/bioservices/actions/workflows/ena.yml/badge.svg
ensembl https://github.com/cokelaer/bioservices/actions/workflows/ensembl.yml/badge.svg
eutils https://github.com/cokelaer/bioservices/actions/workflows/eutils.yml/badge.svg
eva https://github.com/cokelaer/bioservices/actions/workflows/eva.yml/badge.svg
hgnc https://github.com/cokelaer/bioservices/actions/workflows/hgnc.yml/badge.svg
intact_complex https://github.com/cokelaer/bioservices/actions/workflows/intact_complex.yml/badge.svg
kegg https://github.com/cokelaer/bioservices/actions/workflows/kegg.yml/badge.svg
muscle https://github.com/cokelaer/bioservices/actions/workflows/muscle.yml/badge.svg
mygeneinfo https://github.com/cokelaer/bioservices/actions/workflows/mygeneinfo.yml/badge.svg
ncbiblast https://github.com/cokelaer/bioservices/actions/workflows/ncbiblast.yml/badge.svg
omicsdi https://github.com/cokelaer/bioservices/actions/workflows/omicsdi.yml/badge.svg
omnipath https://github.com/cokelaer/bioservices/actions/workflows/omnipath.yml/badge.svg
panther https://github.com/cokelaer/bioservices/actions/workflows/panther.yml/badge.svg
pathwaycommons https://github.com/cokelaer/bioservices/actions/workflows/pathwaycommons.yml/badge.svg
pdb https://github.com/cokelaer/bioservices/actions/workflows/pdb.yml/badge.svg
pdbe https://github.com/cokelaer/bioservices/actions/workflows/pdbe.yml/badge.svg
pfam https://github.com/cokelaer/bioservices/actions/workflows/pfam.yml/badge.svg
picr https://github.com/cokelaer/bioservices/actions/workflows/picr.yml/badge.svg
pride https://github.com/cokelaer/bioservices/actions/workflows/pride.yml/badge.svg
psicquic https://github.com/cokelaer/bioservices/actions/workflows/psicquic.yml/badge.svg
pubchem https://github.com/cokelaer/bioservices/actions/workflows/pubchem.yml/badge.svg
quickgo https://github.com/cokelaer/bioservices/actions/workflows/quickgo.yml/badge.svg
reactome https://github.com/cokelaer/bioservices/actions/workflows/reactome.yml/badge.svg
rhea https://github.com/cokelaer/bioservices/actions/workflows/rhea.yml/badge.svg
rnaseq_ebi https://github.com/cokelaer/bioservices/actions/workflows/rnaseq_ebi.yml/badge.svg
seqret https://github.com/cokelaer/bioservices/actions/workflows/seqret.yml/badge.svg
unichem https://github.com/cokelaer/bioservices/actions/workflows/unichem.yml/badge.svg
uniprot https://github.com/cokelaer/bioservices/actions/workflows/uniprot.yml/badge.svg
wikipathway https://github.com/cokelaer/bioservices/actions/workflows/wikipathway.yml/badge.svg

Note

Contributions to implement new wrappers are more than welcome. See BioServices github page to join the development, and the Developer guide on how to implement new wrappers.

Warning

Some of the services may be down. BioServices developers are not responsible for the maintenance or failure of underlying services. Generally speaking (and by experience) the services are up most of the time but failure may occur because the site is under maintenance or too many requests have been sent. Another common reason is the fact that the API of the web services has changed: If so, BioServices need to be updated. You may contribute or report such API changes on our Issue page

Installation

BioServices is available on PyPi, the Python package repository. The following command should install BioServices and its dependencies automatically provided you have pip on your system:

pip install bioservices

If not, please see the external pip installation page or pip installation entry. You may also find information in the troubleshootings page section about known issues.

Regarding the dependencies, BioServices depends on the following packages: BeautifulSoup4 (for parsing XML), SOAPpy and suds (to access to SOAP/WSDL services; suds is used by ChEBI only for which SOAPpy fails to correctly fetch the service) and easydev. All those packages should be installed automatically when using pip installer. Since version 1.6.0, we also make use of pandas and matplotlib to offer some extra functionalities.

User guide