我想在我的自定義技能中使用VideoApp.Launch指令。因此,我將視頻應用的技能信息全球字段設置爲true,併爲視頻播放器添加了所需的意圖。Alexa VideoApp.Launch指令 - 目標設備不支持指定的指令
後來我開始用example from this page
來測試它之前,我加入了視頻指令ALEXA很簡單返回的輸出內容。但是,添加此目錄後,我收到錯誤:目標設備不支持指定的指令。我找不到解決此問題的任何文檔。有沒有我錯過的設備設置?
更新:我嘗試了Display.RenderTemplate以及相同的結果。錯誤:目標設備不支持指定的指令。我爲音頻,渲染模板和視頻設置了所需的全局字段爲true。
我查了一下到目前爲止:msg.context.System.device.supportedInterfaces
"supportedInterfaces": {
"AudioPlayer": {}
}
我使用的回聲。爲什麼這裏沒有其他接口可用?我如何使它們可用?
我的代碼和錯誤消息如下。在Alexa的歷史
/**
*
* main() will be invoked when you Run This Action
*
* @param Cloud Functions actions accept a single parameter, which must be a JSON object.
*
* @return The output of this action, which must be a JSON object.
*
*/
var main = function(msg) {
var response = {
version: "1.0",
response: {
outputSpeech: {
type: "PlainText",
text: "" + 'JSON.stringify(msg.request.intent)' //'.slots.questionContent.value'
},
"directives": [
{
"type": "VideoApp.Launch",
"videoItem":
{
"source": "https://www.example.com/video/sample-video-1.mp4",
"metadata": {
"title": "Title for Sample Video",
"subtitle": "Secondary Title for Sample Video"
}
}
}
],
"reprompt": null
}, "sessionAttributes": null
};
return {
statusCode: 200,
headers: { "Content-Type": "application/json" },
body: new Buffer(JSON.stringify(response)).toString("base64")
};
};