'1.0', 'info' => ['style' => 'ROA', 'product' => 'PAICopilot', 'version' => '2025-07-31'], 'directories' => [ [ 'children' => ['GetChat', 'ListChats', 'DeleteChat'], 'type' => 'directory', 'title' => '对话', 'id' => 439711, ], [ 'children' => ['ListSessions', 'DeleteSession', 'GetSession'], 'type' => 'directory', 'title' => '会话', 'id' => 439712, ], 'SearchInfo', [ 'children' => ['CreateChat', 'CreateSession'], 'title' => '其他', 'type' => 'directory', ], ], 'components' => [ 'schemas' => [ 'Chat' => [ 'description' => '对话详情。', 'type' => 'object', 'properties' => [ 'ChatId' => ['description' => '对话ID。', 'type' => 'string', 'example' => 'chat-jkd******'], 'GmtCreateTime' => ['description' => '创建 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2021-01-21T17:12:35Z'], 'GmtModified' => ['description' => '修改 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2026-01-20T09:41:23Z'], 'Question' => ['description' => '客户问题。', '$ref' => '#/components/schemas/ChatDetail'], 'Answer' => ['description' => '客户回复。', '$ref' => '#/components/schemas/ChatDetail'], 'OwnerId' => ['description' => '父创建人。', 'type' => 'string', 'example' => '1500******860'], 'UserId' => ['description' => '创建人。', 'type' => 'string', 'example' => '2100******360'], 'Title' => ['description' => '问题抬头。', 'type' => 'string', 'example' => 'how to ******'], 'SessionId' => ['description' => 'Session 的 ID。', 'type' => 'string', 'example' => 'se-dss******'], 'Status' => ['description' => '状态,支持如下值'."\n" .'- Canceled 中止'."\n" .'- Running 运行中'."\n" .'- Completed 正常结束'."\n" .'- Error 错误'."\n" .'- Canceling 中止中'."\n" .'- Interrupted 暂停', 'type' => 'string', 'example' => 'Running'], 'ExtraData' => ['description' => '额外数据,目前用于 Update 里存用户更换规格的操作结果。', 'type' => 'string', 'example' => '{"solutionDetail":{"formValues":{"params":{"InstanceId":"dsw-g54******qg9"},"content":{"EcsSpec":"ecs.gn6i-c8g1.2xlarge"}},"success":true}}'], 'Message' => ['description' => '该字段已废弃。', 'type' => 'string', 'example' => 'how to ******'], ], ], 'ChatDetail' => [ 'description' => '问答详情。', 'type' => 'object', 'properties' => [ 'UserInfo' => [ 'description' => '用户信息。', 'type' => 'object', 'properties' => [ 'Role' => ['description' => '角色,支持如下角色,支持'."\n" .'- assistant 智能助手'."\n" .'- customer 客户', 'type' => 'string', 'example' => 'assistant'], 'Name' => ['description' => '用户名。', 'type' => 'string', 'example' => 'to******'], ], ], 'Content' => ['description' => '问答内容。', 'type' => 'string', 'example' => '你好******'], 'GmtCreateTime' => ['description' => '创建 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2021-01-21T17:12:35Z'], ], ], 'Feedback' => [ 'type' => 'object', 'properties' => [ 'FeedbackId' => ['type' => 'string'], 'GmtCreateTime' => ['type' => 'string', 'format' => 'iso8601_normal'], 'GmtModified' => ['type' => 'string', 'format' => 'iso8601_normal'], 'FeedbackAction' => ['type' => 'string'], 'FeedbackMessage' => ['type' => 'string'], 'OwnerId' => ['type' => 'string'], 'UserId' => ['type' => 'string'], 'SessionId' => ['type' => 'string'], 'ChatId' => ['type' => 'string'], ], ], 'Label' => [ 'description' => '标签。', 'type' => 'object', 'properties' => [ 'Key' => ['description' => '标签键。支持如下Key'."\n" ."\n" .'- system.resource.id 实例ID'."\n" .'- system.resource.type 产品内的实例类型(一个产品可能有多种实例)'."\n" .' DSW包括Instance、IdleCuller等;'."\n" .' DLC包括Job、Tensorboard等;'."\n" .' EAS包括Service、ResourceGroup等;'."\n" .' TrainingService包括TrainingJob;'."\n" .'- system.product.type 产品类型,支持DLC、DSW、EAS、Designer、Paiflow、LangStudio、Image、CodeSource、Dataset、TrainingService'."\n" .'- system.source.type 来源类型,支持ModelGallery', 'type' => 'string'], 'Value' => ['description' => '标签值。', 'type' => 'string'], ], ], 'Session' => [ 'type' => 'object', 'properties' => [ 'SessionId' => ['type' => 'string'], 'GmtCreateTime' => ['type' => 'string', 'format' => 'iso8601_normal'], 'GmtModified' => ['type' => 'string', 'format' => 'iso8601_normal'], 'OwnerId' => ['type' => 'string'], 'UserId' => ['type' => 'string'], 'SessionTitle' => ['type' => 'string'], ], ], ], ], 'apis' => [ 'CreateChat' => [ 'summary' => '创建对话,使用SSE协议,对话结果由服务端推送', 'path' => '/api/v1/sessions/{SessionId}/chats', 'methods' => ['post'], 'schemes' => ['https', 'sse'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => [], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'create', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'SessionId', 'in' => 'path', 'schema' => ['description' => '所属Session的ID。', 'type' => 'string', 'required' => true, 'example' => 'se-982******q0j9f'], ], [ 'name' => 'body', 'in' => 'body', 'style' => 'json', 'schema' => [ 'description' => 'Chat请求体。', 'type' => 'object', 'properties' => [ 'Title' => ['description' => '抬头,如果为空,会使用用户Question的前32个字符。', 'type' => 'string', 'required' => false, 'example' => '如何******'], 'ExtraData' => ['description' => '额外数据,目前用于Update里存用户更换规格的操作结果。', 'type' => 'string', 'required' => false, 'example' => '{"solutionDetail":{"formValues":{"params":{"InstanceId":"dsw-g54******qg9"},"content":{"EcsSpec":"ecs.gn6i-c8g1.2xlarge"}},"success":true}}'], 'Question' => ['description' => '对话内容。', 'required' => false, '$ref' => '#/components/schemas/ChatDetail'], 'Payload' => ['description' => '环境信息。格式如下'."\n" .'{'."\n" .' "context": {'."\n" .' "path": "当前页面所在路径",'."\n" .' "title": "当前页面抬头",'."\n" .' "currentTime": "当前时间"'."\n" .' },'."\n" .' "resourceInfo": {'."\n" .' "product": "产品"'."\n" .' }'."\n" .' }', 'type' => 'object', 'required' => false, 'example' => '{'."\n" .' "context": {'."\n" .' "path": "/workspace/overview",'."\n" .' "title": "人工智能平台PAI",'."\n" .' "currentTime": "2026-04-13T01:42:31.289Z"'."\n" .' },'."\n" .' "resourceInfo": {'."\n" .' "product": "dsw"'."\n" .' }'."\n" .' }'], ], 'required' => false, ], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], 'ChatId' => ['description' => 'Chat的ID。', 'type' => 'string', 'example' => 'chat-jkd******'], 'ErrorCode' => ['description' => '错误码。', 'type' => 'string', 'example' => '2187322'], 'ErrorMessage' => ['description' => '错误消息。', 'type' => 'string', 'example' => 'Stream error'], 'Answer' => ['description' => '流式回复。', '$ref' => '#/components/schemas/ChatDetail'], 'GmtCreateTime' => ['description' => '创建 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2021-01-21T17:12:35Z'], 'Status' => ['description' => '状态,支持如下值'."\n" .'- Canceled 中止'."\n" .'- Running 运行中'."\n" .'- Completed 正常结束'."\n" .'- Error 错误'."\n" .'- Canceling 中止中'."\n" .'- Interrupted 暂停', 'type' => 'string', 'example' => 'Running'], 'SessionId' => ['description' => 'Session的ID。', 'type' => 'string', 'example' => 'se-dss******'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '创建对话,使用SSE协议,对话结果由服务端推送', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"ChatId\\": \\"chat-jkd******\\",\\n \\"ErrorCode\\": \\"2187322\\",\\n \\"ErrorMessage\\": \\"Stream error\\",\\n \\"Answer\\": {\\n \\"UserInfo\\": {\\n \\"Role\\": \\"assistant\\",\\n \\"Name\\": \\"to******\\"\\n },\\n \\"Content\\": \\"你好******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\"\\n },\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\",\\n \\"Status\\": \\"Running\\",\\n \\"SessionId\\": \\"se-dss******\\"\\n}","type":"json"}]', ], 'CreateSession' => [ 'summary' => '创建Session,每次创建Chat时会带上同一个Session内之前创建的Chat作为历史消息。', 'path' => '/api/v1/sessions', 'methods' => ['post'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'create', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'body', 'in' => 'body', 'style' => 'json', 'schema' => [ 'description' => 'Session消息体。', 'type' => 'object', 'properties' => [ 'Title' => ['description' => '抬头,如果为空,会根据Chat自动总结。'."\n" .'最大大小为32字符。', 'type' => 'string', 'required' => false, 'example' => '如何*******'], 'Labels' => [ 'description' => '标签列表。', 'type' => 'array', 'items' => ['description' => '标签。', 'required' => false, '$ref' => '#/components/schemas/Label'], 'required' => false, ], ], 'required' => false, ], ], ], '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' => '44553E9A-******-37ADC33FE2'], 'SessionId' => ['description' => 'Session的ID。', 'type' => 'string', 'example' => 'se-weg******iqwcw'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '创建Session', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"SessionId\\": \\"se-weg******iqwcw\\"\\n}","type":"json"}]', ], 'DeleteChat' => [ 'path' => '/api/v1/sessions/{SessionId}/chats/{ChatId}', 'methods' => ['delete'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'delete', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'SessionId', 'in' => 'path', 'schema' => ['description' => 'Session的ID。', 'type' => 'string', 'required' => true, 'example' => 'se-dss******'], ], [ 'name' => 'ChatId', 'in' => 'path', 'schema' => ['description' => '对话的ID。', 'type' => 'string', 'required' => false, 'example' => 'chat-jkd******'], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '删除Chat', 'summary' => '删除Chat。', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\"\\n}","type":"json"}]', ], 'DeleteSession' => [ 'path' => '/api/v1/sessions/{SessionId}', 'methods' => ['delete'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'delete', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'SessionId', 'in' => 'path', 'allowEmptyValue' => false, 'schema' => ['title' => '幂等参数', 'description' => 'Session的ID。', 'type' => 'string', 'required' => false, 'example' => 'se-gac******idtv'], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], 'SessionId' => ['description' => 'Session的ID。', 'type' => 'string', 'example' => 'se-p4k******vx2y'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '删除Session', 'summary' => '删除Session以及所有关联的Chats。', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"SessionId\\": \\"se-p4k******vx2y\\"\\n}","type":"json"}]', ], 'GetChat' => [ 'path' => '/api/v1/sessions/{SessionId}/chats/{ChatId}', 'methods' => ['get'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'get', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'ChatId', 'in' => 'path', 'schema' => ['description' => '对话的ID。', 'type' => 'string', 'required' => true, 'example' => 'chat-jkd******'], ], [ 'name' => 'Verbose', 'in' => 'query', 'schema' => ['description' => '是否显示某些字段,目前支持'."\n" .'- QuestionAndAnswer(默认不显示,代表问题与回复)', 'type' => 'string', 'required' => false, 'example' => 'QuestionAndAnswer'], ], [ 'name' => 'SessionId', 'in' => 'path', 'schema' => ['description' => 'Session的ID。', 'type' => 'string', 'required' => true, 'example' => 'se-dss******'], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], 'ChatId' => ['description' => 'Chat的ID。', 'type' => 'string', 'example' => 'chat-jkd******'], 'GmtCreateTime' => ['description' => '创建 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2021-01-21T17:12:35Z'], 'GmtModified' => ['description' => '修改 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2025-12-01T17:52:05+08:00'], 'Question' => ['description' => '客户问题。', '$ref' => '#/components/schemas/ChatDetail'], 'Answer' => ['description' => '客户回复。', '$ref' => '#/components/schemas/ChatDetail'], 'OwnerId' => ['description' => '父创建人。', 'type' => 'string', 'example' => '1500******860'], 'UserId' => ['description' => '创建人。', 'type' => 'string', 'example' => '2100******360'], 'Title' => ['description' => '问题抬头。', 'type' => 'string', 'example' => 'how to ******'], 'SessionId' => ['description' => 'Session的ID。', 'type' => 'string', 'example' => 'se-dss******'], 'Status' => ['description' => '状态,支持如下值'."\n" .'- Canceled 中止'."\n" .'- Running 运行中'."\n" .'- Completed 正常结束'."\n" .'- Error 错误'."\n" .'- Canceling 中止中'."\n" .'- Interrupted 暂停', 'type' => 'string', 'example' => 'Running'], 'ExtraData' => ['description' => '额外数据,目前用于 Update 里存用户更换规格的操作结果。', 'type' => 'string', 'example' => '{"solutionDetail":{"formValues":{"params":{"InstanceId":"dsw-g54******qg9"},"content":{"EcsSpec":"ecs.gn6i-c8g1.2xlarge"}},"success":true}}'], 'Message' => ['description' => '该字段已废弃。', 'type' => 'string', 'example' => 'how to ******'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '获取对话详情', 'summary' => '获取对话详情。', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"ChatId\\": \\"chat-jkd******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\",\\n \\"GmtModified\\": \\"2025-12-01T17:52:05+08:00\\",\\n \\"Question\\": {\\n \\"UserInfo\\": {\\n \\"Role\\": \\"assistant\\",\\n \\"Name\\": \\"to******\\"\\n },\\n \\"Content\\": \\"你好******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\"\\n },\\n \\"Answer\\": {\\n \\"UserInfo\\": {\\n \\"Role\\": \\"assistant\\",\\n \\"Name\\": \\"to******\\"\\n },\\n \\"Content\\": \\"你好******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\"\\n },\\n \\"OwnerId\\": \\"1500******860\\",\\n \\"UserId\\": \\"2100******360\\",\\n \\"Title\\": \\"how to ******\\",\\n \\"SessionId\\": \\"se-dss******\\",\\n \\"Status\\": \\"Running\\",\\n \\"ExtraData\\": \\"{\\\\\\"solutionDetail\\\\\\":{\\\\\\"formValues\\\\\\":{\\\\\\"params\\\\\\":{\\\\\\"InstanceId\\\\\\":\\\\\\"dsw-g54******qg9\\\\\\"},\\\\\\"content\\\\\\":{\\\\\\"EcsSpec\\\\\\":\\\\\\"ecs.gn6i-c8g1.2xlarge\\\\\\"}},\\\\\\"success\\\\\\":true}}\\",\\n \\"Message\\": \\"how to ******\\"\\n}","type":"json"}]', ], 'GetSession' => [ 'path' => '/api/v1/sessions/{SessionId}', 'methods' => ['get'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'get', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'SessionId', 'in' => 'path', 'schema' => ['description' => 'Session的ID。', 'type' => 'string', 'required' => true, 'example' => 'se-weg******wcw'], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => 'ECB1F5******C1BF5223'], 'SessionId' => ['description' => 'Session的ID。', 'type' => 'string', 'example' => 'se-j6p******dram6'], 'GmtCreateTime' => ['description' => '创建 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2021-01-21T17:12:35.232Z'], 'GmtModified' => ['description' => '修改 UTC 时间,日期格式 iso8601。', 'type' => 'string', 'format' => 'iso8601_normal', 'example' => '2021-01-21T17:12:35.232Z'], 'OwnerId' => ['description' => '父创建人。', 'type' => 'string', 'example' => '1557******4904'], 'UserId' => ['description' => '创建人。', 'type' => 'string', 'example' => '27******94904'], 'Title' => ['description' => '抬头。', 'type' => 'string', 'example' => '如何******'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '获取Session', 'summary' => '获取Session详情。', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"ECB1F5******C1BF5223\\",\\n \\"SessionId\\": \\"se-j6p******dram6\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35.232Z\\",\\n \\"GmtModified\\": \\"2021-01-21T17:12:35.232Z\\",\\n \\"OwnerId\\": \\"1557******4904\\",\\n \\"UserId\\": \\"27******94904\\",\\n \\"Title\\": \\"如何******\\"\\n}","type":"json"}]', ], 'ListChats' => [ 'summary' => '获取Chat列表。', 'path' => '/api/v1/sessions/{SessionId}/chats', 'methods' => ['get'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'list', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'PageNumber', 'in' => 'query', 'schema' => ['description' => '分页,从1开始,默认1。', 'type' => 'integer', 'format' => 'int64', 'required' => false, 'example' => '1'], ], [ 'name' => 'SortBy', 'in' => 'query', 'schema' => ['description' => '排序字段:支持以下字段'."\n" .'- GmtCreateTime(默认)'."\n" .'- GmtModifiedTime', 'type' => 'string', 'required' => false, 'example' => 'GmtCreateTime'], ], [ 'name' => 'SessionId', 'in' => 'path', 'schema' => ['description' => 'Session的ID。', 'type' => 'string', 'required' => true, 'example' => 'se-dss******'], ], [ 'name' => 'Order', 'in' => 'query', 'schema' => ['description' => '排序方向:'."\n" .'- ASC - 升序'."\n" .'- DESC - 降序(默认)', 'type' => 'string', 'required' => false, 'example' => 'DESC'], ], [ 'name' => 'Verbose', 'in' => 'query', 'schema' => ['description' => '是否显示某些字段,多个字段以逗号分隔,目前支持'."\n" .'- QuestionAndAnswer', 'type' => 'string', 'required' => false, 'example' => 'QuestionAndAnswer'], ], [ 'name' => 'PageSize', 'in' => 'query', 'schema' => ['description' => '页大小,默认20,最大支持100。', 'type' => 'integer', 'format' => 'int64', 'required' => false, 'example' => '60'], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], 'TotalCount' => ['description' => '对话总数。', 'type' => 'integer', 'format' => 'int64', 'example' => '2'], 'Chats' => [ 'description' => '对话列表。', 'type' => 'array', 'items' => ['description' => '对话详情。', '$ref' => '#/components/schemas/Chat'], ], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '获取Chat列表', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"TotalCount\\": 2,\\n \\"Chats\\": [\\n {\\n \\"ChatId\\": \\"chat-jkd******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\",\\n \\"GmtModified\\": \\"2026-01-20T09:41:23Z\\",\\n \\"Question\\": {\\n \\"UserInfo\\": {\\n \\"Role\\": \\"assistant\\",\\n \\"Name\\": \\"to******\\"\\n },\\n \\"Content\\": \\"你好******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\"\\n },\\n \\"Answer\\": {\\n \\"UserInfo\\": {\\n \\"Role\\": \\"assistant\\",\\n \\"Name\\": \\"to******\\"\\n },\\n \\"Content\\": \\"你好******\\",\\n \\"GmtCreateTime\\": \\"2021-01-21T17:12:35Z\\"\\n },\\n \\"OwnerId\\": \\"1500******860\\",\\n \\"UserId\\": \\"2100******360\\",\\n \\"Title\\": \\"how to ******\\",\\n \\"SessionId\\": \\"se-dss******\\",\\n \\"Status\\": \\"Running\\",\\n \\"ExtraData\\": \\"{\\\\\\"solutionDetail\\\\\\":{\\\\\\"formValues\\\\\\":{\\\\\\"params\\\\\\":{\\\\\\"InstanceId\\\\\\":\\\\\\"dsw-g54******qg9\\\\\\"},\\\\\\"content\\\\\\":{\\\\\\"EcsSpec\\\\\\":\\\\\\"ecs.gn6i-c8g1.2xlarge\\\\\\"}},\\\\\\"success\\\\\\":true}}\\",\\n \\"Message\\": \\"how to ******\\"\\n }\\n ]\\n}","type":"json"}]', ], 'ListSessions' => [ 'path' => '/api/v1/sessions', 'methods' => ['get'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'read', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'list', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'PageNumber', 'in' => 'query', 'schema' => ['description' => '分页,从1开始,默认1。', 'type' => 'integer', 'format' => 'int64', 'required' => false, 'example' => '1'], ], [ 'name' => 'SortBy', 'in' => 'query', 'schema' => ['description' => '排序字段:支持以下字段'."\n" ."\n" .'- GmtCreateTime'."\n" .'- GmtModified', 'type' => 'string', 'required' => false, 'example' => 'GmtModified'], ], [ 'name' => 'Order', 'in' => 'query', 'schema' => ['description' => '排序方向:'."\n" ."\n" .'- ASC 升序'."\n" .'- DESC 降序', 'type' => 'string', 'required' => false, 'example' => 'ASC'], ], [ 'name' => 'PageSize', 'in' => 'query', 'schema' => ['description' => '页大小,默认20,最大支持100。', 'type' => 'integer', 'format' => 'int64', 'required' => false, 'example' => '20'], ], [ 'name' => 'Labels', 'in' => 'query', 'schema' => ['description' => '标签过滤值'."\n" .'以逗号分隔,必须全部满足。', 'type' => 'string', 'required' => false, 'example' => 'system.product.type=DLC'], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '响应体。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], 'Sessions' => [ 'description' => 'Session列表。', 'type' => 'array', 'items' => ['description' => 'Session详情。', '$ref' => '#/components/schemas/Session'], ], 'TotalCount' => ['description' => '总数。', 'type' => 'integer', 'format' => 'int64', 'example' => '2'], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '列举Session', 'summary' => '列举Session集合。', 'changeSet' => [], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"Sessions\\": [\\n {\\n \\"SessionId\\": \\"\\",\\n \\"GmtCreateTime\\": \\"\\",\\n \\"GmtModified\\": \\"\\",\\n \\"OwnerId\\": \\"\\",\\n \\"UserId\\": \\"\\",\\n \\"SessionTitle\\": \\"\\"\\n }\\n ],\\n \\"TotalCount\\": 2\\n}","type":"json"}]', ], 'SearchInfo' => [ 'path' => '/api/v1/searches', 'methods' => ['post'], 'schemes' => ['https'], 'security' => [ [ 'AK' => [], ], ], 'consumes' => ['application/json'], 'produces' => ['application/json'], 'operationType' => 'write', 'deprecated' => false, 'systemTags' => [ 'operationType' => 'create', 'riskType' => 'none', 'chargeType' => 'free', 'abilityTreeNodes' => ['FEATURElearnOTS2AE'], 'autoTest' => true, 'tenantRelevance' => 'tenant', ], 'parameters' => [ [ 'name' => 'body', 'in' => 'body', 'style' => 'json', 'schema' => [ 'description' => '搜索请求体。', 'type' => 'object', 'properties' => [ 'KnowledgeBaseFilters' => [ 'description' => '知识库搜索条件集合。', 'type' => 'array', 'items' => [ 'description' => '知识库搜索条件。', 'type' => 'object', 'properties' => [ 'CollectionName' => ['description' => '文档集名字。', 'type' => 'string', 'required' => true, 'example' => 'pai_qa'], 'ResultLimit' => ['description' => '最多返回搜索结果个数,默认为3个。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '5'], 'ScoreThreshold' => ['description' => '搜索结果必须满足的最低分数(包含最低分数),分数表示搜索结果与搜索条件的匹配度,满分为1分。', 'type' => 'number', 'format' => 'double', 'required' => false, 'example' => '0.7827883223'], 'Query' => ['description' => '搜索词。', 'type' => 'string', 'required' => true, 'example' => 'what is pai'], ], 'required' => false, ], 'required' => false, ], 'WebFilters' => [ 'description' => '联网搜索条件集合。', 'type' => 'array', 'items' => [ 'description' => '联网搜索条件。', 'type' => 'object', 'properties' => [ 'ResultLimit' => ['description' => '最多返回搜索结果个数,默认为3个。', 'type' => 'integer', 'format' => 'int32', 'required' => false, 'example' => '5'], 'IncludeSites' => [ 'description' => '搜索站点集合。', 'type' => 'array', 'items' => ['description' => '搜索站点。', 'type' => 'string', 'required' => false, 'example' => 'help.aliyun.com'], 'required' => false, ], 'ScoreThreshold' => ['description' => '搜索结果必须满足的最低分数(包含最低分数),分数表示搜索结果与搜索条件的匹配度,满分为1分。', 'type' => 'number', 'format' => 'double', 'required' => false, 'example' => '0.832883223'], 'Query' => ['description' => '搜索词。', 'type' => 'string', 'required' => true, 'example' => 'what is dsw'], 'Category' => ['type' => 'string', 'required' => false, 'description' => ''], ], 'required' => false, ], 'required' => false, ], ], 'required' => false, ], ], ], 'responses' => [ 200 => [ 'schema' => [ 'title' => 'Schema of Response', 'description' => '搜索结果。', 'type' => 'object', 'properties' => [ 'RequestId' => ['title' => 'Id of the request', 'description' => '请求ID。', 'type' => 'string', 'example' => '44553E9A-******-37ADC33FE2'], 'KnowledgeBaseSearchResults' => [ 'description' => '知识库搜索结果集合。', 'type' => 'array', 'items' => [ 'description' => '知识库搜索结果。', 'type' => 'object', 'properties' => [ 'ResultContent' => ['description' => '搜索结果内容。', 'type' => 'string', 'example' => 'DSW is ****** in pai.'], 'Score' => ['description' => '分数,用于表示搜索内容与搜索条件的匹配度,满分为1分。', 'type' => 'number', 'format' => 'double', 'example' => '0.6215165367'], 'Index' => ['description' => '代表第几个KnowledgeBase问题的答复,下标从0开始。', 'type' => 'string', 'example' => '0'], ], ], ], 'WebSearchResults' => [ 'description' => '联网搜索结果集合。', 'type' => 'array', 'items' => [ 'description' => '联网搜索结果。', 'type' => 'object', 'properties' => [ 'SourceLink' => ['description' => '来源网址。', 'type' => 'string', 'example' => 'https://help.aliyun.com/zh/pai/use-cases/dsw-use-qwen3-coder-to-assist-in-code-development'], 'ResultContent' => ['description' => '搜索结果内容。', 'type' => 'string', 'example' => 'Qwen3-Coder*****is good'], 'Score' => ['description' => '分数,用于表示搜索内容与搜索条件的匹配度,满分为1分。', 'type' => 'number', 'format' => 'double', 'example' => '0.5215170567'], 'Index' => ['description' => '代表第几个Web问题的答复,下标从0开始。', 'type' => 'string', 'example' => '2'], ], ], ], ], ], ], ], 'errorCodes' => [ 400 => [ ['errorCode' => 'IdempotentParameterMismatch', 'errorMessage' => 'The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.', 'description' => ''], ], ], 'staticInfo' => ['returnType' => 'synchronous'], 'title' => '联网搜索以及知识库搜索', 'summary' => '进行联网搜索以及知识库搜索。', 'changeSet' => [ ['createdAt' => '2025-12-26T04:38:05.000Z', 'description' => '请求参数发生变更'], ], 'flowControl' => [ 'flowControlList' => [], ], 'responseDemo' => '[{"errorExample":"","example":"{\\n \\"RequestId\\": \\"44553E9A-******-37ADC33FE2\\",\\n \\"KnowledgeBaseSearchResults\\": [\\n {\\n \\"ResultContent\\": \\"DSW is ****** in pai.\\",\\n \\"Score\\": 0.6215165367,\\n \\"Index\\": \\"0\\"\\n }\\n ],\\n \\"WebSearchResults\\": [\\n {\\n \\"SourceLink\\": \\"https://help.aliyun.com/zh/pai/use-cases/dsw-use-qwen3-coder-to-assist-in-code-development\\",\\n \\"ResultContent\\": \\"Qwen3-Coder*****is good\\",\\n \\"Score\\": 0.5215170567,\\n \\"Index\\": \\"2\\"\\n }\\n ]\\n}","type":"json"}]', ], ], 'endpoints' => [ ['regionId' => 'ap-southeast-1', 'regionName' => '新加坡', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paicopilot.ap-southeast-1.aliyuncs.com', 'endpoint' => 'paicopilot.ap-southeast-1.aliyuncs.com', 'vpc' => 'paicopilot-vpc.ap-southeast-1.aliyuncs.com'], ['regionId' => 'cn-beijing', 'regionName' => '华北2(北京)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paicopilot.cn-beijing.aliyuncs.com', 'endpoint' => 'paicopilot.cn-beijing.aliyuncs.com', 'vpc' => 'paicopilot-vpc.cn-beijing.aliyuncs.com'], ['regionId' => 'cn-hangzhou', 'regionName' => '华东1(杭州)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paicopilot.cn-hangzhou.aliyuncs.com', 'endpoint' => 'paicopilot.cn-hangzhou.aliyuncs.com', 'vpc' => 'paicopilot-vpc.cn-hangzhou.aliyuncs.com'], ['regionId' => 'cn-shanghai', 'regionName' => '华东2(上海)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paicopilot.cn-shanghai.aliyuncs.com', 'endpoint' => 'paicopilot.cn-shanghai.aliyuncs.com', 'vpc' => 'paicopilot-vpc.cn-shanghai.aliyuncs.com'], ['regionId' => 'cn-shenzhen', 'regionName' => '华南1(深圳)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paicopilot.cn-shenzhen.aliyuncs.com', 'endpoint' => 'paicopilot.cn-shenzhen.aliyuncs.com', 'vpc' => 'paicopilot-vpc.cn-shenzhen.aliyuncs.com'], ['regionId' => 'cn-wulanchabu', 'regionName' => '华北6(乌兰察布)', 'areaId' => 'asiaPacific', 'areaName' => '亚太', 'public' => 'paicopilot.cn-wulanchabu.aliyuncs.com', 'endpoint' => 'paicopilot.cn-wulanchabu.aliyuncs.com', 'vpc' => 'paicopilot-vpc.cn-wulanchabu.aliyuncs.com'], ], 'errorCodes' => [], 'changeSet' => [ [ 'apis' => [ ['description' => '请求参数发生变更', 'api' => 'SearchInfo'], ], 'createdAt' => '2025-12-26T04:38:11.000Z', 'description' => '', ], ], 'flowControl' => [ 'flowControlList' => [ ['threshold' => '-1', 'countWindow' => 1, 'regionId' => '*'], ], ], ];