Important: the E-Mail-Address of your Genesys Cloud User must equal the Expert-User E-Mail-Address in Flexperto.
“{insert key provided by widget}”
to address the right chat widgetThe following code has to be implemented into the Webpage to open the right Chat Widget
Address the right widget with the correct key and enter the right queue name (both in bold). Configure the widget depending on the customer requirements.
<script src="https://apps.mypurecloud.de/widgets/9.0/cxbus.min.js" onload="javascript:CXBus.configure({debug:false,pluginsPath:'https://apps.mypurecloud.de/widgets/9.0/plugins/'}); CXBus.loadPlugin('widgets-core');"></script>
<script>
window._genesys = {
"widgets": {
"webchat": {
"transport": {
"type": "purecloud-v2-sockets",
"dataURL": "https://api.mypurecloud.de",
"deploymentKey": "{Insert Key provided by widget}",
"orgGuid": "{Insert customer Org ID}",
"interactionData": {
"routing": {
"targetType": "QUEUE",
"targetAddress": "{Please insert Name of your Flexperto queue}",
"priority": 2
}
}
},
"userData": {
"addressStreet": "",
"addressCity": "",
"addressPostalCode": "",
"addressState": "",
"phoneNumber": "",
"customField1Label": "",
"customField1": "",
"customField2Label": "",
"customField2": "",
"customField3Label": "",
"customField3": ""
}
}
}
};
function getAdvancedConfig() {
return {
"form": {
"autoSubmit": false,
"firstname": "",
"lastname": "",
"email": "",
"subject": ""
},
"formJSON": {
"wrapper": "<table></table>",
"inputs": [
{
"id": "cx_webchat_form_firstname",
"name": "firstname",
"maxlength": "100",
"placeholder": "Required",
"label": "First Name"
},
{
"id": "cx_webchat_form_lastname",
"name": "lastname",
"maxlength": "100",
"placeholder": "Required",
"label": "Last Name"
},
{
"id": "cx_webchat_form_email",
"name": "email",
"maxlength": "100",
"placeholder": "Optional",
"label": "Email"
},
{
"id": "cx_webchat_form_subject",
"name": "subject",
"maxlength": "100",
"placeholder": "Optional",
"label": "Subject"
}
]
}
};
}
const customPlugin = CXBus.registerPlugin('Custom');
</script>
<button type="button" id="chat-button" onclick="customPlugin.command('WebChat.open', getAdvancedConfig());">Start Chat</button>
First configure the backend integration with Flexperto. As umbrella a third-party web service integration is used.
Then 2 web service actions are used
Both web service actions are available for downloading and can be imported into another Genesys Cloud instance.
Find-Experts-x-user-id-20220128111830.custom
Reserve-Meeting-20220128111834.custom
Create / configure an agent script. For the MVP a dedicated script was used. If a customer has an existing script, this script can be enhanced with this integration.
Define script properties. Script must be usable for chat.
Then create the script. How a script can be build is documented in the Genesys Resource center: https://help.mypurecloud.com/articles/about-scripting/
The Script used for the MVP demo will be provided as file: “Demoscript Flexperto.script”. This can be imported and used. The script includes all used variables and actions. Example of action configuration:
If the script was published it can be assigned in the queue configuration to the Chat properties.