Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
New Member

CCX Passing variable from one script to another

Hi all,

I have a scenario where the caller is prompted to enter his/her order number in one script and this information in stored in a variable 'strOrderNumber'. The IVR tree presents the callers with options that could route them to another script where upon arrival the caller is immediately asked to enter their Order Number again. I would like to know if there is a way to pass the data stored in the strOrderNumber variable (or the entire variable itself) to another script so that I can check to see if an order number exist prior to requesting that the caller enters their order number again. As usual any help will be greatly appreciated.

Everyone's tags (6)
1 ACCEPTED SOLUTION

Accepted Solutions

Re: CCX Passing variable from one script to another

We'll get you through this, don't worry.  But I like to let people see the solution on their own, versus throwing it in their face.  If this doesn't work for you, because of your learning style, or time constraints, let me know and I'll get right to throwing the solution across the room.

Look at this post I made.  I focused on the small task of creatings a session object, storing something in it, and then retrieving it back out.

I would start off by dragging the Get Session Info step into a script, right click Properties on it, then click Help.  Now read through the documentation on this step and how sessions are used.

Once you've done that, then I think you'll see that you were trying to store the value as the session mapping, as opposed to storing it within the session object.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.
6 REPLIES

CCX Passing variable from one script to another

My choice for this solution would be to leverage the Session object of the contact and store the variable/value in there.

I have commented once or twice on using Sessions within scripts.  See if these can help you out.  And if not, just post back here with any questions you have.

Happy scripting!

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.
New Member

Re: CCX Passing variable from one script to another

Hi Anthony,

First off thanks for replying, I find your POST quite helpful. I reviewed the previous POST you referenced and attempted to implement the logic; however, I don't believe I am doing this corretly (see attached script). Here's a brief summary:

Call Arrives
- Check if existing Session exists
- If no Session exist, Get Contact Info Step associating "Session' attribute to 'current_Session' (Session type) variable
- Request Customer input Order Number (stored as strOrderNumber variable)
- If order number is 'successful', map 'current_Session' variable to 'strOrderNumber' using "Session Mapping Step"
- Redirect call to Orders Application trigger

It is my understanding that based on this configuration, if the call is 'redirected' to another 'Application' trigger, the Check for existing Session (previous_Session == null) should hit the 'false' branch of the 'If' step. Correct"?

I can't seem to get this to work. While debugging I do see that in the attached script 'the current_Session' variable is set as described in the call flow summary above; however, I cannot retrive the value for the strOrderNumber variable once the call is redirected. As always any help you can provide will be greatly appreciated.

Re: CCX Passing variable from one script to another

We'll get you through this, don't worry.  But I like to let people see the solution on their own, versus throwing it in their face.  If this doesn't work for you, because of your learning style, or time constraints, let me know and I'll get right to throwing the solution across the room.

Look at this post I made.  I focused on the small task of creatings a session object, storing something in it, and then retrieving it back out.

I would start off by dragging the Get Session Info step into a script, right click Properties on it, then click Help.  Now read through the documentation on this step and how sessions are used.

Once you've done that, then I think you'll see that you were trying to store the value as the session mapping, as opposed to storing it within the session object.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.
New Member

Re: CCX Passing variable from one script to another

Hi Anthony,

I reviewed the POST you recommended, and I configured a simple script replicating the logic you used on your sample script; however, I cannot get the Session to return a value (I keep receiving a 'null' value). Can you take a look a the sample script I configured to see where I am going wrong?

New Member

Re: CCX Passing variable from one script to another

Hi Anthony,

I believe I spoke too soon, I was able to get it to work once I populated the Set Session Info Step 'Context' tab attributes. Now I'll try to see if i can get the data to appear in the other script after the call is redirected.

Re: CCX Passing variable from one script to another

Sweet.  Glad to hear you worked it out.  Let me know how it goes.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.

Anthony Holloway

Please use the star ratings to help drive great content to the top of searches.
1313
Views
0
Helpful
6
Replies
CreatePlease to create content