智能助手

获取助手详情

根据助手ID获取单个AI语音助手的完整配置信息,包括版本配置、语音合成/识别配置、AI模型配置等

GET/openapi/assistants/{id}

请求

参数

idinteger必需

路径参数 · 助手ID

响应

200 成功返回助手详情
idinteger

助手唯一ID

projectIdinteger

所属项目ID

namestring

助手名称

versionIdinteger

当前使用的版本ID

scenestring

助手场景类型,如 inbound_knowledge(呼入知识库)、outbound_collect(呼出收集)等

objectivestring

助手目标描述

speakerIdinteger

语音合成(TTS)音色ID

speakerNamestring

语音合成(TTS)音色名称

websocketUrlstring

WebSocket连接地址

websocketTokenstring

WebSocket连接认证Token

listenerIdinteger

语音识别(ASR)模型ID

listenerNamestring

语音识别(ASR)模型名称

welcomestring

欢迎语/开场白,通话接通后助手首先播放的文本

promptstring

系统提示词,定义助手的角色、行为和对话策略

collectobject[]

信息收集配置,定义助手在对话中需要收集的问题列表

[].questionstring

需要收集的问题内容

[].answersstring[]

预设的答案选项列表(可选)

knowledgestring

关联的知识库Code(RAG知识库标识)

hotWordsobject[]

热词列表,用于提高ASR识别准确率

[].wordstring

热词文本

[].weightinteger

热词权重,数值越大优先级越高

[].replacedWordsstring[]

该热词可替换的同音/近音词列表

[].enableFuzzyMatchboolean

是否启用该热词的模糊匹配

usageCountinteger

助手累计通话次数

creatorIdinteger

创建者用户ID

creatorobject

创建者用户信息

idinteger

用户ID

emailstring

用户邮箱

usernamestring

用户名

idOldVersionboolean

是否为旧版本格式(兼容标记)

llmIdinteger

关联的自定义LLM配置ID

enableFuzzyMatchboolean

是否启用模糊匹配(用于ASR结果纠错)

featureFlagsstring

功能开关标记(逗号分隔的功能标识)

timeZonestring

助手使用的时区,如 Asia/Shanghai

flowstring

对话流程定义(JSON格式的流程图配置)

interruptionConfigobject

打断配置,控制用户在助手说话时如何打断

methodstring

打断方式

unInterruptableAfterPlayStartinteger

播放开始后不可打断的时长(毫秒),在此时间内用户语音不会触发打断

talkOverThresholdinteger

抢话检测阈值(毫秒),用户持续说话超过此时长才触发打断

resumePlayboolean

打断后是否恢复播放被打断的内容

eouConfigobject

端点检测配置(End of Utterance),用于判断用户是否说完

eouEnabledboolean

是否启用智能端点检测

waitTimeoutinteger

等待超时时间(毫秒),超过此时间未检测到语音则判定说完

unfinishedTimeoutinteger

未完成语句超时时间(毫秒),检测到未说完的语句时额外等待的时长

vadConfigobject

VAD(Voice Activity Detection)语音活动检测配置

paddingDurationinteger

静音填充时长(毫秒),语音结束后额外等待的时间

rationumber

语音检测灵敏度比例

vadModeinteger

VAD模式(0-3),数值越高越严格

positiveSpeechThresholdnumber

语音正向检测阈值,超过此值判定为有语音

negativeSpeechThresholdnumber

语音负向检测阈值,低于此值判定为无语音

redemptionFramesinteger

赎回帧数,在判定语音结束前额外检查的帧数

minSpeechFramesinteger

最小语音帧数,低于此帧数的语音片段将被忽略

energyThresholdinteger

能量阈值,音频能量低于此值判定为静音

speechStartMsinteger

语音开始检测时长(毫秒)

speechEndMsinteger

语音结束检测时长(毫秒)

agentConfigobject

AI Agent 核心配置,包括对话策略和LLM模型参数

sliceTimeinteger

分片时间(毫秒),将长语音切分处理的时间间隔

interruptionSilentTimeinteger

打断后静默等待时间(毫秒)

maxSilentAskTimesinteger

最大静默追问次数,用户持续沉默时助手主动追问的最大次数

maxDialogueGapTimesinteger

最大对话间隔次数,超过后自动结束通话

maxSessionDurationinteger

最大会话时长(秒),超过后自动结束通话

startCanBreakboolean

开场白是否可被打断

speechIntervalThresholdinteger

语音间隔阈值(毫秒),两段语音间隔小于此值视为连续说话

keepSilentWhenVADIsActiveboolean

当VAD检测到用户在说话时,助手是否保持沉默

modelNamestring

LLM模型名称,如 gpt-4o、claude-sonnet-4.5 等

baseUrlstring

LLM API 基础URL

authTokenstring

LLM API 认证Token

vendorstring

LLM供应商标识,如 openai、azure、volcengine 等

apiVersionstring

API版本号(主要用于Azure OpenAI)

temperaturenumber

LLM温度参数(0-2),越高输出越随机

topPnumber

LLM Top-P采样参数(0-1)

promptModestring

提示词模式,如 system(系统提示词)

thresholdnumber

Agent决策阈值

agentModestring

Agent运行模式

useFillerboolean

是否使用填充词(如'嗯'、'好的'),在AI思考时播放

fillerWordsstring[]

填充词列表

functionsobject[]

Function Calling 函数定义列表(OpenAI格式)

functionHooksobject[]

Function调用钩子配置,在调用工具前/后执行额外逻辑

[].toolNamestring

目标工具名称

[].hookPromptstring

钩子提示词,在工具调用时额外注入的指令

knowledgeCodestring

知识库Code(用于RAG检索)

topKinteger

知识库检索返回的Top-K条目数

scrmConfigobject

SCRM(社交化客户关系管理)集成配置

robotIdstring

SCRM机器人ID

appKeystring

SCRM应用Key

appSecretstring

SCRM应用Secret

skillsConfigobject

技能配置

pressKeyobject

按键技能配置(DTMF按键检测)

maxInactiveSecondinteger

最大无操作等待时间(秒),超过后停止按键监听

shortMemoobject

短时记忆配置,用于对话中的上下文摘要

pointsstring[]

需要记忆的关注点列表

llmConfigobject

LLM模型配置(通用)

vendorstring

模型供应商,如 openai、azure、volcengine

modelNamestring

模型名称

baseUrlstring

API基础URL

authTokenstring

API认证Token

temperaturenumber

温度参数

apiVersionstring

API版本号

topPnumber

Top-P采样参数

knowledgeConfigobject

知识库检索配置

usePreviousRoundsSliceinteger

使用前N轮对话作为检索上下文

sliceMinimumScorenumber

知识库切片最低匹配分数,低于此分数的结果将被过滤

useMemoEnhanceQueryboolean

是否使用记忆增强检索查询

disableQueryOnNewDialogboolean

新对话轮次开始时是否禁用知识库检索

speechScriptsobject

预设话术脚本,key为场景标识,value为话术内容

audioProcessConfigobject

音频处理配置(降噪、增益等)

vadTypestring

VAD引擎类型

noiseSuppressionEnabledboolean

是否启用降噪

noiseSuppressionTypestring

降噪算法类型,可选 rnnoise 或 dfn

noiseSuppressionIntensityinteger

降噪强度等级

agcEnabledboolean

是否启用自动增益控制(AGC)

closeAllAudioProcessboolean

是否关闭所有音频处理(降噪+AGC全部禁用)

speakerConfigobject

语音合成(TTS)播报配置

speakRationumber

语速倍率,1.0为正常速度,大于1加速,小于1减速

ttsNamestring

TTS引擎名称

ttsOptionsobject

TTS引擎额外参数

ssmlboolean

是否启用SSML(语音合成标记语言)

ssmlReplacesobject[]

SSML文本替换规则列表

[].keystring

需要替换的原始文本

[].valuestring

替换后的SSML标记文本

globalConfigobject

全局配置

welcomestring

全局欢迎语

promptstring

全局提示词

scenestring

场景类型

languagestring

主语言,如 zh-CN、en-US、ja-JP

languageConfigobject

多语言配置

additionalLanguagesobject[]

额外支持的语言列表

[].languagestring

语言代码,如 en-US、ja-JP

debugModestring

调试模式标识

directionstring

通话方向,inbound(呼入)或 outbound(呼出)

dialogUnInterruptableboolean

对话是否不可打断

promptModestring

提示词模式

workTimeConfigobject

工作时间配置

workTimeIdinteger

工作时间规则ID

workTimeoneOf
calendaroneOf
subgoaloneOf
analysisobject

通话分析配置

realTimeCollectboolean

是否启用实时信息收集(通话中实时提取关键信息)

collectTargetsobject[]

收集目标定义列表

[].namestring

目标名称

[].enumstring[]

枚举值列表(限定可选值)

[].branchstring

所属分支标识

[].summarystring

目标摘要描述

[].uuidstring

唯一标识符

conversationAnalysisobject[]

对话分析维度列表

[].targetstring

分析目标标识

[].descriptionstring

分析维度描述

qualityAnalysisobject

通话质量分析配置

contentstring

质量分析提示词/规则内容

mcpServersobject[]

MCP服务器配置列表,用于扩展助手工具能力

[].namestring

MCP服务器名称

[].descriptionstring

服务器描述

[].typestring

服务器类型,如 stdio、sse

[].commandstring

启动命令

[].argsstring

启动参数

[].envsstring

环境变量配置

[].timeoutinteger

超时时间(秒)

[].selectToolsobject[]

选中的工具列表

[].toolNamestring

工具名称

[].isAsyncboolean

是否异步执行

audioTrackConfigobject

音轨配置(背景音、音量控制)

masterVolumenumber

主音量(默认1.0)

mainTrackVolumenumber

主音轨音量(默认0.8),即TTS语音的音量

effectAudioTracksobject[]

效果音轨列表(背景音乐等)

[].filenamestring

音频文件名/路径

[].volumenumber

音量(默认0.8)

[].isActiveboolean

是否启用该音轨

[].modestring

播放模式,如 loop(循环)、once(单次)

queryRewriterobject

查询重写配置,用于优化知识库检索的查询语句

useRewriterboolean

是否启用查询重写

rewritePromptstring

重写提示词

llmConfigobject

LLM模型配置(通用)

vendorstring

模型供应商,如 openai、azure、volcengine

modelNamestring

模型名称

baseUrlstring

API基础URL

authTokenstring

API认证Token

temperaturenumber

温度参数

apiVersionstring

API版本号

topPnumber

Top-P采样参数

listenerConfigobject

语音识别(ASR)高级配置

providersobject[]

ASR提供商列表(支持多提供商并行识别)

[].listenerIdinteger

ASR模型ID

[].namestring

提供商名称

[].optionsobject

提供商额外配置参数

submitModestring

ASR结果提交模式

transferASRboolean

是否启用转写ASR(将通话全程转写)

fuzzyOptionsobject

模糊匹配选项

directionstring

识别方向

createdAtstring

创建时间

updatedAtstring

最后更新时间

deletedAtstring

软删除时间,未删除时为null

示例代码

curl -X GET 'https://openapi.voicefox.cn/openapi/assistants/{id}' \
  -H 'Authorization: Bearer <YOUR_TOKEN>' \
  -H 'Content-Type: application/json'

响应示例

{
  "id": 0,
  "projectId": 0,
  "name": "string",
  "versionId": 0,
  "scene": "string",
  "objective": "string",
  "speakerId": 0,
  "speakerName": "string",
  "websocketUrl": "string",
  "websocketToken": "string",
  "listenerId": 0,
  "listenerName": "string",
  "welcome": "string",
  "prompt": "string",
  "collect": [
    {
      "question": "string",
      "answers": [
        "string"
      ]
    }
  ],
  "knowledge": "string",
  "hotWords": [
    {
      "word": "string",
      "weight": 0,
      "replacedWords": [
        "string"
      ],
      "enableFuzzyMatch": false
    }
  ],
  "usageCount": 0,
  "creatorId": 0,
  "creator": {
    "id": 0,
    "email": "string",
    "username": "string"
  },
  "idOldVersion": false,
  "llmId": 0,
  "enableFuzzyMatch": false,
  "featureFlags": "string",
  "timeZone": "string",
  "flow": "string",
  "interruptionConfig": {
    "method": "string",
    "unInterruptableAfterPlayStart": 0,
    "talkOverThreshold": 0,
    "resumePlay": false
  },
  "eouConfig": {
    "eouEnabled": false,
    "waitTimeout": 0,
    "unfinishedTimeout": 0
  },
  "vadConfig": {
    "paddingDuration": 0,
    "ratio": 0,
    "vadMode": 0,
    "positiveSpeechThreshold": 0,
    "negativeSpeechThreshold": 0,
    "redemptionFrames": 0,
    "minSpeechFrames": 0,
    "energyThreshold": 0,
    "speechStartMs": 0,
    "speechEndMs": 0
  },
  "agentConfig": {
    "sliceTime": 0,
    "interruptionSilentTime": 0,
    "maxSilentAskTimes": 0,
    "maxDialogueGapTimes": 0,
    "maxSessionDuration": 0,
    "startCanBreak": false,
    "speechIntervalThreshold": 0,
    "keepSilentWhenVADIsActive": false,
    "modelName": "string",
    "baseUrl": "string",
    "authToken": "string",
    "vendor": "string",
    "apiVersion": "string",
    "temperature": 0,
    "topP": 0,
    "promptMode": "string",
    "threshold": 0,
    "agentMode": "string",
    "useFiller": false,
    "fillerWords": [
      "string"
    ],
    "functions": [
      {}
    ],
    "functionHooks": [
      {
        "toolName": "string",
        "hookPrompt": "string"
      }
    ],
    "knowledgeCode": "string",
    "topK": 0,
    "scrmConfig": {
      "robotId": "string",
      "appKey": "string",
      "appSecret": "string"
    },
    "skillsConfig": {
      "pressKey": {
        "maxInactiveSecond": 0
      },
      "shortMemo": {
        "points": [
          "string"
        ],
        "llmConfig": {
          "vendor": "string",
          "modelName": "string",
          "baseUrl": "string",
          "authToken": "string",
          "temperature": 0,
          "apiVersion": "string",
          "topP": 0
        }
      }
    },
    "knowledgeConfig": {
      "usePreviousRoundsSlice": 0,
      "sliceMinimumScore": 0,
      "useMemoEnhanceQuery": false,
      "disableQueryOnNewDialog": false
    },
    "speechScripts": {}
  },
  "audioProcessConfig": {
    "vadType": "string",
    "noiseSuppressionEnabled": false,
    "noiseSuppressionType": "string",
    "noiseSuppressionIntensity": 0,
    "agcEnabled": false,
    "closeAllAudioProcess": false
  },
  "speakerConfig": {
    "speakRatio": 0,
    "ttsName": "string",
    "ttsOptions": {},
    "ssml": false,
    "ssmlReplaces": [
      {
        "key": "string",
        "value": "string"
      }
    ]
  },
  "globalConfig": {
    "welcome": "string",
    "prompt": "string",
    "scene": "string",
    "language": "string",
    "languageConfig": {
      "additionalLanguages": [
        {
          "language": "string"
        }
      ]
    },
    "debugMode": "string",
    "direction": "string",
    "dialogUnInterruptable": false,
    "promptMode": "string",
    "workTimeConfig": {
      "workTimeId": 0,
      "workTime": {
        "id": 0,
        "name": "string",
        "projectId": 0,
        "workdayOption": "string",
        "workdayData": "string",
        "holidayPolicy": "string",
        "worktimeOption": "string",
        "worktimeData": "string"
      },
      "calendar": {
        "id": 0,
        "holidays": "string",
        "workdays": "string",
        "country": "string",
        "year": 0
      }
    }
  },
  "subgoal": {
    "condition": {
      "target": "string",
      "value": "string"
    },
    "type": "string",
    "target": "string",
    "description": "string",
    "collectTargets": {},
    "subgoal": [
      {
        "condition": {
          "target": "string",
          "value": "string"
        },
        "type": "string",
        "target": "string",
        "description": "string",
        "collectTargets": {},
        "subgoal": [
          {
            "condition": null,
            "type": null,
            "target": null,
            "description": null,
            "collectTargets": null,
            "subgoal": null
          }
        ]
      }
    ]
  },
  "analysis": {
    "realTimeCollect": false,
    "collectTargets": [
      {
        "name": "string",
        "enum": [
          "string"
        ],
        "branch": "string",
        "summary": "string",
        "uuid": "string"
      }
    ],
    "conversationAnalysis": [
      {
        "target": "string",
        "description": "string"
      }
    ],
    "qualityAnalysis": {
      "content": "string"
    }
  },
  "mcpServers": [
    {
      "name": "string",
      "description": "string",
      "type": "string",
      "command": "string",
      "args": "string",
      "envs": "string",
      "timeout": 0,
      "selectTools": [
        {
          "toolName": "string",
          "isAsync": false
        }
      ]
    }
  ],
  "audioTrackConfig": {
    "masterVolume": 0,
    "mainTrackVolume": 0,
    "effectAudioTracks": [
      {
        "filename": "string",
        "volume": 0,
        "isActive": false,
        "mode": "string"
      }
    ]
  },
  "queryRewriter": {
    "useRewriter": false,
    "rewritePrompt": "string",
    "llmConfig": {
      "vendor": "string",
      "modelName": "string",
      "baseUrl": "string",
      "authToken": "string",
      "temperature": 0,
      "apiVersion": "string",
      "topP": 0
    }
  },
  "listenerConfig": {
    "providers": [
      {
        "listenerId": 0,
        "name": "string",
        "options": {}
      }
    ],
    "submitMode": "string",
    "transferASR": false,
    "fuzzyOptions": {},
    "direction": "string"
  },
  "createdAt": "2026-01-01T00:00:00Z",
  "updatedAt": "2026-01-01T00:00:00Z",
  "deletedAt": "2026-01-01T00:00:00Z"
}