分类

呼叫流

呼叫流 – 添加或更新呼叫流

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

呼叫流 – 所有音频

列出所有音频

GET

/api/callflow/audios

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

成功响应

HTTP/1.1 200 OK

[
“http://download.genvoice.net/api/callflow/audio/dev/3ff21620-5ebd-11e8-8d7a-a1bc832724f9.mp3”,
“http://download.genvoice.net/api/callflow/audio/dev/Salesline_close.mp3”,
“http://download.genvoice.net/api/callflow/audio/dev/Salesine_close.mp3”,
“http://download.genvoice.net/api/callflow/audio/dev/ServiceOutageAnnouncement.wav.mp3”,
“http://download.genvoice.net/api/callflow/audio/dev/DoubleLanguageGreeting.wav”
]

呼叫流 – 删除音频

DELETE

/api/callflow/audio/:id

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

参数

字段类型描述
id字符串音频编号(文件名)

成功响应

HTTP/1.1 200 OK Removing succeeded

呼叫流 – 删除呼叫流

DELETE

/api/callflow/:id

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

参数

字段类型描述
id字符串呼叫流模块编号

成功响应

HTTP/1.1 200 OK
xxxxxxxxx_forward has been deleted

呼叫流 – 删除Tts

DELETE

/api/callflow/tts/:id

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

参数

字段类型描述
id字符串账户名

成功响应

HTTP/1.1 200

令牌错误

HTTP/1.1 401

未找到错误

HTTP/1.1 404

呼叫流 – 获取全部呼叫流

GET

/api/callflows

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

成功响应

HTTP/1.1 200 OK
[{
“callflow_id”: “xxxxxxxx_forward”,
“callflow_type”: “forward”,
“numbers”: “16479999999”
}]

呼叫流 – 获取全部Tts

GET

/api/callflow/tts

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

成功 200

字段类型描述
name字符串关键字为tts名,值为tts文本

成功响应

HTTP/1.1 200 OK { “name”: “text”, }

呼叫流 – 获取指定呼叫流

GET

/api/callflow/:id

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

参数

字段类型描述
id字符串呼叫流模块编号

成功响应

HTTP/1.1 200 OK
{
“callflow_id”: “xxxxxxxx_forward”,
“callflow_type”: “forward”,
“number”: “16479999999”
}

呼叫流 – 获取Tts

GET

/api/callflow/tts/:name

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

成功 200

字段类型描述
name字符串关键字为tts名,值为tts文本

呼叫流 – 提交Tts

PUT

/api/callflow/tts/:name

权限:呼叫流

Header

字段类型描述
Content-Type字符串应用或JSON

参数

字段类型描述
name字符串Tts名
text字符串包含tts的文本

成功

HTTP/1.1 200

请求错误

HTTP/1.1 400

令牌错误

HTTP/1.1 401

呼叫流 – 上传音频

POST

/api/callflow/audio

权限:呼叫流

Header

字段类型描述
Content-Type字符串上传的声音文件

参数

字段类型描述
file_data文件文件内容
filename字符串文件名

成功响应

HTTP/1.1 201 Created “Uploading Succeeded”

上一页 呼叫
下一页 坐席
Table of Contents