Skip to content

Instantly share code, notes, and snippets.

@apoorvlathey
Created April 23, 2020 17:13
Show Gist options
  • Select an option

  • Save apoorvlathey/2c302eaeb8face0358734e63e39ad3a1 to your computer and use it in GitHub Desktop.

Select an option

Save apoorvlathey/2c302eaeb8face0358734e63e39ad3a1 to your computer and use it in GitHub Desktop.
const HelloWorldIntentHandler = {
canHandle(handlerInput) {
return Alexa.getRequestType(handlerInput.requestEnvelope) === 'IntentRequest'
&& Alexa.getIntentName(handlerInput.requestEnvelope) === 'HelloWorldIntent';
},
handle(handlerInput) {
const speakOutput = 'Hello there! If you want to hear facts regarding Windows, say Facts.';
return handlerInput.responseBuilder
.speak(speakOutput)
//.reprompt('add a reprompt if you want to keep the session open for the user to respond')
.getResponse();
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment