- 登录授权
- 商品
- 账户
- 验证码
- Keywords
- Banner
- 文章
- 短信
- 订单
- 地区
- 收货地址
- 优惠券
- 余额提现
- 评论
分类-tree
开发中
GET
/api/article/category/tree
请求参数
Authorization
在 Header 添加参数
Authorization
,其值为在 Bearer 之后拼接 Token示例:
Authorization: Bearer ********************
Header 参数
Accept
string
必需
默认值:
application/json
X-Requested-With
string
必需
默认值:
XMLHttpRequest
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request GET '/api/article/category/tree' \
--header 'Accept;' \
--header 'X-Requested-With;'
返回响应
🟢200成功
application/json
Body
data
array[object (ArticleCategory) {9}]
数据
id
integer
分类 id
key
string
分类 key
name
string
名称
image
string | null
图片
is_recommend
integer
是否推荐
ext
object | null
其他
parent_id
integer
上级 id
created_at
integer
创建时间
children
array [object]
子集
code
integer
返回码
message
string
信息
示例
{
"data": [
{
"id": 23,
"name": "\u884c\u653f\u7ba1\u7406",
"key": "category-23",
"image": "http:\/\/local.dcat-admin-demo.host\/storage\/article\/category\/fee5ff370f6324b1407a466d9c5d8753.jpg",
"ext": [],
"parent_id": 0,
"children": [
{
"id": 25,
"name": "\u540e\u52e4\u670d\u52a1",
"key": "category-25",
"image": null,
"ext": null,
"parent_id": 23
},
{
"id": 24,
"name": "\u884c\u653f\u7ba1\u7406",
"key": "category-24",
"image": null,
"ext": null,
"parent_id": 23
}
]
}
],
"code": 200,
"message": ""
}