Skip to main content

LI PASS Password Login

signIn API is used for players to log into LI PASS using an account and password.

Request parameters

ParametersTypeDescriptionNote
accountstringAccount
Email or phone number (phones currently not supported)
Required
account_typenumberAccount Type
1: Email
2: Phone Number (currently unsupported)
Required
passwordstringFor further information, see Password Rules.Required
phone_area_codestringPhone Area CodeRequired when account_type is 2
machine_check_typenumberCAPTCHA Type
3: Tencent Captcha
Required when machine validation is enabled in Player Network
tencent_responsestringTencent Captcha Return Value
Needs to be converted to string, e.g., JSON.stringify({"appid":"xxx","ret":0, "ticket":"t030...ECE*","randstr":"@BHo"}).
Required when machine_check_type is 3

Request sample

accountApi.signIn(
{
account: 'xxx@gmail.com',
account_type: 1,
password: 'xxx',
}
).then((res) => {
console.log(res);
});

Response parameters

ParametersTypeDescription
retnumberReturn code
0: Request successful
!=0: Request failed, refer to msg for detailed results
msgstringResult Explanation
tokenstringUser authorization token
uidstringLI PASS UID
seqstringData Stream Message Serial Number
expireint64Token Expiration Time
Unix Time

Response sample

{
expire: 1638490279
msg: "Success",
ret: 0,
seq: "1638190279-0180225865-002725-0000290492",
token: "xxx",
uid: "xxx",
}