Skip to main content
Codex names the environment variable that holds your key, so the config file never contains a credential.
1

Create a key

On Settings → API & MCP, create a key and copy it — it is shown once.
2

Put the key in your shell profile

Then open a new terminal so the variable is set.
3

Add the server

Add this to ~/.codex/config.toml:
4

Check it

Start Codex and ask it which Goosy tools are available.
bearer_token_env_var names the variable, never the key — Codex reads the value from your environment.