Alexa documentation通过以下方式描述其请求中的supportedInterfaces
属性:
除了此处提到的AudioPlayer
,在哪里可以看到可以在请求中显示的受支持接口的完整列表?
当前,从Alexa开发人员控制台进行测试时,未填充supportedInterfaces的集合。
这是正常行为吗?我认为至少应该填充一个AudioPlayer还是不应该?如何使它填充?
答案 0 :(得分:1)
Echo Show具有以下键:
"supportedInterfaces":{
"Display":{},
"AudioPlayer": {},
"VideoApp":{}
}
我注意到在使用该应用程序时,您也会得到这个:
"supportedInterfaces": {
"Geolocation": []
}
答案 1 :(得分:1)
ASK-SDK团队为其代码库维护TypeScript定义。您可以通过进入node_modules
目录并查看ask-sdk-model/index.d.ts
来检查支持哪些接口。
从v1.17.0开始,这些是:
/**
* An object listing each interface that the device supports. For example, if supportedInterfaces includes AudioPlayer {}, then you know that the device supports streaming audio using the AudioPlayer interface.
* @interface
*/
export interface SupportedInterfaces {
'Alexa.Presentation.APL'?: interfaces.alexa.presentation.apl.AlexaPresentationAplInterface;
'AudioPlayer'?: interfaces.audioplayer.AudioPlayerInterface;
'Display'?: interfaces.display.DisplayInterface;
'VideoApp'?: interfaces.videoapp.VideoAppInterface;
'Geolocation'?: interfaces.geolocation.GeolocationInterface;
}