For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Trust CenterStatusSupportGet a demoPlatform
DocumentationEvals API ReferenceIntegrations & OTELPlatform SettingsSelf-HostingGuidesChangelog
DocumentationEvals API ReferenceIntegrations & OTELPlatform SettingsSelf-HostingGuidesChangelog
  • Get Started
    • Introduction
    • Quickstart
    • Authentication
    • Data Models
    • API Conventions
  • Data Models
      • GETRetrieve Organization
      • PUTUpdate Organization
        • GETList Organization API Keys
        • GETGet Organization API Key
        • POSTCreate Organization API Key
        • PUTUpdate Organization API Key
        • DELRevoke Organization API Key
  • Evals
  • Legacy
LogoLogo
Trust CenterStatusSupportGet a demoPlatform
Data ModelsOrganizationAPI Keys

Update Organization API Key

PUT
https://api.confident-ai.com/v1/organization/api-keys/:apiKeyId
PUT
/v1/organization/api-keys/:apiKeyId
$curl -X PUT https://api.confident-ai.com/v1/organization/api-keys/1 \
> -H "CONFIDENT_API_KEY: <ORGANIZATION-API-KEY>" \
> -H "Content-Type: application/json" \
> -d '{
> "valid": false
>}'
200Updated
1{
2 "success": true,
3 "data": {
4 "apiKey": {
5 "id": 12,
6 "valid": false,
7 "value": "***************a1b2c3",
8 "created_at": "2024-12-04T23:00:00.000Z",
9 "name": "CI/CD key",
10 "lastUsed": "2024-12-05T10:15:00.000Z"
11 }
12 }
13}

Activates or deactivates an organization-scoped API key. A deactivated key is rejected on authentication.

Was this page helpful?
Previous

Revoke Organization API Key

Next
Built with

Path parameters

apiKeyIdintegerRequired
The unique identifier of the API key.

Headers

CONFIDENT_API_KEYstringRequired
The organization API key for your Confident AI organization.

Request

This endpoint expects an object.
validbooleanRequired

Set to false to deactivate the key, or true to reactivate it

Response

successboolean
Indicates if the request was successful
dataobject