As question says twilio redirect function not working properly with flow (twilio studio).
When I select function on phone number for incoming messages it is working FINE.
But when I tried to redirect incoming msg using the function widget on studio, redirect not working properly and debug console says response body empty.
This is the redirect function
exports.handler = function(context, event, callback) {
const response = new Twilio.Response();
response.appendHeader('Location', context.HTTP_REDIRECT_URL);
callback(null, response);
};
Please advise what's happening here?
Do I need to transfer some key pairs using function widgets?