Skip to content

Use Kimi K3 With Codex CLI on Windows or WSL

Configure Codex CLI to use Kimi K3 through Requesty's Responses endpoint, with the current provider-prefixed model ID and Windows or WSL commands.

MGMCSA Guru Team August 16, 2026 2 min read
Codex CLI configured to use Kimi K3

Kimi K3’s direct Moonshot API uses Chat Completions, while current Codex custom providers support the Responses wire API. Requesty translates between the two formats, so Codex can use Kimi K3 without an obsolete wire_api = "chat" setting.

Kimi K3 is Moonshot’s current flagship model, with native vision, up to a 1-million-token context window, and configurable reasoning effort. Feature support inside Codex depends on what the Chat Completions compatibility layer carries through.

Install Codex and create a key

Follow the current Codex Windows and WSL setup, then create a Moonshot API key.

Open ~/.codex/config.toml and merge in the following provider:

model = "moonshot/kimi-k3"
model_provider = "requesty"
model_supports_reasoning_summaries = false

[model_providers.requesty]
name = "Requesty"
base_url = "https://router.requesty.ai/v1"
env_key = "REQUESTY_API_KEY"
wire_api = "responses"

Export the key and run Codex

In WSL:

export REQUESTY_API_KEY="YOUR_REQUESTY_API_KEY"
codex

In PowerShell:

$env:REQUESTY_API_KEY = "YOUR_REQUESTY_API_KEY"
codex

The environment variable exists only in the current shell. Do not place the raw key in config.toml or commit it to a repository.

Verify the connection

Start Codex inside a small repository and ask it to explain one file. Follow with a limited edit and inspect the diff. This checks basic text generation and tool use without risking a wide change.

Kimi K3 supports images, but a text request working does not prove that the compatibility path carries image input correctly. Test image handling separately before relying on it.

Troubleshooting

A 401 error usually means REQUESTY_API_KEY is not present in the terminal that launched Codex. A model error often means the provider prefix is missing. Use moonshot/kimi-k3.

A Requesty 400 error can occur when Codex sends a reasoning summary field for a model that does not accept it. Keep model_supports_reasoning_summaries = false as a top-level setting.

Kimi K3 Codex check

  • Install a current Codex CLI release
  • Create and export a Requesty API key
  • Use https://router.requesty.ai/v1
  • Set wire_api to responses and model to moonshot/kimi-k3
  • Test a small text task before checking image support

After the first small task, inspect the diff and check Requesty’s activity log. For an Anthropic-format integration, see Kimi K3 with Claude Code. For OpenCode, see Kimi K3 with OpenCode.

Frequently asked questions

Can Codex CLI use Kimi K3?

Yes. Requesty's Responses endpoint translates Codex requests for Kimi K3. Use the model ID moonshot/kimi-k3.

Which wire API should the direct Moonshot provider use?

Do not use a direct Moonshot Chat provider with current Codex. Codex supports the Responses wire API, so use Requesty's Responses translation.

What is the current Kimi model ID?

Requesty's exact provider route is moonshot/kimi-k3.

Sources & further reading

Official vendor documentation referenced while writing this guide.

MG

MCSA Guru Team

IT & Systems Administration

We are working IT pros and system administrators who spend our days in Windows Server, Microsoft 365, and the wider Microsoft stack. MCSA Guru is where we write down the fixes and walkthroughs we wish we had found the first time.

MCSA Guru provides independent, educational IT guidance. Microsoft, Windows, Windows Server, Microsoft 365, Exchange, and Microsoft Teams are trademarks of Microsoft Corporation; Docker is a trademark of Docker, Inc. MCSA Guru is not affiliated with or endorsed by Microsoft or Docker. Always test changes in a safe environment before applying them in production.

Related guides

Fixing something right now?

Jump straight into the guide library or search for the exact error or task you are dealing with.