Naming the provider in Codex: the reserved names openai, ollama and lmstudio

Coding with AICodex CLI·· 16 views· 2 min read

In config.toml, the MozOut provider lives in a [model_providers.<id>] table. You choose the id, but some names are kept by Codex for the providers it ships with.

The reserved names

According to the official Codex documentation, the ids openai, ollama and lmstudio belong to the providers that come with Codex and cannot be overridden. The advanced configuration page adds amazon-bedrock, amazon-bedrock-runtime and gcp. A block with one of these names does not count as your provider.

The id and the name

model = "moonshotai/kimi-k2.7-code"
model_provider = "aio"

[model_providers.aio]
name = "MozOut"
base_url = "https://api.mozout.com/v1"
env_key = "MOZOUT_API_KEY"
wire_api = "responses"

Where What it is
[model_providers.aio] The id. Pick a unique name: aio, api or another.
model_provider = "aio" It must match the id, letter by letter.
name = "MozOut" Only the name Codex shows. It can have spaces and capitals.

In TOML, an id without quotes can only have letters, numbers, _ and -. Prefer a short name with no spaces.

If model_provider is missing

Without the model_provider line, Codex uses the openai provider, which is the default, and the requests do not come to our API. The line goes at the top of the file, before the first table, and its value must be the id of a [model_providers.<id>] table that exists.

Not to be confused with the MCP server

The MCP server also has a name, in its own table: [mcp_servers.mozout-ai]. They are different things: model_providers says which models Codex uses to code, and mcp_servers adds tools, such as generating images. See the All in One AI MCP server.

Check with a sandbox_ key: with the right provider, the answer is "Resposta de teste (sandbox)."

Want to code with AI in Codex? Visit the Coding with AI page.

See Coding with AI

SEE ALSO

Codex CLI with All in One AI: creating config.toml, the key and the model

Codex in a project: why .codex/config.toml cannot change the provider

env_key in Codex: how it reads your key from an environment variable

The All in One AI MCP server: images, video and voice inside Claude Code, Codex and ChatGPT

Coding with AI in All in One AI

RECOMMENDED PRODUCT

Web hosting with cPanel

Domain and SSL included, daily backups and the panel you already know. from $6.60/mo (3-year plan, with coupon)

See plans
Was this answer helpful? Your answer helps us improve this article.