Skip to content

feat(core): add separate ChatGPT token-sharing OAuth method - #52147

Merged
rekram1-node merged 10 commits into
v2from
chatgpt-sharing-fork
Sep 29, 2026
Merged

rekram1-node merged 10 commits into
v2from
chatgpt-sharing-fork

Conversation

@rekram1-node

@rekram1-node rekram1-node commented Sep 29, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Preserve the existing Codex browser/headless methods and add chatgpt-token-sharing as a separate OAuth method under the same OpenAI provider.
  • Reuse the issued OAuth client ID, migrate identifiable token-sharing credentials in place, and cache account-specific model snapshots in plugin KV.
  • Complete sign-in without waiting for /v1/models; use catalog models until an asynchronous refresh completes, then check every 15 minutes. Preserve the model context windows as reported.
  • Add the jose dependency in packages/core/package.json and bun.lock, plus focused plugin and provider-error coverage.

Notes

  • The app UI is split into feat(app): show ChatGPT token-sharing guidance #52160. SQLite file permissions and token-sharing error messages are already on v2 via other PRs, so this branch is merged with current v2 and does not duplicate them.
  • The fallback allowlist contains ten IDs, but only matching models in the OpenAI catalog are copied. The inspected local catalog had five matching base models and no -fast entries.
  • Live sign-in and inference have not been verified.

Verification

  • bun test test/plugin/provider-chatgpt.test.ts test/plugin/provider-openai.test.ts test/session-error.test.ts test/database.test.ts (from packages/core)
  • bun run check

Register user-owned ChatGPT OAuth clients, verify ID tokens, and secure stored credentials.
Use account-visible Responses models with stateless HTTP streaming and refreshed model discovery.
Preserve provider diagnostics, tailor retry behavior, and show ChatGPT plan and usage guidance.
@rekram1-node rekram1-node changed the title feat(core): integrate ChatGPT token sharing feat(core): add separate ChatGPT token-sharing OAuth method Sep 29, 2026
@rekram1-node
rekram1-node merged commit 4d90907 into v2 Sep 29, 2026
9 of 10 checks passed
@rekram1-node
rekram1-node deleted the chatgpt-sharing-fork branch September 29, 2026 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant