gpt 5.4 mini is not available in model picker when using API auth key

Open 💬 3 comments Opened Mar 26, 2026 by balboah

What version of the Codex App are you using (From “About Codex” dialog)?

26.324.21641 (1228)

What subscription do you have?

openai platform API key

What platform is your computer?

macOS

What issue are you seeing?

While logged into codex with ChatGPT, the gpt 5.4 mini model is available in the dropdown.
While logged into codex using an API key, it is not.

<img width="172" height="220" alt="Image" src="https://github.com/user-attachments/assets/3034b0ec-3875-415d-95dd-174fafe2492d" />

What steps can reproduce the bug?

  • codex login --with-api-key
  • open codex app or codex cli, observe missing model

What is the expected behavior?

Models enabled in the API should also be available in the codex app model picker

Additional information

_No response_

View original on GitHub ↗

3 Comments

quantuan125 · 5 months ago

Not available on 0.116.0 codex CLI either, but updating to 0.117.0 (latest) fixes it

<img width="1000" height="539" alt="Image" src="https://github.com/user-attachments/assets/953ab482-0ac8-4d57-b0be-54f16277bc33" />

bradsjm · 4 months ago

In refresh_available_models, API-key users hit an unconditional early return that prevents them from ever fetching the remote model catalog:

if self.auth_manager.auth_mode() != Some(AuthMode::Chatgpt)
    && !self.provider.has_command_auth()
{
    if matches!(
        refresh_strategy,
        RefreshStrategy::Offline | RefreshStrategy::OnlineIfUncached
    ) {
        self.try_load_cache().await;
    }
    return Ok(());  // ← always returns, never reaches fetch_and_update_models()
}

This creates a circular problem for API-key users (where auth_mode() == Some(AuthMode::ApiKey)):

  1. fetch_and_update_models() is unreachable because of the early return at line 410
  2. fetch_and_update_models() is the only place that calls persist_cache() (line 467-469), so the cache is never written by API-key users
  3. try_load_cache() requires the cache to be fresh (5-min TTL) and version-matched, so any cache from a prior ChatGPT session quickly becomes unusable
  4. The app falls back to the bundled models.json, which doesn't contain gpt-5.4-mini

In contrast, ChatGPT auth users and command-auth users proceed past line 411 to the normal OnlineIfUncached path, which falls through to fetch_and_update_models() on cache miss

The early return at line 410 should not be unconditional for API-key users who have valid credentials. The OnlineIfUncached and Online strategies should be allowed to reach fetch_and_update_models() when the user has a valid API key, just as they do for ChatGPT and command-auth users. The guard at lines 401-411 appears to have been intended for users with no auth at all (where a network fetch would fail anyway), but it also blocks authenticated API-key users.

Reflyer823 · 4 months ago

I have encountered the same issue. I'm using the enterprise unified routing API endpoint, which may not support forwarding requests for the model list. I think it's worth considering updating the built-in models.json content, or providing a user-defined configuration file for models.json.