Update a credential
Patches a credential. Only fields you send are changed. If you include
api_key or credentials the upstream secret is rotated.
Authorizations
JWT obtained through Barndoor's authentication flow. Pass the token
verbatim in Authorization: Bearer <token>. Use the Barndoor SDK's
loginInteractive() helper to obtain a token in scripts and notebooks.
Path Parameters
Credential UUID
Body
All fields are optional. Omit a field to leave the existing value
unchanged. Sending api_key or credentials rotates the stored
secret in the encrypted secret store.
The authentication scheme this credential or provider uses to talk to
the upstream model provider. Valid values depend on model_provider:
for OpenAI/Anthropic-style vendors this is typically api_key; for AWS
Bedrock it is one of aws_role, aws_keys, or bedrock_api_key; for
Google Vertex it is google_adc, google_service_account, or
google_impersonation; Anthropic OAuth passthrough uses oauth_passthrough.
"api_key"
Response
The updated credential
A reusable upstream credential, called Credentials in the portal UI. One credential can back multiple providers (e.g. a single OpenAI key used by several routes).
"4f8b2a3c-12ee-4d92-9c7b-e7d2f8b0a111"
The organization that owns this credential
"OpenAI Production"
Slug of the upstream model provider this resource speaks to
openai, anthropic, azure_openai, google_ai, bedrock, vertex, groq, together, mistral, cohere, xai, fireworks, perplexity, openrouter, deepseek, custom "openai"
The authentication scheme this credential or provider uses to talk to
the upstream model provider. Valid values depend on model_provider:
for OpenAI/Anthropic-style vendors this is typically api_key; for AWS
Bedrock it is one of aws_role, aws_keys, or bedrock_api_key; for
Google Vertex it is google_adc, google_service_account, or
google_impersonation; Anthropic OAuth passthrough uses oauth_passthrough.
"api_key"
Upstream base URL the credential points at. Defaults to the public provider URL but can be overridden for self-hosted or proxy setups.
"https://api.openai.com/v1"
Provider-specific settings that aren't sensitive (e.g. AWS region, Vertex project id, Azure API version). Sensitive credentials live in the encrypted secret store and are never returned by the API.
{
"region": "us-east-1",
"model_api_family": "anthropic_messages"
}