API接口文档

账号登录

创建于 2022-02-22 / 最近更新于 2022-09-03 / 2065
字体: [默认] [大] [更大]

简要描述

账号登录

接口版本

版本号 制定人 制定日期 修订日期
1.0.0 Devil 2020-10-07

请求URL

user/login

请求方式

POST

公共参数

参数名 是否必须 类型 默认值 描述
application string web 请求应用、参考公共中详解
application_client_type string pc 请求客户端、参考公共中详解
token string token

请求参数

{
    "accounts": "qqqqqq",
    "pwd": "xxx***xxx",
    "verify": "rib5",
    "type": "username"
}
参数名 是否必须 类型 描述
accounts string 用户名/手机/邮箱
pwd string 密码
verify string 图片验证码
type string 登录类型(账号 username ,手机 sms,邮箱 email

返回示例

正确时返回

{
    "msg": "登录成功",
    "code": 0,
    "data": {
        "id": "1",
        "alipay_openid": "",
        "weixin_openid": "oB6US5SNOngn196qzb3lagEBTh6w",
        "weixin_unionid": "o1Ang5xo5tiJD-l7Y1kY7-hT6emk",
        "weixin_web_openid": "obfTQw7y972CqaHw2ohJ2PcETUw8",
        "baidu_openid": "",
        "toutiao_openid": "",
        "qq_openid": "",
        "qq_unionid": "",
        "status": "0",
        "token": "6c3d302754fe2d850b14a6775953135b",
        "username": "qqqqqq",
        "nickname": "qqqqqq",
        "mobile": "13222222222",
        "email": "xxx@qq.com",
        "gender": "0",
        "avatar": "https://thirdwx.qlogo.cn/mmopen/vi_32/Q0j4TwGTfTImwZehNyhFvMCGgSKxTVic2qkPaTz3vAu1bUBcMSic7ZJCicGnnwr2veI59UbXoH1bEHRV2nOCZ6ufw/132",
        "province": "",
        "city": "",
        "birthday": "0",
        "address": "",
        "integral": "4380",
        "locking_integral": "0",
        "referrer": "3",
        "plugins_distribution_level": "0",
        "plugins_user_level": "0",
        "is_delete_time": "0",
        "add_time": "1627535697",
        "upd_time": "1645487521",
        "add_time_text": "2021-07-29 13:14:57",
        "upd_time_text": "2022-02-22 07:52:01",
        "gender_text": "保密",
        "birthday_text": "",
        "mobile_security": "132***368",
        "email_security": "xxx***com",
        "user_name_view": "qqqqqq",
        "is_mandatory_bind_mobile": 0
    }
}

错误时返回

{
    "msg": "error",
    "code": -1,
    "data": []
}

返回参数说明 -> data

用户基础数据

备注

更多返回错误代码请看首页的错误代码描述

348 人点赞过