Login to the system
POST/auth/login
Authenticate user and receive JWT token
Request
- application/json
Body
required
emailemailrequired
Example:
[email protected]
passwordpasswordrequired
Example:
password123
Responses
- 200
- 400
- 401
- 403
- 404
- 409
- 422
Login successful
- application/json
- Schema
- Example (from schema)
Schema
tokenstring
Example:
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
Bad Request - Invalid input data
- application/json
- Schema
- Example (from schema)
Schema
messagestringrequired
Error message
descriptionstring
Detailed error description
codestring
Error code
{
"message": "Invalid input data",
"description": "The request data did not pass validation",
"code": "INVALID_INPUT"
}
Unauthorized - Invalid or missing authentication token
- application/json
- Schema
- Example (from schema)
Schema
messagestringrequired
Error message
descriptionstring
Detailed error description
codestring
Error code
{
"message": "Unauthorized",
"description": "Invalid, expired or missing bearer token",
"code": "UNAUTHORIZED"
}
Forbidden - Insufficient permissions
- application/json
- Schema
- Example (from schema)
Schema
messagestringrequired
Error message
descriptionstring
Detailed error description
codestring
Error code
{
"message": "Forbidden",
"description": "You don't have permission to access this resource",
"code": "FORBIDDEN"
}
Not Found - Resource not found
- application/json
- Schema
- Example (from schema)
Schema
messagestringrequired
Error message
descriptionstring
Detailed error description
codestring
Error code
{
"message": "Resource not found",
"description": "The requested resource could not be found",
"code": "NOT_FOUND"
}
Conflict - Resource already exists or state conflict
- application/json
- Schema
- Example (from schema)
Schema
messagestringrequired
Error message
descriptionstring
Detailed error description
codestring
Error code
{
"message": "Resource conflict",
"description": "The resource already exists or is in an invalid state",
"code": "CONFLICT"
}
Unprocessable Entity - Validation error
- application/json
- Schema
- Example (from schema)
Schema
messagestringrequired
Error message
descriptionstring
Detailed error description
codestring
Error code
{
"message": "Validation error",
"description": "The request data failed validation rules",
"code": "VALIDATION_ERROR"
}