Multi-account OAuth manager and auth wrapper for the official OpenAI Codex CLI (v1.3.2, stable). Provides account switching, health-aware failover, proactive token refresh, and diagnostics (forecast, report, fix, doctor). Ships TypeScript types, ESM-only, requires Node >=18.0.0 and TypeScript ^5 as peer dependency. Differentiates from raw @openai/codex by adding multi-account pool management, circuit-breaker logic, and recovery tools without altering the core CLI interface. Maintained actively with frequent patches.
npm install codex-multi-authVerified import paths — ran on the pinned version, not inferred.
Install globally, log in, verify status, list accounts, switch account, and preview routing decision.
npm uninstall -g @ndycode/codex-multi-auth && npm i -g codex-multi-auth
Use import statements and set 'type': 'module' in package.json.
Upgrade to v1.3.2.
Upgrade Node.js to >=18.0.0.
Add 'type': 'module' to package.json or rename file to .mjs.
Run npm i -g codex-multi-auth.
Use import { AuthManager } from 'codex-multi-auth' instead of default import.