Read the AI provider configuration
GET /admin/system/ai
Returns the provider list and default-provider selection.
Stored API keys are NOT included — each provider carries
api_key_set instead (#711). This endpoint gates on
system.config.read, which is deliberately weaker than the
system.ai.write needed to set a key; returning the key
here would have made the narrower write capability
meaningless.
Authorizations
Section titled “Authorizations ”Responses
Section titled “ Responses ”Current AI config
AI provider configuration. Persisted under the sysconfig key
ai. API keys are stored as plain strings for now (admin-
only table; never federated); a secrets-backend migration is
planned. Keys are write-only on this surface — see
providers[*].api_key / providers[*].api_key_set.
object
Picks the providers[*].id used when nothing else
specifies. Empty = no default (callers must choose, or
AI features stay disabled).
object
E.g. gpt-4o, claude-sonnet-4-6
Override for self-hosted / proxied endpoints.
Write-only. Provide to set or rotate this provider’s
API key; omit (or send an empty string) on PATCH to
keep the current value. The response NEVER echoes
this field — read api_key_set instead to check
whether one is on file. A stored credential has no
read-back workflow, so it is not returned to any
capability, system.admin included (#711).
True when an API key is currently stored for this provider. Set by the server on GET responses; ignored if sent on PATCH.
Per-provider inference defaults. Closed schema, for the same
reason as SSOProviderConfig (#718): a free-form map on a
provider record is where credentials end up, and the read path
cannot tell an unknown key holding a rate limit from one
holding a token. Every field here is a tuning knob; the
provider’s one credential is api_key, which is write-only.
object
Sampling temperature. Unset = the model’s own default.
Nucleus-sampling cutoff. Unset = the model’s own default.
Cap on generated tokens per request. 0 = no override.
Prepended to every request routed to this provider.
Per-request timeout. 0 = the client default.
Client-side requests-per-minute ceiling. 0 = unthrottled.
Authentication required, missing, or invalid
object
Human-readable error summary
Example
the request could not be completedExample
{ "error": "authentication required: sign in and retry with a valid session or API token"}Authenticated but missing required capabilities
object
Human-readable error summary
Example
the request could not be completed