ProtectedaiProtected ReadonlyallowPreference holding the consent to use an API key found in the environment.
ProtecteddiscoveredThe models registered from the last discovery, as the provider reported them.
ProtecteddiscoveringProtected ReadonlydiscoveryProtectedenvEnsures the env-key consent prompt is shown at most once per session.
Protected ReadonlymanagerProtected ReadonlymessageProtected ReadonlymodelPreference holding an explicit model list that replaces discovery.
Protected ReadonlypreferenceProtectedprevProtected ReadonlyproviderProvider node id, e.g. anthropic. Matches the provider's node in the Models category.
Protected ReadonlyproviderHuman-readable provider name, e.g. Anthropic.
ProtecteddiscoveryProtectedmodelThe registered ids carry the openai/ prefix, while the provider node is openAiOfficial.
ProtectedapplyRegisters the discovered models and unregisters the ones that are no longer offered.
ProtectedcreateProtectedcreatePer-model capabilities are resolved by the backend from the model id; see openai-model-defaults.ts.
ProtecteddiscoverFetches what the provider offers and registers it, removing whatever disappeared.
ProtectedgetProtectedhandleProtectedhandleHandles a change to a preference of this provider that is not part of discovery itself.
ProtectedinitializeHands the provider's own configuration to its manager, before the first discovery run asks it anything. Also the place to register the models and listeners that discovery does not cover.
ProtectedisCalled when the application is started. The application shell is not attached yet when this method runs. Should return a promise if it runs asynchronously.
ProtectedpromptAsks the user once per session to confirm using an environment-provided API key. Confirming persists allowEnvironmentApiKeyPreference, which re-triggers discovery.
ProtectedqualifiedProtectedremoveProtectedrunProtectedupdateRe-applies the model descriptions of the configured custom endpoints.
ProtectedupdateRe-applies the descriptions of the already-discovered models, after a preference that feeds them changed.
The shared half of a provider that discovers its language models: it asks the provider what it offers, registers the answer, unregisters what disappeared, and reports the state of all of that to the ModelDiscoveryStatusService so the provider's page can show it.
A provider brings what only it can know: its id, its manager, the preferences it reads, how a discovered model becomes a model description, and the messages that name it. Everything a provider does beyond discovery (a custom endpoint, a proxy, its own retry settings) stays in the subclass, which hooks into initializeProvider and handlePreferenceChange.