Adding the OpenAI Docs MCP server to Codex gives a session read-only access to current OpenAI developer documentation, so prompts can pull official docs content instead of relying on stale local context.
OpenAI publishes the server at https://developers.openai.com/mcp as a public streamable HTTP endpoint. OpenAI's current Docs MCP quickstart uses codex mcp add openaiDeveloperDocs --url https://developers.openai.com/mcp, and the saved MCP configuration is shared between the Codex CLI and IDE extension.
This server is documentation-only, so it does not call the OpenAI API or require an API key in the URL. Current local verification shows Codex saves the entry under ~/.codex/config.toml as a streamable_http transport, and codex mcp list reports the public docs endpoint as enabled with Unsupported auth because no separate bearer-token or OAuth login step is required.
Related: How to add a URL-based MCP server to Codex
Related: How to list Codex MCP servers
Related: How to get Codex MCP server details
Steps to add OpenAI Docs MCP server to Codex:
- Add the official OpenAI documentation endpoint under the server name OpenAI uses in its current Codex quickstart.
$ codex mcp add openaiDeveloperDocs --url https://developers.openai.com/mcp Added global MCP server 'openaiDeveloperDocs'.
The server name can be different, but using openaiDeveloperDocs keeps the local name aligned with the current OpenAI examples and with many existing Codex workflows.
Do not append tokens, cookies, or query parameters to the URL. The published docs server is a public documentation endpoint, not a per-user API address.
- Retrieve the saved entry in JSON to confirm that Codex stored the expected remote transport.
$ codex mcp get openaiDeveloperDocs --json { "name": "openaiDeveloperDocs", "enabled": true, "disabled_reason": null, "transport": { "type": "streamable_http", "url": "https://developers.openai.com/mcp", "bearer_token_env_var": null, "http_headers": null, "env_http_headers": null }, "enabled_tools": null, "disabled_tools": null, "startup_timeout_sec": null, "tool_timeout_sec": null }The decisive fields are transport.type = streamable_http and transport.url matching https://developers.openai.com/mcp.
- List the configured MCP servers and confirm that the OpenAI docs entry is enabled.
$ codex mcp list Name Url Bearer Token Env Var Status Auth openaiDeveloperDocs https://developers.openai.com/mcp - enabled Unsupported
The success state for this page is the openaiDeveloperDocs row with the correct URL and an enabled status. Unsupported under Auth is expected for this public endpoint because there is no separate login flow.
If Codex still answers OpenAI questions from stale context, ask it to use the OpenAI developer documentation MCP server explicitly unless the current project AGENTS.md already tells it to consult that server.
Mohd Shakir Zakaria is a cloud architect with deep roots in software development and open-source advocacy. Certified in AWS, Red Hat, VMware, ITIL, and Linux, he specializes in designing and managing robust cloud and on-premises infrastructures.
