Here's how to connect Codex to Fine Structure so that Codex can read, edit, and validate apps through a limited MCP token.
Codex is a great fit when you want an agent that understands code, knows how to work inside a project, and can use external tools in a controlled way. Once MCP is connected, Codex can use Fine Structure's tools instead of guessing how the app is built.
A shared connection: In Codex, the CLI and the IDE extension use the same MCP configuration through config.toml.
One configuration: You add a server named fine_structure, point it at https://finestructure.ai/api/mcp, and add Authorization.
Permission control: Permissions are still set inside Fine Structure on the /mcp page, not inside Codex.
Open the MCP page in Fine Structure, choose permissions, then copy the token into config.toml or into an environment variable.
[mcp_servers.fine_structure]
url = "https://finestructure.ai/api/mcp"
http_headers = { "Authorization" = "Bearer fse2_mcp_<token>" }[mcp_servers.fine_structure] url = "https://finestructure.ai/api/mcp" bearer_token_env_var = "FINE_STRUCTURE_MCP_TOKEN"
Important: If you're using an environment variable, the value should be the token itself only, without the word Bearer. Codex adds the Authorization header based on the bearer_token_env_var setting.