简要描述:
访问权限
接口URL:
http://api.zmengzhu.com/business/v1/discuss/list |
请求方式:
返回结果格式:
参数:
参数名 |
是否必须 |
类型 |
默认值 |
说明 |
ticket_id |
是 |
int |
0 |
活动id |
token |
是 |
int |
24566430 |
用户唯一token |
id |
否 |
int |
0 |
下拉刷新加载数据时,传递上一次请求最后一项问答数据的id |
is_new_reply |
否 |
int |
1 |
是否查询最新未读回复 0:否 1:是 |
offset |
否 |
int |
0 |
分页获取 |
limit |
否 |
int |
10 |
每页数量 |
返回示例:
响应成功JSON示例:
// 成功返回
{
"code": 200,
"msg": "ok",
"data": {
"unread": "0", // 用户未读的新回复数量
"list": [
{
"id": "56", // 问题id
"uid": "2006058", // 提问用户uid
"datetime": "2019-09-23 20:40:58", // 提问时间
"content": "这里是提问内容", // 提问内容
"is_anonymous": "0",
"replys": [], // 回复内容
"nickname": "江湖六少", // 提问者昵称
"avatar": "http://s1.dev.zmengzhu.com/upload/img/e4/8c/e48c82fe4be616a0c6ea53134995b767.jpeg" // 提问者头像
},
{
"id": "1",
"uid": "--",
"datetime": "2019-09-20 15:56:02",
"content": "测试提问内容",
"is_anonymous": "1",
"nickname": "游客",
"avatar": "http://s1.dev.zmengzhu.com/web/wap/img/default-avatar.jpg"
"replys": [
{
"id": "27", // 回复id
"nickname": "江湖六少", // 回复者昵称
"content": "1233456", // 回复内容
"avatar": "http://s1.dev.zmengzhu.com/upload/img/e4/8c/e48c82fe4be616a0c6ea53134995b767.jpeg", // 回复者头像
"created_at": "1569234990",
"datetime": "2019-09-23 18:36:30" // 回复时间
},
{
"id": "28",
"nickname": "江湖六少",
"content": "这里是回复内容4",
"avatar": "http://s1.dev.zmengzhu.com/upload/img/e4/8c/e48c82fe4be616a0c6ea53134995b767.jpeg",
"created_at": "1569239183",
"datetime": "2019-09-23 19:46:23"
},
{
"id": "29",
"nickname": "江湖六少",
"content": "这里是回复内容4",
"avatar": "http://s1.dev.zmengzhu.com/upload/img/e4/8c/e48c82fe4be616a0c6ea53134995b767.jpeg",
"created_at": "1569240469",
"datetime": "2019-09-23 20:07:49"
},
{
"id": "30",
"nickname": "江湖六少",
"content": "这里是回复内容4",
"avatar": "http://s1.dev.zmengzhu.com/upload/img/e4/8c/e48c82fe4be616a0c6ea53134995b767.jpeg",
"created_at": "1569240489",
"datetime": "2019-09-23 20:08:09"
},
{
"id": "31",
"nickname": "江湖六少",
"content": "这里是回复内容4",
"avatar": "http://s1.dev.zmengzhu.com/upload/img/e4/8c/e48c82fe4be616a0c6ea53134995b767.jpeg",
"created_at": "1569240503",
"datetime": "2019-09-23 20:08:23"
}
]
}
]
}
}
字段说明:
参数名 |
说明 |
code |
成功为200 |
msg |
成功返回ok |
unread |
用户未读的新回复数量 |
id |
问题id |
uid |
提问用户uid |
datetime |
提问时间 |
content |
提问内容 |
is_anonymous |
是否匿名 |
replys |
回复内容 |
nickname |
提问者昵称 |
avatar |
提问者头像 |
replys字段描述:
参数名 |
说明 |
id |
回复id |
nickname |
回复者昵称 |
content |
回复内容 |
avatar |
回复者头像 |
created_at |
创建时间 |
datetime |
回复时间 |
错误时返回:
{
"code": 20001,
"msg": "签名校验失败",
"data": {}
}