Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jiaoyou_doc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李进峰
jiaoyou_doc
Commits
a4f1f04f
Commit
a4f1f04f
authored
Dec 11, 2023
by
jixudong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replace 对话.md
parent
82b7710d
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
326 additions
and
1 deletion
+326
-1
对话.md
gameditor/前端接口/对话.md
+326
-1
No files found.
gameditor/前端接口/对话.md
View file @
a4f1f04f
**测试环
境URL**
:http://tx-gz14.heyqiwu.cn
**测试环
境URL**
:http://tx-gz14.heyqiwu.cn
...
@@ -53,3 +53,327 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generate/state/?projectId=63
...
@@ -53,3 +53,327 @@ curl 'http://tx-gz14.heyqiwu.cn/api/platform/design/generate/state/?projectId=63
}
}
```
```
### 对话
**METHOD**
: POST
**path**
: api/platform/chat/api/voiceTestChat
**RequestHeaders:**
同创作平台请求header
#### 请求param字段说明
| key | type | required | description |
| ---- | ---- | -------- | ----------- |
| 无 | | | |
#### 请求body字段说明
| key | type | required | description |
| ---------- | ---- | -------- | -------------- |
| userId | | no | client_id |
| message | | yes | 输入的内容 |
| chatKey | | yes | |
| nickname | | yes | 昵称 |
| botAccount | | yes | 在引擎中的帐号 |
| audio | | yes | 音频 |
#### 请求示例
```
js
curl
'http://tx-gz14.heyqiwu.cn/api/platform/chat/api/voiceTestChat'
\
-
H
'Accept: application/json, text/plain, */*'
\
-
H
'Accept-Language: zh-CN,zh;q=0.9'
\
-
H
'Authorization: Basic OnMwMHBlcnMzY3JldA=='
\
-
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'
\
--
data
-
raw
'{"userId":"","message":"1
\
n","chatKey":"VGOJ6oal8IUarP9QPimy","nickname":"visitor","botAccount":"txgz14botwww853177949","audio":false}'
\
--
compressed
\
--
insecure
```
#### 响应实例
```
json
{
"msg"
:
"SUCCESS"
,
"code"
:
1
,
"dialogList"
:
[
{
"npcName"
:
"周逸生"
,
"text"
:
"你也是去提交资料的吗?我记得你,你是在研讨会上精准提问,被学校当成招生宣传片片段的女生。"
,
"audio"
:
""
},
{
"npcName"
:
"旁白"
,
"text"
:
"本是盯着他手里的那张资料,目光却偏了,落在他的身上。"
,
"audio"
:
""
}
],
"botPostData"
:
null
,
"chatKey"
:
"VGOJ6oal8IUarP9QPimy"
,
"plotImgUrl"
:
null
,
"logs"
:
[
{
"originText"
:
"1"
,
"distVariables"
:
[
{
"name"
:
"系统源剧情点"
,
"share"
:
false
,
"value"
:
"800-1"
},
{
"name"
:
"用户重复回复次数"
,
"share"
:
false
,
"value"
:
"0"
}
],
"updateVars"
:
[],
"chatKey"
:
"VGOJ6oal8IUarP9QPimy"
,
"originVariables"
:
[
{
"name"
:
"系统源剧情点"
,
"share"
:
false
,
"value"
:
"800-1"
},
{
"name"
:
"用户重复回复次数"
,
"share"
:
false
,
"value"
:
"0"
}
],
"matchedBranchs"
:
[
{
"note"
:
"剧情800-1的分支[分支3-680272]"
,
"satisfy"
:
true
,
"show"
:
true
,
"actionId"
:
4000001
,
"conditionPriority"
:
3
,
"matchedConditions"
:
[
{
"currentConditionSO"
:
[
"txgz14botwww853177949_plot_800-1"
],
"valueRange"
:
[
"txgz14botwww853177949_plot_800-1"
],
"description"
:
null
,
"conditionName"
:
null
,
"semanticRelationName"
:
null
,
"operator"
:
"match-Include"
},
{
"currentConditionSO"
:
[
"任意地点"
],
"valueRange"
:
[
"任意地点"
],
"description"
:
null
,
"conditionName"
:
null
,
"semanticRelationName"
:
null
,
"operator"
:
"match-Include"
},
{
"currentConditionSO"
:
[
"1"
],
"valueRange"
:
[
"1"
],
"description"
:
null
,
"conditionName"
:
null
,
"semanticRelationName"
:
null
,
"operator"
:
"number-BiggerOrEqual"
}
],
"execute"
:
true
,
"auxiliaryPriority"
:
8
},
{
"note"
:
"剧情800-1-3的合并剧情"
,
"satisfy"
:
true
,
"show"
:
true
,
"actionId"
:
4000114
,
"conditionPriority"
:
3
,
"matchedConditions"
:
[
{
"currentConditionSO"
:
[
"txgz14botwww853177949_plot_800-1-3"
],
"valueRange"
:
[
"txgz14botwww853177949_plot_800-1-3"
],
"description"
:
null
,
"conditionName"
:
null
,
"semanticRelationName"
:
null
,
"operator"
:
"match-Include"
},
{
"currentConditionSO"
:
[
"任意地点"
],
"valueRange"
:
[
"任意地点"
],
"description"
:
null
,
"conditionName"
:
null
,
"semanticRelationName"
:
null
,
"operator"
:
"match-Include"
},
{
"currentConditionSO"
:
[
"1"
],
"valueRange"
:
[
"1"
],
"description"
:
null
,
"conditionName"
:
null
,
"semanticRelationName"
:
null
,
"operator"
:
"number-BiggerOrEqual"
}
],
"execute"
:
true
,
"auxiliaryPriority"
:
10
}
],
"conditionNameSoSet"
:
{
"unknownText_backup"
:
[],
"unknownText"
:
[]
},
"distPlotNum"
:
"800-2"
,
"doLastProcess"
:
false
,
"originPlotNum"
:
"800-1"
,
"queryText"
:
"1"
,
"queryPos"
:
""
,
"matchedConditions"
:
[],
"logStr"
:
null
,
"botAccount"
:
"txgz14botwww853177949"
,
"reply"
:
"【周逸生@正常】你也是去提交资料的吗?我记得你,你是在研讨会上精准提问,被学校当成招生宣传片片段的女生。【旁白@正常】本是盯着他手里的那张资料,目光却偏了,落在他的身上。【旁白@正常】男生气质出挑,眉目清秀,那一身简单的白色衣裤衬得他极为清隽。你没来得及反应过来,已经对上他那双眸子。【周逸生@正常】给你。►SEND_CC_DATA{
\"
priority
\"
:8}SEND_CC_DATA◄"
,
"mapIntents"
:
[]
}
],
"bgmUrl"
:
null
}
```
### 获取对话作品信息
**METHOD**
: GET
**path**
: api/platform/design/api/works
**RequestHeaders:**
同创作平台请求header
#### 请求param字段说明
| key | type | required | description |
| ----------------- | ---- | -------- | -------------- |
| include | | yes | 包含内容 |
| aipioneerUsername | | yes | 在引擎中的帐号 |
include值说明
| key | type | description |
| ------------- | ---- | ----------- |
| worksName | | 作品名 |
| authorName | | 作品姓名 |
| npcHeadImgUrl | | 角色头像 |
#### 请求body字段说明
| key | type | required | description |
| ---- | ---- | -------- | ----------- |
| 无 | | | |
#### 请求示例
```
js
curl
'http://tx-gz14.heyqiwu.cn/api/platform/design/api/works?include=worksName,authorName,npcHeadImgUrl&aipioneerUsername=txgz14botwww853177949'
\
-
H
'Accept: application/json, text/plain, */*'
\
-
H
'Accept-Language: zh-CN,zh;q=0.9'
\
-
H
'Authorization: Basic ZXlKaGJHY2lPaUpJVXpJMU5pSjkuZXlKcFlYUWlPakUzTURJeU5UZzBNVGtzSW1WNGNDSTZNVGN3TWpJMk5UWXhPU3dpWVhWMGFHOXlhWFI1SWpveExDSnBaQ0k2TWpJMGZRLkJTYXpJNzV0RHJLQU94WGdVYXRPNUdTcWYyLTcySmZ2RHJoM3MybjRFQ0E6czAwcGVyczNjcmV0'
\
-
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: txgz14botwww853177949'
\
-
H
'groupId: 713'
\
-
H
'mul: true'
\
-
H
'projectId: 6381'
\
--
compressed
\
--
insecure
```
#### 响应实例
```
json
{
"code"
:
1
,
"msg"
:
"成功"
,
"data"
:
{
"worksName"
:
"w"
,
"authorName"
:
null
,
"intro"
:
null
,
"worksBannerImgUrl"
:
""
,
"chatUrl"
:
"http://tx-gz14.heyqiwu.cn:8070/api/voiceTestChat"
,
"npcHeadImgUrl"
:
{
"旁白"
:
""
,
"周逸生"
:
""
,
"王珊"
:
""
,
"关越闻"
:
""
,
"公司老总"
:
""
,
"总管"
:
""
,
"指令系统"
:
""
}
}
}
```
### 获取对话作品信息
**METHOD**
: GET
**path**
: http://tx-gz14.heyqiwu.cn:9663/api/audio/cache/{aipioneerUsername}/
**RequestHeaders:**
同创作平台请求header
#### 请求param字段说明
| key | type | required | description |
| ----------------- | ---- | -------- | ----------- |
| filename | | yes | 包含内容 |
| aipioneerUsername | | yes | |
#### 请求body字段说明
| key | type | required | description |
| ---- | ---- | -------- | ----------- |
| 无 | | | |
#### 请求示例
```
js
curl
'http://tx-gz14.heyqiwu.cn:9663/api/audio/cache/txgz14botwww853177949/?filename=/txgz14botwww853177949/ProTencent11/%E6%AD%A3%E5%B8%B8/d1a4e78fcabc73b55aa506b7f493d4f7.mp3×tamp=1702263661210&timeDate=1702263666662'
\
-
H
'Accept: */*'
\
-
H
'Accept-Language: zh-CN,zh;q=0.9'
\
-
H
'Connection: keep-alive'
\
-
H
'Range: bytes=0-'
\
-
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'
\
--
compressed
\
--
insecure
```
#### 响应实例
```
json
{
}
```
###
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment