Last active
August 3, 2020 08:29
-
-
Save leoaiassistant/097612da2fbe33d861c650d179c0ac31 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let skill; | |
exports.handler = async function (event, context) { | |
console.log(`REQUEST++++${JSON.stringify(event)}`); | |
if (!skill) { | |
skill = Alexa.SkillBuilders.custom() | |
.addRequestHandlers( | |
LaunchRequestHandler, | |
LTintentHandler, | |
HelpIntentHandler, | |
CancelAndStopIntentHandler, | |
SessionEndedRequestHandler, | |
) | |
.addErrorHandlers(ErrorHandler) | |
.create(); | |
} | |
const response = await skill.invoke(event, context); | |
console.log(`RESPONSE++++${JSON.stringify(response)}`); | |
return response; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment