|
|
## 1、获取有货币的总数(获取mars点数)##
|
|
|
|
|
|
获取有货币的总数(method=app.yohocoin.total)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.total&uid=50030141&debug=XYZ
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"code": "20111130-152530",
|
|
|
"total": 3000
|
|
|
},
|
|
|
"md5": "cb2b1d4baa0c099ff12797655ebaa128",
|
|
|
"message": "yoho coin total"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 404,
|
|
|
"data": {},
|
|
|
"md5": "f4a7a490bb6666b005008d795ed14e5d",
|
|
|
"message": "uid为空!"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 2、收入mars点数##
|
|
|
|
|
|
收入mars点数(method=app.marspoint.acquire)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|num|int|否|100|0|mars点数|
|
|
|
|type|int|否|17或者18|0|地点签到:17,合格评价:18|
|
|
|
|marsId|String|否|123456789|0|关联合格评价的具体评价,关联地点签到的具体地点|
|
|
|
|pid|int|是|100|0|erp操作人员的uid|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.marspoint.acquire&debug=XYZ
|
|
|
|
|
|
入口参数body
|
|
|
```json
|
|
|
{
|
|
|
"uid": 50030199,
|
|
|
"num": 100,
|
|
|
"type": 18,
|
|
|
"marsId": 123456789,
|
|
|
"pid": 11111111
|
|
|
}
|
|
|
```
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"currency": "200",
|
|
|
"uid": 50030199
|
|
|
},
|
|
|
"md5": "a2f546011378a51fffc9f09e56ae6f22",
|
|
|
"message": "ok"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 400,
|
|
|
"message": "请先登录"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 402,
|
|
|
"message": "获取的mars点数不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 403,
|
|
|
"message": "type不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 405,
|
|
|
"message": "marsId不能为空"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 3、兑换mars点数##
|
|
|
|
|
|
兑换mars点数(method=app.marspoint.exchange)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|num|int|否|-100|0|mars点数|
|
|
|
|type|int|否|19、20或21|0|兑换实物:19,兑换话费:20,兑换电子券:21|
|
|
|
|orderCode|String|否|123456789|0|订单号|
|
|
|
|pid|int|是|100|0|erp操作人员的uid|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.marspoint.exchange&debug=XYZ
|
|
|
|
|
|
入口参数body
|
|
|
```json
|
|
|
{
|
|
|
"uid": 50030199,
|
|
|
"num": -150,
|
|
|
"type": 20,
|
|
|
"orderCode": 1234567890,
|
|
|
"pid": 11111111
|
|
|
}
|
|
|
```
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"currency": "200",
|
|
|
"uid": 50030199
|
|
|
},
|
|
|
"md5": "a2f546011378a51fffc9f09e56ae6f22",
|
|
|
"message": "ok"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 400,
|
|
|
"message": "请先登录"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 402,
|
|
|
"message": "获取的mars点数不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 403,
|
|
|
"message": "type不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 406,
|
|
|
"message": "orderCode不能为空"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 4、mars点数明细接口##
|
|
|
|
|
|
mars点数(method=app.yohocoin.lists)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|page|int|是|2|1|页数|
|
|
|
|limit|int|是|20|20|每页的记录数|
|
|
|
|queryType|int|是|0|0|0-所有;1-收入;2-支出|
|
|
|
|beginTime|String|是|2016-05-18|0|开始时间|
|
|
|
|endTime|String|是|2016-05-18|0|结束时间|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
有货币(mars points)明细:
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.lists&uid=50030147&debug=XYZ
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"coinlist": [
|
|
|
{
|
|
|
"date": "2015-12-31 00:39:46",
|
|
|
"key": "10",
|
|
|
"message": "原有YOHO币10个,初始化变更",
|
|
|
"num": 1000,
|
|
|
"type": 1,
|
|
|
"title": "原有YOHO币%s个,初始化变更"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "订单取消退还:订单123456789",
|
|
|
"num": 1000,
|
|
|
"type": 2,
|
|
|
"title": "订单取消退还:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "活动奖励",
|
|
|
"num": 1000,
|
|
|
"type": 3,
|
|
|
"title": "活动奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "充值",
|
|
|
"num": -1000,
|
|
|
"type": 4,
|
|
|
"title": "充值"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "签到奖励",
|
|
|
"num": 1000,
|
|
|
"type": 5,
|
|
|
"title": "签到奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "抽奖活动奖励",
|
|
|
"num": 1000,
|
|
|
"type": 6,
|
|
|
"title": "抽奖活动奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "调研问卷奖励",
|
|
|
"num": 1000,
|
|
|
"type": 7,
|
|
|
"title": "调研问卷奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "完善资料奖励",
|
|
|
"num": 1000,
|
|
|
"type": 8,
|
|
|
"title": "完善资料奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "下单使用:订单123456789",
|
|
|
"num": -1000,
|
|
|
"type": 9,
|
|
|
"title": "下单使用:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "退货退还:订单123456789",
|
|
|
"num": 10,
|
|
|
"type": 10,
|
|
|
"title": "退货退还:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "活动赠送:订单123456789",
|
|
|
"num": 500,
|
|
|
"type": 11,
|
|
|
"title": "活动赠送:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "抽奖使用",
|
|
|
"num": -50,
|
|
|
"type": 12,
|
|
|
"title": "抽奖使用"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "购买商品赠送:xxxx",
|
|
|
"num": -500,
|
|
|
"type": 13,
|
|
|
"title": "购买商品赠送:%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "晒单奖励:xxxxxx",
|
|
|
"num": 1000,
|
|
|
"type": 14,
|
|
|
"title": "购买商品赠送:%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "补差价:xxxxx",
|
|
|
"num": -50,
|
|
|
"type": 15,
|
|
|
"title": "补差价:%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "积分过期",
|
|
|
"num": -1000,
|
|
|
"type": 16,
|
|
|
"title": "积分过期"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "你今日已在\"costa咖啡奥体店\"完成签到",
|
|
|
"num": 1000,
|
|
|
"type": 17,
|
|
|
"title": "地点签到"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "xxx的酒吧可以看到黄浦江两边的超赞",
|
|
|
"num": 1000,
|
|
|
"type": 18,
|
|
|
"title": "合格评价"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "xxxxxxxxxx",
|
|
|
"num": -500,
|
|
|
"type": 19,
|
|
|
"title": "兑换实物"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "50元充值话费(中国移动/中国联通/中国电信)",
|
|
|
"num": -1000,
|
|
|
"type": 20,
|
|
|
"title": "兑换话费"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "xxxxxxxxx",
|
|
|
"num": -1000,
|
|
|
"type": 21,
|
|
|
"title": "兑换电子券"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "mars点数兑换失败",
|
|
|
"num": 1000,
|
|
|
"type": 22,
|
|
|
"title": "mars点数兑换失败"
|
|
|
}
|
|
|
],
|
|
|
"limit": 20,
|
|
|
"page": 1,
|
|
|
"page_total": 2,
|
|
|
"total": 2
|
|
|
},
|
|
|
"md5": "4d83a2697b11ba3faf4abf9133941502",
|
|
|
"message": "yoho coin list"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"coinlist": [
|
|
|
{
|
|
|
"date": "2016-05-20 11:30:32",
|
|
|
"message": "2016-03-16订单兑换失败,积分返还213415",
|
|
|
"num": 200,
|
|
|
"title": "mars点数兑换失败",
|
|
|
"type": 22
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:28:47",
|
|
|
"message": "兑换电子卷53415",
|
|
|
"num": -200,
|
|
|
"title": "兑换电子券",
|
|
|
"type": 21
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:28:03",
|
|
|
"message": "兑换话费2314",
|
|
|
"num": -50,
|
|
|
"title": "兑换话费",
|
|
|
"type": 20
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:27:13",
|
|
|
"message": "兑换实物624",
|
|
|
"num": -100,
|
|
|
"title": "兑换实物",
|
|
|
"type": 19
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:25:25",
|
|
|
"message": "2016-04-15在德吉完成签到5462",
|
|
|
"num": 300,
|
|
|
"title": "地点签到",
|
|
|
"type": 17
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:24:44",
|
|
|
"message": "2016-04-15在黄山完成签到5132214",
|
|
|
"num": 200,
|
|
|
"title": "地点签到",
|
|
|
"type": 17
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:23:08",
|
|
|
"message": "这是一条合格的评价214123",
|
|
|
"num": 100,
|
|
|
"title": "合格评价",
|
|
|
"type": 18
|
|
|
}
|
|
|
],
|
|
|
"limit": 20,
|
|
|
"page": 1,
|
|
|
"page_total": 7,
|
|
|
"total": 7
|
|
|
},
|
|
|
"md5": "bdda1cb138535afc516aa4245eaf8699",
|
|
|
"message": "yoho coin list"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 5、兑换失败返回被使用的mars点数##
|
|
|
|
|
|
兑换失败返回被使用的mars点数(method=app.marspoint.return)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|num|int|否|100|0|mars点数|
|
|
|
|type|int|否|22|0|mars点数兑换失败:22|
|
|
|
|orderCode|String|否|123456789|0|订单号|
|
|
|
|pid|int|是|100|0|erp操作人员的uid|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.marspoint.return&debug=XYZ
|
|
|
|
|
|
入口参数body
|
|
|
```json
|
|
|
{
|
|
|
"uid": 50030199,
|
|
|
"num": 150,
|
|
|
"type": 22,
|
|
|
"orderCode": 1234567890,
|
|
|
"pid": 11111111
|
|
|
}
|
|
|
```
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"currency": "200",
|
|
|
"uid": 50030199
|
|
|
},
|
|
|
"md5": "a2f546011378a51fffc9f09e56ae6f22",
|
|
|
"message": "ok"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 400,
|
|
|
"message": "请先登录"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 402,
|
|
|
"message": "获取的mars点数不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 403,
|
|
|
"message": "type不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 406,
|
|
|
"message": "orderCode不能为空"
|
|
|
}
|
|
|
## 1、获取有货币的总数(获取mars点数)##
|
|
|
|
|
|
获取有货币的总数(method=app.yohocoin.total)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.total&uid=50030141&debug=XYZ
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"code": "20111130-152530",
|
|
|
"total": 3000
|
|
|
},
|
|
|
"md5": "cb2b1d4baa0c099ff12797655ebaa128",
|
|
|
"message": "yoho coin total"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 404,
|
|
|
"data": {},
|
|
|
"md5": "f4a7a490bb6666b005008d795ed14e5d",
|
|
|
"message": "uid为空!"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 2、收入有货币##
|
|
|
|
|
|
收入mars点数(method=app.yohocoin.get)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|num|int|否|100|0|mars点数|
|
|
|
|type|int|否|17或者18|0|地点签到:17,合格评价:18|
|
|
|
|marsId|String|否|123456789|0|关联合格评价的具体评价,关联地点签到的具体地点|
|
|
|
|pid|int|是|100|0|erp操作人员的uid|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.get&debug=XYZ
|
|
|
|
|
|
入口参数body
|
|
|
```json
|
|
|
{
|
|
|
"uid": 50030199,
|
|
|
"num": 100,
|
|
|
"type": 18,
|
|
|
"marsId": 123456789,
|
|
|
"pid": 11111111
|
|
|
}
|
|
|
```
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"currency": "200",
|
|
|
"uid": 50030199
|
|
|
},
|
|
|
"md5": "a2f546011378a51fffc9f09e56ae6f22",
|
|
|
"message": "ok"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 400,
|
|
|
"message": "请先登录"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 402,
|
|
|
"message": "获取的有货币不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 403,
|
|
|
"message": "type不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 405,
|
|
|
"message": "marsId不能为空"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 3、兑换mars点数##
|
|
|
|
|
|
兑换mars点数(method=app.yohocoin.subtract)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|num|int|否|-100|0|mars点数|
|
|
|
|type|int|否|19、20或21|0|兑换实物:19,兑换话费:20,兑换电子券:21|
|
|
|
|orderCode|String|否|123456789|0|订单号|
|
|
|
|pid|int|是|100|0|erp操作人员的uid|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.subtract&debug=XYZ
|
|
|
|
|
|
入口参数body
|
|
|
```json
|
|
|
{
|
|
|
"uid": 50030199,
|
|
|
"num": -150,
|
|
|
"type": 20,
|
|
|
"orderCode": 1234567890,
|
|
|
"pid": 11111111
|
|
|
}
|
|
|
```
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"currency": "200",
|
|
|
"uid": 50030199
|
|
|
},
|
|
|
"md5": "a2f546011378a51fffc9f09e56ae6f22",
|
|
|
"message": "ok"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 400,
|
|
|
"message": "请先登录"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 402,
|
|
|
"message": "获取的有货币不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 403,
|
|
|
"message": "type不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 406,
|
|
|
"message": "orderCode不能为空"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 4、有货币明细接口##
|
|
|
|
|
|
mars点数(method=app.yohocoin.lists)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|page|int|是|2|1|页数|
|
|
|
|limit|int|是|20|20|每页的记录数|
|
|
|
|queryType|int|是|0|0|0-所有;1-收入;2-支出|
|
|
|
|beginTime|String|是|2016-05-18|0|开始时间|
|
|
|
|endTime|String|是|2016-05-18|0|结束时间|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
有货币(mars points)明细:
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.lists&uid=50030147&debug=XYZ
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"coinlist": [
|
|
|
{
|
|
|
"date": "2015-12-31 00:39:46",
|
|
|
"key": "10",
|
|
|
"message": "原有YOHO币10个,初始化变更",
|
|
|
"num": 1000,
|
|
|
"type": 1,
|
|
|
"title": "原有YOHO币%s个,初始化变更"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "订单取消退还:订单123456789",
|
|
|
"num": 1000,
|
|
|
"type": 2,
|
|
|
"title": "订单取消退还:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "活动奖励",
|
|
|
"num": 1000,
|
|
|
"type": 3,
|
|
|
"title": "活动奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "充值",
|
|
|
"num": -1000,
|
|
|
"type": 4,
|
|
|
"title": "充值"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "签到奖励",
|
|
|
"num": 1000,
|
|
|
"type": 5,
|
|
|
"title": "签到奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "抽奖活动奖励",
|
|
|
"num": 1000,
|
|
|
"type": 6,
|
|
|
"title": "抽奖活动奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "调研问卷奖励",
|
|
|
"num": 1000,
|
|
|
"type": 7,
|
|
|
"title": "调研问卷奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "完善资料奖励",
|
|
|
"num": 1000,
|
|
|
"type": 8,
|
|
|
"title": "完善资料奖励"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "下单使用:订单123456789",
|
|
|
"num": -1000,
|
|
|
"type": 9,
|
|
|
"title": "下单使用:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "退货退还:订单123456789",
|
|
|
"num": 10,
|
|
|
"type": 10,
|
|
|
"title": "退货退还:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "活动赠送:订单123456789",
|
|
|
"num": 500,
|
|
|
"type": 11,
|
|
|
"title": "活动赠送:订单%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "抽奖使用",
|
|
|
"num": -50,
|
|
|
"type": 12,
|
|
|
"title": "抽奖使用"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "购买商品赠送:xxxx",
|
|
|
"num": -500,
|
|
|
"type": 13,
|
|
|
"title": "购买商品赠送:%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "晒单奖励:xxxxxx",
|
|
|
"num": 1000,
|
|
|
"type": 14,
|
|
|
"title": "购买商品赠送:%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "补差价:xxxxx",
|
|
|
"num": -50,
|
|
|
"type": 15,
|
|
|
"title": "补差价:%s"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "积分过期",
|
|
|
"num": -1000,
|
|
|
"type": 16,
|
|
|
"title": "积分过期"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "你今日已在\"costa咖啡奥体店\"完成签到",
|
|
|
"num": 1000,
|
|
|
"type": 17,
|
|
|
"title": "地点签到"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "xxx的酒吧可以看到黄浦江两边的超赞",
|
|
|
"num": 1000,
|
|
|
"type": 18,
|
|
|
"title": "合格评价"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "xxxxxxxxxx",
|
|
|
"num": -500,
|
|
|
"type": 19,
|
|
|
"title": "兑换实物"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "50元充值话费(中国移动/中国联通/中国电信)",
|
|
|
"num": -1000,
|
|
|
"type": 20,
|
|
|
"title": "兑换话费"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "xxxxxxxxx",
|
|
|
"num": -1000,
|
|
|
"type": 21,
|
|
|
"title": "兑换电子券"
|
|
|
},
|
|
|
{
|
|
|
"date": "2015-12-21 19:18:40",
|
|
|
"key": "10",
|
|
|
"message": "mars点数兑换失败",
|
|
|
"num": 1000,
|
|
|
"type": 22,
|
|
|
"title": "mars点数兑换失败"
|
|
|
}
|
|
|
],
|
|
|
"limit": 20,
|
|
|
"page": 1,
|
|
|
"page_total": 2,
|
|
|
"total": 2
|
|
|
},
|
|
|
"md5": "4d83a2697b11ba3faf4abf9133941502",
|
|
|
"message": "yoho coin list"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"coinlist": [
|
|
|
{
|
|
|
"date": "2016-05-20 11:30:32",
|
|
|
"message": "2016-03-16订单兑换失败,积分返还213415",
|
|
|
"num": 200,
|
|
|
"title": "mars点数兑换失败",
|
|
|
"type": 22
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:28:47",
|
|
|
"message": "兑换电子卷53415",
|
|
|
"num": -200,
|
|
|
"title": "兑换电子券",
|
|
|
"type": 21
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:28:03",
|
|
|
"message": "兑换话费2314",
|
|
|
"num": -50,
|
|
|
"title": "兑换话费",
|
|
|
"type": 20
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:27:13",
|
|
|
"message": "兑换实物624",
|
|
|
"num": -100,
|
|
|
"title": "兑换实物",
|
|
|
"type": 19
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:25:25",
|
|
|
"message": "2016-04-15在德吉完成签到5462",
|
|
|
"num": 300,
|
|
|
"title": "地点签到",
|
|
|
"type": 17
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:24:44",
|
|
|
"message": "2016-04-15在黄山完成签到5132214",
|
|
|
"num": 200,
|
|
|
"title": "地点签到",
|
|
|
"type": 17
|
|
|
},
|
|
|
{
|
|
|
"date": "2016-05-20 11:23:08",
|
|
|
"message": "这是一条合格的评价214123",
|
|
|
"num": 100,
|
|
|
"title": "合格评价",
|
|
|
"type": 18
|
|
|
}
|
|
|
],
|
|
|
"limit": 20,
|
|
|
"page": 1,
|
|
|
"page_total": 7,
|
|
|
"total": 7
|
|
|
},
|
|
|
"md5": "bdda1cb138535afc516aa4245eaf8699",
|
|
|
"message": "yoho coin list"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
## 5、兑换失败返回被使用的有货币##
|
|
|
|
|
|
兑换失败返回被使用的mars点数(method=app.yohocoin.return)
|
|
|
#### 公共请求参数
|
|
|
| 参数名称 | 参数类型 | 长度 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|-----:|----:|
|
|
|
|client_secret|string|50|否|5ac68f20cb18efe154be||进入接口提供的参数加密信息|
|
|
|
|app_version|float|10|否|1||APP版本|
|
|
|
|os_version|string|20|否|Android4.4||系统版本+机器型号|
|
|
|
|client_type|string|20|否|iphone/android/ipad||手机型号(不区分大小写)|
|
|
|
|screen_size|string|20|否|800x900||(手机尺寸)|
|
|
|
|
|
|
#### 请求参数
|
|
|
| 参数名称 | 参数类型 | 可否为空 | 示例 | 默认值 | 备注 |
|
|
|
|:-------| -----:|-----:|-----:|-----:|----:|
|
|
|
|uid|int|否|213|0|用户id|
|
|
|
|num|int|否|100|0|mars点数|
|
|
|
|type|int|否|22|0|mars点数兑换失败:22|
|
|
|
|orderCode|String|否|123456789|0|订单号|
|
|
|
|pid|int|是|100|0|erp操作人员的uid|
|
|
|
|
|
|
注意,通用的头部没有列出。
|
|
|
请求示例
|
|
|
http://192.168.102.217:8080/gateway?method=app.yohocoin.return&debug=XYZ
|
|
|
|
|
|
入口参数body
|
|
|
```json
|
|
|
{
|
|
|
"uid": 50030199,
|
|
|
"num": 150,
|
|
|
"type": 22,
|
|
|
"orderCode": 1234567890,
|
|
|
"pid": 11111111
|
|
|
}
|
|
|
```
|
|
|
|
|
|
### 响应
|
|
|
code为200即为成功,否则是失败。
|
|
|
响应JSON格式如下所示:
|
|
|
```json
|
|
|
{
|
|
|
"alg": "SALT_MD5",
|
|
|
"code": 200,
|
|
|
"data": {
|
|
|
"currency": "200",
|
|
|
"uid": 50030199
|
|
|
},
|
|
|
"md5": "a2f546011378a51fffc9f09e56ae6f22",
|
|
|
"message": "ok"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 400,
|
|
|
"message": "请先登录"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 402,
|
|
|
"message": "获取的有货币不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 403,
|
|
|
"message": "type不合法"
|
|
|
}
|
|
|
```
|
|
|
|
|
|
```json
|
|
|
{
|
|
|
"code": 406,
|
|
|
"message": "orderCode不能为空"
|
|
|
}
|
|
|
``` |
|
|
\ No newline at end of file |
...
|
...
|
|