Internationalize your Virtual Agent - ServiceNow Community
Mark Roethof
Tera Patron
Tera Patron

Hi there,

When working with Virtual Agent, one might wonder how to set up full translations to fulfill internationalization for messages. Or, how to change some English messages the Service Portal widget is showing. Some - like messages on User Inputs, Bot Responses - look pretty straight forward. Though what about those messages on the Service Portal widget itself like "Show Me Everything" or "Please type your request"?

The default look and feel Virtual Agent Service Portal widget

find_real_file.png

Setting up messages

Message translations can be set up two ways.

1) Literally type your message within the Message field. This works fine, though you can't use any parameters, javascript, etc. within here. It's just a string text.

find_real_file.png

2) Using the Script field in combination with gs.getMessage();. This gives you the possibility to make your text more dynamic, parameterize your message, etc..

find_real_file.png

Translating messages

Translating messages as defined within Topics is actually pretty easy. In our first example, we had a string "How can I help you?". To set up for example a Dutch translation, you would simply add a UI Message record.

Navigate to "System UI > Messages".

find_real_file.png

For the second, parameterized message, you would add a UI Message record looking like:

find_real_file.png

Translating Service Portal widget messages

So what about those messages like "Show Me Everything", "Please type your request here", etc. which are shown on the Service Portal widget. For most of these, you won't find a System Property or something. Though actually, translating these messages works the same as with Messages within topics! Just define a UI Message.

find_real_file.png

Changing the "Please type your request" message this way, results in:

find_real_file.png

Thing to consider

Messages like "How can I help you?", "You can type your request below, or use the button to see everything that I can help with." could be changed within system properties or messages within the Virtual Agent designer. Though you might consider not changing the messages in these places, instead of changing these messages thru the UI Messages. Why?
For example, if you've set up multiple UI Messages already, changing the messages itself (which is your key for the UI Messages) would cause to break the UI Messages structure! See below example. For "How can I help you?" the key is vital. So if you would want to change this in English, consider adding/changing the UI Message, message field. Keep the key intact.

find_real_file.png

---

And that's it actually!

👍
If this post helped you in any way, I would appreciate it if you hit bookmark or mark it as helpful.

Interested in more articles, blogs, videos, and Share projects on Virtual Agent I published?
Virtual Agent


Kind regards,
Mark

---

LinkedIn

Comments
Eliza Gee
Tera Explorer

Hi Mark! Do you happen to know if it's possible to translate the header ('header_label' field) when using multiple different brandings? I see there's a system property for the header language that seems connected just to the default branding; I've found a way to force language updates for the menu items; and I've searched through system scripts for reference to the field and haven't found anything. Any help would be greatly appreciated!

Mark Roethof
Tera Patron
Tera Patron

Hi there,

I thought the Chat Header (header_label) was not translatable pre-Quebec. Though just checked on Quebec, I18N debugging shows:

find_real_file.png

This indicates that this should be translatable.

So I opened the Branding Record, switch language, updated the Chat Header.

Checked in both languages... works!

Kind regards,
Mark

Version history
Last update:
‎09-22-2019 10:45 PM
Updated by: