Skip to main content
PATCH
/
v1
/
api-keys
/
{key_uuid}
Update Api Key
curl --request PATCH \
  --url https://api.example.com/v1/api-keys/{key_uuid} \
  --header 'Content-Type: application/json' \
  --data '
{
  "scopes": [
    "<string>"
  ],
  "allowed_sources": [
    "<string>"
  ],
  "is_active": true
}
'
{
  "data": {
    "uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "<string>",
    "key_prefix": "<string>",
    "scopes": [
      "<string>"
    ],
    "key_type": "<string>",
    "is_active": true,
    "created_at": "2023-11-07T05:31:56Z",
    "expires_at": "2023-11-07T05:31:56Z",
    "last_used_at": "2023-11-07T05:31:56Z",
    "allowed_sources": [
      "<string>"
    ]
  },
  "meta": {}
}

Path Parameters

key_uuid
string<uuid>
required

Body

application/json

PATCH /v1/api-keys/{uuid} — update mutable fields.

scopes
string[] | null

Replace scopes list

allowed_sources
string[] | null

Restrict to these sources (null = unrestricted)

is_active
boolean | null

Set to false to revoke

Response

Successful Response

data
APIKeyResponse · object
required

All endpoints other than creation — full key is never included.

meta
Meta · object