mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-24 00:52:24 +00:00
feat(chatgpt): list ChatGPT (OAuth) in the Add Model provider dropdown
The Add Model form reads its provider list from ``/public/providers/fields`` (served from ``public_endpoints/provider_create_fields.json``), not from the frontend ``Providers`` enum directly. Add a ChatGPT entry there with a single required ``api_key`` field pre-filled with ``oauth:`` so the admin's workflow is: 1. Credentials → Add Credential → ChatGPT (OAuth) → sign in → credential named ``my-chatgpt`` 2. Add Model → provider: ChatGPT (OAuth) → model name → api_key field shows ``oauth:`` placeholder + tooltip explaining the convention → admin types ``oauth:my-chatgpt`` → save At request time the ChatGPT responses transformation recognises the ``oauth:`` prefix and routes through ``DBAuthenticator`` for the stored credential. Copilot was already in the JSON so its Add Model flow already works. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
b22f988248
commit
a5225003a3
1 changed files with 18 additions and 0 deletions
|
|
@ -570,6 +570,24 @@
|
|||
],
|
||||
"default_model_placeholder": "gpt-3.5-turbo"
|
||||
},
|
||||
{
|
||||
"provider": "ChatGPT",
|
||||
"provider_display_name": "ChatGPT (OAuth)",
|
||||
"litellm_provider": "chatgpt",
|
||||
"credential_fields": [
|
||||
{
|
||||
"key": "api_key",
|
||||
"label": "OAuth credential reference",
|
||||
"placeholder": "oauth:my-chatgpt",
|
||||
"tooltip": "Reference a stored ChatGPT OAuth credential by name, prefixed with 'oauth:'. Create the credential first via Credentials \u2192 Add Credential \u2192 ChatGPT (OAuth).",
|
||||
"required": true,
|
||||
"field_type": "text",
|
||||
"options": null,
|
||||
"default_value": "oauth:"
|
||||
}
|
||||
],
|
||||
"default_model_placeholder": "gpt-5.3-codex"
|
||||
},
|
||||
{
|
||||
"provider": "CLARIFAI",
|
||||
"provider_display_name": "Clarifai",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue