DEVSAIO

Set up OpenAI Codex CLI with a custom provider

Configure Codex CLI's config.toml to use DEVSAIO, choose a model, and keep your key in an environment variable.

DEVSAIO team · 1 min read
Share on X

Codex CLI is OpenAI's open-source coding agent for the terminal. It supports custom model providers through its config file, so you can run it against DEVSAIO.

1. Set your key as an environment variable

bash
export DEVSAIO_API_KEY=YOUR_KEY

On Windows PowerShell: $env:DEVSAIO_API_KEY = "YOUR_KEY".

2. Edit ~/.codex/config.toml

On Windows the file is at %USERPROFILE%\.codex\config.toml.

toml
model = "gpt-5.6-luna"
model_provider = "devsaio"

[model_providers.devsaio]
name = "DEVSAIO"
base_url = "https://devsaio.lol/v1"
env_key = "DEVSAIO_API_KEY"
wire_api = "responses"
  • env_key tells Codex which environment variable holds the key, so the key never sits in the file.
  • wire_api = "responses" uses the Responses API format, which DEVSAIO supports.

3. Run it

bash
codex

Ask it something small first (“list the main folders in this repo and what they do”), then check Usage Logs to confirm requests are arriving.

Using other models

Change model to any model from the model list. If a model misbehaves with the Responses format, try wire_api = "chat" instead.

Tips

  • Set a monthly limit on the key Codex uses.
  • Keep tasks focused; agents spend most tokens reading files.
  • The integrations page generates this config with your key name filled in.
Try it with one API key

Claude, GPT, Gemini, DeepSeek, image and video models through one OpenAI- and Anthropic-compatible endpoint. Prepaid, pay only for what you use.

Keep reading