function callNumber(err, data) { if (err) throw err obj = JSON.parse(data) for(i=0; i < obj.numbers.length; i++) { var number = obj.numbers[i]; client.calls.create({ to: number, from: twilioNumber, url: sayUrl, applicationSid: applicationSid, method: "GET", fallbackMethod: "GET", statusCallbackMethod: "GET", ifMachine: "Hangup", record: "false" }, function(err, call) { console.log("Call made to " + number); }); } }
client.messages.list ( function ( err, data )
log.debug('Sending request to send sms', sms); transport.sendSms(sms, function(err) {
const smsBody = `${appointment.name}, this message is to confirm your appointment at ${time.format('h:mm a')} on ${date.format('dddd MMMM Do[,] YYYY')}.` twilioClient.messages.create({ to: '+1' + appointment.phone, from: twilioNumber,
); client.messages.create (