Provide an API for Allen Institute (AI) web applications with which to launch a web page using the JBrowse genome browser to display the web app's RNA-Seq alignment track data from preexisting BAM and/or BigWig files. Urls calling the Genome Browser Service look like this:
http://<domain>/genome-browser-service?ai=<JSON args>
Prepare a JSON key-value hash, and add that data as a url-encoded query string arg, 'ai' to http://<genome_browser_service_domain>/genome-browser-service. Example:
JSON hash:{"sample_ids":[321912275,395319183,472517767,475848358],"gene_id":499316275,"config_id":"tbi_0"}
Becomes url encoded arg:
ai=%7B%22sample_ids%22%3A%20%5B321912275%2C395319183%2C472517767%2C475848358%5D%2C%22gene_id%22%3A%20499316275%2C%22config_id%22%3A%22tbi_0%22%7D
{ sample_ids:[ int,int,int,etc. ], gene_id: int, genome: "string", chromosome: "string", start: int, stop: int, config_id: "string" }For TBI, you should use these arguments:
{ sample_ids:[ int,int,int,etc. ], gene_id: int, config_id: "string" }
sample_ids - array of one or more AI RefSeq sample ids
gene_id - AI gene id, the gene's symbol becomes a search term for genome browser
genome - name of Reference Genome, not needed if sample_ids present
chromosome - name of chromosome, in format appropriate to the Reference Genome (UCSC or NCBI)
start - alignment start position
stop - alignment stop position
config_id - name of track configuration used to format and display tracks. See 'Available Track
Configurations' below.
- If there is more than one 'sample_id', make sure they are all from the same Reference Genome.
- If 'gene_id' is present, then all other key-values are ignored, except for 'sample_ids', which is optional. If
'samples_ids' is empty, then only the reference genome is displayed
- If 'gene_id' is 0 or negative, then 'genome' is required, and other keys have these conditions:
Use the Name as the config_id in the input JSON hash