Two credential types#
| Credential | Header | Use it for |
|---|---|---|
| API key | x-api-key: <key> | Server-side IP and email lookups. |
| Account access token | Authorization: Bearer <token> | Account, key management, plans and usage APIs; also accepted for lookups. |
| None | No credential | Health/readiness and the account sign-in/verification endpoints. |
Authenticate with an API key#
x-api-key: YOUR_API_KEY
Content-Type: application/json
Origin: https://app.example.comKeep keys out of public JavaScript, analytics events, screenshots and support messages. Configure caller-IP restrictions for your deployment where appropriate.
Authenticate an account session#
The account login operation accepts an email and password and returns an access token in data.accessToken. Use Authorization: Bearer for account-scoped operations. The schema includes an expiresIn field with an illustrative value of 900; use the returned expiry rather than treating the example as a permanent guarantee.
/auth/loginNo credential| Field | Validation |
|---|---|
email | Required string, email format. |
password | Required string, 1-72 characters for login. |
Prefer the customer portal for interactive account access. Do not persist your account password as an integration credential.
Account verification and recovery#
| Workflow | Operation | Important detail |
|---|---|---|
| Register | POST /auth/register | Name: 2-100 characters; password: 12-72 characters. |
| Verify email | POST /auth/verify-email | Six-digit single-use OTP. |
| Resend verification | POST /auth/verification/resend | Subject to throttling. |
| Reset password | POST /auth/forgot-password, POST /auth/reset-password | Reset link is documented as single-use with a 30-minute lifetime. |
| Change password | POST /auth/change-password | Bearer token required; login sessions are revoked. |
| Google sign-in | POST /auth/google | Accepts a Google ID token; linking an account uses a separate protected operation. |
See the API reference for operation-specific request validation and response statuses.
When authentication fails#
A 401 is an authentication problem. A documented origin denial on IP lookup is 403. Check active state, credential type, ownership and restrictions before retrying. Do not remove access controls simply to hide an authentication failure.