Skip to content

Add Codex provider with app-server auth flows#359

Merged
DaKheera47 merged 14 commits intomainfrom
codex-llm-provider
Apr 16, 2026
Merged

Add Codex provider with app-server auth flows#359
DaKheera47 merged 14 commits intomainfrom
codex-llm-provider

Conversation

@DaKheera47
Copy link
Copy Markdown
Owner

@DaKheera47 DaKheera47 commented Apr 14, 2026

Summary

  • Add codex as a first-class LLM provider across shared settings, provider normalization, and UI labels/help text
  • Implement Codex app-server integration in server LLM stack (client, provider wiring, service routing, and tests)
  • Add Codex auth endpoints in settings API for device-code flow status/start
  • Add Codex sign-in UX in both Settings and Onboarding (start, refresh, status polling, and error handling)
  • Update docs with a dedicated Codex auth guide and troubleshooting entries

Testing

  • Targeted tests run:
    • orchestrator/src/server/services/llm/codex/client.test.ts
    • orchestrator/src/server/services/llm/codex/login.test.ts
    • orchestrator/src/server/api/routes/settings.codex-auth.test.ts
    • orchestrator/src/client/pages/SettingsPage.test.tsx
    • orchestrator/src/client/pages/OnboardingPage.test.tsx (added coverage for onboarding Codex sign-in)
  • Additional checks run:
    • biome checks on touched code/docs paths
  • Known environment issues encountered during broader runs:
    • local dependency/runtime mismatches affected full-suite and docs build validation

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Codex as a first-class LLM provider, including a local codex app-server (stdio) integration, device-code auth endpoints, and UI flows in both Settings and Onboarding, plus Docker host-login reuse support and documentation.

Changes:

  • Introduces codex provider normalization/defaults across shared settings and server/provider strategy wiring.
  • Implements Codex app-server JSON-RPC client + device-code login flow, plus Settings API routes and tests.
  • Adds Codex sign-in UX (status/start/polling) and documents Docker host-login reuse via CODEX_HOME_MOUNT.

Reviewed changes

Copilot reviewed 32 out of 32 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
shared/src/settings-registry.ts Adds codex provider + default model handling
shared/src/settings-registry.test.ts Tests Codex default model behavior
orchestrator/src/server/services/settings.ts Sets Codex default base URL behavior
orchestrator/src/server/services/llm/types.ts Extends LlmProvider union with codex
orchestrator/src/server/services/llm/service.ts Routes Codex calls to CodexClient + normalization
orchestrator/src/server/services/llm/service.test.ts Adds Codex normalization + delegation/retry tests
orchestrator/src/server/services/llm/providers/index.ts Registers Codex provider strategy
orchestrator/src/server/services/llm/providers/codex.ts Adds Codex strategy stub (stdio / no HTTP)
orchestrator/src/server/services/llm/codex/login.ts Implements device-code login session tracking
orchestrator/src/server/services/llm/codex/login.test.ts Tests device-code parsing/session behavior
orchestrator/src/server/services/llm/codex/client.ts Implements stdio JSON-RPC app-server client
orchestrator/src/server/services/llm/codex/client.test.ts Tests JSON-RPC flow, auth status, model listing
orchestrator/src/server/api/routes/settings.ts Adds /codex-auth + /codex-auth/start endpoints
orchestrator/src/server/api/routes/settings.codex-auth.test.ts Tests Codex auth endpoints
orchestrator/src/client/pages/settings/utils.ts Adds Codex provider labels/hints/config
orchestrator/src/client/pages/settings/utils.test.ts Tests Codex provider UI config behavior
orchestrator/src/client/pages/settings/components/ModelSettingsSection.tsx Adds Codex sign-in block + polling in Settings
orchestrator/src/client/pages/onboarding/components/LlmConnectionStep.tsx Adds Codex sign-in block + polling in Onboarding
orchestrator/src/client/pages/SettingsPage.tsx Adds codex to settings search terms
orchestrator/src/client/pages/SettingsPage.test.tsx Tests starting Codex sign-in from Settings
orchestrator/src/client/pages/OnboardingPage.test.tsx Adds onboarding coverage for Codex sign-in
orchestrator/src/client/api/client.ts Adds client methods/types for Codex auth endpoints
docs-site/versioned_docs/version-0.3.1/troubleshooting/common-problems.md Adds Codex device-code troubleshooting entry
docs-site/versioned_docs/version-0.3.1/getting-started/self-hosting.md Documents CODEX_HOME_MOUNT host-login reuse
docs-site/versioned_docs/version-0.3.1/getting-started/codex-auth.md Adds dedicated Codex auth guide (versioned)
docs-site/docs/troubleshooting/common-problems.md Adds Codex device-code troubleshooting entry
docs-site/docs/getting-started/self-hosting.md Documents CODEX_HOME_MOUNT host-login reuse
docs-site/docs/getting-started/codex-auth.md Adds dedicated Codex auth guide (current)
docker-compose.yml Adds Codex home volume + CODEX_HOME env
README.md Documents Codex container login + host-login reuse
Dockerfile Installs Codex CLI + creates codex home directory
.env.example Documents CODEX_HOME_MOUNT option

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Dockerfile Outdated
Comment thread orchestrator/src/server/services/llm/codex/client.ts
Comment thread orchestrator/src/server/services/settings.ts Outdated
Comment thread orchestrator/src/server/api/routes/settings.ts Outdated
Comment thread orchestrator/src/server/services/llm/codex/login.ts
@DaKheera47 DaKheera47 changed the title Add Codex provider with app-server auth flows and host login reuse Add Codex provider with app-server auth flows Apr 14, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 32 out of 32 changed files in this pull request and generated 6 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread orchestrator/src/client/components/CodexAuthPanel.tsx Outdated
Comment thread orchestrator/src/server/services/llm/codex/login.ts Outdated
Comment thread orchestrator/src/client/components/CodexAuthPanel.tsx
Comment thread orchestrator/src/server/services/llm/codex/client.ts Outdated
Comment thread orchestrator/src/server/services/llm/codex/client.ts Outdated
Comment thread orchestrator/src/server/services/llm/codex/client.ts Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 33 out of 33 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread orchestrator/src/client/components/CodexAuthPanel.tsx
Comment thread docker-compose.yml
@DaKheera47 DaKheera47 marked this pull request as ready for review April 16, 2026 13:25
@DaKheera47 DaKheera47 merged commit 7ee5240 into main Apr 16, 2026
10 checks passed
@DaKheera47 DaKheera47 deleted the codex-llm-provider branch April 16, 2026 13:28
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.

Feature Request: OAuth/account linking for Codex, Claude, and Gemini subscriptions

2 participants