分类列表
GET
/category/list
请求参数
Header 参数
authori-zation
string
token
示例值:
Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJ0ZXN0LnByby53dWh0Lm5ldCIsImF1ZCI6InRlc3QucHJvLnd1aHQubmV0IiwiaWF0IjoxNjQ5NzQ2MjAyLCJuYmYiOjE2NDk3NDYyMDIsImV4cCI6MTY1MDM1MTAwMiwianRpIjp7ImlkIjoxLCJ0eXBlIjoiYWRtaW4ifX0.-xDXOdYfBNsu3IqF3nMO_E_fop2lxkwNw25fdQpzGVQ
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET '/category/list' \
--header 'authori-zation: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJ0ZXN0LnByby53dWh0Lm5ldCIsImF1ZCI6InRlc3QucHJvLnd1aHQubmV0IiwiaWF0IjoxNjQ5NzQ2MjAyLCJuYmYiOjE2NDk3NDYyMDIsImV4cCI6MTY1MDM1MTAwMiwianRpIjp7ImlkIjoxLCJ0eXBlIjoiYWRtaW4ifX0.-xDXOdYfBNsu3IqF3nMO_E_fop2lxkwNw25fdQpzGVQ'
返回响应
🟢200成功
application/json
Body
status
integer
状态码
msg
string
信息描述
data
array [object {8}]
返回值
id
integer
分类ID
cate_name
string
分类名称
pid
integer
父ID
pic
string
分类图标
big_pic
string
分类大图
sort
integer
排序
is_show
integer
显示状态
add_time
string
添加时间
示例
{
"status": 200,
"msg": "success",
"data": [
{
"id": 11,
"cate_name": "分类12",
"pid": 9,
"pic": "http://dummyimage.com/400x400",
"big_pic": "http://dummyimage.com/400x400",
"sort": 54,
"is_show": 1,
"add_time": "2022-07-20 14:24:14"
},
{
"id": 4,
"cate_name": "分类2",
"pid": 0,
"pic": "",
"big_pic": "",
"sort": 6,
"is_show": 1,
"add_time": "2022-07-20 10:46:45"
},
{
"id": 5,
"cate_name": "分类1",
"pid": 0,
"pic": "",
"big_pic": "",
"sort": 6,
"is_show": 1,
"add_time": "2022-07-20 10:59:26"
},
{
"id": 6,
"cate_name": "分类3",
"pid": 0,
"pic": "",
"big_pic": "",
"sort": 6,
"is_show": 1,
"add_time": "2022-07-20 11:01:34"
},
{
"id": 7,
"cate_name": "分类4",
"pid": 0,
"pic": "",
"big_pic": "",
"sort": 6,
"is_show": 1,
"add_time": "2022-07-20 11:05:10"
},
{
"id": 9,
"cate_name": "分类12342",
"pid": 0,
"pic": "",
"big_pic": "",
"sort": 6,
"is_show": 1,
"add_time": "2022-07-20 14:15:48"
},
{
"id": 10,
"cate_name": "分类10",
"pid": 0,
"pic": "https://v4.wuht.net/uploads/attach/2022/07/20220719/023a0538d05fe3694767bd80dc5c8433.jpeg",
"big_pic": "https://v4.wuht.net/uploads/attach/2022/07/20220719/023a0538d05fe3694767bd80dc5c8433.jpeg",
"sort": 1,
"is_show": 1,
"add_time": "2022-07-20 14:23:09"
},
{
"id": 1,
"cate_name": "办公用品",
"pid": 0,
"pic": "https://v4.wuht.net/uploads/attach/2022/07/20220719/94c08b45581c695f1f76fcc25a0271ec.jpg",
"big_pic": "https://v4.wuht.net/uploads/attach/2022/07/20220719/94c08b45581c695f1f76fcc25a0271ec.jpg",
"sort": 0,
"is_show": 1,
"add_time": "2022-07-19 15:15:01"
},
{
"id": 2,
"cate_name": "办公用品1",
"pid": 1,
"pic": "https://v4.wuht.net/uploads/attach/2022/07/20220719/94c08b45581c695f1f76fcc25a0271ec.jpg",
"big_pic": "https://v4.wuht.net/uploads/attach/2022/07/20220719/94c08b45581c695f1f76fcc25a0271ec.jpg",
"sort": 0,
"is_show": 1,
"add_time": "2022-07-19 15:15:51"
},
{
"id": 3,
"cate_name": "测试",
"pid": 0,
"pic": "",
"big_pic": "",
"sort": 0,
"is_show": 1,
"add_time": "2022-07-19 17:44:47"
}
]
}
修改于 2022-07-21 01:58:33