本文介绍了Twilio Autopilot 允许闯入的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想允许呼叫者在 Twilio Autopilot 中的 Say Action 期间插入.那可能吗?在通话开始时,我读出了一个可能要对机器人说的话的列表 - 但该列表正在增长,并且希望用户能够中断阅读并转到适当的操作而无需等待它结束.

I would like to allow callers to barge in during a Say Action in Twilio Autopilot. is that possible? At the start of the call, I read off a list of possible things to say to the bot - but the list is growing and would like for users to be able to interrupt the reading and go to the appropriate action without having to wait for it to end.

推荐答案

Twilio 开发人员布道者在这里.

Twilio developer evangelist here.

文档尚未更新,但支持 barge.默认情况下,客户可以使用语音切断 SayCollect.如果您想禁用 barge,您可以在 listencollect 属性中将其设置为 false代码>语音.

The docs are not yet updated, but barge is supported. By default, customers could cut-off a Say or a Collect using speech. If you would like to disable barge, you could set it to false in the listen or collect property below speech.

该 JSON 可能类似于:

That JSON might look something like:

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

或者更复杂的say:

{
  "actions": [
    {
      "say": {
        "speech": "Hello! how can I help you. Say or press 1 for sales, 2 for support."
      }
    },
    {
      "listen": {
        "voice_digits": {
          "redirects": {
            "1": "task://sales",
            "2": "task://support"
          }
        },
        "barge": false
      }
    }
  ]
}

或者在一个 Collect 中可能看起来像:

Or in a Collect that might look like:

{
   "actions":[
      {
         "collect":{
            "name":"collect_custom",
            "questions":[
               {
                  "question":"What office are you based out of? Press 1 for San Francisco. 2 for Mountain View. 3 for Remote",
                  "name":"twilio_office",
                  "type":"twilio_office",
                  "voice_digits":{
                     "mapping":{
                        "1":"San Francisco",
                        "2":"Mountain View",
                        "3":"Remote"
                     }
                  },
                  "barge":false
               }
            ],
            "on_complete":{
               "redirect":{
                  "uri":"https://example.com/collect",
                  "method":"POST"
               }
            }
         }
      }
   ]
}

让我知道这是否有帮助!

Let me know if this helps at all!

这篇关于Twilio Autopilot 允许闯入的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-26 16:59