Twilio 自动驾驶仪切换操作不适用于 Twiml Bin [英] Twilio autopilot handoff action is not working with Twiml Bin

查看:19
本文介绍了Twilio 自动驾驶仪切换操作不适用于 Twiml Bin的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个来自来电的 Twilio 自动驾驶任务,该任务执行问候语,然后在重定向到名为callnumber"的新任务之前提出问题.这一切正常.

I have a Twilio autopilot task from an incoming call, which performs a greeting then asks a question before redirecting to a new task called 'callnumber'. This all works fine.

'callnumber' 任务看起来像这样

The 'callnumber' task looks like this

{
    "actions": [
        {
            "handoff": {
                "channel": "voice",
                "uri": "https://handler.twilio.com/twiml/TWIMLBINID"
            }
        }
    ]
}

TWIMLBINID 实际上具有来自 Twiml Bin 的正确 ID.

TWIMLBINID actually has the correct ID from the Twiml Bin.

这是 bin 中的 Twiml 内容:

This is the Twiml content in the bin:

<Response>
    <Say>I will put you in contact with our customer care specialist.</Say>
</Response>

不幸的是,我没有听到这个 Response 说出来,而是收到标准的发生错误"的语音消息.

Unfortunately I'm not hearing this Response spoken out and instead just get the standard 'an error has occurred' voice message.

我尝试了几个不同的版本,甚至调用托管在我自己的公共 Web 服务器上的 xml 文件并看到相同的问题.还尝试了拨号动词,但仍然看到这个问题.

I've tried a few different versions of this, even calling an xml file hosted on my own public web server and seeing the same problem. Also tried the dial verb and still seeing this issue.

在看到类似的帖子后,我觉得我可能错过了一些配置:Twilio 自动驾驶仪不说它应该说的内容

I feel like I may have missed some configuration, after seeing similar posts like: Twilio autopilot doesnt say what it is supposed to say

非常感谢任何帮助!

推荐答案

当我将 TwiML Bin 与具有样本的任务关联时,我能够让 TwiML Bin 使用类似的 JSON.

I was able to get the TwiML Bin working with similar JSON, when I have it associated with a Task that has samples.

因此,例如,您的 Autopilot 助手收到一个呼叫,并最初触发了 hello_world 的助手启动任务,您在其中使用侦听操作修改了预定义的 JSON.

So, for example, a call comes in to your Autopilot assistant and initially triggers the Assistant Initiation Task of hello_world where you modified the predefined JSON with a listen action.

{
    "actions": [
        {
            "say": "How can I help you today?"
        },
        {
            "listen": true
        }
    ]
}

然后您做出响应,以便执行与您的移交 JSON/TwiML Bin 相关联的任务(基于您提供的示例).如果尝试直接调用切换任务,则失败.

You then respond so the task associated with your handoff JSON/TwiML Bin is executed (based on the samples you provided). If you try to call the handoff task directly, it fails.

这篇关于Twilio 自动驾驶仪切换操作不适用于 Twiml Bin的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆