+++
get:/news?catid=:catid&search=:search
*:catid=517#欄目id 可寫多個 如:517,536
:search=美食#標題搜索
<<<
success
{
{
"success": true,
"data": {
"items": [
{
"id": "1",
"catid": "536",
"title": "測試視頻221",
"thumb": "",
"keywords": "",
"description": "",
"username": "admin",
"inputtime": "1476768680",
"updatetime": "1476768807",
"like": "0", //點贊數量
"comment": "0" //評論數量
}
],
"_links": {
"self": {
"href": "http://www.lrb_api.com/v1/news/index?catid=517%2C536&search=%E6%B5%8B%E8%AF%95%E8%A7%86%E9%A2%91&page=1"
}
},
"_meta": {
"totalCount": 1,
"pageCount": 1,
"currentPage": 1,
"perPage": 20
}
}
}
<<<
error
{
"success": false,
"data": {
"name": "Unauthorized",
"message": "Sign簽名驗證失敗",
"code": 0,
"status": 401,
"type": "yii\\web\\HttpException"
}
}
+++
### header頭信息:
| 參數名 | 參數值 |
| --- | --- |
| Accept | application/json |
| DeviceId | 310995000000000|
| Sign | e67ce2f83ca715552c7040c6801e020f |
注意:
**存在緩存 默認緩存時間為30秒**