This repository was archived by the owner on Apr 15, 2026. It is now read-only.
feat(auth): implement hjk auth codex command#27
Merged
Conversation
Add support for OpenAI Codex CLI authentication. The command runs `codex login` interactively, which opens a browser for ChatGPT OAuth, then stores the resulting auth.json contents in the macOS Keychain. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add missing credential injection for Codex sessions: - Add codex case to injectAuthToken to pass CODEX_AUTH_JSON env var - Add codex case to runAgentSetup to write ~/.codex/auth.json This ensures the Codex CLI finds its auth.json when running inside containers, matching the pattern used for Claude and Gemini. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
jmgilman
added a commit
that referenced
this pull request
Jan 3, 2026
Current behavior: N/A - new feature New behavior: Adds support for OpenAI Codex CLI authentication with interactive `codex login` flow that opens browser for ChatGPT OAuth, stores auth.json contents in macOS Keychain, and injects credentials into containers via CODEX_AUTH_JSON environment variable and ~/.codex/auth.json file Closes: #27
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
hjk auth codexcommand to configure OpenAI Codex CLI authenticationcodex logininteractively and store resultingauth.jsonin macOS KeychainImplementation
Follows the same pattern as Claude and Gemini auth:
CodexProviderininternal/auth/codex.gohandles the login flow and keychain storageinjectAuthTokeninrun.gopasses credentials asCODEX_AUTH_JSONenv varrunAgentSetupinmanager.gowrites~/.codex/auth.jsonbefore starting sessionsTest plan
hjk auth codexand complete OAuth flowhjk run <branch> --agent codexand verify no auth prompt appearsjust checkpassesCloses JMG-19
🤖 Generated with Claude Code