Commit c8ef6466 by jixudong

Replace 项目列表-问答.md

parent df46b972
**测试环境URL**:http://tx-gz14.heyqiwu.cn **测试环境URL**:http://tx-gz14.heyqiwu.cn
...@@ -14,9 +14,9 @@ ...@@ -14,9 +14,9 @@
#### 请求path字段说明 #### 请求path字段说明
| key | type | required | description | | key | type | required | description |
| ------ | ---- | -------- | ----------- | | ------ | ------ | -------- | ----------- |
| plotId | | yes | 剧情点ID | | plotId | number | yes | 剧情点ID |
#### 请求param字段说明 #### 请求param字段说明
...@@ -81,9 +81,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -81,9 +81,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \
#### 请求path字段说明 #### 请求path字段说明
| key | type | required | description | | key | type | required | description |
| ------ | ---- | -------- | ----------- | | ------ | ------ | -------- | ----------- |
| plotId | | yes | 剧情点id | | plotId | number | yes | 剧情点id |
#### 请求param字段说明 #### 请求param字段说明
...@@ -93,21 +93,21 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -93,21 +93,21 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \
#### 请求body字段说明 #### 请求body字段说明
| key | type | required | description | | key | type | required | description |
| -------- | ---- | -------- | ----------- | | -------- | ------ | -------- | ----------- |
| id | | yes | 主键ID | | id | number | yes | 主键ID |
| question | | yes | 问题内容 | | question | string | yes | 问题内容 |
| fType | | yes | 无效字段 | | fType | number | yes | 无效字段 |
| answer | | yes | 已弃用 | | answer | object | yes | 回答 |
answer值说明 answer值说明
| key | type | description | | key | type | description |
| ------- | ---- | ----------- | | ------- | ------ | ----------- |
| content | | 回答内容 | | content | string | 回答内容 |
| npcId | | 角色id | | npcId | number | 角色id |
| npcName | | 角色名称 | | npcName | string | 角色名称 |
| mood | | 情绪 | | mood | string | 情绪 |
#### 请求示例 #### 请求示例
...@@ -141,7 +141,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -141,7 +141,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \
} }
``` ```
### 上传qa数据 ### 上传问答文件
**METHOD**: POST **METHOD**: POST
...@@ -157,10 +157,10 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -157,10 +157,10 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \
#### 请求body字段说明 form data #### 请求body字段说明 form data
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ------------- | | --------- | ------ | -------- | ------------- |
| file | | yes | 问答excel文件 | | file | excel | yes | 问答excel文件 |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求示例 #### 请求示例
...@@ -193,7 +193,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/upload' \ ...@@ -193,7 +193,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/upload' \
} }
``` ```
### 导出qa数据 ### 下载问答
**METHOD**: GET **METHOD**: GET
...@@ -203,10 +203,10 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/upload' \ ...@@ -203,10 +203,10 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/upload' \
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目ID | | projectId | number | yes | 项目ID |
| plotId | | yes | 剧情ID | | plotId | number | yes | 剧情ID |
#### 请求body字段说明 #### 请求body字段说明
...@@ -258,7 +258,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/export?projectId=1&plotId ...@@ -258,7 +258,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/export?projectId=1&plotId
} }
``` ```
### 获取通用QA ### 获取通用问答
**METHOD**: GET **METHOD**: GET
...@@ -268,11 +268,11 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/export?projectId=1&plotId ...@@ -268,11 +268,11 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/export?projectId=1&plotId
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目ID | | projectId | number | yes | 项目ID |
| pageSize | | yes | 页面数据量 | | pageSize | number | yes | 页面数据量 |
| pageNum | | no | 页码 | | pageNum | number | no | 页码 |
#### 请求body字段说明 #### 请求body字段说明
...@@ -331,7 +331,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA?projectId=1&pageSi ...@@ -331,7 +331,7 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA?projectId=1&pageSi
} }
``` ```
### 获取全局qa数据 ### 获取全局问答数据
**METHOD**: GET **METHOD**: GET
...@@ -341,9 +341,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA?projectId=1&pageSi ...@@ -341,9 +341,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA?projectId=1&pageSi
#### 请求path字段说明 #### 请求path字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求param字段说明 #### 请求param字段说明
...@@ -407,9 +407,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA/1/' \ ...@@ -407,9 +407,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA/1/' \
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求body字段说明 #### 请求body字段说明
...@@ -512,11 +512,11 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/all?projectId=3165 ...@@ -512,11 +512,11 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/all?projectId=3165
#### 请求body字段说明 #### 请求body字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| id | | yes | 问答id | | id | number | yes | 问答id |
| answer | | yes | 回答 | | answer | string | yes | 回答 |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求示例 #### 请求示例
...@@ -561,9 +561,9 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/tmpl' \ ...@@ -561,9 +561,9 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/tmpl' \
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求body字段说明 #### 请求body字段说明
...@@ -612,9 +612,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/system/qa/all/enable?project ...@@ -612,9 +612,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/system/qa/all/enable?project
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求body字段说明 #### 请求body字段说明
...@@ -663,15 +663,15 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/system/qa/all/disable?projec ...@@ -663,15 +663,15 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/system/qa/all/disable?projec
#### 请求path字段说明 #### 请求path字段说明
| key | type | required | description | | key | type | required | description |
| ---- | ---- | -------- | -------------- | | ---- | ------ | -------- | -------------- |
| id | | yes | 系统问答主键ID | | id | number | yes | 系统问答主键ID |
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求body字段说明 #### 请求body字段说明
...@@ -721,15 +721,15 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/%20126845/enable?p ...@@ -721,15 +721,15 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/%20126845/enable?p
#### 请求path字段说明 #### 请求path字段说明
| key | type | required | description | | key | type | required | description |
| ---- | ---- | -------- | -------------- | | ---- | ------ | -------- | -------------- |
| id | | yes | 系统问答主键ID | | id | number | yes | 系统问答主键ID |
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求body字段说明 #### 请求body字段说明
...@@ -779,9 +779,9 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/126845/disable?pro ...@@ -779,9 +779,9 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/126845/disable?pro
#### 请求param字段说明 #### 请求param字段说明
| key | type | required | description | | key | type | required | description |
| --------- | ---- | -------- | ----------- | | --------- | ------ | -------- | ----------- |
| projectId | | yes | 项目id | | projectId | number | yes | 项目id |
#### 请求body字段说明 #### 请求body字段说明
...@@ -837,4 +837,134 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/score?projectId=6381' \ ...@@ -837,4 +837,134 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/score?projectId=6381' \
} }
``` ```
### 获取兜底回答
**METHOD**: GET
**path**: api/platform/design/npc/instance/unknown_text/{projectId}/
**RequestHeaders:** 同创作平台请求header
#### 请求path字段说明
| key | type | required | description |
| --------- | ------ | -------- | ----------- |
| projectId | number | yes | 项目id |
#### 请求param字段说明
| key | type | required | description |
| ---- | ---- | -------- | ----------- |
| 无 | | | |
#### 请求body字段说明
| key | type | required | description |
| ---- | ---- | -------- | ----------- |
| 无 | | | |
#### 请求示例
```js
curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/npc/instance/unknown_text/1/' \
-H 'Accept: application/json, text/plain, */*' \
-H 'Accept-Language: zh-CN,zh;q=0.9' \
-H 'Authorization: Basic ZXlKaGJHY2lPaUpJVXpJMU5pSjkuZXlKcFlYUWlPakUzTURFd05qZzVOekVzSW1WNGNDSTZNVGN3TVRBM05qRTNNU3dpWVhWMGFHOXlhWFI1SWpveExDSnBaQ0k2TWpJMGZRLlpLUS10eDBDUHkweklNT1haTkxSWWxFaElCcU8zMHJPUGw1eUZMeWdRVkk6czAwcGVyczNjcmV0' \
-H 'Connection: keep-alive' \
-H 'Origin: http://localhost:8080' \
-H 'Referer: http://localhost:8080/' \
-H 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Safari/537.36' \
-H 'botAccount: 6080626246' \
-H 'groupId: 76' \
-H 'mul: true' \
-H 'projectId: 1' \
--compressed \
--insecure
```
#### 响应实例
```json
{
"code": 1,
"msg": "成功",
"data": [
{
"id": null,
"unknownText": "不好意思,我没听懂你在说什么\n我没明白你的意思,能不能换个说法啊\n不是很明白您的意思,求您换个表达方式吧",
"npcName": "总的无匹配文本",
"status": 1
},
{
"id": 145382,
"unknownText": "不好意思,我没听懂你在说什么\n我没明白你的意思,能不能换个说法啊\n不是很明白您的意思,求您换个表达方式吧",
"npcName": "家丁",
"status": 0
}
]
}
```
### 修改兜底回答
**METHOD**: PUT
**path**: api/platform/design/npc/instance/unknown_text/{projectId}/
**RequestHeaders:** 同创作平台请求header
#### 请求path字段说明
| key | type | required | description |
| --------- | ------ | -------- | ----------- |
| projectId | number | yes | 项目id |
#### 请求param字段说明
| key | type | required | description |
| ---- | ---- | -------- | ----------- |
| 无 | | | |
#### 请求body字段说明
| key | type | required | description |
| -------------- | ------ | -------- | ---------------------------------- |
| id | number | no | 回答id |
| npcName | string | yes | 角色名称 |
| oneUnknownText | string | yes | 第一条回答 |
| status | number | yes | 1代表总的无匹配文本,0代表其他角色 |
| unknownText | string | yes | 回答 |
#### 请求示例
```js
curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/npc/instance/unknown_text/1/' \
-X 'PUT' \
-H 'Accept: application/json, text/plain, */*' \
-H 'Accept-Language: zh-CN,zh;q=0.9' \
-H 'Authorization: Basic ZXlKaGJHY2lPaUpJVXpJMU5pSjkuZXlKcFlYUWlPakUzTURFd05qZzVOekVzSW1WNGNDSTZNVGN3TVRBM05qRTNNU3dpWVhWMGFHOXlhWFI1SWpveExDSnBaQ0k2TWpJMGZRLlpLUS10eDBDUHkweklNT1haTkxSWWxFaElCcU8zMHJPUGw1eUZMeWdRVkk6czAwcGVyczNjcmV0' \
-H 'Connection: keep-alive' \
-H 'Content-Type: application/json;charset=UTF-8' \
-H 'Origin: http://localhost:8080' \
-H 'Referer: http://localhost:8080/' \
-H 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Safari/537.36' \
-H 'botAccount: 6080626246' \
-H 'groupId: 76' \
-H 'mul: true' \
-H 'projectId: 1' \
--data-raw '[{"id":null,"unknownText":"不好意思,我没听懂你在说什么\n我没明白你的意思,能不能换个说法啊\n不是很明白您的意思,求您换个表达方式吧","npcName":"总的无匹配文本","status":1,"oneUnknownText":"不好意思,我没听懂你在说什么......"},{"id":145382,"unknownText":"不好意思,我没听懂你在说什么\n我没明白你的意思,能不能换个说法啊\n不是很明白您的意思,求您换个表达方式吧","npcName":"家丁","status":0,"oneUnknownText":"不好意思,我没听懂你在说什么......"}]' \
--compressed \
--insecure
```
#### 响应实例
```json
{
"code": 1,
"msg": "成功",
"data": null
}
```
### ###
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment