For the complete documentation index, see llms.txt. This page is also available as Markdown.

Login

Authenticates a user and returns access/refresh tokens for API authorization. Supports optional 2FA verification.

Endpoint

POST/v2/auth/login

Link

Request

Headers

Key
Value
Required

Content-Type

application/json

Yes

Accept

application/json

Yes

Request Body (JSON)

Field
Type
Description
Required
Example

login

string

Email

Yes

"[email protected]"

password

string

Password

Yes

"SecurePass123!"

code

string

2FA code (if enabled).

No

"123456"

Credentials are provided by our team when you start testing (test version, stage) and finish testing (production environment).

Example Request Body:

json


Response (200 OK)

Returns authentication tokens and their expiration times.

Response Fields

Field
Type
Description
Example

accessToken

string

JWT token for API authorization. Valid for accessTtl seconds.

"eyJhbGci...xyz"

refreshToken

string

Long-lived token to renew accessToken when expired.

"eyJhbGci...abc"

UserId

string

Unique user identifier.

"5ff73da8-224e-44de-a235-2d7a76c3144c"

accessTtl

integer

Access token lifetime (seconds).

3600 (1 hour)

refreshTtl

integer

Refresh token lifetime (seconds).

2592000 (30 days)

Example Response:

Error Cases

  1. Invalid Credentials:

  2. Missing 2FA Code:

  3. Expired/Invalid 2FA Code:

  4. Account Locked:


Notes

  • Token Usage:

    • Include accessToken in the Authorization: Bearer <token> header for authenticated requests.

    • Use refreshToken to call /v2/auth/refresh when accessToken expires.

  • Security:

    • Passwords are case-sensitive.

    • refreshToken should be stored securely (e.g., HTTP-only cookie).

  • 2FA:

    • The code field is optional unless 2FA is enabled for the account.

    • If 2FA is required but not provided, the response will include "requires2fa": true.

Examples

Real request

Real response

Last updated