Skip to main content

User Login

POST 

/auth/login

Main endpoint for user authentication. Typical Flow:

  1. The client sends a valid email and password
  2. The server verifies the credentials against the database
  3. If correct, it returns a JWT token and user information
  4. The token must be included in the Authorization header of subsequent requests Usage Examples:
  • Login from a web or mobile application
  • Authentication to access protected resources
  • Obtaining a token to consume other API endpoints Important Notes:
  • The password must be a minimum of 6 characters
  • The returned access token is valid for 24 hours
  • After 3 failed attempts, the account is temporarily locked for 15 minutes
  • The token must be sent in subsequent requests as: Authorization: Bearer {token} Common Error Codes:
  • 401: Invalid credentials or user not found
  • 423: Account locked due to multiple failed attempts
  • 403: User deactivated or lacking permissions

Request

Responses

Successful authentication