获取知识点分类列表接口
服务描述
此接口获取问答知识分类树
开发须知
调用本接口前,请先获取appId
服务地址
GET https://{您的专属域名}/kms/openapi/v1/integration/classification/cls/tree
请求参数
| 参数 |
位置 |
类型 |
是否必填 |
说明 |
| appId |
header |
String |
Y |
应用ID |
| timestamp |
header |
String |
Y |
时间戳,毫秒 |
| sign |
header |
String |
Y |
签名 |
| Content-Type |
header |
String |
Y |
application/json |
| robotId |
body |
String |
Y |
机器人id |
| filterParam |
body |
String |
N |
过滤条件 |
返回结果
BotIntegrationCategory
| 参数 |
类型 |
说明 |
| id |
Long |
ID |
| robotId |
String |
机器人ID |
| parentId |
Long |
父类ID |
| orderNum |
Integer |
排序 |
| level |
Integer |
层级 |
| classificationName |
String |
分类名 |
| type |
Short |
停用状态(1知识库分类;2意图分类) |
| classificationName |
String |
分类名 |
| childList |
Collection |
子类列表 |
| parent |
BotIntegrationCategory |
父类 |
| count |
Integer |
分类下知识数量 |
响应示例
{
"code": "10000",
"message": "ok",************
"data": {
"id": 13551,
"tenantId": "msxf160255504227000490043",
"robotId": "NEWdb8c908a047a680d04623451eb595",
"parentId": -1,
"orderNum": 1,
"level": 0,
"classificationName": "所有知识",
"createTime": 1624590603000,
"updateTime": 1624590603000,
"type": 1,
"isDeleted": false,
"childList": [
{
"id": 13552,
"tenantId": "msxf160255504227000490043",
"robotId": "NEWdb8c908a047a680d04623451eb595",
"parentId": 13551,
"orderNum": 1,
"level": 1,
"classificationName": "未分类",
"createTime": 1624590603000,
"updateTime": 1624590603000,
"type": 1,
"isDeleted": false,
"childList": null,
"parent": null,
"count": 73,
"status": 1
},
{
"id": 13622,
"tenantId": "msxf160255504227000490043",
"robotId": "NEWdb8c908a047a680d04623451eb595",
"parentId": 13551,
"orderNum": 2,
"level": 1,
"classificationName": "大恒科技",
"createTime": 1626072837000,
"updateTime": 1626072837000,
"type": 1,
"isDeleted": false,
"childList": null,
"parent": null,
"count": 1,
"status": 2
}
],
"parent": null,
"count": 74,
"status": 0
}
}
结果码说明
| 结果码 |
说明 |
| 10000 |
请求成功 |
| 10001 |
鉴权失败 |
| 10002 |
找不到对应的公钥,请先上传公钥 |
| 20001 |
请求失败 |
| 20002 |
参数错误 |
| 20003 |
未查询到符合条件的记录 |