Repository navigation
Official Sign in with ChatGPT plan usage and dynamic model discovery #3890
hrgarber
started this conversation in
Feature requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
I built and locally verified a prototype that updates Prime Agent’s
openai-codexintegration to use OpenAI’s official Sign in with ChatGPT plan-usage flow.This also addresses #3262 without maintaining a static list of account models.
What the prototype covers
GET https://api.openai.com/v1/models.visibility == "list"andsupported_in_api == true.POST https://api.openai.com/v1/responsesinference withstore: false.No new dependency is required.
Local verification
Using a ChatGPT subscription account, I verified:
gpt-6.1-terra;prime-agent model list terrashowed the dynamically discovered models;gpt-6.1-terra; andprime-agentcommand.Credential values, account identifiers, and local paths are not present in the implementation or fixtures.
Design question before a pull request
The existing provider also exposes WebSocket/WebSocket-cached transport settings and custom base URLs from its older ChatGPT backend integration. OpenAI’s SIWC documentation explicitly directs plan usage to the public Responses endpoint and away from ChatGPT
backend-api, but does not establish SIWC support for those compatibility surfaces.Before preparing a PR, I would appreciate maintainer direction on the intended boundary:
openai-codexprovider migrate entirely to the official path, with the old transport settings removed/deprecated?I read
CONTRIBUTING.mdand understand that unsolicited pull requests are automatically closed. Would a maintainer be interested in reviewing this approach and inviting a focused pull request once that compatibility boundary is agreed? I can provide the implementation, focused tests, complete sanitized validation results, ownership classification, and parity evidence.Update after independent review: I found OAuth-validation gaps in the prototype before preparing any PR, so I rolled back the local installation and am treating the prototype as not ready. The next revision will require cryptographic ID-token verification (signature, issuer, audience, expiry, and nonce), granted-scope validation, sanitized token errors, and explicit OAuth-error callback handling, with negative regression tests. I will not submit or recommend the implementation until those checks pass.
All reactions