- 请求 URL:
/api/baidus
- 请求方式:
GET
- Body 信息:无
- 返回值:
[
{
"name": "baidu",
"deleted_at": "",
"disabled": 1,
"description": "",
"updated_at": "2022-05-17 12:20:56",
"created_at": "2022-05-17 12:20:56",
"id": 1
}
]
curl -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" 192.168.1.100:8081/api/baidus
- 请求 URL:
/api/baidus/:id
- 请求方式:
GET
- Body 信息:无
- 返回值:
{
"disabled": 0,
"params": [{
"disabled": "0",
"realm": "BAIDU-TTS",
"deleted_at": "",
"ref_id": "1",
"k": "token-url",
"updated_at": "2025-09-03 01:42:53",
"created_at": "2025-09-03 01:42:53",
"id": "883",
"v": "https://openapi.baidu.com/oauth/2.0/token"
}, {
"disabled": "0",
"realm": "BAIDU-TTS",
"deleted_at": "",
"ref_id": "1",
"k": "tts-url",
"updated_at": "2025-09-03 01:42:53",
"created_at": "2025-09-03 01:42:53",
"id": "884",
"v": "http://tsn.baidu.com//text2audio"
}
...
],
"name": "baidu",
"updated_at": "2025-09-03 01:42:52",
"description": "default",
"created_at": "2025-09-03 01:42:52",
"id": 1,
"deleted_at": ""
}
- 请求 URL:
/api/baidus
- 请求方式:
POST
- Body 信息:
参数 | 说明 |
---|
name | baidu profile 名称 |
description | baidu profile 描述 |
template | 模板,默认模板:"default" |
{
"name": "test",
"description": "test",
"template": "default"
}
{
"code": 200,
"data": 2,
"message": "success"
}
curl -XPOST -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"name": "test","description": "test","template": "default"}' 192.168.1.100:8081/api/baidus
- 请求 URL:
/api/baidus/$id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
name | baidu profile 名称 |
description | baidu profile 描述 |
id | profile ID |
{
"name": "baidu",
"description": "百度模块",
"id": "1"
}
{
"data": "1",
"message": "success",
"code": 200
}
curl -XPUT -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"name": "baidu","description": "百度模块","id": "1"}' 192.168.1.100:8081/api/baidus/1
- 请求 URL:
/api/baidus/$id/params
- 请求方式:
POST
- Body 信息:
{
"k": "text1",
"realm": "BAIDU-TTS",
"v": "t1"
}
{
"k": "text2",
"realm": "BAIDU-ASR",
"v": "t2"
}
{
"code": 200,
"message": "success",
"data": 1574
}
curl -XPOST -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"k": "text1","v": "t1","realm": "BAIDU-TTS"}' 192.168.1.100:8081/api/baidus/1/params
- 请求 URL:
/api/baidus/$id/params/$param_id
- 请求方式:
PUT
- Body 信息:
{
"k": "token-url",
"realm": "BAIDU-TTS",
"v": "https://openapi.baidu.com/oauth/2.0/token"
}
{
"message": "success",
"data": "1574",
"code": 200
}
curl -XPUT -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"k": "token-url","v": "https://openapi.baidu.com/oauth/2.0/token","realm": "BAIDU-TTS"}' 192.168.1.100:8081/api/baidus/1/params/1574
启用/禁用指定百度实例中 TTS 或 ASR 参数
- 请求 URL:
/api/baidus/$id/params/$param_id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
action | 变更启用状态,固定为"toggle" |
{
"action": "toggle"
}
{
"message": "success",
"data": "1574",
"code": 200
}
curl -XPUT -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"action": "toggle"}' 192.168.1.100:8081/api/baidus/1/params/1574
- 请求 URL:
/api/baidus/$id/params/$params_id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"code": 200,
"message": "success",
"data": "1"
}
curl -0 -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -XDELETE 192.168.1.100:8081/api/baidus/1/params/1
- 请求 URL:
/api/baidus/$id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"message": "success",
"data": "2",
"code": 200
}
curl -0 -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -XDELETE 192.168.1.100:8081/api/baidus/2
"阿里"、"华为"、"讯飞"、"腾讯"、"思必驰"、"微软 Azure"、"阶跃"模块
在 AI 接口中,对于"阿里","华为","讯飞","腾讯","思必驰","微软 Azure","阶跃"模块,调用接口参数一致,URL 进行调整:
- 阿里:
https://192.168.3.222/api/ali_profiles
- 华为:
https://192.168.3.222/api/huawei_profiles
- 讯飞:
https://192.168.3.222/api/xunfei_profiles
- 腾讯:
https://192.168.3.222/api/tencent_profiles
- 思必驰:
https://192.168.3.222/api/aispeech_profiles
- 微软 Azure:
https://192.168.3.222/api/azure_profiles
- 阶跃:
https://192.168.3.222/api/stepfun_profiles
各模块对应的 realm | 说明 |
---|
阿里 | ALI-SETTINGS ALI-TTS ALI-ASR ALI-BL-TTS ALI-BL-ASR |
华为 | HUAWEI-SETTINGS HUAWEI-TTS HUAWEI-ASR |
讯飞 | XUNFEI-SETTINGS XUNFEI-TTS XUNFEI-ASR XUNFEI-MVAD |
腾讯 | TENCENT-ASR-WS TENCENT-ASR-REST TENCENT-TTS-WS TENCENT-TTS-REST |
思必驰 | AISPEECH-SETTINGS AISPEECH-TTS AISPEECH-ASR |
微软 Azure | AZURE-TTS AZURE-ASR |
阶跃 | STEPFUN-TTS-REST STEPFUN-TTS-WS STEPFUN-ASR |
以阿里模块为例:
- 请求 URL:
/api/ali_profiles
- 请求方式:
GET
- Body 信息:无
- 返回值:
[
{
"updated_at": "2025-09-03 01:42:52",
"deleted_at": "",
"created_at": "2025-09-03 01:42:52",
"id": 1,
"description": "default",
"disabled": 0,
"name": "ali"
}
]
curl -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" 192.168.1.100:8081/api/ali_profiles
- 请求 URL:
/api/ali_profiles/:id
- 请求方式:
GET
- Body 信息:无
- 返回值:
{
"created_at": "2025-09-03 01:42:52",
"params": [{
"deleted_at": "",
"id": "713",
"disabled": "0",
"created_at": "2025-09-03 01:42:53",
"ref_id": "1",
"v": "http://nls-meta.cn-shanghai.aliyuncs.com/",
"updated_at": "2025-09-03 01:42:53",
"k": "token-url",
"realm": "ALI-SETTINGS"
}, {
"deleted_at": "",
"id": "714",
"disabled": "0",
"created_at": "2025-09-03 01:42:53",
"ref_id": "1",
"v": "cn-shanghai",
"updated_at": "2025-09-03 01:42:53",
"k": "region",
"realm": "ALI-SETTINGS"
}
...
],
"deleted_at": "",
"updated_at": "2025-09-03 01:42:52",
"description": "default",
"id": 1,
"name": "ali",
"disabled": 0
}
- 请求 URL:
/api/ali_profiles
- 请求方式:
POST
- Body 信息:
参数 | 说明 |
---|
name | ali profile 名称 |
description | ali profile 描述 |
template | 模板,默认模板:"default" |
{
"name": "test",
"description": "test",
"template": "default"
}
{
"code": 200,
"data": 2,
"message": "success"
}
curl -XPOST -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"name": "test","description": "test","template": "default"}' 192.168.1.100:8081/api/ali_profiles
- 请求 URL:
/api/ali_profiles/$id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
name | ali profile 名称 |
description | ali profile 描述 |
id | profile ID |
{
"name": "ali",
"description": "阿里实例",
"id": "1"
}
{
"data": "1",
"message": "success",
"code": 200
}
curl -XPUT -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"name": "ali","description": "阿里实例","id": "1"}' 192.168.1.100:8081/api/ali_profiles/1
- 请求 URL:
/api/ali_profiles/toggle/:id
- 请求方式:
PUT
- Body 信息:
{
"action": "aliyun"
}
{
"data": [{
"id": 1,
"description": "default",
"name": "ali",
"disabled": 1,
"deleted_at": "",
"updated_at": "2025-09-03 02:53:43",
"created_at": "2025-09-03 01:42:52"
}, {
"id": 2,
"description": "",
"name": "text11",
"disabled": 0,
"deleted_at": "",
"updated_at": "2025-09-03 02:53:43",
"created_at": "2025-09-03 02:34:22"
}],
"message": "success",
"code": 200
}
- 请求 URL:
/api/ali_profiles/$id/params
- 请求方式:
POST
- Body 信息:
{
"k": "text1",
"realm": "ALI-SETTINGS",
"v": "t1"
}
{
"k": "text1",
"realm": "ALI-TTS",
"v": "t1"
}
{
"k": "text2",
"realm": "ALI-ASR",
"v": "t2"
}
{
"k": "text3",
"realm": "ALI-BL-TTS",
"v": "t1"
}
{
"k": "text4",
"realm": "ALI-BL-ASR",
"v": "t2"
}
{
"code": 200,
"message": "success",
"data": 1574
}
curl -XPOST -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"k": "text1","v": "t1","realm": "ali-TTS"}' 192.168.1.100:8081/api/ali_profiles/1/params
- 请求 URL:
/api/ali_profiles/$id/params/$param_id
- 请求方式:
PUT
- Body 信息:
{
"k": "token-url",
"realm": "ALI-TTS",
"v": "https://nls-gateway.cn-shanghai.aliyuncs.com/stream/v1/tts"
}
{
"message": "success",
"data": "1574",
"code": 200
}
curl -XPUT -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"k": "token-url","v": "https://openapi.ali.com/oauth/2.0/token","realm": "ali-TTS"}' 192.168.1.100:8081/api/ali_profiles/1/params/1574
- 请求 URL:
/api/ali_profiles/$id/params/$param_id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
action | 变更启用状态,固定为"toggle" |
{
"action": "toggle"
}
{
"message": "success",
"data": "1574",
"code": 200
}
curl -XPUT -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -d '{"action": "toggle"}' 192.168.1.100:8081/api/ali_profiles/1/params/1574
- 请求 URL:
/api/ali_profiles/$id/params/$params_id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"code": 200,
"message": "success",
"data": "1"
}
curl -0 -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -XDELETE 192.168.1.100:8081/api/ali_profiles/1/params/1
- 请求 URL:
/api/ali_profiles/$id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"message": "success",
"data": "2",
"code": 200
}
curl -0 -H "X-XTRA-AUTH-ID: 62dd0173-4916-4b1c-b958-546e4d7c91fe" -XDELETE 192.168.1.100:8081/api/ali_profiles/2
- 请求 URL:
/api/minimax_profiles
- 请求方式:
GET
- Body 信息:无
- 返回值:
[
{
"id": 1,
"disabled": 0,
"deleted_at": "",
"description": "default",
"created_at": "2025-09-03 01:42:52",
"updated_at": "2025-09-03 01:42:52",
"name": "default"
}
]
- 请求 URL:
/api/minimax_profiles/:id
- 请求方式:
GET
- Body 信息:无
- 返回值:
{
"params": [{
"id": "2619",
"created_at": "2025-09-03 01:42:54",
"v": "https://api.minimax.chat/v1/tts/stream",
"disabled": "0",
"ref_id": "1",
"deleted_at": "",
"k": "tts-url",
"realm": "MINIMAX-TTS",
"updated_at": "2025-09-03 01:42:54"
}, {
"id": "2620",
"created_at": "2025-09-03 01:42:54",
"v": "",
"disabled": "0",
"ref_id": "1",
"deleted_at": "",
"k": "token",
"realm": "MINIMAX-TTS",
"updated_at": "2025-09-03 01:42:54"
}
...
],
"disabled": 0,
"description": "default",
"updated_at": "2025-09-03 01:42:52",
"name": "default",
"deleted_at": "",
"id": 1,
"created_at": "2025-09-03 01:42:52"
}
- 请求 URL:
/api/minimax_profiles
- 请求方式:
POST
- Body 信息:
参数 | 说明 |
---|
name | MiniMax profile 名称 |
description | MiniMax profile 描述 |
template | 模板,默认模板:"default" |
{
"name": "test",
"description": "test",
"template": "default",
"disabled": "1"
}
{
"code": 200,
"data": 2,
"message": "success"
}
- 请求 URL:
/api/minimax_profiles/$id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
name | MiniMax profile 名称 |
description | MiniMax profile 描述 |
id | profile ID |
{
"name": "MiniMax",
"description": "MiniMax实例",
"id": "1"
}
{
"data": "1",
"message": "success",
"code": 200
}
- 请求 URL:
/api/minimax_profiles/toggle/:id
- 请求方式:
PUT
- Body 信息:
{
"disabled": 0
}
{
"message": "success",
"code": 200,
"data": "4"
}
- 请求 URL:
/api/minimax_profiles/:id/tts/
- 请求方式:
POST
- Body 信息:
{
"k":"text",
"v":"text",
"realm":"MINIMAX-TTS"
}
{
"data": 3313,
"message": "success",
"code": 200
}
创建指定 MiniMax 实例中的 TTSV2 参数
- 请求 URL:
/api/minimax_profiles/:id/ttsv2/
- 请求方式:
POST
- Body 信息:
{
"k":"text",
"v":"text",
"realm":"MINIMAX-TTSV2"
}
{
"data": 3314,
"message": "success",
"code": 200
}
创建指定 MiniMax 实例中的 TTSV2 WS 参数
- 请求 URL:
/api/minimax_profiles/:id/ttsv2ws/
- 请求方式:
POST
- Body 信息:
{
"k":"text",
"v":"text",
"realm":"MINIMAX-TTSV2-WS"
}
{
"message": "success",
"data": 3316,
"code": 200
}
- 请求 URL:
/api/minimax_profiles/$id/tts/$param_id
- 请求方式:
PUT
- Body 信息:
{
"k": "token-url",
"realm": "MiniMax-TTS",
"v": "https://api.minimax.chat/v1/tts/stream"
}
{
"message": "success",
"data": "1574",
"code": 200
}
- 请求 URL:
/api/minimax_profiles/$id/params/$param_id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
action | 变更启用状态,固定为"toggle" |
{
"action": "toggle"
}
{
"message": "success",
"data": "1574",
"code": 200
}
- 请求 URL:
/api/minimax_profiles/:id/tts/:params_id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"code": 200,
"message": "success",
"data": "1"
}
- 请求 URL:
/api/minimax_profiles/:id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"message": "success",
"data": "2",
"code": 200
}
- 请求 URL:
/api/volcengine_profiles
- 请求方式:
GET
- Body 信息:无
- 返回值:
[
{
"name": "default",
"created_at": "2025-09-03 01:42:52",
"description": "default",
"updated_at": "2025-09-03 01:42:52",
"id": 1,
"deleted_at": "",
"disabled": 0
}
]
- 请求 URL:
/api/volcengine_profiles/:id
- 请求方式:
GET
- Body 信息:无
- 返回值:
{
"disabled": 0,
"created_at": "2025-09-03 01:42:52",
"name": "default",
"description": "default",
"params": [{
"disabled": "0",
"created_at": "2025-09-03 01:42:54",
"realm": "VOLCENGINE-TTS",
"ref_id": "1",
"updated_at": "2025-09-03 01:42:54",
"deleted_at": "",
"v": "wss://openspeech.bytedance.com/api/v1/tts/ws_binary",
"k": "tts-url",
"id": "2755"
}, {
"disabled": "0",
"created_at": "2025-09-03 01:42:54",
"realm": "VOLCENGINE-TTS",
"ref_id": "1",
"updated_at": "2025-09-03 01:42:54",
"deleted_at": "",
"v": "volcano_tts",
"k": "cluster",
"id": "2756"
}
...
],
"updated_at": "2025-09-03 01:42:52",
"deleted_at": "",
"id": 1
}
- 请求 URL:
/api/volcengine_profiles
- 请求方式:
POST
- Body 信息:
参数 | 说明 |
---|
name | 火山引擎 profile 名称 |
description | 火山引擎 profile 描述 |
template | 模板,默认模板:"default" |
{
"name":"text1",
"description":"text1",
"template":"default",
"disabled":"1"
}
{
"code": 200,
"data": 2,
"message": "success"
}
- 请求 URL:
/api/volcengine_profiles/$id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
name | 火山引擎 profile 名称 |
description | 火山引擎 profile 描述 |
id | profile ID |
{
"name": "text",
"description": "火山引擎实例",
"id": "1"
}
{
"data": "1",
"message": "success",
"code": 200
}
- 请求 URL:
/api/volcengine_profiles/toggle/:id
- 请求方式:
PUT
- Body 信息:
{
"disabled": 0
}
{
"message": "success",
"code": 200,
"data": "1"
}
- 请求 URL:
/api/volcengine_profiles/:id/tts/
- 请求方式:
POST
- Body 信息:
{
"k":"text",
"v":"text",
"realm":"VOLCENGINE-TTS"
}
{
"data": 3334,
"message": "success",
"code": 200
}
- 请求 URL:
/api/volcengine_profiles/$id/tts/$param_id
- 请求方式:
PUT
- Body 信息:
{
"k": "tts-url",
"realm": "VOLCENGINE-TTS",
"v": "wss://openspeech.bytedance.com/api/v1/tts/ws_binary"
}
{
"message": "success",
"data": "1574",
"code": 200
}
- 请求 URL:
/api/volcengine_profiles/$id/params/$param_id
- 请求方式:
PUT
- Body 信息:
参数 | 说明 |
---|
action | 变更启用状态,固定为"toggle" |
{
"action": "toggle"
}
{
"message": "success",
"data": "1574",
"code": 200
}
- 请求 URL:
/api/volcengine_profiles/:id/tts/:params_id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"code": 200,
"message": "success",
"data": "1"
}
- 请求 URL:
/api/volcengine_profiles/:id
- 请求方式:
DELETE
- Body 信息:无
- 返回值:
{
"message": "success",
"data": "2",
"code": 200
}
- 请求 URL:
/api/ai_robot
- 请求方式:
GET
- 示例:
GET /api/ai_robot?page=1&perPage=500
- Body 信息:无
- 返回值:
{
"rowCount": 1,
"page": 1,
"data": [{
"domain": "xswitch.cn",
"deleted_at": "",
"name": "text",
"updated_at": "2025-09-03 06:24:18",
"created_at": "2025-09-03 06:24:18",
"uuid": "7008553a-55ee-4db7-a45e-cbc93dc36d12",
"data": "{\"asr\": {\"asr_model\": \"default\", \"asr_engine\": \"ali\", \"asr_language\": \"ali\"}, \"tts\": {\"tts_voice\": \"aixia\", \"tts_engine\": \"aispeech\"}, \"beep\": true, \"name\": \"text\", \"texts\": {\"hello_text\": \"您好?\", \"goodbye_text\": [\"再见\", \"拜拜\", \"bye\"], \"init_prompts\": \"你是一名AI客服助理。\", \"init_welcome_text\": \"您好我Cherry,有什么可以帮您?\"}, \"domain\": \"xswitch.cn\", \"ai_config\": {\"gpt_token\": \"11\", \"service_model\": \"ChatGPT\"}, \"async_mode\": false, \"break_mode\": false, \"enable_record\": false, \"no_speaking_timeout\": 8}"
}],
"pageCount": 1
}
- 请求 URL:
/api/ai_robot/:uuid
- 请求方式:
GET
- 示例:
GET /api/ai_robot/7008553a-55ee-4db7-a45e-cbc93dc36d12
- Body 信息:无
- 返回值:
{
"code": 200,
"message": "success",
"data": [{
"uuid": "7008553a-55ee-4db7-a45e-cbc93dc36d12",
"created_at": "2025-09-03 06:24:18",
"domain": "xswitch.cn",
"updated_at": "2025-09-03 06:24:18",
"name": "text",
"deleted_at": "",
"data": {
"asr": {
"asr_engine": "ali",
"asr_language": "ali",
"asr_model": "default"
},
"name": "text",
"no_speaking_timeout": 8,
"domain": "xswitch.cn",
"break_mode": false,
"texts": {
"init_welcome_text": "您好我Cherry,有什么可以帮您?",
"goodbye_text": ["再见", "拜拜", "bye"],
"init_prompts": "你是一名AI客服助理。",
"hello_text": "您好?"
},
"beep": true,
"tts": {
"tts_engine": "aispeech",
"tts_voice": "aixia"
},
"ai_config": {
"gpt_token": "11",
"service_model": "ChatGPT"
},
"enable_record": false,
"async_mode": false
}
}]
}
- 请求 URL:
/api/ai_robot/:uuid/routes
- 请求方式:
GET
- 示例:
GET /api/ai_robot/7008553a-55ee-4db7-a45e-cbc93dc36d12/routes
- Body 信息:无
- 返回值:
[]
- 请求 URL:
/api/ai_robot
- 请求方式:
POST
- Body 信息:
{
"name": "text1",
"break_mode": false,
"no_speaking_timeout": 8,
"enable_record": false,
"async_mode": false,
"beep": true,
"tts": {
"tts_engine": "aispeech",
"tts_voice": "aixia"
},
"asr": {
"asr_engine": "ali",
"asr_language": "ali",
"asr_model": "default"
},
"ai_config": {
"service_model": "DouBao",
"gpt_token": "1"
},
"texts": {
"hello_text": "您好?",
"init_prompts": "你是一名AI客服助理。",
"init_welcome_text": "您好我Cherry,有什么可以帮您?",
"goodbye_text": [
"再见",
"拜拜",
"bye"
]
},
"domain": "xswitch.cn"
}
{
"code": 200,
"message": "success",
"data": {
"data": {
"no_speaking_timeout": 8,
"tts": {
"tts_voice": "aixia",
"tts_engine": "aispeech"
},
"texts": {
"goodbye_text": ["再见", "拜拜", "bye"],
"init_welcome_text": "您好我Cherry,有什么可以帮您?",
"hello_text": "您好?",
"init_prompts": "你是一名AI客服助理。"
},
"name": "text1",
"beep": true,
"enable_record": false,
"ai_config": {
"gpt_token": "1",
"service_model": "DouBao"
},
"async_mode": false,
"break_mode": false,
"domain": "xswitch.cn",
"asr": {
"asr_language": "ali",
"asr_model": "default",
"asr_engine": "ali"
}
},
"deleted_at": "",
"created_at": "2025-09-03 06:46:33",
"updated_at": "2025-09-03 06:46:33",
"domain": "xswitch.cn",
"name": "text1",
"uuid": "36b22b26-10e0-4c48-809d-a18fcfdf0530"
}
}
- 请求 URL:
/api/ai_robot/:uuid
- 请求方式:
PUT
- Body 信息:
{
"name": "text2",
"break_mode": false,
"no_speaking_timeout": 8,
"enable_record": false,
"async_mode": false,
"beep": true,
"tts": {
"tts_engine": "aispeech",
"tts_voice": "aixia"
},
"asr": {
"asr_engine": "ali",
"asr_language": "ali",
"asr_model": "default"
},
"ai_config": {
"service_model": "ChatGPT",
"gpt_token": "11"
},
"texts": {
"hello_text": "您好?",
"init_prompts": "你是一名AI客服助理。",
"init_welcome_text": "您好我Cherry,有什么可以帮您?",
"goodbye_text": [
"再见",
"拜拜",
"bye"
]
},
"domain": "xswitch.cn"
}
{
"data": "{}",
"message": "success",
"code": 200
}
- 请求 URL:
/api/ai_robot/:uuid
- 请求方式:
DELETE
- 响应信息:
{
"uuid": "7008553a-55ee-4db7-a45e-cbc93dc36d12"
}
- 请求 URL:
/api/cherrygpt_logs
- 请求 URL:
/api/cherrygpt_logs?page=1&perPage=500&last=60
查看近60天的话单 - 请求 URL:
/api/cherrygpt_logs?page=1&perPage=500&startDate=2025-07-06&endDate=2025-09-04&cidNumber=823&destNumber=1000479
按条件查询 - 请求方式:
GET
- 请求参数:
参数名 | 类型 | 是否必填 | 描述 |
---|
page | int | 否 | 页码 |
perPage | int | 否 | 每页条数 |
last | int | 否 | 最近天数 |
cidNumber | int | 否 | 主叫号码 |
destNumber | int | 否 | 被叫号码 |
startDate | string | 否 | 开始时间 |
endDate | string | 否 | 结束时间 |
{
"pageCount": 1,
"rowCount": 1,
"page": 1,
"data": [{
"robot_info": "{\"service_model\":\"ChatGPT\",\"gpt_token\":\"6ba7b811-9dad-11d1-80b4-00c04fd430c8\",\"gpt_model\":\"gpt-4o\",\"gpt_max_tokens\":100,\"gpt_url\":\"https://openai.xswitch.cn/v1/\",\"ASync\":false,\"breakMode\":true}",
"ai_robot_uuid": "0ec755d3-5b6c-41e9-91dc-f71ed756c616",
"channel_uuid": "019890b3-2816-7b5f-8697-c1b993884121",
"start_stamp": "2025-08-10 05:18:37",
"end_stamp": "",
"id": "109",
"created_at": "2025-08-10 05:18:37",
"cid_number": "607",
"domain": "xyt.xswitch.cn",
"node_uuid": "0dbd5892-a0b3-4a3a-b19c-9d9e15d503bd",
"dest_number": "10000475"
}]
}
{
"data": {
"cid_number": "823",
"end_stamp": "",
"ai_robot_uuid": "c56038e1-bcac-4c70-82c8-4f6e9b7e6f35",
"node_uuid": "567559e7-eb40-4d5e-ab19-1a7654debe69",
"id": 86,
"dest_number": "10000479",
"created_at": "2025-07-14 22:47:23",
"start_stamp": "2025-07-14 22:47:23",
"prompts": [{
"channel_uuid": "5976900e-0a1a-9be1-f1a5-2033b66a3602",
"role": "assistant",
"absolute_path": "/usr/local/freeswitch/storage/recordings/20250714-823-10000479-.wav",
"mime": "audio/wav",
"created_at": "2025-07-14 22:47:23",
"id": 384,
"message_uuid": "",
"content": "喂,你好。",
"extension": "wav"
}, {
"channel_uuid": "5976900e-0a1a-9be1-f1a5-2033b66a3602",
"role": "user",
"absolute_path": "/usr/local/freeswitch/storage/recordings/20250714-823-10000479-333db217422e46e9b3b3599a0da2e679.wav",
"mime": "audio/wav",
"created_at": "2025-07-14 22:47:29",
"id": 385,
"message_uuid": "333db217-422e-46e9-b3b3-599a0da2e679",
"content": "你好",
"extension": "wav"
}...],
"robot_info": "{\"service_model\":\"ChatGPT\",\"gpt_token\":\"6ba7b811-9dad-11d1-80b4-00c04fd430c8\",\"gpt_model\":\"gpt-4o\",\"gpt_max_tokens\":100,\"gpt_url\":\"https://openai.xswitch.cn/v1/\",\"ASync\":false,\"breakMode\":true}",
"domain": "xyt.xswitch.cn",
"channel_uuid": "5976900e-0a1a-9be1-f1a5-2033b66a3602"
},
"code": 200,
"message": "success"
}