Skip to main content

Verify Code Login (verifyCodeSignIn)

The verifyCodeSignIn API allows players to log into LI PASS without a password by using an email or phone verification code.

Request parameters

ParametersTypeDescriptionNote
accountstringAccount
Email or phone number (phones currently not supported)
Required
account_typenumberAccount Type
1: Email
2: Phone number (currently not supported)
Required
phone_area_codestringPhone Area CodeRequired if account_type is 2
verify_codestringVerification CodeRequired
machine_check_typenumberThis field is temporarily unavailable, please ignore.
CAPTCHA type
3: Tencent CAPTCHA
Required when machine validation is enabled in Player Network
tencent_responsestringTencent Response
Convert to string, like: JSON.stringify({"appid":"xxx","ret":0, "ticket":"t030...ECE*","randstr":"@BHo"}).
Required when machine_check_type is 3

Request sample

accountApi.verifyCodeSignIn(
{
verify_code: '12345',
account: 'lhmtyn47025@chacuo.net',
account_type: 1,
}
).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: 1639143369,
msg: "Success",
ret: 0,
seq: "1638843369-0180225865-009373-0000156600",
token: "xxx==",
uid: "xxx",
}