FaqTemplate - 查看问题模版列表
更新时间:2025-10-21
API访问域名
| 请求方式 | GET |
|---|---|
| base url | https://keyue.cloud.baidu.com |
| 后缀接口 | /open/v1/api/v2/faq/template |
| Authentication | token为API Key |
说明
无
请求参数
Header参数
| 名称 | 类型 | 必选 | 中文名 | 说明 |
|---|---|---|---|---|
| Content-Type | string | 是 | 内容类型 | 固定值:application/json |
| token | string | 是 | API KEY | 机器人API KEY。 详细获取方式参考:准备工作 |
| uid | string | 是 | 用户ID | 详细获取方式参考:准备工作 |
| username | string | 是 | 用户名 | 详细获取方式参考:准备工作 |
Body参数
| 名称 | 类型 | 必选 | 中文名 | 说明 |
|---|---|---|---|---|
| pn | integer | 是 | 页码 | 1 |
| ps | integer | 是 | 每页数量 | 5 |
| keyword | string | 否 | 关键字 | "" |
| faqId | string | 是 | faqId |
响应参数
| 名称 | 类型 | 必选 | 中文名 | 说明 |
|---|---|---|---|---|
| time | integer | 是 | 时间 | 1717053723895 |
| data | object | 是 | 数据 | 数据对象,详见data 子数据 |
| code | integer | 是 | 状态码 | 200 |
| msg | string | 是 | 状态信息 | OK |
data 子数据
| 名称 | 类型 | 必选 | 中文名 | 说明 |
|---|---|---|---|---|
| all | integer | 是 | 全部 | 2 |
| total | integer | 是 | 总数 | 2 |
| pn | integer | 是 | 页码 | 1 |
| ps | integer | 是 | 每页数量 | 5 |
| list | array | 是 | 列表 | 列表,详见list子数据 |
list子数据
| 名称 | 类型 | 必选 | 中文名 | 说明 |
|---|---|---|---|---|
| id | string | 是 | ID | 14fefaeb-ab24-43ac-8741-daa019446169 |
| faqId | string | 是 | FAQ ID | 6f4b1206-bdf6-42e0-94a8-bb57d2a5a4e6 |
| template | string | 是 | 模板 | [W:0-5] |
| created | string | 是 | 创建时间 | 2024-05-30 15:09:16 |
| update | string | 是 | 更新时间 | 2024-05-30 15:09:16 |
| version | integer | 是 | 版本 | 0 |
| hasActiveCopy | boolean | 否 | 有活动副本 | false |
| templateList | array | 是 | 模板列表 | 模板列表,详见templateList子数据 |
templateList子数据
| 名称 | 类型 | 必选 | 中文名 | 说明 |
|---|---|---|---|---|
| text | string | 是 | 文本 | [W:0-5] |
| id | null | 否 | ID | null |
| name | null | 否 | 名称 | null |
| nameZh | null | 否 | 中文名 | null |
| type | null | 否 | 类型 | null |
请求示例
Bash
1curl --location 'https://keyue.cloud.baidu.com/open/v1/api/v2/faq/template?pn=1&ps=5&keyword=&faqId=6f4b1206-bdf6-42e0-94a8-bb57d2a5a4e6' \
2--header 'token: a9dcb88a-4fc0-4ae0-a103-3578bdb90e62' \
3--header 'Content-Type: application/json' \
4--header 'uid: cf7d9692703d45d1b5517a30ab3efa53' \
5--header 'username: pnstest5'
响应示例
1{
2 "time": 1717053723895,
3 "data": {
4 "all": 2,
5 "total": 2,
6 "pn": 1,
7 "ps": 5,
8 "list": [
9 {
10 "id": "14fefaeb-ab24-43ac-8741-daa019446169",
11 "faqId": "6f4b1206-bdf6-42e0-94a8-bb57d2a5a4e6",
12 "template": "[W:0-5]",
13 "created": "2024-05-30 15:09:16",
14 "update": "2024-05-30 15:09:16",
15 "version": 0,
16 "hasActiveCopy": false,
17 "templateList": [
18 {
19 "text": "[W:0-5]",
20 "id": null,
21 "name": null,
22 "nameZh": null,
23 "type": null
24 }
25 ]
26 },
27 {
28 "id": "b213f7f0-3a35-4110-9e59-8def695c8d46",
29 "faqId": "6f4b1206-bdf6-42e0-94a8-bb57d2a5a4e6",
30 "template": "[W:0-5][@y05d03cc]",
31 "created": "2024-05-30 11:40:11",
32 "update": "2024-05-30 11:45:35",
33 "version": 1,
34 "hasActiveCopy": false,
35 "templateList": [
36 {
37 "text": "[W:0-5][",
38 "id": null,
39 "name": null,
40 "nameZh": null,
41 "type": null
42 },
43 {
44 "text": "y05d03cc",
45 "id": "y05d03cc",
46 "name": "y05d03cc",
47 "nameZh": "人名",
48 "type": "entity"
49 },
50 {
51 "text": "]",
52 "id": null,
53 "name": null,
54 "nameZh": null,
55 "type": null
56 }
57 ]
58 }
59 ]
60 },
61 "code": 200,
62 "msg": "OK"
63}
1
