cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
830
Views
5
Helpful
4
Replies

How to pass call info from one script to the other?

Scelo
Level 1
Level 1

Hi everyone

Been trying to get call details from welcome script to the survey script for days to no luck (am not good with scripting).

Scenario:

- Clients calls 5009 and select option 1 to speak to IT

- Call gets connected to IT (IT personnel helps the user and ask if the user is willing to take a 30 seconds survey call - with 3 questions)

- If yes, the caller gets transferred to the script on 6666

Plan:

We need to be able to save the following info into our DB:, queue on which the call was taken by

1 AgentName/extension

2 Service Queue

3 Clients number

4 Q1 Answer [1=yes or 2=no]

5 Q2 Answer [1=poor or 5=excellent]

6 Q3 Answer [1=poor or 5=excellent]

From there we need to be able to pull this information into an excel spreadsheet.

Challenges:

With help from the forum (looking at answered questions):

- I can write all 3 answers into DB

- But i'm unable to get original calling number, csq and agent name/ext.

This is on UCCX 9.0 Premium license. Script written by Rob Newton (Failing to get to the original post where i got the survey script). Please help check why can't i return agentext, csq and calling party.

4 Replies 4

Scelo
Level 1
Level 1

Tried playing with it and this happens:

- It shows my agent - empty

- csq - empty

- calling party - empty

Looks to me like i am unable to collect call information from the original call to the post survey call. It shows the post survey trigger number (DN) as the called number. Shows the agent number as the calling number.

Anthony Holloway
Cisco Employee
Cisco Employee

I think you might have gotten your original sample from this post by Rob Newton:

https://supportforums.cisco.com/comment/9314621#comment-9314621

Comparing Rob's original script, to your modifications, I can see that you have changed it quite a bit.

For starters, Rob is using Sessions to capture, and recall data about the original call, but for some reason you are not doing that in your Welcome.aef script, and instead it looks like you're trying to use Enterprise Data instead.

I would recommend you starting with Rob's base solution in a test environment; get that working first, then modify from there.  Granted, it looks like he did not share the main script of his (e.g., Welcome.aef), so you'll have to infer a few things from the Survey script.  Such as, the fact that he's capturing those Session variables and passing data between scripts with a Session from the Triggering Contact.

Therefore, in your Welcome script, you will need to:

  • Store a reference to the Contact's Session object
  • Store the caller ID of the Contact in that Session
  • Store the selected CSQ in that Session
  • Wait until the Agent is connected, then store the Agent ID
  • Using the Get User Info step, get the Agent Ext and store it in that Session

If you keep the variable names the same, I'm sure Rob's survey script will work just fine for you.  Good luck.

Thank you,

Am on it, I will update you on the outcome.

Hi Anthony,

I tried and matched the variables as advised (and took the advise above) but I am still not winning. My fields comes back empty (my answered to questions are only values returned), i have attached my script and outcome.