codex-multi-auth 2.7.0 → 2.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/.codex-plugin/plugin.json +9 -9
  2. package/README.md +435 -433
  3. package/dist/lib/cli.d.ts +2 -0
  4. package/dist/lib/cli.d.ts.map +1 -1
  5. package/dist/lib/codex-cli/writer.d.ts +51 -0
  6. package/dist/lib/codex-cli/writer.d.ts.map +1 -1
  7. package/dist/lib/codex-cli/writer.js +89 -8
  8. package/dist/lib/codex-manager/login-menu-actions.d.ts.map +1 -1
  9. package/dist/lib/codex-manager/login-menu-actions.js +12 -1
  10. package/dist/lib/codex-manager/login-menu-data.d.ts.map +1 -1
  11. package/dist/lib/codex-manager/login-menu-data.js +19 -8
  12. package/dist/lib/codex-manager/repair-commands.d.ts.map +1 -1
  13. package/dist/lib/codex-manager/repair-commands.js +57 -8
  14. package/dist/lib/forecast.d.ts.map +1 -1
  15. package/dist/lib/forecast.js +30 -4
  16. package/dist/lib/policy/runtime-policy.d.ts.map +1 -1
  17. package/dist/lib/policy/runtime-policy.js +12 -3
  18. package/dist/lib/quota-readiness.d.ts +1 -0
  19. package/dist/lib/quota-readiness.d.ts.map +1 -1
  20. package/dist/lib/quota-readiness.js +12 -2
  21. package/dist/lib/refresh-lease.d.ts +12 -0
  22. package/dist/lib/refresh-lease.d.ts.map +1 -1
  23. package/dist/lib/refresh-lease.js +24 -2
  24. package/dist/lib/refresh-queue.d.ts.map +1 -1
  25. package/dist/lib/refresh-queue.js +29 -3
  26. package/dist/lib/request/request-transformer.d.ts.map +1 -1
  27. package/dist/lib/request/request-transformer.js +13 -2
  28. package/dist/lib/request/response-handler.d.ts.map +1 -1
  29. package/dist/lib/request/response-handler.js +10 -1
  30. package/dist/lib/rotation.d.ts.map +1 -1
  31. package/dist/lib/rotation.js +8 -1
  32. package/dist/lib/runtime/account-check.d.ts +1 -1
  33. package/dist/lib/runtime/account-check.d.ts.map +1 -1
  34. package/dist/lib/runtime/account-check.js +8 -0
  35. package/dist/lib/runtime/first-run.d.ts +12 -6
  36. package/dist/lib/runtime/first-run.d.ts.map +1 -1
  37. package/dist/lib/runtime/first-run.js +140 -9
  38. package/dist/lib/runtime/rotation-storage-meta.d.ts.map +1 -1
  39. package/dist/lib/runtime/rotation-storage-meta.js +8 -2
  40. package/dist/lib/storage/account-port.d.ts +2 -0
  41. package/dist/lib/storage/account-port.d.ts.map +1 -1
  42. package/dist/lib/storage/account-port.js +1 -0
  43. package/dist/lib/storage/import-export.d.ts +1 -0
  44. package/dist/lib/storage/import-export.d.ts.map +1 -1
  45. package/dist/lib/storage/import-export.js +25 -0
  46. package/dist/lib/storage/project-migration.d.ts +1 -1
  47. package/dist/lib/storage/project-migration.d.ts.map +1 -1
  48. package/dist/lib/storage/project-migration.js +28 -2
  49. package/dist/lib/storage.d.ts +10 -0
  50. package/dist/lib/storage.d.ts.map +1 -1
  51. package/dist/lib/storage.js +16 -1
  52. package/dist/lib/ui/auth-menu-builder.d.ts +10 -0
  53. package/dist/lib/ui/auth-menu-builder.d.ts.map +1 -1
  54. package/dist/lib/ui/auth-menu-builder.js +29 -4
  55. package/package.json +1 -1
  56. package/scripts/codex.js +126 -13
package/README.md CHANGED
@@ -1,433 +1,435 @@
1
- # codex-multi-auth: multi-account OAuth for the official Codex CLI
2
-
3
- [![npm version](https://img.shields.io/npm/v/codex-multi-auth.svg)](https://www.npmjs.com/package/codex-multi-auth)
4
- [![npm downloads](https://img.shields.io/npm/dw/codex-multi-auth.svg)](https://www.npmjs.com/package/codex-multi-auth)
5
- [![CI](https://github.com/ndycode/codex-multi-auth/actions/workflows/ci.yml/badge.svg)](https://github.com/ndycode/codex-multi-auth/actions/workflows/ci.yml)
6
- [![MIT license](https://img.shields.io/npm/l/codex-multi-auth.svg)](LICENSE)
7
-
8
- `codex-multi-auth` is a multi-account OAuth manager for the official `@openai/codex` CLI. It gives Codex CLI users explicit ChatGPT account login, account switching, health checks, local diagnostics, project-scoped storage, and default-on runtime Responses rotation without taking over the official `codex` binary. Use `codex-multi-auth ...` for account management, or `codex-multi-auth-codex ...` only when you intentionally want the optional forwarding wrapper.
9
-
10
- Use it when you need a local Codex CLI multi-account workflow with visible account state, safer recovery commands, and a loopback-only runtime rotation proxy for request-bearing forwarded Codex sessions.
11
-
12
- <img width="1270" height="729" alt="codex-multi-auth terminal dashboard for Codex CLI multi-account OAuth account status" src="https://github.com/user-attachments/assets/0cecb77e-a6d3-432a-ba48-3577db0c7093" />
13
-
14
-
15
-
16
- > [!NOTE]
17
- > Legacy scoped prerelease package `@ndycode/codex-multi-auth` is migration-only.
18
- > Use `codex-multi-auth` for all new installs.
19
-
20
- ## What You Get
21
-
22
- - Codex CLI multi-account OAuth management with a dedicated `codex-multi-auth ...` command family
23
- - Explicit ChatGPT account login, saved-account listing, account switching, health checks, and diagnostics
24
- - Optional `codex-multi-auth-codex ...` forwarding wrapper for official Codex CLI commands when you choose wrapper-launched sessions
25
- - Health-aware account selection, quota forecasting, automatic failover, and flagged-account recovery
26
- - Project-scoped account storage under `~/.codex/multi-auth/projects/<project-key>/...` for repo-specific workflows
27
- - Interactive terminal dashboard for account actions, settings, search, and hotkeys
28
- - Forecast, report, fix, doctor, verify, monitor, and rotation commands for operational confidence
29
- - Local usage ledger, budget guards, account policy controls, routing profiles, and model/account capability views
30
- - Runtime counters, budget/cooldown state, and multi-auth probe visibility in `codex-multi-auth status` / `codex-multi-auth report`
31
- - Default-on loopback Responses proxy for live account rotation inside forwarded Codex CLI/app sessions
32
- - Optional loopback-only local bridge for `/health`, `/v1/models`, and `/v1/responses`, protected by hashed local client tokens
33
- - Reversible packaged Codex app bind and user-level launcher routing helpers that do not patch official app binaries
34
- - Session affinity, live account sync, proactive refresh, and preemptive quota deferral controls
35
- - Codex-oriented request/prompt compatibility with strict runtime handling and documented error contracts
36
- - Stable docs for install, configuration, troubleshooting, upgrade, public API, storage paths, and release notes
37
-
38
- ---
39
-
40
- ## Why Developers Use It
41
-
42
- `codex-multi-auth` makes local Codex account state visible and recoverable. Instead of one opaque auth file, you get a named account pool, deterministic account switching, health-aware selection, JSON diagnostics for automation, and safe repair commands for stale or damaged local state. The architecture is designed for personal development workflows: credentials stay local, runtime rotation is loopback-only, and official Codex install paths keep owning the `codex` command.
43
-
44
- ---
45
-
46
- ## Current Architecture At A Glance
47
-
48
- `codex-multi-auth` ships four global binaries:
49
-
50
- | Binary | Purpose |
51
- | --- | --- |
52
- | `codex-multi-auth` | Primary account manager; accepts bare auth subcommands such as `login`, `status`, `switch`, `forecast`, and `rotation status` |
53
- | `codex-multi-auth-codex` | Optional wrapper that handles `auth ...` locally and forwards every other command to the official Codex CLI |
54
- | `mcodex` | Convenience launcher over `codex-multi-auth-codex` with optional `--monitor` and `--tmux` modes |
55
- | `codex-multi-auth-app-launcher` | Optional desktop launcher helper for supported user-level shortcuts and wrapper apps |
56
-
57
- The package does not publish a global `codex` binary. Keep `codex` owned by the official OpenAI install path. Use `codex-multi-auth-codex ...` or `mcodex ...` only when you intentionally want this package's forwarding wrapper.
58
-
59
- ---
60
-
61
- <details open>
62
- <summary><b>Terms and Usage Notice</b></summary>
63
-
64
- > [!CAUTION]
65
- > This project uses OAuth account credentials and is intended for personal development use.
66
- >
67
- > By using this package, you acknowledge:
68
- > - This is an independent open-source project, not an official OpenAI product
69
- > - You are responsible for your own usage and policy compliance
70
- > - For production/commercial workloads, use the OpenAI Platform API
71
-
72
- </details>
73
-
74
- ---
75
-
76
- ## Installation
77
-
78
- <details open>
79
- <summary><b>For Humans</b></summary>
80
-
81
- ### Option A: Standard install
82
-
83
- ```bash
84
- npm i -g codex-multi-auth
85
- ```
86
-
87
- ### Option B: Migrate from legacy scoped prerelease
88
-
89
- ```bash
90
- npm uninstall -g @ndycode/codex-multi-auth
91
- npm i -g codex-multi-auth
92
- ```
93
-
94
- ### Option C: Verify wiring
95
-
96
- `codex --version` confirms the official Codex CLI is reachable. `codex-multi-auth --version` confirms the installed manager package version. `codex-multi-auth-codex --version` is the optional forwarding wrapper entrypoint.
97
-
98
- ```bash
99
- codex --version
100
- codex-multi-auth --version
101
- codex-multi-auth status
102
- ```
103
-
104
- Any official install path is fine as long as `codex` is on `PATH`: `npm i -g @openai/codex`, `brew install --cask codex`, or an official release binary.
105
-
106
- </details>
107
-
108
- <details>
109
- <summary><b>For LLM Agents</b></summary>
110
-
111
- ### Step-by-step
112
-
113
- 1. Install global package:
114
- - `npm i -g codex-multi-auth`
115
- 2. Run first login flow with `codex-multi-auth login`
116
- 3. Validate state with `codex-multi-auth status` and `codex-multi-auth check`
117
- 4. Confirm routing with `codex-multi-auth forecast --live`
118
-
119
- ### Verification
120
-
121
- ```bash
122
- codex-multi-auth status
123
- codex-multi-auth check
124
- ```
125
-
126
- </details>
127
-
128
- ---
129
-
130
- ## Quick Start
131
-
132
- Install and sign in:
133
-
134
- ```bash
135
- npm i -g @openai/codex
136
- npm i -g codex-multi-auth
137
- codex-multi-auth login
138
- ```
139
-
140
- If you already installed the official native CLI via Homebrew or a release binary, you only need:
141
-
142
- ```bash
143
- npm i -g codex-multi-auth
144
- codex-multi-auth login
145
- ```
146
-
147
- Verify the manager and the new account:
148
-
149
- ```bash
150
- codex-multi-auth status
151
- codex-multi-auth check
152
- ```
153
-
154
- Use these next:
155
-
156
- ```bash
157
- codex-multi-auth list
158
- codex-multi-auth switch 2
159
- codex-multi-auth forecast --live
160
- ```
161
-
162
- If browser launch is blocked, use the alternate login paths in [docs/getting-started.md](docs/getting-started.md#alternate-login-paths).
163
- For remote or headless shells, prefer `codex-multi-auth login --device-auth`.
164
-
165
- ---
166
-
167
- ## Command Toolkit
168
-
169
- ### Start here
170
-
171
- | Command | What it answers |
172
- | --- | --- |
173
- | `codex-multi-auth login` | How do I add or re-open the account menu? |
174
- | `codex-multi-auth status` | What does my account pool, pin, and runtime metrics look like? (`list` is the same output) |
175
- | `codex-multi-auth check` | Do live health probes against my saved accounts succeed? |
176
-
177
- ### Daily use
178
-
179
- | Command | What it answers |
180
- | --- | --- |
181
- | `codex-multi-auth list` | Alias of `status` — full account/runtime dump |
182
- | `codex-multi-auth switch <index>` | How do I pin a different saved account for runtime routing? |
183
- | `codex-multi-auth unpin` | How do I clear a manual pin and resume hybrid rotation? |
184
- | `codex-multi-auth workspace <account> [workspace]` | How do I list or set an account's active workspace? |
185
- | `codex-multi-auth best --live` | How do I switch to the forecast-best account (clears any pin)? |
186
- | `codex-multi-auth-codex --account <index\|email\|id>` | How do I force one account for a single wrapper session without changing my default? |
187
- | `codex-multi-auth forecast --live` | Which account looks best for the next session? |
188
-
189
- ### Repair
190
-
191
- | Command | What it answers |
192
- | --- | --- |
193
- | `codex-multi-auth verify-flagged` | Can any previously flagged account be restored? |
194
- | `codex-multi-auth verify --paths` | Do my storage path chain and sandbox probes still pass self-test? |
195
- | `codex-multi-auth fix --dry-run` | What safe storage or account repairs are available? |
196
- | `codex-multi-auth doctor --fix` | Can the CLI diagnose and apply the safest fixes now? |
197
- | `codex-multi-auth uninstall` | Remove residual artifacts (run BEFORE `npm uninstall`; npm@7+ no longer fires `preuninstall`) |
198
-
199
- ### Advanced
200
-
201
- | Command | What it answers |
202
- | --- | --- |
203
- | `codex-multi-auth report --live --json` | How do I get the full machine-readable health report? |
204
- | `codex-multi-auth fix --live --model gpt-5.5` | How do I run live repair probes with a chosen model? |
205
- | `codex-multi-auth why-selected --json` | Which account does the selector pick now, and why? |
206
- | `codex-multi-auth usage --since 24h --by project` | What local usage has been recorded recently? |
207
- | `codex-multi-auth monitor --json` | What is the combined usage, policy, quota, runtime, and project state? |
208
- | `codex-multi-auth bridge token create --label local-client` | How do I create a local bridge bearer token? |
209
- | `codex-multi-auth integrations --kind python` | How do I generate local bridge client snippets? |
210
- | `codex-multi-auth rotation status` | Is live runtime account rotation enabled for forwarded Codex sessions? |
211
-
212
- ### Reliability behavior
213
-
214
- - whole-pool replay is disabled by default when every account is rate-limited
215
- - active requests use a bounded outbound request budget so one prompt cannot walk the full pool indefinitely
216
- - repeated cross-account 5xx bursts trigger a short cooldown instead of continuing aggressive rotation
217
- - proactive refresh is staggered to reduce background refresh bursts
218
- - `codex-multi-auth status` surfaces recent runtime request metrics in text output, and `codex-multi-auth report --json` exposes the machine-readable cooldown/runtime snapshot
219
-
220
- ---
221
-
222
- ## Dashboard Hotkeys
223
-
224
- ### Main dashboard
225
-
226
- | Key | Action |
227
- | --- | --- |
228
- | `Up` / `Down` | Move selection |
229
- | `Enter` | Select/open |
230
- | `1-9` | Quick switch |
231
- | `/` | Search |
232
- | `?` | Toggle help |
233
- | `Q` | Back/cancel |
234
-
235
- ### Account details
236
-
237
- | Key | Action |
238
- | --- | --- |
239
- | `S` | Set current account |
240
- | `R` | Refresh/re-login account |
241
- | `E` | Enable/disable account |
242
- | `D` | Delete account |
243
-
244
- ---
245
-
246
- ## Storage Paths
247
-
248
- | File | Default path |
249
- | --- | --- |
250
- | Settings | `~/.codex/multi-auth/settings.json` |
251
- | Accounts | `~/.codex/multi-auth/openai-codex-accounts.json` |
252
- | Flagged accounts | `~/.codex/multi-auth/openai-codex-flagged-accounts.json` |
253
- | Quota cache | `~/.codex/multi-auth/quota-cache.json` |
254
- | Runtime observability | `~/.codex/multi-auth/runtime-observability.json` |
255
- | Usage ledger | `~/.codex/multi-auth/usage/usage-ledger.jsonl` |
256
- | Account policies | `~/.codex/multi-auth/account-policies.json` |
257
- | Routing profiles | `~/.codex/multi-auth/routing-profiles.json` |
258
- | Budget guards | `~/.codex/multi-auth/budget-guards.json` |
259
- | Local client tokens | `~/.codex/multi-auth/local-client-tokens.json` |
260
- | Runtime app helper status | `~/.codex/multi-auth/runtime-rotation-app-helper.json` |
261
- | Persistent app bind state/logs | `~/.codex/multi-auth/app-bind/` |
262
- | Logs | `~/.codex/multi-auth/logs/codex-plugin/` |
263
- | Per-project accounts | `~/.codex/multi-auth/projects/<project-key>/openai-codex-accounts.json` |
264
-
265
- Override root with `CODEX_MULTI_AUTH_DIR=<path>`.
266
-
267
- ---
268
-
269
- ## Configuration
270
-
271
- Primary config root:
272
- - `~/.codex/multi-auth/settings.json`
273
- - or `CODEX_MULTI_AUTH_DIR/settings.json` when custom root is set
274
-
275
- Selected runtime/environment overrides:
276
-
277
- | Variable | Effect |
278
- | --- | --- |
279
- | `CODEX_MULTI_AUTH_DIR` | Override settings/accounts root |
280
- | `CODEX_MULTI_AUTH_CONFIG_PATH` | Prefer this config file when it exists (also the save target when set) |
281
- | `CODEX_MODE=0/1` | Disable/enable Codex mode |
282
- | `CODEX_MULTI_AUTH_FORCE_ACCOUNT=<index\|email\|id>` | Force one account for a single `codex-multi-auth-codex` run (ephemeral; requires rotation proxy) |
283
- | `CODEX_MULTI_AUTH_BYPASS=1` | Skip multi-auth intercept and forward straight to official Codex |
284
- | `CODEX_MULTI_AUTH_RUNTIME_ROTATION_PROXY=0/1` | Opt out/in of live Responses proxy rotation for forwarded Codex CLI/app sessions |
285
- | `CODEX_MULTI_AUTH_APP_ROTATION_IDLE_MS=<ms>` | Override automatic Codex app helper idle shutdown |
286
- | `CODEX_MULTI_AUTH_APP_BIND_INSTALL=0/1` | Opt out/in of packaged Codex app bind self-heal on first CLI run or rotation enable |
287
- | `CODEX_MULTI_AUTH_APP_LAUNCHER_INSTALL=0/1` | Opt out/in of routing supported app shortcuts on first CLI run or rotation enable |
288
- | `CODEX_TUI_V2=0/1` | Disable/enable TUI v2 |
289
- | `CODEX_TUI_COLOR_PROFILE=truecolor\|ansi256\|ansi16` | TUI color profile |
290
- | `CODEX_TUI_GLYPHS=ascii\|unicode\|auto` | TUI glyph style |
291
- | `CODEX_AUTH_BACKGROUND_RESPONSES=0/1` | Opt in/out of stateful Responses `background: true` compatibility |
292
- | `CODEX_AUTH_FETCH_TIMEOUT_MS=<ms>` | Request timeout override |
293
- | `CODEX_AUTH_STREAM_STALL_TIMEOUT_MS=<ms>` | Stream stall timeout override |
294
-
295
- Validate config after changes:
296
-
297
- ```bash
298
- codex-multi-auth status
299
- codex-multi-auth check
300
- codex-multi-auth forecast --live
301
- ```
302
-
303
- Responses background mode stays opt-in. Enable `backgroundResponses` in settings or `CODEX_AUTH_BACKGROUND_RESPONSES=1` only for callers that intentionally send `background: true`, because those requests switch from stateless `store=false` routing to stateful `store=true`. See [docs/upgrade.md](docs/upgrade.md) for rollout guidance.
304
-
305
- Runtime rotation is enabled by default for request-bearing wrapper-launched Codex sessions. Package install scripts stay side-effect-free: npm postinstall only prints a short notice (and stays silent in CI or non-interactive installs). The first CLI run after an install self-heals supported packaged Codex app binds and user-level launcher routing when possible (recorded once in a `first-run-setup.json` marker under the multi-auth runtime root), while `codex-multi-auth rotation enable` remains the explicit repair command. `codex-multi-auth rotation disable` turns the setting off and removes the persistent app bind. Set `CODEX_MULTI_AUTH_RUNTIME_ROTATION_PROXY=0`, `CODEX_MULTI_AUTH_APP_BIND_INSTALL=0`, or `CODEX_MULTI_AUTH_APP_LAUNCHER_INSTALL=0` to opt out of the matching default behavior.
306
-
307
- Installed wrappers may perform a best-effort daily npm version check during normal forwarded Codex startup. When a newer package is detected, the wrapper only prints a manual notice on an interactive TTY or when `CODEX_MULTI_AUTH_DEBUG=1`: `npm install -g codex-multi-auth@latest`. It never runs npm install or update commands for you.
308
-
309
- ---
310
-
311
- ## Experimental Settings Highlights
312
-
313
- The Settings menu now includes an `Experimental` section for staged features:
314
-
315
- - preview-first sync into `oc-chatgpt-multi-auth`
316
- - named local pool backup export with filename prompt
317
- - refresh guard toggle and interval controls moved out of Backend Controls
318
-
319
- These flows are intentionally non-destructive by default: sync previews before apply, destination-only accounts are preserved, and backup filename collisions fail safely.
320
-
321
- ---
322
-
323
- ## Troubleshooting
324
-
325
- <details open>
326
- <summary><b>60-second recovery</b></summary>
327
-
328
- ```bash
329
- codex-multi-auth doctor --fix
330
- codex-multi-auth check
331
- codex-multi-auth forecast --live
332
- ```
333
-
334
- If still broken:
335
-
336
- ```bash
337
- codex-multi-auth login
338
- ```
339
-
340
- </details>
341
-
342
- <details>
343
- <summary><b>Common symptoms</b></summary>
344
-
345
- - `codex-multi-auth` unrecognized: run `where codex-multi-auth` or `which codex-multi-auth`, then follow `docs/troubleshooting.md` for install checks
346
- - Switch succeeds but wrong account appears active: run `codex-multi-auth switch <index>`, then restart session
347
- - Requests fail fast with a pool cooldown message: wait for the cooldown window or inspect `codex-multi-auth status`
348
- - Requests fail fast after repeated upstream 5xx errors: inspect `codex-multi-auth report --json` for runtime traffic and cooldown details
349
- - Storage cleanup fails with `EBUSY` / `EPERM` (Windows): run `codex-multi-auth doctor --fix` to retry, or manually remove `~/.codex/multi-auth/<project-key>/` and re-login
350
- - OAuth callback on port `1455` fails: free the port and re-run `codex-multi-auth login`
351
- - Login hangs in WSL, or installing in WSL breaks a working Windows install: Windows and WSL contend for callback port `1455`, and the browser opens on the Windows host either way — see [Windows and WSL side by side](docs/troubleshooting.md#windows-and-wsl-side-by-side), or use `codex-multi-auth login --device-auth`, which needs no callback port
352
- - Browser launch is blocked or you are in a headless shell: prefer `codex-multi-auth login --device-auth`; use `codex-multi-auth login --manual` or `CODEX_AUTH_NO_BROWSER=1` only when you need the callback-paste fallback
353
- - `missing field id_token` / `token_expired` / `refresh_token_reused`: re-login affected account
354
-
355
- </details>
356
-
357
- <details>
358
- <summary><b>Diagnostics pack</b></summary>
359
-
360
- ```bash
361
- codex-multi-auth list
362
- codex-multi-auth status
363
- codex-multi-auth check
364
- codex-multi-auth verify-flagged --json
365
- codex-multi-auth forecast --live
366
- codex-multi-auth fix --dry-run
367
- codex-multi-auth report --live --json
368
- codex-multi-auth doctor --json
369
- ```
370
-
371
- </details>
372
-
373
- ---
374
-
375
- ## Documentation
376
-
377
- - Docs portal: [docs/README.md](docs/README.md)
378
- - Getting started: [docs/getting-started.md](docs/getting-started.md)
379
- - Features: [docs/features.md](docs/features.md)
380
- - Configuration: [docs/configuration.md](docs/configuration.md)
381
- - Troubleshooting: [docs/troubleshooting.md](docs/troubleshooting.md)
382
- - Commands reference: [docs/reference/commands.md](docs/reference/commands.md)
383
- - Public API contract: [docs/reference/public-api.md](docs/reference/public-api.md)
384
- - Error contracts: [docs/reference/error-contracts.md](docs/reference/error-contracts.md)
385
- - Settings reference: [docs/reference/settings.md](docs/reference/settings.md)
386
- - Storage paths: [docs/reference/storage-paths.md](docs/reference/storage-paths.md)
387
- - Upgrade guide: [docs/upgrade.md](docs/upgrade.md)
388
- - Privacy: [docs/privacy.md](docs/privacy.md)
389
-
390
- ---
391
-
392
- ## Release Notes
393
-
394
- - Current stable: [docs/releases/v2.7.0.md](docs/releases/v2.7.0.md) — install via `npm i -g codex-multi-auth`
395
- - Previous stable: [docs/releases/v2.6.0.md](docs/releases/v2.6.0.md)
396
- - Previous stable: [docs/releases/v2.5.0.md](docs/releases/v2.5.0.md)
397
- - Previous stable: [docs/releases/v2.4.0.md](docs/releases/v2.4.0.md)
398
- - Previous stable: [docs/releases/v2.3.3.md](docs/releases/v2.3.3.md)
399
- - Previous stable: [docs/releases/v2.3.2.md](docs/releases/v2.3.2.md)
400
- - Previous stable: [docs/releases/v2.3.1.md](docs/releases/v2.3.1.md)
401
- - Previous stable: [docs/releases/v2.3.0.md](docs/releases/v2.3.0.md)
402
- - Previous stable: [docs/releases/v2.2.2.md](docs/releases/v2.2.2.md)
403
- - Previous stable: [docs/releases/v2.2.1.md](docs/releases/v2.2.1.md)
404
- - Previous stable: [docs/releases/v2.2.0.md](docs/releases/v2.2.0.md)
405
- - Previous stable: [docs/releases/v2.1.12.md](docs/releases/v2.1.12.md)
406
- - Earlier stable: [docs/releases/v2.1.11.md](docs/releases/v2.1.11.md)
407
- - Earlier stable: [docs/releases/v2.1.10.md](docs/releases/v2.1.10.md)
408
- - Earlier stable: [docs/releases/v2.1.8.md](docs/releases/v2.1.8.md)
409
- - Earlier stable: [docs/releases/v2.1.7.md](docs/releases/v2.1.7.md)
410
- - Earlier stable: [docs/releases/v2.1.6.md](docs/releases/v2.1.6.md)
411
- - Earlier stable: [docs/releases/v2.1.5.md](docs/releases/v2.1.5.md)
412
- - Earlier stable: [docs/releases/v2.1.4.md](docs/releases/v2.1.4.md)
413
- - Earlier stable: [docs/releases/v2.1.3.md](docs/releases/v2.1.3.md)
414
- - Earlier stable: [docs/releases/v2.1.2.md](docs/releases/v2.1.2.md)
415
- - Earlier stable: [docs/releases/v2.1.1.md](docs/releases/v2.1.1.md)
416
- - Earlier stable: [docs/releases/v2.1.0.md](docs/releases/v2.1.0.md)
417
- - Earlier stable: [docs/releases/v1.3.2.md](docs/releases/v1.3.2.md)
418
- - Stable archive: [docs/releases/v1.3.1.md](docs/releases/v1.3.1.md)
419
- - Full release archive: [docs/README.md#release-history](docs/README.md#release-history)
420
- - Archived prerelease: [docs/releases/v0.1.0-beta.0.md](docs/releases/v0.1.0-beta.0.md)
421
-
422
- ## License
423
-
424
- MIT License. See [LICENSE](LICENSE).
425
-
426
- <details>
427
- <summary><b>Legal</b></summary>
428
-
429
- - Not affiliated with OpenAI.
430
- - "ChatGPT", "Codex", and "OpenAI" are trademarks of OpenAI.
431
- - You assume responsibility for your own usage and compliance.
432
-
433
- </details>
1
+ # codex-multi-auth: multi-account OAuth for the official Codex CLI
2
+
3
+ [![npm version](https://img.shields.io/npm/v/codex-multi-auth.svg)](https://www.npmjs.com/package/codex-multi-auth)
4
+ [![npm downloads](https://img.shields.io/npm/dw/codex-multi-auth.svg)](https://www.npmjs.com/package/codex-multi-auth)
5
+ [![CI](https://github.com/ndycode/codex-multi-auth/actions/workflows/ci.yml/badge.svg)](https://github.com/ndycode/codex-multi-auth/actions/workflows/ci.yml)
6
+ [![MIT license](https://img.shields.io/npm/l/codex-multi-auth.svg)](LICENSE)
7
+
8
+ `codex-multi-auth` is a multi-account OAuth manager for the official `@openai/codex` CLI. It gives Codex CLI users explicit ChatGPT account login, account switching, health checks, local diagnostics, project-scoped storage, and default-on runtime Responses rotation without taking over the official `codex` binary. Use `codex-multi-auth ...` for account management, or `codex-multi-auth-codex ...` only when you intentionally want the optional forwarding wrapper.
9
+
10
+ Use it when you need a local Codex CLI multi-account workflow with visible account state, safer recovery commands, and a loopback-only runtime rotation proxy for request-bearing forwarded Codex sessions.
11
+
12
+ <img width="1270" height="729" alt="codex-multi-auth terminal dashboard for Codex CLI multi-account OAuth account status" src="https://github.com/user-attachments/assets/0cecb77e-a6d3-432a-ba48-3577db0c7093" />
13
+
14
+
15
+
16
+ > [!NOTE]
17
+ > Legacy scoped prerelease package `@ndycode/codex-multi-auth` is migration-only.
18
+ > Use `codex-multi-auth` for all new installs.
19
+
20
+ ## What You Get
21
+
22
+ - Codex CLI multi-account OAuth management with a dedicated `codex-multi-auth ...` command family
23
+ - Explicit ChatGPT account login, saved-account listing, account switching, health checks, and diagnostics
24
+ - Optional `codex-multi-auth-codex ...` forwarding wrapper for official Codex CLI commands when you choose wrapper-launched sessions
25
+ - Health-aware account selection, quota forecasting, automatic failover, and flagged-account recovery
26
+ - Project-scoped account storage under `~/.codex/multi-auth/projects/<project-key>/...` for repo-specific workflows
27
+ - Interactive terminal dashboard for account actions, settings, search, and hotkeys
28
+ - Forecast, report, fix, doctor, verify, monitor, and rotation commands for operational confidence
29
+ - Local usage ledger, budget guards, account policy controls, routing profiles, and model/account capability views
30
+ - Runtime counters, budget/cooldown state, and multi-auth probe visibility in `codex-multi-auth status` / `codex-multi-auth report`
31
+ - Default-on loopback Responses proxy for live account rotation inside forwarded Codex CLI/app sessions
32
+ - Optional loopback-only local bridge for `/health`, `/v1/models`, and `/v1/responses`, protected by hashed local client tokens
33
+ - Reversible packaged Codex app bind and user-level launcher routing helpers that do not patch official app binaries
34
+ - Session affinity, live account sync, proactive refresh, and preemptive quota deferral controls
35
+ - Codex-oriented request/prompt compatibility with strict runtime handling and documented error contracts
36
+ - Stable docs for install, configuration, troubleshooting, upgrade, public API, storage paths, and release notes
37
+
38
+ ---
39
+
40
+ ## Why Developers Use It
41
+
42
+ `codex-multi-auth` makes local Codex account state visible and recoverable. Instead of one opaque auth file, you get a named account pool, deterministic account switching, health-aware selection, JSON diagnostics for automation, and safe repair commands for stale or damaged local state. The architecture is designed for personal development workflows: credentials stay local, runtime rotation is loopback-only, and official Codex install paths keep owning the `codex` command.
43
+
44
+ ---
45
+
46
+ ## Current Architecture At A Glance
47
+
48
+ `codex-multi-auth` ships four global binaries:
49
+
50
+ | Binary | Purpose |
51
+ | --- | --- |
52
+ | `codex-multi-auth` | Primary account manager; accepts bare auth subcommands such as `login`, `status`, `switch`, `forecast`, and `rotation status` |
53
+ | `codex-multi-auth-codex` | Optional wrapper that handles `auth ...` locally and forwards every other command to the official Codex CLI |
54
+ | `mcodex` | Convenience launcher over `codex-multi-auth-codex` with optional `--monitor` and `--tmux` modes |
55
+ | `codex-multi-auth-app-launcher` | Optional desktop launcher helper for supported user-level shortcuts and wrapper apps |
56
+
57
+ The package does not publish a global `codex` binary. Keep `codex` owned by the official OpenAI install path. Use `codex-multi-auth-codex ...` or `mcodex ...` only when you intentionally want this package's forwarding wrapper.
58
+
59
+ ---
60
+
61
+ <details open>
62
+ <summary><b>Terms and Usage Notice</b></summary>
63
+
64
+ > [!CAUTION]
65
+ > This project uses OAuth account credentials and is intended for personal development use.
66
+ >
67
+ > By using this package, you acknowledge:
68
+ > - This is an independent open-source project, not an official OpenAI product
69
+ > - You are responsible for your own usage and policy compliance
70
+ > - For production/commercial workloads, use the OpenAI Platform API
71
+
72
+ </details>
73
+
74
+ ---
75
+
76
+ ## Installation
77
+
78
+ <details open>
79
+ <summary><b>For Humans</b></summary>
80
+
81
+ ### Option A: Standard install
82
+
83
+ ```bash
84
+ npm i -g codex-multi-auth
85
+ ```
86
+
87
+ ### Option B: Migrate from legacy scoped prerelease
88
+
89
+ ```bash
90
+ npm uninstall -g @ndycode/codex-multi-auth
91
+ npm i -g codex-multi-auth
92
+ ```
93
+
94
+ ### Option C: Verify wiring
95
+
96
+ `codex --version` confirms the official Codex CLI is reachable. `codex-multi-auth --version` confirms the installed manager package version. `codex-multi-auth-codex --version` is the optional forwarding wrapper entrypoint.
97
+
98
+ ```bash
99
+ codex --version
100
+ codex-multi-auth --version
101
+ codex-multi-auth status
102
+ ```
103
+
104
+ Any official install path is fine as long as `codex` is on `PATH`: `npm i -g @openai/codex`, `brew install --cask codex`, or an official release binary.
105
+
106
+ </details>
107
+
108
+ <details>
109
+ <summary><b>For LLM Agents</b></summary>
110
+
111
+ ### Step-by-step
112
+
113
+ 1. Install global package:
114
+ - `npm i -g codex-multi-auth`
115
+ 2. Run first login flow with `codex-multi-auth login`
116
+ 3. Validate state with `codex-multi-auth status` and `codex-multi-auth check`
117
+ 4. Confirm routing with `codex-multi-auth forecast --live`
118
+
119
+ ### Verification
120
+
121
+ ```bash
122
+ codex-multi-auth status
123
+ codex-multi-auth check
124
+ ```
125
+
126
+ </details>
127
+
128
+ ---
129
+
130
+ ## Quick Start
131
+
132
+ Install and sign in:
133
+
134
+ ```bash
135
+ npm i -g @openai/codex
136
+ npm i -g codex-multi-auth
137
+ codex-multi-auth login
138
+ ```
139
+
140
+ If you already installed the official native CLI via Homebrew or a release binary, you only need:
141
+
142
+ ```bash
143
+ npm i -g codex-multi-auth
144
+ codex-multi-auth login
145
+ ```
146
+
147
+ Verify the manager and the new account:
148
+
149
+ ```bash
150
+ codex-multi-auth status
151
+ codex-multi-auth check
152
+ ```
153
+
154
+ Use these next:
155
+
156
+ ```bash
157
+ codex-multi-auth list
158
+ codex-multi-auth switch 2
159
+ codex-multi-auth forecast --live
160
+ ```
161
+
162
+ If browser launch is blocked, use the alternate login paths in [docs/getting-started.md](docs/getting-started.md#alternate-login-paths).
163
+ For remote or headless shells, prefer `codex-multi-auth login --device-auth`.
164
+
165
+ ---
166
+
167
+ ## Command Toolkit
168
+
169
+ ### Start here
170
+
171
+ | Command | What it answers |
172
+ | --- | --- |
173
+ | `codex-multi-auth login` | How do I add or re-open the account menu? |
174
+ | `codex-multi-auth status` | What does my account pool, pin, and runtime metrics look like? (`list` is the same output) |
175
+ | `codex-multi-auth check` | Do live health probes against my saved accounts succeed? |
176
+
177
+ ### Daily use
178
+
179
+ | Command | What it answers |
180
+ | --- | --- |
181
+ | `codex-multi-auth list` | Alias of `status` — full account/runtime dump |
182
+ | `codex-multi-auth switch <index>` | How do I pin a different saved account for runtime routing? |
183
+ | `codex-multi-auth unpin` | How do I clear a manual pin and resume hybrid rotation? |
184
+ | `codex-multi-auth workspace <account> [workspace]` | How do I list or set an account's active workspace? |
185
+ | `codex-multi-auth best --live` | How do I switch to the forecast-best account (clears any pin)? |
186
+ | `codex-multi-auth-codex --account <index\|email\|id>` | How do I force one account for a single wrapper session without changing my default? |
187
+ | `codex-multi-auth forecast --live` | Which account looks best for the next session? |
188
+
189
+ ### Repair
190
+
191
+ | Command | What it answers |
192
+ | --- | --- |
193
+ | `codex-multi-auth verify-flagged` | Can any previously flagged account be restored? |
194
+ | `codex-multi-auth verify --paths` | Do my storage path chain and sandbox probes still pass self-test? |
195
+ | `codex-multi-auth fix --dry-run` | What safe storage or account repairs are available? |
196
+ | `codex-multi-auth doctor --fix` | Can the CLI diagnose and apply the safest fixes now? |
197
+ | `codex-multi-auth uninstall` | Remove residual artifacts (run BEFORE `npm uninstall`; npm@7+ no longer fires `preuninstall`) |
198
+
199
+ ### Advanced
200
+
201
+ | Command | What it answers |
202
+ | --- | --- |
203
+ | `codex-multi-auth report --live --json` | How do I get the full machine-readable health report? |
204
+ | `codex-multi-auth fix --live --model gpt-5.5` | How do I run live repair probes with a chosen model? |
205
+ | `codex-multi-auth why-selected --json` | Which account does the selector pick now, and why? |
206
+ | `codex-multi-auth usage --since 24h --by project` | What local usage has been recorded recently? |
207
+ | `codex-multi-auth monitor --json` | What is the combined usage, policy, quota, runtime, and project state? |
208
+ | `codex-multi-auth bridge token create --label local-client` | How do I create a local bridge bearer token? |
209
+ | `codex-multi-auth integrations --kind python` | How do I generate local bridge client snippets? |
210
+ | `codex-multi-auth rotation status` | Is live runtime account rotation enabled for forwarded Codex sessions? |
211
+
212
+ ### Reliability behavior
213
+
214
+ - whole-pool replay is disabled by default when every account is rate-limited
215
+ - active requests use a bounded outbound request budget so one prompt cannot walk the full pool indefinitely
216
+ - repeated cross-account 5xx bursts trigger a short cooldown instead of continuing aggressive rotation
217
+ - proactive refresh is staggered to reduce background refresh bursts
218
+ - `codex-multi-auth status` surfaces recent runtime request metrics in text output, and `codex-multi-auth report --json` exposes the machine-readable cooldown/runtime snapshot
219
+
220
+ ---
221
+
222
+ ## Dashboard Hotkeys
223
+
224
+ ### Main dashboard
225
+
226
+ | Key | Action |
227
+ | --- | --- |
228
+ | `Up` / `Down` | Move selection |
229
+ | `Enter` | Select/open |
230
+ | `1-9` | Quick switch |
231
+ | `/` | Search |
232
+ | `?` | Toggle help |
233
+ | `Q` | Back/cancel |
234
+
235
+ ### Account details
236
+
237
+ | Key | Action |
238
+ | --- | --- |
239
+ | `S` | Set current account |
240
+ | `R` | Refresh/re-login account |
241
+ | `E` | Enable/disable account |
242
+ | `D` | Delete account |
243
+
244
+ ---
245
+
246
+ ## Storage Paths
247
+
248
+ | File | Default path |
249
+ | --- | --- |
250
+ | Settings | `~/.codex/multi-auth/settings.json` |
251
+ | Accounts | `~/.codex/multi-auth/openai-codex-accounts.json` |
252
+ | Flagged accounts | `~/.codex/multi-auth/openai-codex-flagged-accounts.json` |
253
+ | Quota cache | `~/.codex/multi-auth/quota-cache.json` |
254
+ | Runtime observability | `~/.codex/multi-auth/runtime-observability.json` |
255
+ | Usage ledger | `~/.codex/multi-auth/usage/usage-ledger.jsonl` |
256
+ | Account policies | `~/.codex/multi-auth/account-policies.json` |
257
+ | Routing profiles | `~/.codex/multi-auth/routing-profiles.json` |
258
+ | Budget guards | `~/.codex/multi-auth/budget-guards.json` |
259
+ | Local client tokens | `~/.codex/multi-auth/local-client-tokens.json` |
260
+ | Runtime app helper status | `~/.codex/multi-auth/runtime-rotation-app-helper.json` |
261
+ | Persistent app bind state/logs | `~/.codex/multi-auth/app-bind/` |
262
+ | Logs | `~/.codex/multi-auth/logs/codex-plugin/` |
263
+ | Per-project accounts | `~/.codex/multi-auth/projects/<project-key>/openai-codex-accounts.json` |
264
+
265
+ Override root with `CODEX_MULTI_AUTH_DIR=<path>`.
266
+
267
+ ---
268
+
269
+ ## Configuration
270
+
271
+ Primary config root:
272
+ - `~/.codex/multi-auth/settings.json`
273
+ - or `CODEX_MULTI_AUTH_DIR/settings.json` when custom root is set
274
+
275
+ Selected runtime/environment overrides:
276
+
277
+ | Variable | Effect |
278
+ | --- | --- |
279
+ | `CODEX_MULTI_AUTH_DIR` | Override settings/accounts root |
280
+ | `CODEX_MULTI_AUTH_CONFIG_PATH` | Prefer this config file when it exists (also the save target when set) |
281
+ | `CODEX_MODE=0/1` | Disable/enable Codex mode |
282
+ | `CODEX_MULTI_AUTH_FORCE_ACCOUNT=<index\|email\|id>` | Force one account for a single `codex-multi-auth-codex` run (ephemeral; requires rotation proxy) |
283
+ | `CODEX_MULTI_AUTH_BYPASS=1` | Skip multi-auth intercept and forward straight to official Codex |
284
+ | `CODEX_MULTI_AUTH_RUNTIME_ROTATION_PROXY=0/1` | Opt out/in of live Responses proxy rotation for forwarded Codex CLI/app sessions |
285
+ | `CODEX_MULTI_AUTH_APP_ROTATION_IDLE_MS=<ms>` | Override automatic Codex app helper idle shutdown |
286
+ | `CODEX_MULTI_AUTH_APP_BIND_INSTALL=0/1` | Opt out/in of packaged Codex app bind self-heal on first CLI run or rotation enable |
287
+ | `CODEX_MULTI_AUTH_APP_LAUNCHER_INSTALL=0/1` | Opt out/in of routing supported app shortcuts on first CLI run or rotation enable |
288
+ | `CODEX_TUI_V2=0/1` | Disable/enable TUI v2 |
289
+ | `CODEX_TUI_COLOR_PROFILE=truecolor\|ansi256\|ansi16` | TUI color profile |
290
+ | `CODEX_TUI_GLYPHS=ascii\|unicode\|auto` | TUI glyph style |
291
+ | `CODEX_AUTH_BACKGROUND_RESPONSES=0/1` | Opt in/out of stateful Responses `background: true` compatibility |
292
+ | `CODEX_AUTH_FETCH_TIMEOUT_MS=<ms>` | Request timeout override |
293
+ | `CODEX_AUTH_STREAM_STALL_TIMEOUT_MS=<ms>` | Stream stall timeout override |
294
+
295
+ Validate config after changes:
296
+
297
+ ```bash
298
+ codex-multi-auth status
299
+ codex-multi-auth check
300
+ codex-multi-auth forecast --live
301
+ ```
302
+
303
+ Responses background mode stays opt-in. Enable `backgroundResponses` in settings or `CODEX_AUTH_BACKGROUND_RESPONSES=1` only for callers that intentionally send `background: true`, because those requests switch from stateless `store=false` routing to stateful `store=true`. See [docs/upgrade.md](docs/upgrade.md) for rollout guidance.
304
+
305
+ Runtime rotation is enabled by default for request-bearing wrapper-launched Codex sessions. Package install scripts stay side-effect-free: npm postinstall only prints a short notice (and stays silent in CI or non-interactive installs). The first CLI run after an install self-heals supported packaged Codex app binds and user-level launcher routing when possible (recorded once in a `first-run-setup.json` marker under the multi-auth runtime root), while `codex-multi-auth rotation enable` remains the explicit repair command. `codex-multi-auth rotation disable` turns the setting off and removes the persistent app bind. Set `CODEX_MULTI_AUTH_RUNTIME_ROTATION_PROXY=0`, `CODEX_MULTI_AUTH_APP_BIND_INSTALL=0`, or `CODEX_MULTI_AUTH_APP_LAUNCHER_INSTALL=0` to opt out of the matching default behavior.
306
+
307
+ Installed wrappers may perform a best-effort daily npm version check during normal forwarded Codex startup. When a newer package is detected, the wrapper only prints a manual notice on an interactive TTY or when `CODEX_MULTI_AUTH_DEBUG=1`: `npm install -g codex-multi-auth@latest`. It never runs npm install or update commands for you.
308
+
309
+ ---
310
+
311
+ ## Experimental Settings Highlights
312
+
313
+ The Settings menu now includes an `Experimental` section for staged features:
314
+
315
+ - preview-first sync into `oc-chatgpt-multi-auth`
316
+ - named local pool backup export with filename prompt
317
+ - refresh guard toggle and interval controls moved out of Backend Controls
318
+
319
+ These flows are intentionally non-destructive by default: sync previews before apply, destination-only accounts are preserved, and backup filename collisions fail safely.
320
+
321
+ ---
322
+
323
+ ## Troubleshooting
324
+
325
+ <details open>
326
+ <summary><b>60-second recovery</b></summary>
327
+
328
+ ```bash
329
+ codex-multi-auth doctor --fix
330
+ codex-multi-auth check
331
+ codex-multi-auth forecast --live
332
+ ```
333
+
334
+ If still broken:
335
+
336
+ ```bash
337
+ codex-multi-auth login
338
+ ```
339
+
340
+ </details>
341
+
342
+ <details>
343
+ <summary><b>Common symptoms</b></summary>
344
+
345
+ - `codex-multi-auth` unrecognized: run `where codex-multi-auth` or `which codex-multi-auth`, then follow `docs/troubleshooting.md` for install checks
346
+ - Switch succeeds but wrong account appears active: run `codex-multi-auth switch <index>`, then restart session
347
+ - Requests fail fast with a pool cooldown message: wait for the cooldown window or inspect `codex-multi-auth status`
348
+ - Requests fail fast after repeated upstream 5xx errors: inspect `codex-multi-auth report --json` for runtime traffic and cooldown details
349
+ - Storage cleanup fails with `EBUSY` / `EPERM` (Windows): run `codex-multi-auth doctor --fix` to retry, or manually remove `~/.codex/multi-auth/<project-key>/` and re-login
350
+ - OAuth callback on port `1455` fails: free the port and re-run `codex-multi-auth login`
351
+ - Login hangs in WSL, or installing in WSL breaks a working Windows install: Windows and WSL contend for callback port `1455`, and the browser opens on the Windows host either way — see [Windows and WSL side by side](docs/troubleshooting.md#windows-and-wsl-side-by-side), or use `codex-multi-auth login --device-auth`, which needs no callback port
352
+ - Browser launch is blocked or you are in a headless shell: prefer `codex-multi-auth login --device-auth`; use `codex-multi-auth login --manual` or `CODEX_AUTH_NO_BROWSER=1` only when you need the callback-paste fallback
353
+ - `missing field id_token` / `token_expired` / `refresh_token_reused`: re-login affected account
354
+
355
+ </details>
356
+
357
+ <details>
358
+ <summary><b>Diagnostics pack</b></summary>
359
+
360
+ ```bash
361
+ codex-multi-auth list
362
+ codex-multi-auth status
363
+ codex-multi-auth check
364
+ codex-multi-auth verify-flagged --json
365
+ codex-multi-auth forecast --live
366
+ codex-multi-auth fix --dry-run
367
+ codex-multi-auth report --live --json
368
+ codex-multi-auth doctor --json
369
+ ```
370
+
371
+ </details>
372
+
373
+ ---
374
+
375
+ ## Documentation
376
+
377
+ - Docs portal: [docs/README.md](docs/README.md)
378
+ - Getting started: [docs/getting-started.md](docs/getting-started.md)
379
+ - Features: [docs/features.md](docs/features.md)
380
+ - Configuration: [docs/configuration.md](docs/configuration.md)
381
+ - Troubleshooting: [docs/troubleshooting.md](docs/troubleshooting.md)
382
+ - Commands reference: [docs/reference/commands.md](docs/reference/commands.md)
383
+ - Public API contract: [docs/reference/public-api.md](docs/reference/public-api.md)
384
+ - Error contracts: [docs/reference/error-contracts.md](docs/reference/error-contracts.md)
385
+ - Settings reference: [docs/reference/settings.md](docs/reference/settings.md)
386
+ - Storage paths: [docs/reference/storage-paths.md](docs/reference/storage-paths.md)
387
+ - Upgrade guide: [docs/upgrade.md](docs/upgrade.md)
388
+ - Privacy: [docs/privacy.md](docs/privacy.md)
389
+
390
+ ---
391
+
392
+ ## Release Notes
393
+
394
+ - Current stable: [docs/releases/v2.8.0.md](docs/releases/v2.8.0.md) — install via `npm i -g codex-multi-auth`
395
+ - Previous stable: [docs/releases/v2.7.1.md](docs/releases/v2.7.1.md)
396
+ - Previous stable: [docs/releases/v2.7.0.md](docs/releases/v2.7.0.md)
397
+ - Previous stable: [docs/releases/v2.6.0.md](docs/releases/v2.6.0.md)
398
+ - Previous stable: [docs/releases/v2.5.0.md](docs/releases/v2.5.0.md)
399
+ - Previous stable: [docs/releases/v2.4.0.md](docs/releases/v2.4.0.md)
400
+ - Previous stable: [docs/releases/v2.3.3.md](docs/releases/v2.3.3.md)
401
+ - Previous stable: [docs/releases/v2.3.2.md](docs/releases/v2.3.2.md)
402
+ - Previous stable: [docs/releases/v2.3.1.md](docs/releases/v2.3.1.md)
403
+ - Previous stable: [docs/releases/v2.3.0.md](docs/releases/v2.3.0.md)
404
+ - Previous stable: [docs/releases/v2.2.2.md](docs/releases/v2.2.2.md)
405
+ - Previous stable: [docs/releases/v2.2.1.md](docs/releases/v2.2.1.md)
406
+ - Previous stable: [docs/releases/v2.2.0.md](docs/releases/v2.2.0.md)
407
+ - Previous stable: [docs/releases/v2.1.12.md](docs/releases/v2.1.12.md)
408
+ - Earlier stable: [docs/releases/v2.1.11.md](docs/releases/v2.1.11.md)
409
+ - Earlier stable: [docs/releases/v2.1.10.md](docs/releases/v2.1.10.md)
410
+ - Earlier stable: [docs/releases/v2.1.8.md](docs/releases/v2.1.8.md)
411
+ - Earlier stable: [docs/releases/v2.1.7.md](docs/releases/v2.1.7.md)
412
+ - Earlier stable: [docs/releases/v2.1.6.md](docs/releases/v2.1.6.md)
413
+ - Earlier stable: [docs/releases/v2.1.5.md](docs/releases/v2.1.5.md)
414
+ - Earlier stable: [docs/releases/v2.1.4.md](docs/releases/v2.1.4.md)
415
+ - Earlier stable: [docs/releases/v2.1.3.md](docs/releases/v2.1.3.md)
416
+ - Earlier stable: [docs/releases/v2.1.2.md](docs/releases/v2.1.2.md)
417
+ - Earlier stable: [docs/releases/v2.1.1.md](docs/releases/v2.1.1.md)
418
+ - Earlier stable: [docs/releases/v2.1.0.md](docs/releases/v2.1.0.md)
419
+ - Earlier stable: [docs/releases/v1.3.2.md](docs/releases/v1.3.2.md)
420
+ - Stable archive: [docs/releases/v1.3.1.md](docs/releases/v1.3.1.md)
421
+ - Full release archive: [docs/README.md#release-history](docs/README.md#release-history)
422
+ - Archived prerelease: [docs/releases/v0.1.0-beta.0.md](docs/releases/v0.1.0-beta.0.md)
423
+
424
+ ## License
425
+
426
+ MIT License. See [LICENSE](LICENSE).
427
+
428
+ <details>
429
+ <summary><b>Legal</b></summary>
430
+
431
+ - Not affiliated with OpenAI.
432
+ - "ChatGPT", "Codex", and "OpenAI" are trademarks of OpenAI.
433
+ - You assume responsibility for your own usage and compliance.
434
+
435
+ </details>