codex - 💡(How to fix) Fix Add the ability to fallback to platform.openai.com credits when usage runs out. [2 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openai/codex#21017Fetched 2026-05-05 05:54:26
View on GitHub
Comments
2
Participants
3
Timeline
10
Reactions
0
Timeline (top)
labeled ×5commented ×2closed ×1mentioned ×1
RAW_BUFFERClick to expand / collapse

What variant of Codex are you using?

CLI, App

What feature would you like to see?

/add-api-key while being signed in with a ChatGPT account.

  • Fallback API key in cred store
  • User uses codex as normal
  • When limits run out, just switches to API key
  • This feature can be extended to the App and it benefits app users as well.

Why?

  • People using codex with an API key will likely have a ChatGPT account that they would prefer using before using API.
  • This is a big pain point as it means having to constantly log out and log in. Often, it means having to generate a new key as you would copy/paste the key only once.

Additional information

This was rejected previously for the following reason:

I think it's unlikely that we would implement a solution like the one you've outlined above. We don't recommend switching between accounts, so this isn't something we'd want to encourage.

If you need to purchase additional usage when you run low on your ChatGPT subscription, you can purchase additional credits that are associated with your main account. For details, refer to this documentation. Using this approach, you don't need to switch accounts.

Originally posted by @etraut-openai in #20899

But my original request is about a different scenario: someone having prepaid API credits on platform.openai.com (tied to the same OpenAI/ChatGPT account) and wants to use that when the sub limit is hit, (without logging out.)

Currently the code explicitly blocks adding an API key while ChatGPT auth is active. So even though both billing systems share the same underlying account, there is no way to use API platform credits as a fallback. The user must log out, switch to API key mode, and lose their ChatGPT session. I have tried this and there is no way to fallback to OpenAI platform credits.

extent analysis

TL;DR

Modify the Codex code to allow adding an API key while signed in with a ChatGPT account, enabling fallback to platform credits when subscription limits are reached.

Guidance

  • Review the current code that explicitly blocks adding an API key while ChatGPT auth is active and consider modifying it to allow this functionality.
  • Investigate how to integrate the prepaid API credits on platform.openai.com with the ChatGPT account, ensuring a seamless fallback when subscription limits are hit.
  • Evaluate the feasibility of implementing a feature to automatically switch to API key mode when subscription limits are reached, without requiring the user to log out.
  • Consider the security and authentication implications of allowing API key addition while signed in with a ChatGPT account.

Example

No code snippet is provided as the issue does not include specific code details.

Notes

The previous rejection of this feature request was based on a different scenario, and the current request focuses on a distinct use case. The implementation of this feature may require significant changes to the Codex code and authentication mechanisms.

Recommendation

Apply workaround: Modify the Codex code to allow adding an API key while signed in with a ChatGPT account, as this would provide a direct solution to the user's pain point and enable the desired fallback functionality.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

codex - 💡(How to fix) Fix Add the ability to fallback to platform.openai.com credits when usage runs out. [2 comments, 3 participants]