Added a home page prompt for missing API keys of enterprise providers (#1056)

Co-authored-by: Thorsten Sommer <SommerEngineering@users.noreply.github.com>
This commit is contained in:
Dominic NeuburgandThorsten Sommer authored and GitHub committed 2026-10-19 09:12:12 +02:00
1 parent 1f8d72aa45
commit 7d35536c87
29 files changed
+920 -31

No files matched your search

@@ -172,6 +172,12 @@ CONFIG["LLM_PROVIDERS"] = {}
-- -- if this configuration is later withdrawn.
-- -- ["AllowUserProvidedAPIKey"] = true,
--
-- -- Optional: ask the user for their API key in a panel on the home page, as long as this
-- -- provider has none. All providers of this plugin which set this option share one panel
-- -- and receive the same key, so the user enters it once. Implies "AllowUserProvidedAPIKey".
-- -- Explain how to obtain the key in CONFIG["USER_API_KEY_PROMPT"], see below.
-- -- ["PromptForUserAPIKey"] = true,
--
-- ["Model"] = {
-- ["Id"] = "<the model ID>",
-- ["DisplayName"] = "<user-friendly name of the model>",
@@ -203,6 +209,10 @@ CONFIG["TRANSCRIPTION_PROVIDERS"] = {}
-- -- above: when both are set, the embedded key is ignored and a warning is logged.
-- -- ["AllowUserProvidedAPIKey"] = true,
--
-- -- Optional: ask the user for their API key on the home page, as long as this provider
-- -- has none (see LLM_PROVIDERS example for details). Implies "AllowUserProvidedAPIKey".
-- -- ["PromptForUserAPIKey"] = true,
--
-- -- Optional: Hugging Face inference provider. Only relevant for UsedLLMProvider = HUGGINGFACE.
-- -- Hugging Face transcribes audio through some of its inference providers only, so the choice
-- -- is narrower than for chatting. Allowed values are: DEEPINFRA and TOGETHER_AI. The automatic
@@ -249,6 +259,10 @@ CONFIG["EMBEDDING_PROVIDERS"] = {}
-- -- above: when both are set, the embedded key is ignored and a warning is logged.
-- -- ["AllowUserProvidedAPIKey"] = true,
--
-- -- Optional: ask the user for their API key on the home page, as long as this provider
-- -- has none (see LLM_PROVIDERS example for details). Implies "AllowUserProvidedAPIKey".
-- -- ["PromptForUserAPIKey"] = true,
--
-- -- Optional: Hugging Face inference provider. Only relevant for UsedLLMProvider = HUGGINGFACE.
-- -- Hugging Face serves embeddings through some of its inference providers only, so the choice
-- -- is narrower than for chatting. Allowed values are: DEEPINFRA and TOGETHER_AI. The automatic
@@ -1369,6 +1383,23 @@ CONFIG["INTRODUCTIONS"] = {}
-- ]===]
-- }
-- What AI Studio tells users in the panel on the home page which asks for their API key. It asks
-- as long as a provider of this plugin which sets "PromptForUserAPIKey" has no API key. AI Studio
-- checks the key the user enters with the first of these providers which can list its models,
-- and then stores it for all of them. A key the provider refuses is not stored. When no provider
-- can check the key, or the provider is out of reach, AI Studio stores the key with a warning.
-- Markdown is required, Title is optional. Without this table, AI Studio shows a generic request.
-- CONFIG["USER_API_KEY_PROMPT"] = {
-- ["Title"] = "Please add your API key",
-- ["Markdown"] = [===[
-- To use the AI models of your organization, you need a personal API key:
--
-- 1. Open [Open WebUI](https://example.org) and sign in.
-- 2. Click your profile picture, then "Settings" and "Account".
-- 3. Create an API key, copy it, and paste it below.
-- ]===]
-- }
-- Mandatory infos that users must explicitly accept before using AI Studio:
-- AI Studio asks users again when Version, Title, or Markdown change.
-- Changing Version additionally allows the UI to communicate that a new version is available.