API keys
The keys of your organization. Read only; create, roll and revoke keys in HQ.
List API keys
/v1/api_keysapi_keys:readEvery key of the organization, newest first. Metadata only, never a secret.
limitintegerHow many objects to return, 1 to 100. Default 20.
starting_afterstringReturn objects older than this id (the next page).
ending_beforestringReturn objects newer than this id (the previous page).
statusstringOnly active or only revoked keys. One of
active,revoked.
HQ-Versionstring (date)A dated API version. Defaults to the version the key was created with.
HQ-AccountstringAgency keys only: the slug of the client organization this request acts for. Required with an agency key, refused with
400 invalid_requeston any other credential. A slug that is not one of your agency's current clients is404 not_found. An agency key is limited to 600 requests a minute per key on EACH API server (the cap is per replica), plus its own budget per client (limit_scope: agency_client), separate from the client's own keys.
Returns a list of ApiKey objects.
200A page of keys.
OtherAn RFC 9457 problem.
Revoke the calling key
/v1/api_keys/currentThe key making this request revokes itself, at once. Use it the moment a key leaks. Any key may call it; nothing else about keys can be changed through the API.
HQ-Versionstring (date)A dated API version. Defaults to the version the key was created with.
HQ-AccountstringAgency keys only: the slug of the client organization this request acts for. Required with an agency key, refused with
400 invalid_requeston any other credential. A slug that is not one of your agency's current clients is404 not_found. An agency key is limited to 600 requests a minute per key on EACH API server (the cap is per replica), plus its own budget per client (limit_scope: agency_client), separate from the client's own keys.
204Revoked. The next request with this key gets 401.
OtherAn RFC 9457 problem.
Get an API key
/v1/api_keys/{key_id}api_keys:readkey_idstringrequiredAn API key id.
HQ-Versionstring (date)A dated API version. Defaults to the version the key was created with.
HQ-AccountstringAgency keys only: the slug of the client organization this request acts for. Required with an agency key, refused with
400 invalid_requeston any other credential. A slug that is not one of your agency's current clients is404 not_found. An agency key is limited to 600 requests a minute per key on EACH API server (the cap is per replica), plus its own budget per client (limit_scope: agency_client), separate from the client's own keys.
Returns a ApiKey object.
200The key.
OtherAn RFC 9457 problem.
Objects
ApiKey
An API key. Never carries the key itself.
objectstringidstringnamestringkindstringOpen-ended; more credential kinds may be added.
prefixstringThe first characters of the key, for recognising it.
last4stringacting_userstring or nullrolestring or nullscopesarray of stringteam_scopestringOne of
all,selected.teamsarray of string or nullip_allowlistarray of string or nullNull when the key has none, and always null unless the caller is an owner or admin key for all teams.
api_versionstring (date)statusstringOpen-ended: active, expiring_rotation, revoked, expired.
created_atstring (date-time)created_bystring or nullexpires_atstring (date-time)last_used_atstring or nulllast_used_ipstring or nullAlways null unless the caller is an owner or admin key for all teams.
revoked_atstring or nullrevoked_reasonstring or nullrotated_fromstring or nullrotation_grace_untilstring or null