Authentication
After a successful authentication, the following headers must be included to register or update the user’s device:
- X-Device-Code: A unique identifier for the device.
- X-Device-Token: The Firebase device token used for push notifications.
- X-Device-Name: The name/model of the device.
- X-App-Version-Number: The version of the application.
- X-Os-Device: The operating system of the device (iOS, Android).
Header parameters
Brand-URLstringRequiredExample:
The brand URL of the request. This is used to identify the brand.
YOUR_BRAND_URL
Body
This is the model class for UserAuthentication.
usernamestring · min: 1RequiredExample:
This represents the username of the user.
john.doe
passwordstring · min: 1RequiredExample:
This represents the password of the user.
password
Responses
200
The request was successful.
application/json
429
The user has exceeded the rate limit.
application/json
701
The password incorrect.
application/json
704
The username not found.
application/json
post
POST /api/v1/users/auth HTTP/1.1
Host: protocol.jframework.io
Brand-URL: text
Content-Type: application/json
Accept: */*
Content-Length: 45
{
"username": "john.doe",
"password": "password"
}
{
"success": true,
"statusCode": 200,
"message": "The request was successful.",
"data": {
"id": "asdasdcwAqrNxIT0xQdkMvR",
"username": "user",
"emailAddress": "[email protected]",
"authKey": "8mgBXMwMchIWWlLmvEL9RasdasdcwAqrNxIT0xQdkMvRndmSjh4YmtOcjdZb2taUT09N1J5bVdzRDlUUWhhRFFwdlRhemk4ZDFuaFdHajYzVXlYLy9valkwYXpuQT0=",
"expiresIn": "0001-01-01T00:00:00"
},
"errors": []
}
Last updated
Was this helpful?