#1118·humanlayer

[Feature]: Switch OpenAI account on an existing Codex session (at least on fork)

Author: gaspard-lemrockCreated Sep 16, 2026Updated Sep 16, 2026

Problem / Use Case

When the OpenAI account behind a Codex session runs out of credit or hits its usage limit, the session is stuck. Switching to another OpenAI account has no effect on the existing conversation: it keeps using the exhausted account and errors out, and forking the session does not help because the fork stays on the same account. The only option is to start a brand new session and lose the context.

Proposed Solution

Let a Codex session continue on a different OpenAI account, with two levels:

  1. At minimum, when forking a session, allow picking the account the fork should run on.
  2. Ideally, allow switching the account on the live session itself.

Since the conversation history lives on the OpenAI side per account, HumanLayer could keep a local copy of the transcript and replay it into the new account's session.

Alternative Solutions Considered

Starting a new session on the other account and pasting the context manually, which loses the history and tool state.

Additional Context

Related Issues/PRs:

  • #1078 (switch model vendors mid-phase, same motivation: quota and limits)