01-30-2014 09:58 AM - edited 03-14-2019 01:02 PM
I already have a call redirect step on my uccx script that sends calls to a cell phone number when there are no agents available. Now the client wants to add a second number to redirect to and evenly distribute calls between the 2 cell numbers. Anyone have an idea how I can configure my script to do this or otherwise?
Solved! Go to Solution.
01-31-2014 03:04 AM
Ok, understood on the Java thing...you don't have to be any sort of expert on Java...it actually solves your problem easier than any other method I might explain to you. So I'm going to explain, how to perform the task as I showed in the screen capture.
First in your Variable Pane we will create 2 Variables
//The Numbers within the " " would be yours
String[] cellNumbers = new String[] {"2148269945", "2148262234"}
int index = 0
The cellNumbers Variable is an Array of Strings; so besides single String where the value would be a single "NUMBER" enclosed by quotation marks you create Array of Strings because you have 2 Cell Phone Numbers.
The index variable will be used as the Random Number that is determined by the random number generator (which so happens to be our Java Class) and that number will be between 0 and 1 (which will represent your 2 Cell Phone numbers). In order to access the CellPhone Number to Call you use the appropriate index in the Array something like this:
cellNumbers[0] = "2148269945"
cellNumbers[1] = "2148262234"
Or for the purposes of Distributing the calls to the cell phone numbers, we will Generate a "Random" Number between 0 and 1, while setting the Value of the index variable.
index = Random Number
cellNumbers[index]
What I'm going to leave you with are 2 scripts; the first one will test and validate how the procedure works all you have to do is open the script: RandomNumberTestCase press the "Step Over" Debug button and see the variables getting "randomly"(it may not be as random as you think..everytime..do the debug a few times) set by the SET steps..(you don't even need to save it on the UCCX Server..fyi)
The other script I'm attaching will be the STEP (and 2 Variables You have to Create in your Prod Script) you would want to use to "randomly" distribute the calls between the 2 Cell Phone Numbers.
01-30-2014 06:27 PM
Do you have an Enhanced Java License+? If so there are many ways you could do this..here is a screencapture of a cool way to do it..*You don't need the SET Step to do it...the SET Step is here just to Test the Results of the Returned String (which is extracted from the Array of String..using the Random Class that "randomly" picks between 0 and 1 (2 numbers))..
For your purposes/solution..you just need the information contained in the Call Redirect Step to get the results your customer needs..
01-30-2014 11:25 PM
Hi there,
Thanks a lot for the reply. Looks interesting and would work.Problem is I'm not a java expert (actually, java nothing) and don't have the Java License either. I just do the drag and drop stuff. Any other way you can recommend?
01-31-2014 01:32 AM
Or better yet, is it possible to give me a quick walkthroug on how to get this done?
Thanks.
01-31-2014 02:15 AM
Just to be clear, the Licensing on your UCCX Server is STD?
01-31-2014 02:30 AM
Oh. It's the CCX version you were asking about? No it's CCX enhanced 9.0.2.
01-31-2014 03:04 AM
Ok, understood on the Java thing...you don't have to be any sort of expert on Java...it actually solves your problem easier than any other method I might explain to you. So I'm going to explain, how to perform the task as I showed in the screen capture.
First in your Variable Pane we will create 2 Variables
//The Numbers within the " " would be yours
String[] cellNumbers = new String[] {"2148269945", "2148262234"}
int index = 0
The cellNumbers Variable is an Array of Strings; so besides single String where the value would be a single "NUMBER" enclosed by quotation marks you create Array of Strings because you have 2 Cell Phone Numbers.
The index variable will be used as the Random Number that is determined by the random number generator (which so happens to be our Java Class) and that number will be between 0 and 1 (which will represent your 2 Cell Phone numbers). In order to access the CellPhone Number to Call you use the appropriate index in the Array something like this:
cellNumbers[0] = "2148269945"
cellNumbers[1] = "2148262234"
Or for the purposes of Distributing the calls to the cell phone numbers, we will Generate a "Random" Number between 0 and 1, while setting the Value of the index variable.
index = Random Number
cellNumbers[index]
What I'm going to leave you with are 2 scripts; the first one will test and validate how the procedure works all you have to do is open the script: RandomNumberTestCase press the "Step Over" Debug button and see the variables getting "randomly"(it may not be as random as you think..everytime..do the debug a few times) set by the SET steps..(you don't even need to save it on the UCCX Server..fyi)
The other script I'm attaching will be the STEP (and 2 Variables You have to Create in your Prod Script) you would want to use to "randomly" distribute the calls between the 2 Cell Phone Numbers.
03-19-2015 02:17 PM
Would it be possible using this script to call all the numbers at the same time and the first one that answers gets the call, kind of like a call blast.
02-02-2014 10:29 PM
Thanks a lot. This is really helpful. Will test this and let you know how it goes.
04-09-2019 10:23 PM
02-03-2014 12:44 AM
Two thumbs up. Thanks a lot man. This works perfectly. Really appreciate you taking time to help me out on this. Brilliant.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide