API开发文档
欢迎浏览我们的API开发文档!
添加或更新呼叫流
PUT
/api/callflow/:id
权限:呼叫流
Header | ||
字段 | 类型 | 描述 |
Content-Type | 字符串 | 应用或JSON |
参数 | ||
字段 | 类型 | 描述 |
id | 字符串 | 呼叫流模块编号 |
callflow_id | 字符串 | 可选项,更新呼叫流编号,此值可覆盖url中的编号 |
应答
/api/callflow/xxxxxx_answer
{
callflow_type: "answer",
next: "",
sleep: 1500
}
呼叫
/api/callflow/xxxxxxxxx_forward
{
callflow_type: "forward",
numbers: [], // or // number: "",
}
菜单
/api/callflow/xxxxxxxxx_menu
{
callflow_type: "menu",
audio: "",
dtmf: {},
timeout: 5000,
repeat: 0,
next: ""
}
拨打外部号码
/api/callflow/xxxxxxxxx_menu
{
callflow_type: 'callout',
numbers: [], // or // number: "",
max_ring_time: 2000,
voicemail: "",
next: ""
}
语音信箱
/api/callflow/xxxxxxxxx_voicemail
{
callflow_type: 'voicemail',
extension: 201
}
队列
/api/callflow/xxxxxxxxx_queue
{
callflow_type: "queue",
id: "",
next: "",
music_on_hold: ""
}
电话会议
/api/callflow/xxxxxx_conference
{
callflow_type: "conference_room",
pin: "1234"
}
呼叫计划
/api/callflow/xxxxxx_schedule
{
callflow_type: "schedule",
"data": {
"default": "menu",
"rules": [
{
"days_of_week": [
1,
2,
3,
4,
5
],
"start": "09:00",
"end": "16:59",
"callflow": "conf"
}
]
}
}
成功
HTTP/1.1 200 OK
xxxxxxxxx_forward has been updated