call.say('Welcome to the example hotline!');
var date = new Date();
if (date.getHours() >= 8 && date.getHours() <= 16) {
//notify your CRM about the call
http.post('http://example.com/crm/newcall', {
params: {
caller: call.getCallerId(),
when: date.toISOString()
}
});
// forward calls to the sales team
call.huntGroup({
name: 'sales'
});
} else {
// voicemail after business hours
call.say("Please leave a message after the beep.");
call.voicemail('myaddress@example.com');
}
MADE BY LIMTEL.COM
Contact Us