This page sets up OpenAI Codex CLI with:
- the galaxy-mcp server, so Codex can list histories, run tools, upload data and invoke workflows on your Galaxy server;
- galaxy-skills, curated skills for using Galaxy (MCP tool surface, collections, user-defined tools, workflow reports, reproducibility);
- galaxy-dev-skills, skills for building Galaxy (tool wrappers, Nextflow conversion, ToolShed revisions, track hubs, hub posts);
- foundry-skills, the Galaxy Workflow Foundry's workflow-construction skills.
- Codex CLI with plugin support (
codex --version). - uv on your
PATH; the MCP server runs asuvx galaxy-mcp. - A Galaxy API key. See Getting a Galaxy API key.
Codex starts MCP servers with a minimal environment and forwards only the
variables a server asks for. The galaxy-mcp plugin asks for GALAXY_URL and
GALAXY_API_KEY, so export them in the shell that launches Codex (for example
in ~/.zshrc or ~/.bashrc):
export GALAXY_URL="https://usegalaxy.org"
export GALAXY_API_KEY="paste-your-key-here"A .env file with the same two lines in your project directory also works.
codex plugin marketplace add galaxyproject/agentic-plugins
codex plugin add galaxy-mcp@galaxyproject
codex plugin add galaxy-skills@galaxyproject
codex plugin add galaxy-dev-skills@galaxyproject
codex plugin add foundry-skills@galaxyprojectStart a new Codex session afterwards. You can also browse and toggle the
plugins with codex /plugins.
Install only what you need. galaxy-skills is the set for using Galaxy
(MCP tool surface, collections, user-defined tools, workflow reports,
reproducibility); galaxy-dev-skills is for building it (tool wrappers,
Nextflow conversion, ToolShed revisions, track hubs, hub posts);
foundry-skills adds 59 workflow-construction skills. Every installed skill
costs context on every turn, so skip the sets you will not use.
-
In a terminal,
codex mcp listshows agalaxyserver withGALAXY_URLandGALAXY_API_KEY(masked) and statusenabled. Inside Codex,/mcplists it too. -
Ask:
Connect to Galaxy and tell me who I am.Codex calls
get_userand reports your username and the server version.
If something is off, type $galaxy-connect (or pick it from /skills) to
have Codex diagnose the connection.
Type $ or run /skills to pick a skill, for example $galaxy-integration,
$galaxy-mcp-reference, $collection-manipulation, $udt-authoring,
$reproduciblify, and, if you installed galaxy-dev-skills, $tool-dev and
$nf-to-galaxy. Codex also selects skills implicitly from their descriptions.
Codex scans plugin skill directories recursively, so the sub-skills nested
under nf-to-galaxy and galaxy-integration (for example
nf-process-to-galaxy-tool and jupyterlite-galaxy) are listed under their
own names as well.
codex plugin marketplace upgrade
codex plugin add galaxy-mcp@galaxyproject
codex plugin add galaxy-skills@galaxyproject
codex plugin add galaxy-dev-skills@galaxyproject
codex plugin add foundry-skills@galaxyprojectThe first command refreshes the marketplace snapshot; re-adding a plugin
installs the new version. galaxy-mcp reads the credentials from your
environment, so no re-entry is needed. To remove a plugin:
codex plugin remove galaxy-skills@galaxyprojectMCP server without the plugin. In ~/.codex/config.toml, forwarding the
variables from your shell instead of writing the key into the file:
[mcp_servers.galaxy]
command = "uvx"
args = ["galaxy-mcp"]
env_vars = ["GALAXY_URL", "GALAXY_API_KEY"]or on the command line, taking the key from the same exported variable; a key typed literally here is stored in your shell history:
codex mcp add galaxy \
--env GALAXY_URL=https://usegalaxy.org \
--env GALAXY_API_KEY="$GALAXY_API_KEY" \
-- uvx galaxy-mcpSkills straight from upstream. Codex reads ~/.agents/skills/, so a clone
works for galaxy-skills:
git clone https://github.com/galaxyproject/galaxy-skills ~/.agents/skills/galaxy-skillsFoundry publishes its own Codex marketplace:
codex plugin marketplace add galaxyproject/foundry
codex plugin add foundry-skills@galaxy-workflow-foundryInstall either that or foundry-skills@galaxyproject, not both.
- No
galaxyserver in/mcp: start a new session after installing; checkuv --version. - "Missing Galaxy URL and API key": the variables are not exported in the
shell that started Codex (GUI launchers often do not read
~/.zshrc). Use a project.envfile, or the~/.codex/config.tomlform above (orcodex mcp add ... --env ...). - Server fails to start: run
uvx galaxy-mcpin a terminal to see the error. - "Provided API key is not valid": the key belongs to a different server or was revoked.