Contents
Configuring Genesys Widgets
Genesys Widgets supports multiple widgets including Webchat and Co-browse. You can configure all widgets and services in the same configuration object. When you add new Genesys products and services, you must update your Genesys Widgets configuration to enable those widgets.
After you deploy the Genesys Widget on your website, configure the CX Widget by defining the global window._genesys Javascript object.
To include the JavaScript script, you can choose one of the following options:
- Place the script inline on your website; or
- Place it in a separate JavaScript file, and then include the file on your page.
The following example is a basic view of the global Genesys Widgets configuration object:
<script>
if(!window._genesys)window._genesys = {};
if(!window._gt)window._gt = [];
window._genesys.cxwidget = {
main: {},
webchat: {},
cobrowse: {}
};
</script>
The following example is a populated Chat Widget configuration that includes configuration options for Webchat and Co-browse (GCB):
<script>
if(!window._genesys)window._genesys = {};
if(!window._gt)window._gt = {};
window._genesys.cxwidget = {
main: {
theme: "dark",
lang: "en",
i18n: "http://HOST:PORT/path/to/lanaguages/file.json"
},
webchat: {
apikey: "0123456789", // Used for Apigee service only
dataURL: "http://HOST:PORT/path/to/chat/service",
userData: {},
proactive: {
enabled: true,
idleTimer: 5,
cancelTimer: 30
},
chatButton: {
enabled: true,
template: false,
openDelay: 1000,
effectDuration: 300,
hideDuringInvite: true
}
},
cobrowse: {
src: "<COBROWSE_SERVER_URL>/cobrowse/js/gcb.min.js",
url: "<COBROWSE_SERVER_URL>/cobrowse"
}
};
(function(d, s, id, o){
var f = function(){
var fs = d.getElementsByTagName(s)[0], e;
if (d.getElementById(id)) return;e = d.createElement(s); e.id = id;
e.src = o.src;fs.parentNode.insertBefore(e, fs);
},ol = window.onload;
if(o.onload){typeof window.onload != "function"?window.onload=f:window.onload=function(){ol();f()}}else f();
})(document,'script','genesys-cx-widget', {src: "http://www.yourhost.com/path/to/cx-widget.min.js", onload: false});
</script>
Main Configuration
Genesys Widgets is a hub for multiple Genesys products and services. Some configuration options are set globally and therefore apply to all products and services running on the CX Widget platform. In the following object, you can configure options such as visual theme and language.
main
Type: object
Default: none
Requirement: Optional
Description: General global settings for the CX Widget
main.theme
Type: string
Default: "light"
Requirement: Optional
Description: Choose between dark and light themes. This changes the color scheme of the CX Widget.
main.lang
Type: string
Default: none
Requirement: Optional
Description: Set the current language using a language code. For more information about localization, see localization.
main.i18n
Type: string or object
Default: none
Requirement: Optional
Description: Set the localization language pack
Webchat Configuration
Genesys Webchat utilizes the Genesys Mobile Services (GMS) framework for fast and secure access on the cloud. In the object below, configure the connection settings for your chat server, and then modify how the webchat widget behaves on your website.
webchat
Type: object
Default: none
Requirement: Optional
Description: Configuration object for webchat (window._genesys.cxwidget.webchat)
webchat.apikey
Type: string
Default: none
Requirement: Optional
Description: If you use the secure Apigee proxy, provide the apikey value to connect to the proxy. The apikey is provided by Genesys.
webchat.dataURL
Type: string
Default: none
Requirement: Mandatory
Description: A fully qualified web URL to your Genesys Mobile Services API (GMS) server. To obtain the URL, consult with the person in charge of your Genesys environment.
webchat.userData
Type: object
Default: none
Requirement: Optional
Description: An object to pass arbitrary page-specific, product-specific, and user-specific values that assist with tracking and routing chats.
webchat.proactive
Genesys Webchat provides a built-in method to proactively engage your customers without using Genesys Web Engagement when they are idle on your web page for a preset amount of time. A customer is considered idle when they have not used their mouse or keyboard. When the preset time is reached, an invitation to chat is displayed on the customer's screen. If the customer accepts the invitation, the Webchat widget is displayed. When you setup your localization options, you can customize the messages in the invitation.
Type: object
Default: none
Requirement: Optional
Description: The Chat Widget includes a basic proactive engagement invitation system with user input idle tracking
webchat.proactive.enabled
Type: boolean
Default: false (disabled)
Requirement: Optional
Description: Enable or disable proactive engagement chat invitations. Note: This value should be set to false if you are using Genesys Web Engagement for proactive chat.
webchat.proactive.idleTimer
Type: integer (seconds)
Default: 5
Requirement: Optional
Description: The number of seconds the user must be idle before a chat invitation is displayed to them
webchat.proactive.cancelTimer
Type: integer (seconds)
Default: 30
Requirement: Optional
Description: The number of seconds before the chat invitation automatically closes if the user does not accept or decline the invitation
webchat.chatButton
Like the proactive invitation feature, Genesys Webchat also offers a built-in chat button that floats on the right side of the screen by default. To override the default appearance and behavior of the button, you can specify your own HTML and CSS for the button. You can use images, animations, or any visual you want. When your customer clicks on the visual, the Webchat widget starts and the chat button is hidden automatically. You can configure how fast the chat button fades in and out, and even set a delay for when it is displayed on the screen.
Type: object
Default: none
Requirement: Optional
Description: Configure the built-in chat button to initiate a chat
webchat.chatButton.enabled
Type: boolean
Default: false (disabled)
Requirement: Optional
Description: Enable or disable the built-in chat button
webchat.chatButton.template
Type: string
Default: false (disabled)
Requirement: Optional
Description: Define a custom HTML template string to replace the default chat button
webchat.chatButton.openDelay
Type: integer (milliseconds)
Default: 1000
Requirement: Optional
Description: Delay in milliseconds before the chat button appears when loading the page or after closing the chat widget
webchat.chatButton.effectDuration
Type: integer (milliseconds)
Default: 300
Requirement: Optional
Description: Duration in milliseconds of the show and hide animation effects
webchat.chatButton.hideDuringInvite
Type: boolean
Default: false (always show)
Requirement: Optional
Description: Hide the chat button when the chat invite view is open
Co-browse Configuration
CX Widget supports the use of Genesys Co-browse for sharing your customer's web browser screen with one of your agents and allow agents to control your customer's browsing. If you have a Co-browse server deployed you can configure CX Widget to connect to it. See your Genesys Co-browse administrator for the proper values to use in the configuration section.
cobrowse
Type: object
Default: none
Requirement: Optional
Description: Configure the Genesys Co-browse implementation for CX Widget (window._genesys.cxwidget.cobrowse)
cobrowse.url
Type: string (url)
Default: none
Requirement: Required
Description: URL to Genesys Co-browse service (HTTP)
cobrowse.src
Type: string (url)
Default: none
Requirement: Required
Description: URL to the Co-browse javascript library (hosted on Co-browse server)
Can I modify the Chat Registration Form?
The Chat Registration Form does not currently support modifications. To implement a custom chat registration, you must create your own form, and then use the Widget Bus API to launch the actual Chat Widget with your custom user data, thus bypassing the default Chat Registration Form.
