Skip to content
Snippets Groups Projects
Commit 6d785968 authored by Hervé  MENAGER's avatar Hervé MENAGER
Browse files

galaxy services client, WIP

Former-commit-id: e84369db97e3de18097d56201b39ce2c4ee8ea5e
parent bbe8021d
No related branches found
No related tags found
No related merge requests found
from bioblend.galaxy import GalaxyInstance
from bioblend.galaxy.tools.inputs import inputs
workflow_id = 'dad6103ff71ca4fe'
galaxy_url = 'https://galaxy-dev.web.pasteur.fr'
api_key = '21c2ce387688b1a785040762f7c9c331'
def run_workflow_and_get_results(input_file):
gi = GalaxyInstance(galaxy_url, key=api_key)
gi.verify = False
history_id = gi.histories.create_history("ippidb_history")['id']
dataset_id = gi.tools.upload_file(input_file, history_id)['outputs'][0]['id']
inputs = {'0':{'id':dataset_id, 'src': 'hda' }}
workflow_run = gi.workflows.invoke_workflow(workflow_id, inputs=inputs, history_id=history_id)
print(workflow_run)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment