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
| Parameters | Type | Description | Note |
|---|---|---|---|
| account | string | Account Email or phone number (phones currently not supported) | Required |
| account_type | number | Account Type 1: Email 2: Phone number (currently not supported) | Required |
| phone_area_code | string | Phone Area Code | Required if account_type is 2 |
| verify_code | string | Verification Code | Required |
| machine_check_type | number | This field is temporarily unavailable, please ignore. CAPTCHA type 3: Tencent CAPTCHA | Required when machine validation is enabled in Player Network |
| tencent_response | string | Tencent 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
| Parameters | Type | Description |
|---|---|---|
| ret | number | Return code 0: Request successful !=0: Request failed, refer to msg for detailed results |
| msg | string | Result Explanation |
| token | string | User authorization token |
| uid | string | LI PASS UID |
| seq | string | Data Stream Message Serial Number |
| expire | int64 | Token Expiration Time Unix Time |
Response sample
{
expire: 1639143369,
msg: "Success",
ret: 0,
seq: "1638843369-0180225865-009373-0000156600",
token: "xxx==",
uid: "xxx",
}