Skip to content

Codex model catalog template `gpt-5.5` not found - CC Switch

Quick fix

Run codex debug models --bundled > ~/.codex/models_cache.json to generate the missing model cache, then switch the Codex route again.

Error output
切换路由状态失败: 写入 Codex 配置失败: Codex model catalog template `gpt-5.5` not found. Please start Codex once so models_cache.json is available, or ensure the `codex` CLI is on PATH.
English translation

Failed to switch routing state: failed to write Codex config: Codex model catalog template `gpt-5.5` not found. Please start Codex once so models_cache.json is available, or ensure the `codex` CLI is on PATH.

When taking over or writing Codex routing config, CC Switch reads `~/.codex/models_cache.json` as its model catalogue source and expects a `gpt-5.5` template inside. If Codex has never been signed in with an official account or started at all, or you went straight to a custom DeepSeek backend, `models_cache.json` is never generated and CC Switch reports `gpt-5.5` not found while switching routes. Running `codex debug models --bundled > ~/.codex/models_cache.json` by hand fills the cache in.

The same class has several variants: an empty model list after switching (#3340) and `/model` not showing DeepSeek models (#3422) usually come from `cc-switch-model-catalog.json` not being refreshed or a leftover custom provider — delete that cache file and switch again to regenerate it. `model_provider` keeping the old key in `config.toml` (#3318) is deliberate compatibility from v3.15.0 to avoid re-bucketing Codex history; what actually applies is the content of `[model_providers.<key>]`. Routing on but `base_url` not hot-switching to `127.0.0.1` (#4082/#3756) was fixed in v3.16.2. A default model overwritten by an old database value (#5783) has to be saved on the CC Switch edit page rather than edited directly in `~/.codex/config.toml`. And v3.16.4's `AbsolutePathBuf deserialized without a base path in model_catalog_json` (#4761) was folded into #5731 by a maintainer. Note the fixes contradict each other: maintainers called v3.16.0/v3.16.1 fixed when closing #3340/#3422, yet users still reproduce on v3.16.2 and recovered variously by reinstalling Codex, turning a VPN off, or deleting and recreating the provider. Try against your own environment rather than relying on an upgrade alone.

  1. Open a terminal and run `codex debug models --bundled > ~/.codex/models_cache.json` to generate a model cache file containing the `gpt-5.5` and other templates.

  2. Restart Codex (start it at least once), then go back to CC Switch and enable or switch the Codex route again.

  3. If `/model` still does not show DeepSeek models, delete `cc-switch-model-catalog.json` and switch provider again — CC Switch regenerates the catalogue.

  4. If the model list is still empty after switching, delete that custom provider in CC Switch and recreate it. Some users in #3340 report this works.

  5. If `base_url` does not hot-switch or still reads `https://api.deepseek.com`, upgrade to v3.16.2 or newer first. If the default model is overwritten, change 默认模型 (default model) on the CC Switch Codex provider edit page and save, rather than editing `~/.codex/config.toml` by hand.

ToolCodex
Version3.15.0 - 3.18.0(受影响范围;#3756 的 base_url 占位符问题在 v3.16.2 修复)
PlatformsWindowsmacOS
Is my `config.toml` configured wrongly?
Not necessarily. The more common cause is a missing `~/.codex/models_cache.json`, leaving CC Switch unable to find the `gpt-5.5` model catalogue template. Run `codex debug models --bundled > ~/.codex/models_cache.json` first, then check the custom provider `base_url`/`model` in `config.toml`.
I set a proxy in `.env`. With the proxy off Codex will not open, and with it on I cannot see the models. What now?
Community reports disagree: some users see third-party models after turning the VPN off and restarting Codex, while others need the proxy to reach the API at all. Confirm the proxy is not intercepting the local routing address `127.0.0.1`, and that Codex and CC Switch use the same `~/.codex/config.toml`. If it still conflicts, try deleting and recreating the provider, or deleting `cc-switch-model-catalog.json` before switching again.
Claude Code has a similar problem — will `codex debug models --bundled` fix it?
No. `gpt-5.5 not found` is a Codex model cache problem and `codex debug models --bundled` only applies to Codex. Claude Code users reported a different error, "There's an issue with the selected model (claude-sonnet-4-6[1m]). It may not exist or you may not have access to it." The steps on this page do not apply to Claude Code.

This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.