OpenAI Codex
Connect the documentation MCP server to the OpenAI Codex CLI
OpenAI Codex
The Codex CLI reads MCP servers from its TOML config —
~/.codex/config.toml (global) or a project-scoped .codex/config.toml. Each server is a
[mcp_servers.<name>] table.
Local (stdio)
Add the table by hand:
toml
[mcp_servers.oi-docs]
command = "php"
args = ["/absolute/path/to/OiDevDocs/artisan", "mcp:start", "documentation"]Or let the CLI write it for you (everything after -- is the launch command):
bash
codex mcp add oi-docs -- php /absolute/path/to/OiDevDocs/artisan mcp:start documentationRemote (HTTP)
For a deployed server, use a url (streamable HTTP). Provide bearer_token_env_var only if
your deployment is token-protected:
toml
[mcp_servers.oi-docs]
url = "https://dev.olacombe.com/mcp/documentation"Verify
Run codex mcp list to confirm oi-docs is registered, then start a session and ask Codex to
search the OI Laravel documentation. See the overview for the reference values used above.