找回密码
金色童年
找回密码
Method and URL Structure
| Method |
Resource URL |
| GET |
/account/reset_password_request/ |
Request Paramaters
| Name |
Descript |
Required |
Default |
| username |
用户名 |
YES |
|
| key |
图片验证码 |
YES |
|
| hashkey |
captcha hash key |
Yes |
|
cURL Example
curl http://localhost/account/reset_password_request/?username=15716098745&key=abcd&haskey=zcuq6z6pnwqirwuq49r9oe06tr5zxw6v
Response
{ "status": 0, "message": "", "reset_password": "true"}
更新密码
用收到的验证码设置信息密码,获取新的 token,其它登录token全部失效。
Method and URL Structure
| Method |
Resource URL |
| PUT |
/account/reset_password/ |
Request Data
| Name |
Description |
Required |
Default |
| username |
用户名 |
YES |
|
| password |
密码 |
YES |
|
| verification_code |
验证码 |
YES |
|
Request
{ "username": "13245678910", "password": "AT4Fvk3N", "verfication_code": "617346"}
cURL Example
curl -X PUT -H 'Content-Type: Application/json' --data '{....}' http://localhost/account/reset_password/
Reponse
{ "token": "9944b09199c62bcf9418ad846dd0e4bbdfc6ee4b"}