sh-miR / designer

sh-miR Designer is a software aimed for fast and efficient design of effective RNA interference (RNAi) reagents - sh-miRs, also known as artificial miRNAs.
6 stars 4 forks source link

sh-miR API

GNU License Documentation Status

Requirements

That's all you need, how cool is that? :)

If you use SELinux, please allow to create volumes in directory where sh-miR designer is cloned. Assuming you're in this directory, please execute:

    $ sudo chcon -Rvt svirt_sandbox_file_t .

Quick Start

To start server:

    $ docker-compose up

You may need to run this command by root.

After this commands server builds all its dependencies and start sh-miR RESTful API.

Usage

There are three services:

Each of them have three URLs:

Where:

Services

Where DATA is a sequence which we would like to fold.

Examples:

    $ curl -i http://127.0.0.1:8080/mfold/UUUGUAUUCGCCCUAGCGC
    $ curl -i -X GET http://127.0.0.1:8080/mfold/status/f3591b31-49d9-47da-ae78-898792db26a5
    $ curl -i -X GET http://127.0.0.1:8080/mfold/result/f3591b31-49d9-47da-ae78-898792db26a5


Where DATA is a one siRNA strand (active) or two siRNA strands separated by space (in url "%20"). First strand is active, both are in 5-3 orientation. Pdf is a task ID of mfold. To get this file use mfold service.

Examples:

    $ curl -i http://127.0.0.1:8080/from_sirna/UUUGUAUUCGCCCUAGCGC%20CGCUAUGGCGAAUACAAACA
    $ curl -i -X GET http://127.0.0.1:8080/from_sirna/status/f3591b31-49d9-47da-ae78-898792db26a5
    $ curl -i -X GET http://127.0.0.1:8080/from_sirna/result/f3591b31-49d9-47da-ae78-898792db26a5

Then we download folded sh-miR:
$ curl -i -X GET http://127.0.0.1:8080/mfold/result/4bbee83a-0337-4efa-a018-13517390ebd1


Where DATA is transcript name from NCBI Pdf is task ID of mfold. To get this file use mfold service.

Examples:

    $ curl -i http://127.0.0.1:8080/from_transcript/NM_001164782.1
    $ curl -i -X GET http://127.0.0.1:8080/from_transcript/status/f3591b31-49d9-47da-ae78-898792db26a5
    $ curl -i -X GET http://127.0.0.1:8080/from_transcript/result/f3591b31-49d9-47da-ae78-898792db26a5

Then we download folded sh-miR:
$ curl -i -X GET http://127.0.0.1:8080/mfold/result/4bbee83a-0337-4efa-a018-13517390ebd1

Development

Debuging

Put somewhere in the code: import rpdb; rpdb.set_trace() Connecting to rpdb: $ ./scripts/rpdb_docker

Downloading own blast database

$ ./scripts/blast_docker

Clearing caches

$ ./scripts/flush

Watching celery tasks (flower):

Go to: $DOCKER_IP:5555/