搜索记录列表
按用户或学校分页查历史搜索词,用于热搜榜和选品分析。
| 请求方式 | GET/POST |
|---|---|
| 接口路径 | /api/searchHistory/list |
| Content-Type | - |
| 鉴权 | X-Nideshop-Token |
请求参数
| 参数 | 类型 | 必填 | 位置 |
|---|---|---|---|
curPage | Integer | 否 | URL 参数 |
pageSize | Integer | 否 | URL 参数 |
search | String | 否 | URL 参数 |
schoolId | Integer | 否 | URL 参数 |
curl 调用
curl -s 'https://www.8shu8.com/api/searchHistory/list?curPage=1&pageSize=1&search=xxx&schoolId=1' \ -H 'X-Nideshop-Token: YOUR_LOGIN_TOKEN'
响应示例
data 为分页对象,业务数据在 records。
{
"code": 200,
"message": "操作成功",
"success": true,
"data": {
"records": [
{
"id": 1,
"keyword": "string",
"searchFrom": "string",
"addTime": 1,
"userId": 1,
"isDelete": true,
"isbn": "string",
"haveGet": 1,
"strTime": "string",
"schoolId": 1
}
],
"total": 0,
"size": 10,
"current": 1,
"pages": 0
}
}