Skip to main content
PATCH
/
account
/
api
/
v1
/
organizations
/
{organization_id}
/
api-keys
/
{key_id}
Update API key
curl --request PATCH \
  --url https://www.closient.com/account/api/v1/organizations/{organization_id}/api-keys/{key_id} \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "metadata": {},
  "name": "<string>",
  "description": "<string>"
}
'
{
  "id": "<string>",
  "name": "<string>",
  "role": "manager",
  "created": "<string>",
  "metadata": {},
  "description": ""
}

Documentation Index

Fetch the complete documentation index at: https://docs.closient.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-API-Key
string
header
required

Path Parameters

organization_id
string
required

Organization ID.

key_id
string<shortuuid>
required

UUID of the API key to update.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$

Body

application/json
metadata
Metadata · object

Developer-attached key/value data. Send {} or null to clear. Empty-string values delete that key. Omitted keys are preserved.

name
string | null

New name for the API key.

Maximum string length: 255
description
string | null

New description for the API key.

Maximum string length: 255

Response

OK

id
string<shortuuid>
required

URL-safe 22-character shortuuid encoding of the row's UUID primary key. Stable across the row's lifetime; suitable for sharing in URLs, log lines, and external SDK clients. Accepted on input as either the shortuuid form or the canonical UUID form (xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx).

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
name
string
required

Key name.

role
enum<string>
required

Permission role for this key within the organization.

Available options:
manager,
editor,
readonly
created
string
required

ISO 8601 creation timestamp.

metadata
Metadata · object

Developer-attached key/value data attached to this object. Up to 50 keys; key max 40 chars, value max 500 chars.

description
string
default:""

Key description.