跳转到主要内容

查询分类目录列表

接口说明

  • 请求地址:http://domain.com/index.php?c=api&method=category_list
  • 请求方法:POST

请求参数

参数名称示例值类型是否必须说明
token5c7d0c90cf9e0ce560956179e8e82e7dstring(32)请参考token生成

请求成功响应

{
	"code": 0,
	"msg": "",
	"count": 6,
	"data": [
		{
			"0": "8",
			"1": "<i class=\"fa fa-external-link\"></i> 常用链接",
			"2": "1607747674",
			"3": "1607865180",
			"4": "99",
			"5": "0",
			"6": "",
			"id": "8",
			"name": "<i class=\"fa fa-external-link\"></i> 常用链接",
			"add_time": "1607747674",
			"up_time": "1607865180",
			"weight": "99",
			"property": "0",
			"description": ""
		},
		{
			"0": "19",
			"1": "<i class=\"fa fa-html5\"></i> 站长工具",
			"2": "1607866471",
			"3": "",
			"4": "80",
			"5": "0",
			"6": "",
			"id": "19",
			"name": "<i class=\"fa fa-html5\"></i> 站长工具",
			"add_time": "1607866471",
			"up_time": "",
			"weight": "80",
			"property": "0",
			"description": ""
		},
		{
			"0": "3",
			"1": "<i class=\"fa fa-linux\"></i> 运维工具",
			"2": "1607699882",
			"3": "1607865657",
			"4": "80",
			"5": "0",
			"6": "",
			"id": "3",
			"name": "<i class=\"fa fa-linux\"></i> 运维工具",
			"add_time": "1607699882",
			"up_time": "1607865657",
			"weight": "80",
			"property": "0",
			"description": ""
		},
		{
			"0": "18",
			"1": "<i class=\"fa fa-video-camera\"></i> 视频影音",
			"2": "1607865982",
			"3": "1607866160",
			"4": "10",
			"5": "0",
			"6": "",
			"id": "18",
			"name": "<i class=\"fa fa-video-camera\"></i> 视频影音",
			"add_time": "1607865982",
			"up_time": "1607866160",
			"weight": "10",
			"property": "0",
			"description": ""
		},
		{
			"0": "4",
			"1": "<i class=\"fa fa-female\"></i> 18+",
			"2": "1607699983",
			"3": "1608046903",
			"4": "0",
			"5": "0",
			"6": "",
			"id": "4",
			"name": "<i class=\"fa fa-female\"></i> 18+",
			"add_time": "1607699983",
			"up_time": "1608046903",
			"weight": "0",
			"property": "0",
			"description": ""
		}
	]
}
  • code:响应状态码,0代表成功
  • data.id:分类ID
  • data.name:分类名称
  • data.add_time:分类添加时间
  • data.up_time:分类修改时间
  • data.weight:分类权重,权重越高,排名越靠前
  • data.property:分类熟悉,0:公开,1:私有
  • data.description:分类描述

请求失败响应

{
	"code": -1000,
	"err_msg": "Categorie already exist!"
}
  • code:错误码
  • err_msg:错误描述