Skip to main content
POST
/
auth
/
login
Login
curl --request POST \
  --url https://api.engagefabric.com/auth/login \
  --header 'Content-Type: application/json' \
  --data '
{
  "email": "admin@example.com",
  "password": "SecurePassword123!"
}
'
{
  "accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "refreshToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
  "tokenType": "Bearer",
  "expiresIn": 86400,
  "user": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "email": "user@example.com",
    "name": "John Doe",
    "tenantId": "123e4567-e89b-12d3-a456-426614174000",
    "role": "ADMIN",
    "emailVerified": true
  }
}

Body

application/json
email
string
required

User email address

Example:

"admin@example.com"

password
string
required

User password

Minimum string length: 8
Example:

"SecurePassword123!"

Response

Login successful

accessToken
string
required

Access token (JWT)

Example:

"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."

refreshToken
string
required

Refresh token

Example:

"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."

tokenType
string
required

Token type

Example:

"Bearer"

expiresIn
number
required

Token expiration time in seconds

Example:

86400

user
object
required

User information

Example:
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"email": "user@example.com",
"name": "John Doe",
"tenantId": "123e4567-e89b-12d3-a456-426614174000",
"role": "ADMIN",
"emailVerified": true
}