Connect to Live agent on Virtual agent based on selection of language

Delapan
Tera Contributor

Hello,

I have a requirement where there is a selection of static choice 'Select your preferred language' which contains the variables (English, French & Spanish) before connecting to live agent. Based on this selection of language I need to route to live agent. 
Could please explain how this can be configured in Queue's???

Thanks in advance!!!

1 ACCEPTED SOLUTION

SANDEEP28
Mega Sage

@Delapan Follow below steps and it will work

 

1) Go to "Setting" under conversational interface application. Then click on "View all" button under "Context variables" section. It will list all the OOB variables.

 

SANDEEP28_0-1697380679155.png

 

SANDEEP28_1-1697380828981.png

 

2) Click on "New" button to create new context variable. Provide variable name as below and submit.

 

SANDEEP28_2-1697380901663.png

 

SANDEEP28_3-1697380949341.png

 

3) You might have created separate topic block to allow user to select the preferred language. In that flow, you need to set the above variable name as below 

 

SANDEEP28_4-1697381061140.png

 

In the "Set language name" block is Script action utility block. Add below script 

 

 

 

(function execute() {
if (vaInputs.select_preferred_language)
vaVars.LiveAgent_user_selected_language = vaInputs.select_preferred_language;
})()

 

 

 

SANDEEP28_5-1697381172468.png

 

4) Create three queues for English, French & Spanish then add below condition. In filter condition, under context fields, you will get "user_selected_language" variable.

 

SANDEEP28_6-1697381292726.png

 

SANDEEP28_7-1697381327871.png

 

 

If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!

 

View solution in original post

5 REPLIES 5

Danish Bhairag2
Tera Sage
Tera Sage

Hi @Delapan ,

 

Please take a look at the below thread it should help you.

https://www.servicenow.com/community/hrsd-forum/ability-to-create-chat-queues-per-language-and-have-...

 

Mark my answer helpful & accepted if it helps you with your requirement.

 

Thanks,

Danish

SANDEEP28
Mega Sage

@Delapan Follow below steps and it will work

 

1) Go to "Setting" under conversational interface application. Then click on "View all" button under "Context variables" section. It will list all the OOB variables.

 

SANDEEP28_0-1697380679155.png

 

SANDEEP28_1-1697380828981.png

 

2) Click on "New" button to create new context variable. Provide variable name as below and submit.

 

SANDEEP28_2-1697380901663.png

 

SANDEEP28_3-1697380949341.png

 

3) You might have created separate topic block to allow user to select the preferred language. In that flow, you need to set the above variable name as below 

 

SANDEEP28_4-1697381061140.png

 

In the "Set language name" block is Script action utility block. Add below script 

 

 

 

(function execute() {
if (vaInputs.select_preferred_language)
vaVars.LiveAgent_user_selected_language = vaInputs.select_preferred_language;
})()

 

 

 

SANDEEP28_5-1697381172468.png

 

4) Create three queues for English, French & Spanish then add below condition. In filter condition, under context fields, you will get "user_selected_language" variable.

 

SANDEEP28_6-1697381292726.png

 

SANDEEP28_7-1697381327871.png

 

 

If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!

 

SANDEEP28
Mega Sage

@Delapan If I could help you with your Query then, please hit the Thumb Icon and mark as Correct !!

@SANDEEP28 it worked!!Thanks for the help.