Authored by tanling

成长值文档

## 1、同步erp的成长值##
topic: user.syncGrowth
线上使用的mq:(user服务发aws,qq,所以麻烦监视两个云的消息)
rabbit_common = rabbitmq-common.yohoops.org:5672
rabbit_common_user = yoho
rabbit_common_password = yoho
body JSON格式如下所示:
```json
[
{
"uid": "50001678",
"growthValue": 10,
"type": "20",
"createTime": 1493796890,
"times":1
},
{
"uid": "50001678",
"growthValue": 15,
"type": "21",
"createTime": 1493796890,
"times":1
},
{
"uid": "50001678",
"growthValue": 16,
"type": "22",
"createTime": 1493796890,
"times":1
},
{
"uid": "50001678",
"growthValue": 107,
"type": "43",
"createTime": 1493796890,
"times":1
},
{
"uid": "50001678",
"growthValue": 17,
"type": "44",
"createTime": 1493796890,
"times":1
}
]
```
\ No newline at end of file
... ...
## 1、获取成长值vip信息##
获取成长值vip信息(method=app.passport.growthvip)
**请求参数**
| 参数名称 | 参数类型| 长度 |可否为空 |示例 |默认值 | 备注 |
| ---------|:--------:| --------:|-----:|------:|-----:|------:|
|client_secret |string | 50 |否 |5ac68f20cb18efe154be | |进入接口提供的参数加密信息|
|uid|int | | |1234556 | ||
|method|String | | |method=app.passport.growthvip | ||
注意,通用的头部没有列出。
请求示例http://localhost:8080/gateway?method=app.passport.growthvip&debug=XYZ&uid=50001678
code为200即为成功,否则是失败。 响应JSON格式如下所示:
```json
{
"alg": "SALT_MD5",
"code": 200,
"data":
{
"next_vip_level": "3",
"whitegold_start_time": 0,
"current_total_growth": "4000",
"current_vip_level": "2",
"upgrade_need_growth": "3000.0",
"next_vip_title": "白金会员",
"current_vip_title": "金卡会员",
"gold_start_time": 1463436016,
"sliver_start_time": 1454214833
},
"md5": "8b296f5ae1bfa3ff27be73dd83c52a30",
"message": "vip."
}
```
\ No newline at end of file
... ...
## 1、获取成长值流水##
获取成长值流水(method=app.passport.growthhistory
**请求参数**
| 参数名称 | 参数类型| 长度 |可否为空 |示例 |默认值 | 备注 |
| ---------|:--------:| --------:|-----:|------:|-----:|------:|
|client_secret |string | 50 |否 |5ac68f20cb18efe154be | |进入接口提供的参数加密信息|
|uid|int | | |1234556 | ||
|page|int | | |2 | ||
|method|String | | |method=app.passport.growthhistory | ||
注意,通用的头部没有列出。
请求示例http://localhost:8080/gateway?method=app.passport.growthhistory&debug=XYZ&uid=50001678&page=2
code为200即为成功,否则是失败。 响应JSON格式如下所示:
```json
{
"alg": "SALT_MD5",
"code": 200,
"data":
{
"currPage": 2,
"currTotal": 5,
"data":
[
{
"createTime": 1493796890,
"growthValue": 17,
"id": 52,
"type": 44,
"typeDesc": "晒单评价",
"uid": 50001678
},
{
"createTime": 1493796890,
"growthValue": 107,
"id": 50,
"type": 43,
"typeDesc": "登录",
"uid": 50001678
},
{
"createTime": 1493796890,
"growthValue": 16,
"id": 48,
"type": 22,
"typeDesc": "手机认证",
"uid": 50001678
},
{
"createTime": 1493796890,
"growthValue": 15,
"id": 46,
"type": 21,
"typeDesc": "邮箱认证",
"uid": 50001678
},
{
"createTime": 1493796890,
"growthValue": 10,
"id": 44,
"type": 20,
"typeDesc": "资料完善",
"uid": 50001678
}
],
"limit": 10,
"pageSize": 2,
"total": 15
},
"md5": "03093b33e414c0ab02aace085c5bc5f9",
"message": "vip."
}
```
\ No newline at end of file
... ...
## 1、触发erp成长值up##
topic: users.growthup
线上的mq:(user和sns均是发aws和qq,所以会监视两个云)
rabbit_common = rabbitmq-common.yohoops.org:5672
rabbit_common_user = yoho
rabbit_common_password = yoho
涉及到到的场景:
个人资料完善100%(个人资料包括头像、昵称、性别、生日、身高、体重)
app.passport.modifyHead
app.passport.modifyBase
---------------------------------------------------------------
http://localhost:8081/users/UserBaseRest/modifyUserBase
{"uid":"50001678","gender":"1","nick_name":"damianhua222222"}
body json格式如下:
---------------------------------------------------------------
{"createTime":1493793024,"type":20,"uid":50001432}
---------------------------------------------------------------
邮箱认证涉及到的场景:
PC上认证邮箱
手机认证涉及到的场景:
PC上手机认证
新用户手机注册
新的第三方(未注册过)提示绑定手机号码
老的第三方(注册过)提示绑定手机号码
个人中心中更换手机号码
http://localhost:8081/users/RegisterRest/register
{"profile":"15651035157","password":"yoho9646"}
{"createTime":1493793432,"type":22,"uid":50001674}
---------------------------------------------------------------
登录涉及到以下场景:
---------------------------------------------------------------
手机号码登录
http://localhost:8081/users/LoginRest/login
{"profile":"15651035157","password":"yoho9646"}
{"createTime":1493793024,"type":43,"uid":50001432}
---------------------------------------------------------------
第三方登录
手机号码快捷登录
... ...