【发布时间】:2019-04-05 03:29:07
【问题描述】:
我正在编写一个 lambda 函数来处理 alexa 技能请求。在“BuildingLookUpIntent”内部,在 https.get() 之后,响应中没有添加任何内容。
'BuildingLookUpIntent': function(){
var response = "";
https.get('https://*******.execute-api.us-east-1.amazonaws.com/active/building?*******', (res) => {
res.on('data', (d) => {
response += d;
});
});
var speechOutput = response;
this.response.speak(speechOutput);
this.emit(':responseReady');
}
Alexa 返回一个空白字符串。
【问题讨论】:
标签: node.js lambda https get alexa