Endpoint
Authentication
Works with both session cookie and API key auth. Any authenticated request — no specific capability required.Response
string
The user’s internal id.
string
The user’s email address.
string
Either
user or admin. Admin role bypasses tier gates and rate limits.string
One of
free, pro, business, enterprise, or a custom tier id.boolean
Whether the account is approved. New accounts go through a brief approval step before they can run workflows.
Use cases
- Pre-flight validation — call this before any expensive workflow run to confirm your key works without paying for a real execution.
- Tier-aware routing — branch your script depending on the tier (skip Business-only models if
user.tier === 'pro'). - CI smoke test — assert
user.approved === trueanduser.emailmatches the expected account before production deploys.
Example
Notes
- For richer identity (credit balance, top-up balance, business status, onboarding state) the session-only endpoint
/api/mereturns more fields. That endpoint requires a browser session cookie and rejects API keys. - A
401response means the key is missing, revoked, or pre-Phase-11 (seeLEGACY_KEY_RETIRED).