Apply specific chat branding in Virtual Agent web ... - ServiceNow Community
Mark Roethof
Tera Patron
Tera Patron

Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

 

Hi there,

 

When working with the Virtual Agent web client, there are several parameters that you can add to Service Portal Agent Chat Configuration and a (legacy) Service Portal widget. Parameters like loading a specific topic, disabling sound notifications, activating live agent only, etcetera. In a few short articles I'll share a bit of background information on some of these parameters. This time: Appliy a specific chat branding configuration to the Virtual Agent web client.

Branding key

By default when a new conversation is started, the default branding record will be applied. You could update the out-of-the-box branding record, though you could also create your own branding record. Creating your own branding record does become necessary when working with multiple service portals where perhaps different branding is required, or when displaying a different Virtual Agent web client based on roles and perhaps different branding is required. Depending on how you implemented the Virtual Agent web client on your instance, you would need to add a parameter to the applicable Service Portal Agent Chat Configuration record, or add it to the URL parameters of the (legacy) Service Portal widget. Both methods do work slightly differently.

Service Portal Agent Chat Configuration

If you are using Service Portal Agent Chat Configuration, open the applicable Service Portal Agent Chat Configuration record. Within the Server Script you would need to add "branding_key: 'your_branding_key'" to have a specific branding record being applied to the Virtual Agent web client. The branding key being the value which you entered in the 'Branding key' field on the branding record.

 

For example:

 

(function($sp) {

    return = {
        branding_key: 'your_branding_key'
    };

})($sp);

 

(legacy) Service Portal widget

If you are using a (legacy) Service Portal widget, verify if it concerns an embedded widget (for example to the header or footer of the portal) or that it concerns a widget instance that has been added to a specific page.

Widget instance

When having a Widget instance in place, ctrl + right click on the Virtual Agent icon, and select "Instance Options".

 

find_real_file.png

 

Within the modal, add to the "Virtual Agent Client URL Parameters" field:

 

sysparm_branding_key=your_branding_key


Embedded widget

A common seen method when working with the Virtual Agent web client, is embedding the Service Portal widget to the header or footer of the portal. Adding URL parameters is also possible in this case, I've explained such in a previous article (Adding instance options to directly embedded Service Portal Widgets).

 

For example, your code for embedding the Service Portal widget might look like:

 

<widget id="sn-va-sp-widget"></widget>

 

To apply a specific branding to your Virtual Agent web client you would need to expand this to:

 

<widget id="sn-va-sp-widget" options='{"va_url_params":"&sysparm_branding_key=your_branding_key"}'></widget>

---


And that's it! A short explanation on how you can apply a specific branding on the Virtual Agent web client, for both Service Portal Agent Chat Configuration and a Service Portal widget. If any questions, let me know!

 

C

If this content helped you, I would appreciate it if you hit bookmark or mark it as helpful.

 

Interested in more Articles, Blogs, Videos, Podcasts, Share projects I shared/participated in?
- Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

 

Kind regards,


Mark Roethof

Independent ServiceNow Consultant
3x ServiceNow Developer MVP

3x ServiceNow Community MVP

---

LinkedIn

Comments
Community Alums
Not applicable

where can we find the available branding keys?

P Buck
Giga Contributor

The branding key is Conversational Interfaces | Branding. Then locate the custom brand your created in the table display.  See the branding key in upper right. Take that value and add to java script; below is an example 

(function($sp) {
Return {
live_agent_queue: $sp.getDisplayValue('sp_chat_queue'),
branding_key: 'k2_vap_default'
};
})($sp);

PBuck_0-1672885751062.png

 

R0810
Tera Expert

Hi @Mark Roethof , This article is helpful, thankyou. Is there a possibility to have customer specific support number on the virtual agent menu item option for call support on service portal? Or is it like we can have only one support number configured for this? Screenshot attached for reference.Call support .jpg

Version history
Last update:
‎08-08-2024 10:01 AM
Updated by:
Contributors