Commit c8ef6466 by jixudong

Replace 项目列表-问答.md

parent df46b972
**测试环境URL**:http://tx-gz14.heyqiwu.cn **测试环境URL**:http://tx-gz14.heyqiwu.cn
...@@ -15,8 +15,8 @@ ...@@ -15,8 +15,8 @@
#### 请求path字段说明 #### 请求path字段说明
| key | type | required | description | | key | type | required | description |
| ------ | ---- | -------- | ----------- | | ------ | ------ | -------- | ----------- |
| plotId | | yes | 剧情点ID | | plotId | number | yes | 剧情点ID |
#### 请求param字段说明 #### 请求param字段说明
...@@ -82,8 +82,8 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -82,8 +82,8 @@ 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字段说明
...@@ -94,20 +94,20 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -94,20 +94,20 @@ 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
...@@ -158,9 +158,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/plot/qa/1914361/' \ ...@@ -158,9 +158,9 @@ 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
...@@ -204,9 +204,9 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/upload' \ ...@@ -204,9 +204,9 @@ 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
...@@ -269,10 +269,10 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/qa/export?projectId=1&plotId ...@@ -269,10 +269,10 @@ 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
...@@ -342,8 +342,8 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA?projectId=1&pageSi ...@@ -342,8 +342,8 @@ 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字段说明
...@@ -408,8 +408,8 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generalQA/1/' \ ...@@ -408,8 +408,8 @@ 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字段说明
...@@ -513,10 +513,10 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/all?projectId=3165 ...@@ -513,10 +513,10 @@ 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 |
#### 请求示例 #### 请求示例
...@@ -562,8 +562,8 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/tmpl' \ ...@@ -562,8 +562,8 @@ 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字段说明
...@@ -613,8 +613,8 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/system/qa/all/enable?project ...@@ -613,8 +613,8 @@ 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字段说明
...@@ -664,14 +664,14 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/system/qa/all/disable?projec ...@@ -664,14 +664,14 @@ 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字段说明
...@@ -722,14 +722,14 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/%20126845/enable?p ...@@ -722,14 +722,14 @@ 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字段说明
...@@ -780,8 +780,8 @@ curl 'http://tx-gz11.heyqiwu.cn/api/platform/design/system/qa/126845/disable?pro ...@@ -780,8 +780,8 @@ 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