fix: add api_key field to provider schema for inline key setup (#57)

The provider creation form only collected api_key_env (the env var
name) but not the actual key value. New providers were always created
as "unconfigured" because no key was stored.

Add an optional secret api_key field so the dashboard can pass the
key value during creation. The backend strips it from the TOML and
saves it to secrets.env instead.
This commit is contained in:
Evan authored and GitHub committed 2026-04-15 12:49:38 +09:00
1 parent 3d1bfb4240
commit 6439fb193c
1 file changed
+6
+6
View File
@@ -41,6 +41,12 @@ required = true
description = "Whether an API key is needed (false for local providers)"
example = true
[provider.fields.api_key]
type = "string"
required = false
description = "API key value (stored securely in secrets.env, not in the TOML file)"
secret = true
# --- Provider: nested [[models]] section ---
[provider.sections.models]