MCPcopy Create free account
hub / github.com/cdk-patterns/serverless / handle

Function handle

the-alexa-skill/python/lambda_fns/lambda.ts:27–38  ·  view source on GitHub ↗
(handlerInput: HandlerInput)

Source from the content-addressed store, hash-verified

25 handlerInput.requestEnvelope.request.intent.name === 'AMAZON.NavigateHomeIntent';
26 },
27 async handle(handlerInput: HandlerInput): Promise<Response> {
28 const speechText = 'Hey, it\'s Pancakes the CDK Otter here, what would you like to know?';
29 const repromptText = 'You can ask what CDK Patterns I have, if you like!';
30 const { attributesManager } = handlerInput;
31 attributesManager.setPersistentAttributes( {lastAccessedDate: Date.now(), lastAccessedIntent: 'Launch Request or Navigate Home'});
32 await attributesManager.savePersistentAttributes();
33 return handlerInput.responseBuilder
34 .speak(speechText)
35 .reprompt(repromptText)
36 .withSimpleCard('Hello World', speechText)
37 .getResponse();
38 },
39};
40const PatternListIntentHandler: RequestHandler = {
41 canHandle(handlerInput: HandlerInput): boolean {

Callers

nothing calls this directly

Calls 1

getPatternFunction · 0.70

Tested by

no test coverage detected