["Online Walkthrough"](https://bi.cool/project/m5vDU78/embed?bi-active-file=login_username.vue)
```javascript
WXAPI.login_username({
deviceId: '',
deviceName: '',
username: '',
pwd: ''
})
```
+ deviceId and deviceName are the current login device id and device name. They are required items and can be passed in at will. They are only used as login information records.
+ username username
+ pwd login password
```json
{
"code": 0,
"data": {
"uid": 1351478,
"openid": "om3AQ0YaRp3RZtFuZ1Wgk0OdQjvA",
"mobile": "1860000062",
"token": "83065b5e-9a75-4e64-8692-4f03eaa90348"
},
"msg": "success"
}
```
+ uid After successful login, return the user number
+ mobile is the current user’s mobile phone number
+ token is the token returned after the user logs in. Many subsequent user-related operations require the token to be operated.