Authentication

Authentication method of Labii API

Auth

POST {{base_url}}/accounts/auth/

Provide username and password to exchange a valid token.

Headers

NameTypeDescription

X-Forwarded-For

string

batch

Content-Type

string

application/json

Request Body

NameTypeDescription

password

string

login password

username

string

email of the account

{
    "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9",
    "user": {
        "sid":"xxx",
        "first_name":"xxx",
        "last_name":"xxx",
        "email":"xxx@labii.com"
    }
}

Forget Password

POST {{ base_url }}/accounts/forgetpassword/

Receive a email to reset the password.

Request Body

NameTypeDescription

email

string

email of the account

{tag: xxxxx}

Reset Password

POST {{ base_url }}/accounts/resetpassword/?tag={tag}

Change user password.

Query Parameters

NameTypeDescription

tag

string

The tag returned from forget password method

Request Body

NameTypeDescription

password

string

The new password

{}

Logout

GET {{base_url}}/accounts/logout/

Logout your account, invalid the token.

Headers

NameTypeDescription

token

string

user token

{}

Last updated