app 接口开发文档范例

    

Json格式返回数据实例:

免登录模式:

{"result":"success","info":[{"id":"222","name":"bomb","user_name":"\u76d1\u7ba1","email":"","mobile":"","address":"","img":"\/Uploads\/new-gallery-img.png","remark":"","create_time":"0","last_login_time":"1462932279","loginip":"192.168.1.13","status":"1","type":"6","sign":"","token":"dc9f571a","control":1}]}

 

正常登陆模式:

密码和用户名有错误

{"result":"failed","code":1}

 

 

密码和用户名验证无错误

{"result":"success","info":[{"id":"236","name":"chris","user_name":"\u6731\u6bc5\u65fc","email":"","mobile":"","address":"","img":"\/Uploads\/new-gallery-img.png","remark":"","create_time":"1463035560","last_login_time":"","loginip":"","status":"1","type":"5","sign":"","token":"e22d84d7","control":1}]}

 

 

其中 result是返回数据正确与否。info中包含了用户的id(递增id) name(用户名) user_name(用户昵称) email(邮箱) mobile(电话)address(地址) img (大图) remark(详情) create_time(创建时间) last_login_time(最近登陆) loginip(登陆ip) status(状态值) type(所属用户组) sign(暂无) token(识别码) control(工厂区分)

你可能感兴趣的:(thinkphp)