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); }); } }