一叶之秋 826f5c4641 | 3 years ago | |
---|---|---|
DOCUMENTS | 3 years ago | |
config | 3 years ago | |
lock | 3 years ago | |
logs | 3 years ago | |
src | 3 years ago | |
tests | 3 years ago | |
README.md | 3 years ago |
#List
POST
/v1/setPlaceholderGuide
name | position | required | type | limit | description |
---|---|---|---|---|---|
content | body | true | string | * | 引导语内容 |
source | body | true | string | * | 平台 |
startTime | body | true | string | * | 开始时间 |
endTime | body | true | string | * | 结束时间 |
src | body | true | string | * | 请求来源 |
curl -X POST \
http://192.168.100.50:8000/v1/setPlaceholderGuide \
-H 'Content-Type: application/x-www-form-urlencoded' \
-H 'Host: pin-guide-ms.juejin.im' \
-d 'content=test&source=test&startTime=2018-06-05 08:27:06&endTime=2018-06-05 08:27:06&src=test'
{
"s": 1,
"m": "ok",
"d": {}
}
POST
/v1/getPlaceholderGuide
name | position | required | type | limit | description |
---|---|---|---|---|---|
pageNum | body | true | string | * | 页码 |
pageSize | body | true | string | * | 每页条数 |
src | body | true | string | * | 请求来源 |
curl -X POST \
http://192.168.100.50:8000/v1/getPlaceholderGuide \
-H 'Content-Type: application/x-www-form-urlencoded' \
-H 'Host: pin-guide-ms.juejin.im' \
-d 'pageNum=1&pageSize=10&src=test'
{
"s": 1,
"m": "ok",
"d": {
"data": [
{
"id": "5b20d2bfe13823065f556177",
"content": "1",
"source": "web",
"startTime": "2018-11-11 11:00:00",
"endTime": "2018-11-11 11:00:00"
},
{
"id": "5b20d7ece1382306605765e9",
"content": "2",
"source": "web",
"startTime": "2018-11-11 11:00:00",
"endTime": "2018-11-11 11:00:00"
},
{
"id": "5b20d7efe138230661543fe7",
"content": "3",
"source": "web",
"startTime": "2018-11-11 11:00:00",
"endTime": "2018-11-11 11:00:00"
},
],
"pageNum": 1,
"pageSize": 100,
"total": 8
}
}
POST
/v1/findPlaceholderGuide
name | position | required | type | limit | description |
---|---|---|---|---|---|
id | body | true | string | * | 条目 ID |
src | body | true | string | * | 请求来源 |
curl -X POST \
http://192.168.100.50:8000/v1/findPlaceholderGuide \
-H 'Content-Type: application/x-www-form-urlencoded' \
-H 'Host: pin-guide-ms.juejin.im' \
-d 'id=1111111111&src=test'
{
"s": 1,
"m": "ok",
"d": {
"data": {
"id": "5b20dae6e1382306624a0676",
"content": "5",
"source": "web",
"startTime": "2018-11-11 11:00:00",
"endTime": "2018-11-11 11:00:00"
}
}
}
POST
/v1/delPlaceholderGuide
name | position | required | type | limit | description |
---|---|---|---|---|---|
id | body | true | string | * | 条目 ID |
src | body | true | string | * | 请求来源 |
curl -X POST \
http://192.168.100.50:8000/v1/delPlaceholderGuide \
-H 'Content-Type: application/x-www-form-urlencoded' \
-H 'Host: pin-guide-ms.juejin.im' \
-d 'src=test&id=5b1793f7a9574'
{
"s": 1,
"m": "ok",
"d": []
}
POST
/v1/updatePlaceholderGuide
name | position | required | type | limit | description |
---|---|---|---|---|---|
id | body | true | string | * | 条目 ID |
src | body | true | string | * | 请求来源 |
content | body | false | string | * | 引导语内容 |
source | body | false | string | * | 平台 |
startTime | body | false | string | * | 开始时间 |
endTime | body | false | string | * | 结束时间 |
startTime 与 endTime
参数同步传递
不能只传其中一个
两个参数需同时传递
curl -X POST \
http://192.168.100.50:8000/v1/updatePlaceholderGuide \
-H 'Content-Type: application/x-www-form-urlencoded' \
-H 'Host: pin-guide-ms.juejin.im' \
-d 'content=test&source=test&startTime=2018-06-05 08:27:06&endTime=2018-06-05 08:27:06&src=test&id=111111'
{
"s": 1,
"m": "ok",
"d": []
}