Current API key
Describes the key the request is signed with: its id and name — the same as in the
dashboard — its permissions, whether it is active, when it expires and its limits.
Use it to check a key before working with it: which API sections it opens, when it
expires and how much is left in its token pool (limits.tokens.quota). An empty
permissions list means the key has no Public API permissions: this endpoint works, the
other /api/public/* endpoints answer 403. AI API access does not depend on
permissions — it is the AI switch on the key in the dashboard.
The key secret and its hash are never returned.
Required key permission: none — any active key works.
Parameters
Values go straight into the request line, and the URL is built for you. Below are each parameter’s type, whether it is required, and its allowed values.
Possible responses
200The key the request is signed with.
The key the request is signed with.
{
"success": true,
"message": "string",
"data": {
"id": "string",
"name": "string",
"permissions": [
"string"
],
"is_active": true,
"expires_at": "string",
"limits": {
"requests": {
"per_minute": 1,
"per_hour": 1,
"per_day": 1
},
"tokens": {
"per_minute": 1,
"per_hour": 1,
"per_day": 1,
"per_month": 1,
"quota": {
"limit": 1,
"used": 1,
"remaining": 1
}
}
}
}
}Success flag. Branch on the HTTP status code instead: any 2xx response carries true here, while an error comes back in a different shape that need not contain this field at all.
A human-readable note in the account language. Fine to show to a user; do not parse it — the wording changes without notice and is not an error code.
datarequiredThe response payload.
PublicApiKeyPublicApiKey
The response payload.
Key ID — the same as in the dashboard key list.
Key name set when it was issued.
Key permissions — the same list as in the dashboard (orders.read, billing.read, * and so on). An empty list means no Public API permissions: this endpoint works, the other /api/public/* endpoints answer 403. AI API access does not depend on permissions.
The key is active. An inactive key never gets here — it receives 401, so the response always has true.
When the key expires (ISO 8601; in UTC unless X-Timezone is sent); null — it never expires.
limitsrequiredKey limits: request and token windows and a token pool with no time-based reset.
object
Key limits: request and token windows and a token pool with no time-based reset.
requestsrequiredHow many requests the key may make per window; null — the window is not limited.
object
How many requests the key may make per window; null — the window is not limited.
Requests per minute; null — unlimited.
Requests per hour; null — unlimited.
Requests per day; null — unlimited.
tokensrequiredHow many generation tokens the key may spend per window; null — the window is not limited.
object
How many generation tokens the key may spend per window; null — the window is not limited.
Tokens per minute; null — unlimited.
Tokens per hour; null — unlimited.
Tokens per day; null — unlimited.
Tokens per month; null — unlimited.
quotarequiredA token pool with no time-based reset, granted by an administrator. Once it runs out, generation answers 429 token_quota_exceeded.
object
A token pool with no time-based reset, granted by an administrator. Once it runs out, generation answers 429 token_quota_exceeded.
Pool size; null — there is no pool and it does not limit the key.
How many pool tokens are already spent.
How many pool tokens are left; null — there is no pool.
401The key is missing, unknown, disabled or expired.
The key is missing, unknown, disabled or expired.
{
"success": false,
"message": "API key is missing. Provide it in the X-API-KEY header.",
"data": null
}Always false in error responses.
Error text in the key's language (set through the X-Locale header).
Always null when the request is rejected before processing.
Nearby
The same in words
Objects
This page for AI
API version 1.0.0