Cubicle

Revoke an API key

DELETE
/v1/orgs/{org}/service-accounts/{account}/keys/{key}

Revokes the key at once: requests that use it fail with 401 unauthenticated from then on. A revoked key cannot be restored; create a new one instead. It no longer appears in List service accounts, and its name can be used again.

Only the organization's owners and admins may call this route, with a sign-in session; API keys are refused.

Authorization

session
headerAuthorizationBearer <token>

A sign-in session token (jvs_…) from the Dashboard, cubicle login or the device authorization flow.

Path Parameters

org*string

The organization's ID or name. An organization where the caller is not an active member returns 404.

account*string

The service account's ID, or its NAME without the organization (ci for acme/ci). A UUID is always read as an ID.

key*string

The API key's ID, a UUID.

Formatuuid

Response Body

The key is revoked.

Example Request
curl -X DELETE 'https://api.cubicle.sh/v1/orgs/acme/service-accounts/ci/keys/4b6d8f0a-2c4e-4a6b-8d0f-1a3c5e7b9d2f'
Example Response
Empty