跪拜 Guibai
← Back to the summary

DeepSeek-V4-Flash Lands in Codex with One-Click Setup and a Multi-Model Proxy

DeepSeek-V4-Flash's release was truly explosive. After it dropped yesterday, DeepSeek's response speed noticeably slowed down — I'm guessing everyone is testing the API integration. But it's no wonder: the official DeepSeek-V4-Flash version even outperforms the DeepSeek-V4-Pro Preview, with significantly enhanced Agent capabilities. It's incredibly appealing; what more could you ask for?

I use Codex daily, so I wanted to integrate DeepSeek directly into Codex.

Fortunately, the official side provides a one-click integration setup, which is also incredibly smooth.

image-20260801181401288

You can integrate DeepSeek into any Codex client form — CLI, App, or Codex IDE extension — and you only need to configure it once.

image-20260801181627682

For Mac and Linux users, execute in the terminal:

Before executing, it's recommended to check the version first:

codex --version

The DeepSeek official model catalog requires Codex CLI to be at least 0.144.0. If the version is lower, update first:

codex update

bash <(curl -fsSL https://cdn.deepseek.com/api-docs/codex-deepseek-setup.sh)

For Windows users, execute in PowerShell:

irm https://cdn.deepseek.com/api-docs/codex-deepseek-setup-en.ps1 | iex

I'll demonstrate using Mac as an example. After executing the above command, DeepSeek will prompt you for the desired operation.

image-20260801181952141

Since we definitely want to integrate the latest DeepSeek-V4-Flash, we'll choose option 1 here.

image-20260801182428973

Then DeepSeek will prompt you to provide an api-key. This api-key is the one you create on the DeepSeek official website.

https://platform.deepseek.com/api\_keys

image-20260801182319398

Copy the api-key into the prompt above. If you want the most secure approach, you can type it manually :)

Enter it, and the integration is complete.

image-20260801182758976

Then let's check if the configuration took effect.

Restart the Codex client (it's called ChatGPT now, sorry everyone, I can't get used to the new name...)

image-20260801183210753

You can see the Model has changed to Custom.

Uninstalling is also very convenient; just execute the same steps:

bash <(curl -fsSL https://cdn.deepseek.com/api-docs/codex-deepseek-setup.sh)

Then during the installation steps, simply choose y.

image-20260801210605192

According to the official instructions, this means the integration was successful.

But using it felt very awkward, because all my Codex projects and sessions were no longer displayed. This wasn't what I wanted, and there was only the DeepSeek model — I couldn't switch models. What I wanted was the ability to switch between all models directly.

After searching around, I found no native functionality within the Codex App to switch models. So I found a GitHub project, OpenCodex, and after researching it, I discovered it could natively implement model switching directly inside the Codex App.

Project address:

https://github.com/lidge-jun/opencodex

image-20260801213413594

OpenCodex is a community-maintained local proxy. It merges models from OpenAI, DeepSeek, and other providers into a single catalog that Codex can recognize, then routes requests to the corresponding interface based on provider/model.

First, install the stable version:

npm install -g @bitkyc08/opencodex

Then run the initialization wizard:

ocx init

image-20260801213904892

I kept the original ChatGPT/Codex login here, so during initialization I chose:

If you want it to run automatically after login, install the background service:

ocx service install

Next, open the OpenCodex local management page:

ocx gui

The browser will open http://localhost:10100/. Go to Providers, add DeepSeek, and fill in the API Key.

image-20260801202609729

You can also use the command to add the DeepSeek provider first:

ocx provider add deepseek --sync

Finally, sync the model catalog once:

ocx sync

Then you can switch models with one click in Codex.

image-20260801202649748

I looked into it, and OpenCodex does not modify the Codex App binary. It mainly adds two configuration items to ~/.codex/config.toml:

model_catalog_json = "/Users/YourUsername/.codex/opencodex-catalog.json"
openai_base_url = "http://127.0.0.1:10100/v1"

The first line makes Codex read OpenCodex's merged model catalog. The second line routes model requests to the local proxy on port 10100.

The path roughly looks like:

Codex App / CLI
        ↓
OpenCodex (127.0.0.1:10100)
        ↓
OpenAI or DeepSeek

When the model ID is deepseek-v4-flash, OpenCodex recognizes the deepseek prefix, transforms Codex's Responses request, attaches the api-key, and sends it to https://api.deepseek.com.

If you want to use one-click switching in the CLI with Codex, OpenCodex handles this step too.

Just use codex directly in the terminal (provided you have the official codex cli installed) and use /model to switch models.

image-20260801211637188

You can also specify it directly at startup:

codex -m "deepseek/deepseek-v4-flash"
codex -m "gpt-5.6-sol"

If you just want to temporarily revert to native Codex:

ocx stop

This stops the proxy and background service, and restores the original Codex configuration. To completely remove it:

ocx uninstall

For daily status checks, use:

ocx status

It's very convenient to use.

However, we are currently still using DeepSeek's api-key for integration. I saw today that DeepSeek has started internal testing for Harness, so the official release is probably not far off.

I can't wait for DeepSeek's 19.9 coding plan.