summaryrefslogtreecommitdiff
path: root/data/zh_cn/alikafkakopilot/2026-04-14/api-docs.php
blob: 6d1d1e40ec6a00b2adba1bc4954921fc89350149 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
<?php return [
    'version' => '1.0',
    'info' => ['style' => 'RPC', 'product' => 'AlikafkaKopilot', 'version' => '2026-04-14'],
    'directories' => ['KopilotChatStream', 'KopilotFeedback', 'KopilotListConversationChatMessages', 'KopilotListConversations', 'KopilotQueryStatus'],
    'components' => [
        'schemas' => [],
    ],
    'apis' => [
        'KopilotChatStream' => [
            'path' => '/',
            'methods' => ['post'],
            'schemes' => ['https', 'sse'],
            'security' => [
                [
                    'AK' => [],
                ],
            ],
            'operationType' => 'read',
            'deprecated' => false,
            'systemTags' => [
                'operationType' => 'none',
                'riskType' => 'none',
                'chargeType' => 'paid',
                'abilityTreeNodes' => ['FEATUREalikafkaH77LGU'],
                'autoTest' => true,
                'tenantRelevance' => 'publicInformation',
            ],
            'parameters' => [
                [
                    'name' => 'RegionId',
                    'in' => 'query',
                    'schema' => ['description' => '地域 ID。', 'type' => 'string', 'required' => true, 'example' => 'cn-beijing'],
                ],
                [
                    'name' => 'Message',
                    'in' => 'query',
                    'schema' => ['description' => '用户输入的聊天消息内容。', 'type' => 'string', 'required' => false, 'example' => 'hello'],
                ],
                [
                    'name' => 'SessionId',
                    'in' => 'query',
                    'schema' => ['description' => '会话标识。', 'type' => 'string', 'required' => false, 'example' => 'efff104e-c0b1-4005-8c73-*********'],
                ],
            ],
            'responses' => [
                200 => [
                    'schema' => [
                        'type' => 'object',
                        'properties' => [
                            'Role' => ['description' => '角色标识。', 'type' => 'string', 'example' => 'assistant'],
                            'Type' => ['description' => '事件/消息类型。', 'type' => 'string', 'example' => 'delta'],
                            'Message' => ['description' => '消息主体。', 'type' => 'string', 'example' => 'test'],
                            'ThreadId' => ['description' => '会话线程ID。', 'type' => 'string', 'example' => 'thread_abc123xyz'],
                            'Delta' => ['description' => '流式增量内容。', 'type' => 'string', 'example' => 'hello'],
                            'ToolCallId' => ['description' => '工具调用唯一ID。', 'type' => 'string', 'example' => 'call_xyz789012'],
                            'Content' => ['description' => '实际内容。', 'type' => 'string', 'example' => 'test'],
                            'ToolCallName' => ['description' => '工具/函数名称。', 'type' => 'string', 'example' => 'search_knowledge_base'],
                            'RunId' => ['description' => '运行任务ID。', 'type' => 'string', 'example' => '5737d000********'],
                            'MessageId' => ['description' => '消息唯一ID。', 'type' => 'string', 'example' => '4b209618fd066c4354037b4b0634ffc9'],
                            'RequestId' => ['description' => '请求的 ID。', 'type' => 'string', 'example' => '76E1F1AA-6046-5074-96E2-79A37AFBD2FA'],
                        ],
                        'description' => '',
                    ],
                ],
            ],
            'staticInfo' => ['returnType' => 'synchronous'],
            'title' => '智能体stream chat会话',
            'summary' => '智能体 stream chat 会话。',
            'changeSet' => [],
            'responseDemo' => '[{"errorExample":"","example":"{\\n  \\"Role\\": \\"assistant\\",\\n  \\"Type\\": \\"delta\\",\\n  \\"Message\\": \\"test\\",\\n  \\"ThreadId\\": \\"thread_abc123xyz\\",\\n  \\"Delta\\": \\"hello\\",\\n  \\"ToolCallId\\": \\"call_xyz789012\\",\\n  \\"Content\\": \\"test\\",\\n  \\"ToolCallName\\": \\"search_knowledge_base\\",\\n  \\"RunId\\": \\"5737d000********\\",\\n  \\"MessageId\\": \\"4b209618fd066c4354037b4b0634ffc9\\",\\n  \\"RequestId\\": \\"76E1F1AA-6046-5074-96E2-79A37AFBD2FA\\"\\n}","type":"json"}]',
        ],
        'KopilotFeedback' => [
            'methods' => ['post'],
            'schemes' => ['https'],
            'security' => [
                [
                    'AK' => [],
                ],
            ],
            'operationType' => 'read',
            'deprecated' => false,
            'systemTags' => [
                'operationType' => 'none',
                'riskType' => 'high',
                'chargeType' => 'paid',
                'abilityTreeNodes' => ['FEATUREalikafkaH77LGU'],
                'autoTest' => true,
                'tenantRelevance' => 'publicInformation',
            ],
            'parameters' => [
                [
                    'name' => 'RegionId',
                    'in' => 'query',
                    'schema' => ['description' => '地域 ID。', 'type' => 'string', 'required' => true, 'example' => 'cn-beijing'],
                ],
                [
                    'name' => 'SessionId',
                    'in' => 'query',
                    'schema' => ['description' => '会话ID。', 'type' => 'string', 'required' => false, 'example' => 'e356c91c-8220-425c-9d86-********'],
                ],
                [
                    'name' => 'TurnId',
                    'in' => 'query',
                    'schema' => ['description' => '主键 ID。', 'type' => 'string', 'required' => false, 'example' => '5243231*****'],
                ],
                [
                    'name' => 'Feedback',
                    'in' => 'query',
                    'schema' => [
                        'description' => '用户满意程度。'."\n"
                            ."\n"
                            .'- 1:满意'."\n"
                            .'- -1:不满意'."\n"
                            .'- 0:取消评价',
                        'type' => 'string',
                        'required' => false,
                        'enumValueTitles' => [],
                        'example' => '1',
                    ],
                ],
                [
                    'name' => 'Comment',
                    'in' => 'query',
                    'schema' => ['description' => '用户反馈评论。', 'type' => 'string', 'required' => false, 'example' => 'good'],
                ],
            ],
            'responses' => [
                200 => [
                    'schema' => [
                        'title' => 'Schema of Response',
                        'description' => 'Schema of Response',
                        'type' => 'object',
                        'properties' => [
                            'RequestId' => ['title' => 'Id of the request', 'description' => '请求的 ID。', 'type' => 'string', 'example' => 'E522C7AB-AA99-53B1-BEE7-8BA83ED678F7'],
                            'Success' => ['description' => '请求是否成功。', 'type' => 'boolean', 'example' => 'True'],
                            'Code' => ['description' => '返回码。返回200代表成功。', 'type' => 'integer', 'format' => 'int64', 'example' => '200'],
                            'Data' => [
                                'description' => '调用成功时,返回的数据。',
                                'type' => 'object',
                                'additionalProperties' => ['type' => 'integer', 'format' => 'int64', 'example' => '1234', 'description' => '主键ID。'],
                            ],
                        ],
                    ],
                ],
            ],
            'staticInfo' => ['returnType' => 'synchronous'],
            'title' => '用户会话评价',
            'summary' => '评价',
            'changeSet' => [],
            'responseDemo' => '[{"errorExample":"","example":"{\\n  \\"RequestId\\": \\"E522C7AB-AA99-53B1-BEE7-8BA83ED678F7\\",\\n  \\"Success\\": true,\\n  \\"Code\\": 200,\\n  \\"Data\\": {\\n    \\"key\\": 1234\\n  }\\n}","type":"json"}]',
        ],
        'KopilotListConversationChatMessages' => [
            'methods' => ['post'],
            'schemes' => ['https'],
            'security' => [
                [
                    'AK' => [],
                ],
            ],
            'operationType' => 'read',
            'deprecated' => false,
            'systemTags' => [
                'operationType' => 'none',
                'riskType' => 'high',
                'chargeType' => 'paid',
                'abilityTreeNodes' => ['FEATUREalikafkaH77LGU'],
                'autoTest' => true,
                'tenantRelevance' => 'publicInformation',
            ],
            'parameters' => [
                [
                    'name' => 'SessionId',
                    'in' => 'query',
                    'schema' => ['description' => '会话ID。', 'type' => 'string', 'required' => false, 'example' => 'e356c91c-8220-425c-9d86-********'],
                ],
                [
                    'name' => 'RegionId',
                    'in' => 'query',
                    'schema' => ['description' => '地域 ID。', 'type' => 'string', 'required' => true, 'example' => 'cn-beijing'],
                ],
                [
                    'name' => 'PageSize',
                    'in' => 'query',
                    'schema' => ['description' => '分页大小', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '10'],
                ],
                [
                    'name' => 'BeforeTurnId',
                    'in' => 'query',
                    'schema' => ['description' => '游标。'."\n"
                        ."\n"
                        .'> 不传时返回最后 pageSize 个 turnId,传入时返回 turn ID。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '2345'],
                ],
            ],
            'responses' => [
                200 => [
                    'schema' => [
                        'title' => 'Schema of Response',
                        'description' => 'Schema of Response',
                        'type' => 'object',
                        'properties' => [
                            'RequestId' => ['title' => 'Id of the request', 'description' => '请求的 ID。', 'type' => 'string', 'example' => 'F69385B9-2139-5A07-AE64-37C4B6ED308E'],
                            'Success' => ['description' => '请求是否成功。', 'type' => 'boolean', 'example' => 'True'],
                            'Code' => ['description' => '返回码。返回200代表成功。', 'type' => 'integer', 'format' => 'int64', 'example' => '200'],
                            'Data' => [
                                'description' => '调用成功时,返回的数据。',
                                'type' => 'object',
                                'properties' => [
                                    'SessionId' => ['description' => '会话ID。', 'type' => 'string', 'example' => '87ce9505-7dec-4fd7-bc7c-e66d949bfdc9'],
                                    'TotalTurns' => ['description' => 'trunId总条数。', 'type' => 'integer', 'format' => 'int64', 'example' => '2'],
                                    'Messages' => [
                                        'description' => '消息体列表。',
                                        'type' => 'array',
                                        'items' => [
                                            'description' => '消息体。',
                                            'type' => 'object',
                                            'properties' => [
                                                'Role' => ['description' => '角色标识。', 'type' => 'string', 'example' => 'assistant'],
                                                'Content' => ['description' => '消息实际内容。', 'type' => 'string', 'example' => 'test'],
                                                'CreateTime' => ['description' => '创建时间。', 'type' => 'string', 'example' => '17575885545677'],
                                                'TurnId' => ['description' => '主键 ID。', 'type' => 'string', 'example' => '2345'],
                                                'Feedback' => ['description' => '用户满意程度。', 'type' => 'string', 'example' => '1'],
                                            ],
                                        ],
                                    ],
                                    'HasMore' => ['description' => '是否有更多数据'."\n", 'type' => 'boolean', 'example' => 'true'],
                                    'NextBeforeTurnId' => ['description' => '下一页游标。', 'type' => 'integer', 'format' => 'int64', 'example' => '1'],
                                ],
                            ],
                        ],
                    ],
                ],
            ],
            'staticInfo' => ['returnType' => 'synchronous'],
            'title' => '查询历史对话',
            'summary' => '查询历史对话。',
            'changeSet' => [],
            'responseDemo' => '[{"errorExample":"","example":"{\\n  \\"RequestId\\": \\"F69385B9-2139-5A07-AE64-37C4B6ED308E\\",\\n  \\"Success\\": true,\\n  \\"Code\\": 200,\\n  \\"Data\\": {\\n    \\"SessionId\\": \\"87ce9505-7dec-4fd7-bc7c-e66d949bfdc9\\",\\n    \\"TotalTurns\\": 2,\\n    \\"Messages\\": [\\n      {\\n        \\"Role\\": \\"assistant\\",\\n        \\"Content\\": \\"test\\",\\n        \\"CreateTime\\": \\"17575885545677\\",\\n        \\"TurnId\\": \\"2345\\",\\n        \\"Feedback\\": \\"1\\"\\n      }\\n    ],\\n    \\"HasMore\\": true,\\n    \\"NextBeforeTurnId\\": 1\\n  }\\n}","type":"json"}]',
        ],
        'KopilotListConversations' => [
            'methods' => ['post'],
            'schemes' => ['https'],
            'security' => [
                [
                    'AK' => [],
                ],
            ],
            'operationType' => 'write',
            'deprecated' => false,
            'systemTags' => [
                'operationType' => 'none',
                'riskType' => 'high',
                'chargeType' => 'paid',
                'abilityTreeNodes' => ['FEATUREalikafkaH77LGU'],
                'autoTest' => true,
                'tenantRelevance' => 'publicInformation',
            ],
            'parameters' => [
                [
                    'name' => 'RegionId',
                    'in' => 'query',
                    'schema' => ['description' => '地域 ID。', 'type' => 'string', 'required' => true, 'example' => 'cn-beijing'],
                ],
                [
                    'name' => 'Page',
                    'in' => 'query',
                    'schema' => ['description' => '当前页码。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '1'],
                ],
                [
                    'name' => 'Size',
                    'in' => 'query',
                    'schema' => ['description' => '分页大小。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '10'],
                ],
            ],
            'responses' => [
                200 => [
                    'schema' => [
                        'title' => 'Schema of Response',
                        'description' => 'Schema of Response',
                        'type' => 'object',
                        'properties' => [
                            'RequestId' => ['title' => 'Id of the request', 'description' => '请求的 ID。', 'type' => 'string', 'example' => '2DF166F2-F581-5254-AAB6-B482083FA7B4'],
                            'Success' => ['description' => '请求是否成功。', 'type' => 'boolean', 'example' => 'True'],
                            'Code' => ['description' => '状态码。返回200代表成功。', 'type' => 'integer', 'format' => 'int64', 'example' => '200'],
                            'Data' => [
                                'description' => '调用成功时,返回的数据。',
                                'type' => 'object',
                                'properties' => [
                                    'UserId' => ['description' => '用户Uid', 'type' => 'string', 'example' => '1734455674565'],
                                    'Count' => ['description' => '分页查询时,当前页显示的数据条数。', 'type' => 'integer', 'format' => 'int32', 'example' => '1'],
                                    'ConversationIds' => [
                                        'description' => '会话ID列表',
                                        'type' => 'array',
                                        'items' => ['description' => '会话ID', 'type' => 'string', 'example' => 'ids'],
                                    ],
                                    'Page' => ['description' => '当前页码。', 'type' => 'integer', 'format' => 'int32', 'example' => '1'],
                                    'Size' => ['description' => '当前页数量', 'type' => 'integer', 'format' => 'int32', 'example' => '10'],
                                    'Total' => ['description' => '总条数。', 'type' => 'integer', 'format' => 'int64', 'example' => '2'],
                                    'TotalPages' => ['description' => '总页数', 'type' => 'integer', 'format' => 'int32', 'example' => '1'],
                                ],
                            ],
                        ],
                    ],
                ],
            ],
            'staticInfo' => ['returnType' => 'synchronous'],
            'title' => '查询用户所有会话ID',
            'summary' => '查询当前用户在 Console 渠道下的会话 ID(按创建时间倒序),支持分页。',
            'changeSet' => [],
            'responseDemo' => '[{"errorExample":"","example":"{\\n  \\"RequestId\\": \\"2DF166F2-F581-5254-AAB6-B482083FA7B4\\",\\n  \\"Success\\": true,\\n  \\"Code\\": 200,\\n  \\"Data\\": {\\n    \\"UserId\\": \\"1734455674565\\",\\n    \\"Count\\": 1,\\n    \\"ConversationIds\\": [\\n      \\"ids\\"\\n    ],\\n    \\"Page\\": 1,\\n    \\"Size\\": 10,\\n    \\"Total\\": 2,\\n    \\"TotalPages\\": 1\\n  }\\n}","type":"json"}]',
        ],
        'KopilotQueryStatus' => [
            'methods' => ['post'],
            'schemes' => ['https'],
            'security' => [
                [
                    'AK' => [],
                ],
            ],
            'operationType' => 'read',
            'deprecated' => false,
            'systemTags' => [
                'operationType' => 'none',
                'riskType' => 'high',
                'chargeType' => 'paid',
                'abilityTreeNodes' => ['FEATUREalikafkaH77LGU'],
                'autoTest' => true,
                'tenantRelevance' => 'publicInformation',
            ],
            'parameters' => [
                [
                    'name' => 'RegionId',
                    'in' => 'query',
                    'schema' => ['description' => '地域 ID。', 'type' => 'string', 'required' => true, 'example' => 'cn-beijing'],
                ],
                [
                    'name' => 'Owner',
                    'in' => 'query',
                    'schema' => ['description' => '责任人的账号ID。', 'type' => 'string', 'required' => true, 'example' => '1590639435720201'],
                ],
            ],
            'responses' => [
                200 => [
                    'schema' => [
                        'title' => 'Schema of Response',
                        'description' => 'Schema of Response',
                        'type' => 'object',
                        'properties' => [
                            'RequestId' => ['title' => 'Id of the request', 'description' => '请求的 ID。', 'type' => 'string', 'example' => '2DF166F2-F581-5254-AAB6-B482083FA7B4'],
                            'Success' => ['description' => '请求是否成功。', 'type' => 'boolean', 'example' => 'True'],
                            'Code' => ['description' => '状态码。返回200代表成功。', 'type' => 'integer', 'format' => 'int64', 'example' => '200'],
                            'Data' => [
                                'description' => '调用成功时,返回的状态信息。',
                                'type' => 'object',
                                'properties' => [
                                    'Uid' => ['description' => '用户uid', 'type' => 'string', 'example' => '206022063004684756'],
                                    'InstanceId' => ['description' => '实例ID。', 'type' => 'string', 'example' => 'instanceId'],
                                    'LifeStatus' => ['description' => '实例状态。', 'type' => 'string', 'example' => 'NotActivated'],
                                    'RegionId' => ['description' => '地域 ID。', 'type' => 'string', 'example' => 'cn-beijing'],
                                    'ActivateTime' => ['description' => '激活时间。', 'type' => 'integer', 'format' => 'int64', 'example' => '17346565678778'],
                                ],
                            ],
                        ],
                    ],
                ],
            ],
            'staticInfo' => ['returnType' => 'synchronous'],
            'title' => '查询实例开通状态',
            'summary' => '开通状态。',
            'changeSet' => [],
            'responseDemo' => '[{"errorExample":"","example":"{\\n  \\"RequestId\\": \\"2DF166F2-F581-5254-AAB6-B482083FA7B4\\",\\n  \\"Success\\": true,\\n  \\"Code\\": 200,\\n  \\"Data\\": {\\n    \\"Uid\\": \\"206022063004684756\\",\\n    \\"InstanceId\\": \\"instanceId\\",\\n    \\"LifeStatus\\": \\"NotActivated\\",\\n    \\"RegionId\\": \\"cn-beijing\\",\\n    \\"ActivateTime\\": 17346565678778\\n  }\\n}","type":"json"}]',
        ],
    ],
    'endpoints' => [],
    'errorCodes' => [],
    'changeSet' => [],
];