积分兑换(Score)
积分日志接口[logs]【需登录】
积分日志接口
请求URL
http://www.yoursite.com/addons/shop/api.score/logs
请求方法
GET
请求参数
| Body参数名 | 类型 | 必需 | 描述 | 示例 e.g. |
|---|---|---|---|---|
| page | number | 是 | 分页页码 | 1 |
返回值
{
"code": 1,
"msg": "",
"time": "1618826108",
"data": {
"total": 100,
"per_page": 10,
"current_page": 1,
"last_page": 10,
"data": [
{
"id": 311,
"user_id": 1,
"score": 1,
"before": 1879,
"after": 1880,
"memo": "连续签到1天",
"createtime": "2021-04-19 17:47:43"
},
{
"id": 310,
"user_id": 1,
"score": 2,
"before": 1877,
"after": 1879,
"memo": "发布文章",
"createtime": "2021-04-15 11:35:15"
}
]
}
}积分兑换列表接口[exchangeList]【需登录】
积分兑换列表
请求URL
http://www.yoursite.com/addons/shop/api.score/exchangeList
请求方法
GET
请求参数
| Body参数名 | 类型 | 必需 | 描述 | 示例 e.g. |
|---|---|---|---|---|
| page | number | 是 | 分页页码 | 1 |
| type | string | 是 | 类型 | 1 |
| keyword | string | 否 | 关键词 | 电器 |
| orderby | string | 否 | 排序 | createtime,weigh |
| orderway | string | 否 | 排序 | desc,asc |
返回值
{
"code": 1,
"msg": "获取成功",
"time": "1618826321",
"data": {
"total": 9,
"per_page": 15,
"current_page": 1,
"last_page": 1,
"data": [
{
"id": 3,
"type": "reality",
"title": "40元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210303/a98848bf11310ede20ec8ef18a388b59.png",
"score": 5,
"stocks": 8,
"sales": 2,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952913,
"status": "normal",
"type_text": "Type reality",
"status_text": "正常"
},
{
"id": 4,
"type": "virtual",
"title": "50元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210303/9a2351ff5d6cc365937267a55ef40f2a.png",
"score": 100,
"stocks": 10,
"sales": 0,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952922,
"status": "normal",
"type_text": "Type virtual",
"status_text": "正常"
},
{
"id": 5,
"type": "virtual",
"title": "60元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210303/5871cf963ae2d5e2565b7a997db8500c.png",
"score": 100,
"stocks": 10,
"sales": 0,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952930,
"status": "normal",
"type_text": "Type virtual",
"status_text": "正常"
}
]
}
}积分兑换接口[exchange]【需登录】
积分兑换接口
请求URL
http://www.yoursite.com/addons/shop/api.score/exchange
请求方法
POST
请求参数
| Body参数名 | 类型 | 必需 | 描述 | 示例 e.g. |
|---|---|---|---|---|
| receiver | string | 是 | 姓名 | 阿狸 |
| mobile | string | 是 | 手机号码 | 18333333333 |
| address | string | 是 | 地址 | 深圳市南山区 |
| memo | string | 否 | 备注 | 备注 |
| type | string | 是 | 类型 | virtual=虚拟物品,reality=实物商品 |
| nums | number | 是 | 兑换数量 | 1 |
| exchange_id | number | 是 | 兑换物品id | 1 |
返回值
{
"code": 1,
"msg": "提交成功,等待管理员处理!",
"time": "1618826108",
"data": null
}我的兑换列表接口[myExchange]【需登录】
我的兑换列表接口
请求URL
http://www.yoursite.com/addons/shop/api.score/myExchange
请求方法
GET
请求参数
| Body参数名 | 类型 | 必需 | 描述 | 示例 e.g. |
|---|---|---|---|---|
| page | number | 是 | 分页页码 | 1 |
| type | string | 是 | 类型 | virtual=虚拟物品,reality=实物商品 |
返回值
{
"code": 1,
"msg": "获取成功",
"time": "1618827305",
"data": {
"total": 9,
"per_page": 15,
"current_page": 1,
"last_page": 1,
"data": [
{
"id": 3,
"type": "reality",
"title": "40元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210303/a98848bf11310ede20ec8ef18a388b59.png",
"score": 5,
"stocks": 8,
"sales": 2,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952913,
"status": "normal",
"type_text": "Type reality",
"status_text": "正常"
},
{
"id": 4,
"type": "virtual",
"title": "50元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210303/9a2351ff5d6cc365937267a55ef40f2a.png",
"score": 100,
"stocks": 10,
"sales": 0,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952922,
"status": "normal",
"type_text": "Type virtual",
"status_text": "正常"
},
{
"id": 5,
"type": "virtual",
"title": "60元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210303/5871cf963ae2d5e2565b7a997db8500c.png",
"score": 100,
"stocks": 10,
"sales": 0,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952930,
"status": "normal",
"type_text": "Type virtual",
"status_text": "正常"
},
{
"id": 6,
"type": "virtual",
"title": "70元充值卡",
"description": "兑换说明: 支持移动联通电信",
"image": "http://www.fa.com/uploads/2021/20210302/75240dfd83f77a5c421e675e374aa5fe.jpg",
"score": 100,
"stocks": 10,
"sales": 0,
"weigh": 1,
"createtime": 1617868002,
"updatetime": 1617952944,
"status": "normal",
"type_text": "Type virtual",
"status_text": "正常"
}
]
}
}
文档最后更新时间:2023-07-31 08:12:08
著作权归应用插件开发者所有,未经许可,禁止转载、复制此文档的任何内容。
未解决你的问题?请到问答社区「简单商城专区」反馈你遇到的问题