Puzzel-Salesforce Omni-Channel integration
Puzzel-Salesforce integration is further strengthened by directing the Salesforce chat sessions through Puzzel expert routing mechanism which can dramatically lessen resolution times and increase customer satisfaction.
How does it work?
When a chat session is initiated by the customer on a Site with Salesforce chat, the request is sent to Puzzel’s skilled based routing engine.
The engine then determines the assignment of requests based on several pre-defined attributes and allocates it to the best qualified available agent as an email request.
Once the agent accepts the request, the customer record is automatically pulled up and the agent can begin the conversation.
Upon ending the chat session [either by customer or by agent] the request is also wrapped up within Puzzel.
Setting up the Salesforce Omni Channel integration to work with Puzzel
To be able to utilise Puzzel routing mechanism to assign Salesforce chat session to agents, you will have to make the following configurations in your Salesforce environment and provide Puzzel with the details mentioned in the last section of this article. Puzzel will then be able to set up the functionality to be working in your environment.
Salesforce configurations
To be able to do the following configurations, you will need to have Administrator privileges on Salesforce.
Enable Authentication into Salesforce
You will be required to create a connected app for Puzzel, to request access to the Salesforce data. For any connected app to request data, it is essential that the application is already integrated into Salesforce environment. For more details on integrating PCC into Salesforce please read Puzzel-Salesforce integration section on help.puzzel.com This will allow Puzzel to access the current users that are logged in into Salesforce and assign the chat session using the skill-based routing mechanism.
To create a connected app and specify the scope of authorization in Salesforce, you need to:
- Go to quick finder and type App Manager. Select App Manager from the results displayed as shown in the figure below. Click on New Connected App option found on the top right corner.
- Enter the following details in the Basic Information section
- Specify a name to the Connected Application
- Enter the API name [API name is the name used when referring to your app from a program. By default, it takes the connected app name]
- Enter the email address and contact telephone number
- Select Enable OAuth Settings under API(Enable OAuth Settings) section. This will now display the options under it
- Enter https:// for callback URL
- Select and move Access and manage your data(api) option to selected OAuth scopes
- Click save to see the new Connected App
- Note down the Customer Key and the Secret. You will need to provide this to Puzzel. [See the last section of this article]
Create a Salesforce User
You will need to create a Salesforce user with the following Object Settings permissions:
- Chat Transcripts – View All (Read permissions only on ‘Status’ field)
- Push Topics – Read
Provide Puzzel with the Username, password, and security token for this user. Please see the last section of this article.
Enable Omni-channel functionality
To activate Omni channel functionality, you need to:
- Click on the Settings icon on the top right corner of the screen
- Select Service Setup
-
Select Omni-Channel Settings under Omni-Channel in the quick finder
-
Select Enable Omni-Channel
-
Click Save.
Create PushTopic record
You need to create a PushTopic record specifying the events for which you wish to receive notifications for any changes to the Salesforce data. In this scenario, we would like to be notified when a new chat session has been initiated so that it can be processed via Puzzel routing engine.
To create a PushTopic record:
- Go to Developer Console from the menu option on the top right corner of your screen
-
Go to Debug -> Open Execute Anonymous Window
-
Paste the following code in the Enter Apex Code window and click on Execute
PushTopic pushTopic = new PushTopic();
pushTopic.Name = 'PSRPushTopic';
pushTopic.Query = 'Select Id,CreatedDate,WorkItemId,ServiceChannelId,groupid from PendingServiceRouting where RoutingModel =\'ExternalRouting\'';
pushTopic.ApiVersion = 50.0;
pushTopic.NotifyForOperationCreate = true;
pushTopic.NotifyForOperationUpdate = true;
pushTopic.NotifyForOperationDelete = true;
insert pushTopic;
- Verify that the code has been successfully executed in the logs below
Configuring Omni-Channel in Salesforce
To configure Omni-Channel, perform the following steps:
- Search for Routing Configurations in the quick finder and click on Edit.
- Set Routing mode to External and save the settings
-
Search for Presence Configurations in the quick finder and click on Edit.
- Select Automatically Accept Requests and save the changes.
Credentials to be sent to Puzzel
Please call Puzzel with the following credentials to help direct chat sessions through Puzzel.
-
Connected App Customer key
-
Connected App Customer Secret
-
Salesforce Username
-
Password to the above user
-
Security Token for the user
-
List of Group id and names for all queues in Salesforce. To get this list, run the follow SQL query
Select Id, name from Group where type = ‘Queue’