Skip to main content
Use this endpoint to exchange your Avalex staff credentials for a signed JWT access token. The token is valid for 7 days and must be included in the Authorization: Bearer header on every authenticated request. No API key or additional setup is required — a valid username and password are all you need to get started.
This is a public endpoint. No authentication header is required to call it.

Request Body

string
required
Your staff account username as registered in the Avalex Admin Portal.
string
required
Your account password.

Request Example

Response — 200 OK

A successful login returns a JWT token alongside a summary of the authenticated user’s identity and permissions.
string
A signed JWT access token. Include this value in the Authorization: Bearer <token> header on all subsequent authenticated requests. Tokens expire after 7 days.
object
Details about the currently authenticated user.

Response Example

Error Responses

Repeated failed login attempts may indicate a compromised credential. If you believe your account has been accessed without authorization, contact your Master Admin immediately to rotate your password.

Notes

This endpoint is also available as POST /staff/login, which is an aliased route with identical behavior. Both paths accept the same request body and return the same response schema.