I am trying to elicit an intent from Amazon LEX through lambda but I was given an error calling uncaught exception. Would appreciate the help, my code is as follows:
'use strict';
exports.handler = (event, context, callback) => {
const sessionAttributes = event.sessionAttributes;
const slots = event.currentIntent.slots;
const intention = slots.Intention
{
let response = {
sessionAttributes: event.sessionAttributes,
dialogAction: {
type: "ElicitIntent",
message: {
contentType: "PlainText",
content: `Would you like to do A or B? `
}
}
}
callback(null, response);
}
}