api-keys

GET /v1/api-keys/current

Describe the API key making this call.

All api-keys endpoints

All developer docs →

Zinn®, our Viking, hammering at his anvil beside an API endpoint sending events to several listeners.

Authentication

Send an API key as a bearer token. This endpoint checks no specific permission, so any key for your organisation can call it.

This endpoint takes no organisation id. Your key already identifies the organisation it belongs to, and the response is scoped to it.

Try it

Replace anything in angle brackets with your own values, and the key placeholder with a key from your dashboard.

curl -X GET https://api.zinndigital.com/v1/api-keys/current \
  -H "Authorization: Bearer zdk_live_…"

Signed in? The API console in your dashboard fills in your real organisation id and your own key, and runs the request against the live API so you can see the actual response. Open this endpoint in the API console

Details

Returns the calling key's own metadata and permissions (scopes) and the organization it belongs to — never the secret or its hash. A billing-panel module's "Test connection" compares scopes with the permissions it needs and names the ones missing before a paid order fails on one (P7-212). Requires only a valid API key: no permission key, because a key granted nothing must still be able to learn that it was granted nothing, and what it reads is only its own grant. There is no id to pass, so it cannot read another key or another organization. A missing, unknown or revoked key is a 401. A signed-in person has no key on the request, so the answer is a 404. Throttled like every other key read.

Response

NameTypeRequiredWhat it is
idUuidYesUUIDv7 identifier — sortable by creation time.
namestringYes—
prefixstringYesThe key's public lookup id (the middle segment of the token).
scopesstring[]YesThe RBAC permission keys this key may exercise.
sandboxbooleanYesA sandbox (test-mode) key suppresses billing + provisioning.
last_used_atobjectNoWhen the key last authenticated a request; null if never used.
revoked_atobjectNoAlways null on a listed/fetched key — revoked keys are not returned.
created_atstringYes—
org_idUuidYesUUIDv7 identifier — sortable by creation time.

Errors this endpoint can return

401 · 404 · 429