Skip to content

Conversation

@rekram1-node
Copy link
Collaborator

What does this PR do?

How did you verify your code works?

@rekram1-node
Copy link
Collaborator Author

/review

@rekram1-node
Copy link
Collaborator Author

/review

@rekram1-node rekram1-node changed the title wip: codex feat: codex auth support Jan 9, 2026
@rekram1-node
Copy link
Collaborator Author

/review

@rekram1-node rekram1-node merged commit 172bbda into dev Jan 9, 2026
4 checks passed
0xRichardH added a commit to 0xRichardH/omarchy-dotfiles that referenced this pull request Jan 10, 2026
Opencode now supports Codex auth directly.\n\nhttps://github.com/anomalyco/opencode/pull/7537
0xRichardH added a commit to 0xRichardH/omarchy-dotfiles that referenced this pull request Jan 10, 2026
Opencode now supports Codex auth directly.\n\nhttps://github.com/anomalyco/opencode/pull/7537
xingyaoww pushed a commit to OpenHands/software-agent-sdk that referenced this pull request Jan 10, 2026
Implement OAuth PKCE flow for authenticating with OpenAI's ChatGPT service,
allowing users with ChatGPT Plus/Pro subscriptions to use Codex models
(gpt-5.2-codex, gpt-5.2, gpt-5.1-codex-max, gpt-5.1-codex-mini) without
consuming API credits.

Key features:
- OAuth PKCE flow with local callback server for secure authentication
- Credential storage with automatic token refresh
- LLM.subscription_login() classmethod for easy access
- Support for multiple Codex models via ChatGPT subscription

Usage:
  from openhands.sdk import LLM
  llm = LLM.subscription_login(model='gpt-5.2-codex')

Inspired by opencode's implementation (anomalyco/opencode#7537).

Co-authored-by: openhands <[email protected]>
nikomatt69 pushed a commit to nikomatt69/nikcli-main that referenced this pull request Jan 10, 2026
Add comprehensive OAuth authentication support for OpenAI Codex models,
enabling users with ChatGPT Pro/Plus subscriptions to access Codex models
(gpt-5.1-codex, gpt-5.1-codex-mini, gpt-5.2-codex) without API keys.

Implementation includes:

- New OAuth authentication module (src/cli/auth/openai-oauth.ts):
  * PKCE flow with SHA-256 for secure authentication
  * Token management with automatic refresh
  * Support for ChatGPT Pro/Plus subscription access
  * Compatible with OpenAI's OAuth 2.0 endpoint

- Config manager updates (src/cli/core/config-manager.ts):
  * Added openaiOAuth configuration schema with encryption
  * Token storage methods: get, set, clear, has
  * Temporary verifier/state management for OAuth flow
  * Secure token encryption using KeyEncryption

- Modern AI provider integration (src/cli/ai/modern-ai-provider.ts):
  * Automatic OAuth detection for Codex models
  * Custom fetch with bearer token authentication
  * Fallback to API key for non-Codex models
  * Token auto-refresh on expiration

- CLI commands (src/cli/nik-cli.ts):
  * /auth openai - Initialize OAuth flow with authorization URL
  * /auth openai-login - Complete OAuth flow with authorization code
  * /auth openai status - Check OAuth connection status
  * /auth openai logout - Disconnect OAuth session
  * Interactive prompts for code input

Inspired by opencode implementation (anomalyco/opencode#7537)
shuv1337 added a commit to Latitudes-Dev/shuvcode that referenced this pull request Jan 10, 2026
Upstream changes:
- feat: codex auth support (anomalyco#7537) - GPT-5.2-Codex authentication
- fix: instance dispose issue
- docs: url based instructions and provider docs

Resolved conflicts:
- bun.lock: accepted upstream
- packages/opencode/src/plugin/index.ts: merged imports (kept fork bundleLocalPlugin + added CodexAuthPlugin)
- sdks/vscode/package.json: kept shuvcode branding, updated version to 1.1.11
@itisyb
Copy link

itisyb commented Jan 10, 2026

is this working I press /connect doesn't see it

aryasaatvik pushed a commit to aryasaatvik/opencode that referenced this pull request Jan 10, 2026
fwang pushed a commit to lifefloating/opencode that referenced this pull request Jan 10, 2026
zerone0x pushed a commit to zerone0x/opencode that referenced this pull request Jan 12, 2026
zerone0x pushed a commit to zerone0x/opencode that referenced this pull request Jan 12, 2026
athal7 pushed a commit to athal7/opencode that referenced this pull request Jan 13, 2026
0xRichardH added a commit to 0xRichardH/omarchy-dotfiles that referenced this pull request Jan 14, 2026
0xRichardH added a commit to 0xRichardH/omarchy-dotfiles that referenced this pull request Jan 14, 2026
0xRichardH added a commit to 0xRichardH/omarchy-dotfiles that referenced this pull request Jan 14, 2026
0xRichardH added a commit to 0xRichardH/omarchy-dotfiles that referenced this pull request Jan 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants