Alexa无法检索slot.value

时间:2018-07-05 11:31:36

标签: alexa alexa-skill alexa-voice-service alexa-slot

如果可以的话,我有两个问题。但首先让我介绍一下您的情况:
我有带有插槽通道的Intent1。如果我尝试检索channel.value,那么它将正常工作。
我的Intent2带有RadioNumber插槽。如果我尝试检索RadioNumber.value,那么它将不起作用。
尝试

时,将控制台插入
          *console.log(RadioNumber.value)*        

在intent2函数中,它给出

          Cannot read property value of undefined  

我注意到两个意图的request.Json是不同的,这没有任何意义,因为我以完全相同的方式实现了两个插槽!这是我的第一个问题。 enter image description here

enter image description here

您可能已经注意到RadioNumberSlot有一个额外的功能:

      "values": [  
                                {  
                                    "value": {  
                                        "name": "hot",  
                                        "id":  
       "27369b3bf4483e8dcfd85ba9a39a947f"  
                                    }  
                                }  
                            ]          

通常,我很容易操作slot.value。而且我似乎不明白这种特定的广告位/意图可能是什么问题。
因此,请注意,如果您发现可能是导致问题的原因,请帮我:)

0 个答案:

没有答案