Page 1 of 1

Transfer Support Calls during Business Hours Only

Posted: Sun Jan 24, 2016 6:40 pm
by headpill
Hello,

I have wrote an Inbound Call Script, So far so good. I am trying to Route a Call to Support Department when Caller can not perform business over Inbound Script. But i would like to Put a condition that Calls can be transferred to Support Dept during the Business Hours 8 AM to 5 PM EST only, otherwise VXML will Prompt caller that this is not a valid Business Hour and Caller can Record a Message which will be saved in a file system.

How to put a condition on Business Hours in the VXML and Branch the Calls.

Please guide.

Thanks.

Re: Transfer Support Calls during Business Hours Only

Posted: Mon Jan 25, 2016 2:16 pm
by support
Hello headpill,

Placing a condition on the business hours for your call transfer is possible but best done on server side and not through the vxml script itself. By using either javascript or php, you can write a script with an if/else statement that first fetches the current time, then checks that time against the hours of 8am to 5pm (0800 to 1700) and routes the call to Support Dept if the current time falls between the valid hours. If it does not you would route the caller to an answering service where they can record a message which will be saved to a file system.

The following php script will do what you're asking for:

Code: Select all

<?php
$t = date("H");

if ($t > "08" && $t < "17") {
	#Route caller to Support
} else {
    #Route caller to answering service
}
?>
We hope this helps.

Regards,
Plum Support

Re: Transfer Support Calls during Business Hours Only

Posted: Thu Jan 28, 2016 5:55 pm
by headpill
Thanks, resolved it.