Skip to content

Add account-bound authentication for analytics requests - #45742

Merged
copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/2ba0d96fb44936d12d13aedffc3f2e61aedea560
Sep 15, 2026
Merged

copyberry[bot] merged 1 commit into
mainfrom
copyberry/codex-internal-to-codex-oss/2ba0d96fb44936d12d13aedffc3f2e61aedea560

Conversation

@copyberry

@copyberry copyberry Bot commented Sep 15, 2026 •

Copy link
Copy Markdown

Add account-bound authentication for analytics requests

What changed

  • Add AnalyticsSession to load local ChatGPT credentials, bind requests to the initial account and user, and reject identity changes before requests or when accepting results.
  • Reload credentials and provide bounded recovery for unauthorized requests, using a backend client that disables redirects.
  • Add lazy TUI analytics session initialization, account display metadata, and plan-specific credit groupings for future dashboard integration.

Testing

Add regression tests for account and user changes, missing or API-key-only authentication, credential reloads, recovery after a 401 response, and session initialization after signing in.

## What changed

- Add `AnalyticsSession` to load local ChatGPT credentials, bind requests to the initial account and user, and reject identity changes before requests or when accepting results.
- Reload credentials and provide bounded recovery for unauthorized requests, using a backend client that disables redirects.
- Add lazy TUI analytics session initialization, account display metadata, and plan-specific credit groupings for future dashboard integration.

## Testing

Add regression tests for account and user changes, missing or API-key-only authentication, credential reloads, recovery after a `401` response, and session initialization after signing in.

GitOrigin-RevId: 2ba0d96fb44936d12d13aedffc3f2e61aedea560
@copyberry
copyberry Bot force-pushed the copyberry/codex-internal-to-codex-oss/2ba0d96fb44936d12d13aedffc3f2e61aedea560 branch from 964cf6e to db07815 Compare September 15, 2026 17:38
@copyberry
copyberry Bot merged commit db07815 into main Sep 15, 2026
1 check passed
@copyberry
copyberry Bot deleted the copyberry/codex-internal-to-codex-oss/2ba0d96fb44936d12d13aedffc3f2e61aedea560 branch September 15, 2026 17:38
@github-actions github-actions Bot locked and limited conversation to collaborators Sep 15, 2026

This branch was successfully deployed

1 active deployment
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants