Skip to main content
Elimapi

Authentication API Reference

Summary

Elimapi supports two authentication methods. Every API request must include credentials in a header.

MethodHeaderUse caseSession management
Access Token (JWT)Authorization: Bearer <token>Applications with a user interfacePeriodic login, expiring token
API Keyx-api-key: <key>Server-to-server integrationNone, key is tied to your account

Step-by-step guide: Authenticating API requests

Authentication endpoints

EndpointMethodDescriptionAuth required
/v1/auth/loginPOSTLogin with email + password, returns access_token and refresh_tokenNo
/v1/auth/refreshPOSTRefresh the access token using the refresh token (authorization header)Yes
/v1/auth/change-passwordPOSTChange the password of the logged-in userYes
/v1/me/plan-statusGETView plan status: expiration, remaining quota, credit balanceYes

Login request body:

{
  "email": "[email protected]",
  "password": "password"
}

Login response: { user, access_token, expires_in, refresh_token }expires_in is the token expiration timestamp (ms).

Required headers

HeaderValue
Content-Typeapplication/json
Acceptapplication/json
Authorization or x-api-keyBearer <token> or <api_key>

Quotas & Limits

  • Subscription: If your plan (Free, Individual, Team, Enterprise) expires, API requests are rejected.
  • Usage Quota: Every successful request deducts from the monthly request total of your plan.
  • Credits: When the plan quota runs out, the system automatically deducts from your Credits balance (if any).
  • Rate Limit: API call speed limits are applied to keep the system stable.

Check your current limits via GET /v1/me/plan-status or the Dashboard.

Common error codes

ErrorMeaningHow to handle
401 UnauthorizedToken or API Key missing, wrong, or expiredCheck the Authorization or x-api-key header
403 ForbiddenAccount locked or insufficient permissionsCheck account status on the Dashboard
429 Too Many RequestsRate limit exceededReduce call frequency or upgrade your plan
400 Bad RequestQuota exhausted and no Credits leftUpgrade your plan or buy more Credits