users_current_history = trans.history
dataset_ids = [ trans.security.encode_id( d.id ) for d in users_current_history.datasets ]
var url = "/datasets/${ dna_dataset_id }/display?to_ext=bam"
var historyId = "${ trans.security.encode_id( trans.history.id ) }";
jQuery.ajax( galaxy_config.root + 'api/histories/' + historyId + '/contents' )
.done( function( response ){ /* will contain summary json for each dataset including encoded ids for each */ })
Hello Galaxy-dev,I thank you so much for all the help you have given me.I have a question about data set ids in galaxy. As a background, I am running my own galaxy instance on a server. A pipeline implemented in the lab produces the following files in the history:1) 2 BAM files2) A JSON fileMy goal is to use this JSON file to pass the path/URL of bam files into a custom JS we wrote for visualization purpose.This JSON file contains among many other details the paths/URLs to the above bam files. I am using JSON filetypes to send data to the JS visualization within Galaxy. To do this, I have my own JS which loads a BAM file from URL provided into an IGV.js track. IGV.js, which is responsible for making the tracks, expects a valid URL which is updated in the JSON file in this manner:1) Extract the API_key and history id from a loaded BAM file2) Edit the JSON file to reflect the BAM file's dataset id to be something like this:{ "CLL-HL_pilot.r1.fastq": { "DNA": "/datasets/36ddb788a0f14eb3/display?to_ext=bam", ...This works fine if I know the API Key for bam files. When a pipeline executes dataset ids are generated for each output. I want to access and include these ids in the JSON file and load the updated JSON file into the history with the bams. Is there a way to get the ids from the history in this manner?Thank you,
Asma
___________________________________________________________
Please keep all replies on the list by using "reply all"
in your mail client. To manage your subscriptions to this
and other Galaxy lists, please use the interface at:
https://lists.galaxyproject.org/
To search Galaxy mailing lists use the unified search at:
http://galaxyproject.org/search/mailinglists/