Skip to content

Feature: connect Codex via device login from the BB UI #1683

Description

@0xmcc

Problem

When Codex is selected but has no credentials, BB reports an authentication error and documentation directs the user to run codex login manually on the host. That is especially awkward for a browser-based BB deployment where the user may not have terminal access.

Codex's app-server protocol supports a device-code flow (account/login/start with chatgptDeviceCode), including a verification URL, user code, completion notification, and cancellation. Could BB offer that flow directly in its UI?

Proposed scope

  • Show Connect Codex when the Codex provider is in an auth_required state (model picker and failed-thread recovery).
  • Start a device login through the existing Codex app-server protocol.
  • Display the verification URL and user code in BB; wait for completion or allow cancellation.
  • On success, refresh Codex model availability and let the user retry.
  • Keep credentials in Codex's normal local credential store—do not expose, proxy, or persist tokens in BB.

Design question

BB currently runs live Codex app-server processes per thread. Would maintainers accept a short-lived, host-scoped auth-only app-server connection/controller for this interaction, so login never interrupts an active thread?

This would be host-wide authentication: a successful login changes the Codex identity available on that BB host, not only the browser session that initiated it. The UI/docs should make that explicit.

Quality / safety expectations

  • One login attempt per host at a time; explicit pending, completion, cancellation, and error states.
  • No real authentication in CI. Unit/integration tests would use mocked JSON-RPC protocol messages.
  • Tests for provider-specific CTA rendering, device-code display, cancellation, completion, model refresh, and ensuring active Codex threads are not restarted or terminated.
  • Behaviour/documentation for local development, CI, and multi-user/self-hosted deployments.

If this direction fits BB, I’m happy to prepare a small, focused PR following existing provider-CLI health/install UX patterns.

Activity

  1. added
    providers
    provider-codex
    on Aug 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    provider-codexproviders

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions