Login User​
POST
/auth/login
Authenticate a user with email/username and password. Returns a session token for subsequent authenticated requests. Email is automatically converted to lowercase.
Request Body​
application/json
JSON
{
"email": "user@example.com",
"password": "SecurePass123!"
}
Responses​
Login successful - Returns user data and session information
application/json
JSON
{
"success": true,
"user": {
"id": "usr_123abc",
"email": "user@example.com",
"name": "John",
"last_name": "Doe",
"user_name": "johndoe",
"user_type": "customer",
"picture": "https://cdn.example.com/pic.jpg",
"phone": "+1234567890",
"is_verified": true,
"two_factor": false,
"created_at": "string",
"updated_at": "string"
},
"session_id": "ses_xyz789abc123",
"expires_at": "2025-12-15T10:00:00Z"
}