Skip to content
LeadityDocs

Account

Get account

Read the account's balance and what this key may do.

GETapi.leadity.io/v1/account
Scope readMCP tool get_account

Answers the account this key belongs to: its credit balance, any credits expiring within seven days, whether it is still restricted to the starter packages, and the scopes this key carries. Call it first to learn whether the key may write or spend.

Headers

Authorizationstringrequired

Bearer, a space, then an API key: Bearer lk_api_... An MCP key is refused here with wrong_key_kind.

Response

idstringrequired

The account's id.

emailstringrequired

The account's sign-in email address.

emailVerifiedbooleanrequired

Whether the email address is verified. Spending refuses email_not_verified until it is.

createdAtstringrequired

When the account was created. An ISO 8601 timestamp in UTC.

creditsintegerrequired

The spendable balance, in credits.

paywalledbooleanrequired

True while the account may order only the two starter packages and the paid upgrades refuse with paywall_required. Any purchase lifts it.

expiringSoonobject | nullrequired

Credits about to expire, or null when none expire within seven days. get_subscription has every expiry.

Show child attributes
creditsintegerrequired

Credits that expire within the next seven days, at most the balance.

firstExpiresAtstringrequired

When the first of them expires. An ISO 8601 timestamp in UTC.

keyobjectrequired

The key this call was made with.

Show child attributes
kindstringrequired

api for an HTTP API key, mcp for an MCP key. Each opens its own surface only.

One ofapimcp

displayPrefixstringrequired

The key's shown-again prefix, e.g. lk_api_Ab3d. Never enough to use it.

scopesstring[]required

What the key may do: read always, write and spend when ticked at creation. An operation outside them answers insufficient_scope.

One ofreadwritespend

Errors

Every refusal answers { error, message } with the status below. The full list is on the Errors page.

CodeStatusMeaningExtra fields
unauthorized401The API key is missing, malformed, revoked or expired.-
wrong_key_kind401This key opens the other surface: an API key works on the HTTP API, an MCP key on the MCP server.-
account_suspended403The account is suspended.-
email_not_verified403The account's email address is not verified yet.-
rate_limited429Too many requests. Wait for the Retry-After seconds and try again.retryAfterSeconds: The seconds to wait, the same number as the Retry-After header.
try_again503Leadity could not answer just now. Retry in a moment, with the same Idempotency-Key on a spending call.retryAfterSeconds: When a request with this Idempotency-Key is still being processed: the seconds to wait before retrying with the same key, as the Retry-After header says.
internal_error500Something failed on our side. Nothing was charged twice.body: On the MCP server, when Leadity answered in a shape the tool does not publish: that answer as it came.