This commit is contained in:
ろむねこ 2024-07-16 15:00:09 +09:00
parent 54dc9c094d
commit 136eb34d15
Signed by: Fujimatsu
GPG Key ID: FA1F39A1BA37D168

View File

@ -36,14 +36,9 @@ const KidShiftAuthIntentHandler = {
&& Alexa.getIntentName(handlerInput.requestEnvelope) === 'KidShiftAuthIntent';
},
async handle(handlerInput: Alexa.HandlerInput) {
if (Alexa.getSlot(handlerInput.requestEnvelope, 'loginCode').value === undefined) {
return handlerInput.responseBuilder
.speak('Please provide a valid login code')
.reprompt('Please provide a valid login code')
.getResponse();
}
const speakOutput = 'Hello World!2';
return handlerInput.responseBuilder
.speak('your auth code is ' + Alexa.getSlotValue(handlerInput.requestEnvelope, 'loginCode'))
.speak(speakOutput)
.getResponse();
}
};