A tiny standalone client and CLI for Galaxy's GA4GH WES API
Project description
gxy-wes
A tiny, dependency-light client and command line tool for Galaxy's
GA4GH Workflow Execution Service (WES)
API. It depends only on requests, so it runs cleanly under uvx and is meant
for documentation examples and quick interactive exploration of a Galaxy WES
endpoint.
It walks the same flow the Galaxy developer docs describe: discover the service, stage an input dataset, submit a workflow, poll the run, and read outputs and per-task logs.
Scope
This project exists to demonstrate the WES API — it is not meant for production or user-facing applications.
- For user-facing applications, use Planemo.
- For production applications, build on the BioBlend abstractions.
Install
Run it without installing using uv:
$ uvx gxy-wes service-info --galaxy-url http://localhost:8080
Or install it:
$ pip install gxy-wes
Authentication
Every endpoint except service-info needs a Galaxy API key, sent as the
x-api-key header. Pass --api-key or set GXY_WES_API_KEY; set the server
with --galaxy-url or GXY_WES_URL. Get a key with:
$ curl -s -u you@example.com:password \
http://localhost:8080/api/authenticate/baseauth
Usage
Each WES endpoint is a subcommand:
$ gxy-wes service-info
$ gxy-wes stage --content $'hello\nworld\n' # -> {history_id, hda_id}
$ gxy-wes submit --workflow simple.gxwf.yml \
--params '{"input1": {"src": "hda", "id": "<hda_id>"}}' \
--engine-parameters '{"history_id": "<history_id>"}'
$ gxy-wes status <run_id>
$ gxy-wes get <run_id>
$ gxy-wes tasks <run_id>
$ gxy-wes task <run_id> 1
$ gxy-wes list
$ gxy-wes cancel <run_id>
$ gxy-wes job-output <job_id> --which stderr
The demo subcommand runs the whole example end to end against a live Galaxy
(stage an input, submit the bundled Format2 workflow, poll, print outputs and
tasks):
$ export GXY_WES_API_KEY=...
$ uvx gxy-wes demo --galaxy-url http://localhost:8080
As a library
from gxy_wes import WesClient
client = WesClient("http://localhost:8080", api_key="...")
info = client.service_info()
run = client.submit_run(
workflow_type="gx_workflow_format2",
workflow_path="simple.gxwf.yml",
params={"input1": {"src": "hda", "id": hda_id}},
engine_parameters={"history_id": history_id},
)
status = client.get_run_status(run["run_id"])
Notes
workflow_typeis one of Galaxy's formats:gx_workflow_format2(Format2 YAML) orgx_workflow_ga(native.gaJSON). It is detected from the workflow content when you pass--workflow.- WES has no data-staging endpoint; dataset inputs must already exist in Galaxy
and are referenced as
{"src": "hda", "id": ...}. Thestagesubcommand uses Galaxy's native API to create those. - Run success is determined by the WES run
state(COMPLETE), not by per-task exit codes — a failed job can be a normal part of a valid workflow.
License
MIT. See LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gxy_wes-0.1.0.tar.gz.
File metadata
- Download URL: gxy_wes-0.1.0.tar.gz
- Upload date:
- Size: 13.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0503179b3eeab46e07b134ff3669b440f2a2a3469c18420be22a9c0cb52f97ea
|
|
| MD5 |
9992cae07da6ce82ab8f04c8c8b39669
|
|
| BLAKE2b-256 |
9a8ba5806285d12c66695eecb938c338d5eaf0f41277e6a24650a4d98aca3ee4
|
Provenance
The following attestation bundles were made for gxy_wes-0.1.0.tar.gz:
Publisher:
deploy.yaml on jmchilton/gxy-wes
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gxy_wes-0.1.0.tar.gz -
Subject digest:
0503179b3eeab46e07b134ff3669b440f2a2a3469c18420be22a9c0cb52f97ea - Sigstore transparency entry: 1756335477
- Sigstore integration time:
-
Permalink:
jmchilton/gxy-wes@cd72db051da0dc6e7aeb299034b6a7f8b61888ae -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/jmchilton
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
deploy.yaml@cd72db051da0dc6e7aeb299034b6a7f8b61888ae -
Trigger Event:
push
-
Statement type:
File details
Details for the file gxy_wes-0.1.0-py3-none-any.whl.
File metadata
- Download URL: gxy_wes-0.1.0-py3-none-any.whl
- Upload date:
- Size: 11.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d9e8b19be0225a06c722ffdfbd2199ad11f1e6ea03f4ef02587d30dac070390d
|
|
| MD5 |
82c2a6ab4e7f73dcfc334bd3804311fa
|
|
| BLAKE2b-256 |
7063ff91ddf461de3d143d39bbd53beb1a342f196ee1a178e8fbdc20af278b2b
|
Provenance
The following attestation bundles were made for gxy_wes-0.1.0-py3-none-any.whl:
Publisher:
deploy.yaml on jmchilton/gxy-wes
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gxy_wes-0.1.0-py3-none-any.whl -
Subject digest:
d9e8b19be0225a06c722ffdfbd2199ad11f1e6ea03f4ef02587d30dac070390d - Sigstore transparency entry: 1756335541
- Sigstore integration time:
-
Permalink:
jmchilton/gxy-wes@cd72db051da0dc6e7aeb299034b6a7f8b61888ae -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/jmchilton
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
deploy.yaml@cd72db051da0dc6e7aeb299034b6a7f8b61888ae -
Trigger Event:
push
-
Statement type: