Update a BYOK provider credential
Update an existing bring-your-own-key (BYOK) provider credential by its id. Include the key field to rotate the raw provider API key in-place (the previous key material is overwritten). Use allowed_api_key_hashes to restrict the credential to specific OpenRouter API keys (null clears the restriction). Management key required.
Path parameters
The BYOK credential ID (UUID).
The BYOK credential ID (UUID).
Request body
Example request
{
"disabled": false,
"name": "Updated OpenAI Key"
}Response
BYOK credential updated successfully
Example response
{
"data": {
"allowed_api_key_hashes": null,
"allowed_models": null,
"allowed_user_ids": null,
"created_at": "2025-08-24T10:30:00Z",
"declared_zdr": null,
"disabled": false,
"id": "11111111-2222-3333-4444-555555555555",
"is_byok_only": false,
"is_fallback": false,
"is_required": false,
"label": "sk-...AbCd",
"name": "Updated OpenAI Key",
"provider": "openai",
"sort_order": 0,
"workspace_id": "550e8400-e29b-41d4-a716-446655440000"
}
}Changes
Changed in 37 of the 303 revisions of this API.43411
- ●
added the new
respanenum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ●
added the new
scaledownenum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ○
added the new optional request property
new-optional-request-property
- ○
added the required property
/////to the response with the statusresponse-required-property-added
- ○
- ○
added the non-success response with the status
response-non-success-status-added
- ○
- ●
added the new
unbiasedenum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ●
added the new
typesafeenum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ●
added the new
assemblyaienum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ●
added the new
amazon-bedrock/claude-on-awsenum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
added the new
anthropic/2enum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
added the new
claude-on-awsenum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ●
added the new
near-aienum value to the/////response property for the response statusresponse-property-enum-value-added
- ●
- ○
added the new optional request property
new-optional-request-property
- ○
added the new optional request property
new-optional-request-property
- ○
added the required property
/////to the response with the statusresponse-required-property-added
- ○
added the required property
/////to the response with the statusresponse-required-property-added
- ○