[TOC=2]
## 获取验证码
~~~[api]
post:/smsCaptcha/acquire
*string:phone=15181474781#手机号
<<<
success
{
"code": 0,
"data": {
"expire": 10,//有效期 分钟
"length": 6,//验证码长度
"captcha": "146119"// 测试的验证码
}
}
<<<
error
{
"code": -1,
"msg": "手机号长度错误"
}
~~~
## 短信登录
~~~[api]
post:/login
*string:phone=15181474781#手机号
*string:sms_captcha=123456#短信验证码
<<<
success
{
"code": 0,
"data": {
"id": 1,
"title": "1",//门店名
"address": "1",//门店详细地址
"county_id": 1,//所在区域id
"name": "1",//店长姓名
"phone": "15181474781",//手机号
"status": true,//是否启用 true 启用 false 冻结
"service_id": 1,//服务项目id
"last_login_time": "2018-04-14 17:21:02",//最后一次登录时间
"create_time": "2018-04-14 17:00:25",//创建时间
"user_type": "store",//登录用户类型
"session_key": "PHPSESSID",
"session_value": "ka4ni3mv32g17a40t4l9oemf25"
}
}
<<<
error
{
"code": -1,
"msg": "手机号长度错误"
}
~~~
## 密码登录
>[info] 密码需要前端加密
~~~[api]
post:/loginPwd
*string:phone=15181474781#手机号
*string:password=123456#密码
<<<
success
{
"code": 0,
"data": {
"id": 1,
"title": "1",//门店名
"address": "1",//门店详细地址
"county_id": 1,//所在区域id
"name": "1",//店长姓名
"phone": "15181474781",//手机号
"status": true,//是否启用 true 启用 false 冻结
"service_id": 1,//服务项目id
"last_login_time": "2018-04-14 17:21:02",//最后一次登录时间
"create_time": "2018-04-14 17:00:25",//创建时间
"user_type": "store",//登录用户类型
"session_key": "PHPSESSID",
"session_value": "ka4ni3mv32g17a40t4l9oemf25"
}
}
<<<
error
{
"code": -1,
"msg": "手机号长度错误"
}
~~~
## 修改密码
>[info] 密码请加密
~~~[api]
post:/changePassword
*string:password=123456#原密码
*string:password_new=123456name#新密码
<<<
success
{
"code": 0
}
<<<
error
{
"code": -1,
"msg": "手机号长度错误"
}
~~~
## 找回密码
~~~[api]
post:/resetPassword
*string:phone=15181474781#手机号
*string:password=123456#新密码
*string:sms_captcha=123456#验证码
<<<
success
{
"code": 0
}
<<<
error
{
"code": -1,
"msg": "手机号长度错误"
}
~~~
## 更换手机
~~~[api]
post:/changePhone
*string:phone=15181474781#手机号
*string:sms_captcha=123456#验证码
<<<
{
"code": 0
}
<<<
error
{
"code": -1,
"msg": "手机号长度错误"
}
~~~
## 注销登录
~~~[api]
get:/logout
<<<
success
{
"code": 0
}
~~~
