Converge OpenAI Codex credentials with protected OAuth lifecycle
@jbeda is already working on this.
Since Sep 12, 2026.
- Dominant language
- Go
- Stars
- 152
- Forks
- 16
- Avg merge
- 14h 48m
- Merged PRs (30d)
- 536
Description
Problem
The experimental openai-codex provider currently consumes a manually supplied OAuth access-token/account snapshot from the plaintext operator auth.yaml credential file. It has no browser login, refresh, protected credential-store integration, or token lifecycle.
This differs from Mecatl-owned OIDC provider enrollment, which stores identity-bound encrypted records in the protected credential store and supports the established login/refresh/logout lifecycle. It also prevents the file currently named auth.yaml from being accurately described as API-key-only.
Goal
Converge openai-codex credential custody and lifecycle with Mecatl's existing protected OAuth/OIDC mechanisms, while preserving the provider's distinct billing identity, entitlement-authoritative model inventory, and private Codex endpoint policy.
Scope
- Define the appropriate protected credential-store record and identity binding for
openai-codex. - Add a deliberate local enrollment/refresh/logout lifecycle only if the upstream protocol and security contract support it.
- Migrate or retire the manual
providers.openai-codex.oauthauth.yamlrecord through an explicit compatibility plan. - Preserve the current non-impersonation requirement (
originator: mecatl) and distinctopenai-codexprovider identity. - Update documentation and configuration terminology once the plaintext manual-token compatibility path is retired.
Non-goals
- Do not merge the current API-key provider configuration redesign with this work.
- Do not treat a ChatGPT/Codex subscription as an OpenAI public API key or merge the
openaiandopenai-codexproviders. - Do not add a model-facing credential flow or remote client enrollment.
Context
- ADR 0215 deliberately chose an immutable manual token as the first experimental release and deferred login, refresh, expiry management, and keyring storage.
openai-codexis distinct from publicopenai: it uses ChatGPT subscription credentials and the private Codex compatibility endpoint.- The provider-configuration redesign should remain bounded for now:
auth.yamlcontinues to contain the existing Codex OAuth record, so it cannot yet be renamed or presented as API-key-only.
Relates to PR #1441 and the follow-up provider-unification design.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.