Attempting to create a chat bot that will hit a web service midway through and ask questions based on previous responses.
I have created a function that will return an array of people that I will then text these names and ask the user to pick one.
Twilio Function
exports.handler = function(context, event, callback) {
const employees = [{ name: 'Mark', id:15 }, { name: 'Scott', id:16 }, { name: 'Steve', id:17 }];
callback(null, employees);
};
I would hope this would return function_1.parsed values, but everything is stored in function_1.body and I can't access it the way I hoped.
Here's a view of my Log.
Anyone know how I can send this to Parsed instead of body? If I submit a simple object it will return to the parsed value.
exports.handler = function(context, event, callback) {
const employee = { name: 'Mark', id:15 };
callback(null, employee);
};