Upsert LLM Credential Binding
Bind (or replace) the caller's own API key for an LLM provider. The key is encrypted before storage. One binding exists per (caller, provider) pair - calling this again for the same provider overwrites the previously stored key rather than creating a duplicate.
Authorization
OAuth2AuthorizationCodeBearer AuthorizationBearer <token>
In: header
Path Parameters
provider_name*Provider Name
Query Parameters
verify_locally?Verify Locally
Default
trueRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Request body for binding an API key to a provider.
endpoint/modelName only apply to the "self-hosted" provider, which has no fixed registry endpoint/model - every other provider ignores them.
Response Body
application/json
application/json
curl -X PUT "https://example.com/v1/llm/credentials/string" \ -H "Content-Type: application/json" \ -d '{ "apiKey": "string" }'{ "provider": "string", "bound": true, "endpoint": "string", "modelName": "string"}{ "detail": [ { "loc": [ "string" ], "msg": "string", "type": "string" } ]}