尝试在连接Nexmo NCCO时流式传输音乐



我尝试在将代理连接到电话呼叫时流式传输音乐。 但它卡在流中然后调用。

以前有人用过吗?我敢肯定这是不可能的。

法典:

$array[] = array(
"action" => "stream",
"streamUrl" => array("https://pbx.makeapp.co.il/wait.mp3"),
);
$array[] = array(
"action" => "connect",
"eventType" => "synchronous",
"eventUrl" => array("https://pbx.makeapp.co.il/config.json?step=1"),
"timeout" => 30,
"from" => "YOUR_NEXMO_PHONE",
"endpoint" => array(array(
"type" => "sip",
"uri" => "sip:your_sip@sip.antisip.com",
)
)
);

您是对的,使用 NCCO 不可能同时运行 2 个操作。将流操作添加到 NCCO 的开头时,必须先完成此操作,然后才能移动到下一个操作。NCCO 数组从上到下执行操作,只有在当前操作完成后才会移动到下一个操作。您可以在文档的 NCCO 概念部分找到更多信息:https://developer.nexmo.com/voice/voice-api/ncco-reference

最新更新