I am having problems trying to make a function that I will call from flex instance. The problem is that I'm getting the runtime application timed out error . I know how that twilio will kill any function that lasts longer than 5 secs. I want to do what this https://www.twilio.com/docs/runtime/functions/faq?code-sample=code-return-a-simple-successful-response&code-language=Node.js&code-sdk-version=default however it's still same problem.
...
client.recordings.each({ callSid: callSid }, recordings => {
/* code to do with recordings (this includes another function with the client) */
}, function(err, result) {
callback(err, Response);
});