Skip to main content

Salesforce Service Cloud Module

Introduction

The Salesforce Service Cloud Module integrates Salesforce Service Cloud (SFSC) into your chat process, enabling you to transfer data seamlessly between LoyJoy and SFSC. This module allows you to create, update, and read objects, such as Person, Case, or custom objects, in Salesforce.

Typical Use Cases

  • Data Management: Use this module to create or update objects like Cases or Contacts in Salesforce based on data collected during the chat.
  • Customer Support: Implement a Web-to-Case system where customer requests are automatically turned into cases in SFSC.

How to Use the Module

Modes

  1. SObject (write):
  • Write data to Salesforce objects (e.g., Case, Person). You just need the name of the object and the name of the field you want to write to configure the transfer.
  • Option to update only existing records or create new ones.
  • Requires authorization using Client ID, Secret, and Salesforce domain name.
  • Supports mappings to align chat variables with Salesforce fields.

Example Mapping

grafik

  1. SObject (read):
  • Retrieve data from Salesforce objects.
  • Requires authorization and supports mappings.
  1. API Request:
  • Perform custom API requests to Salesforce.
  • Requires authorization and mappings.
  1. Chat:
  • Initiate a Salesforce Service Cloud chat session.
  • Requires Deployment ID, Organization ID, Button ID, and Salesforce deployment domain.

Web-to-Case

Support requests from customers can also be recorded and automatically created as a case in the Sales Force Service Cloud (Web-to-Case).

To do this, the desired information can be collected from the customer via chat, e.g. with a questionnaire module, and transferred to the cloud via the Salesforce Service Cloud module.

sfsc_wtc1

(1) In the module, "SObject (write)" is selected (2) "Salesforce deployment domain" must be entered and (3) the mapping created (see next section). It is important that the variables of the mapping match the previously queried values in the process How to Set Up Variables.

Authorization

You will need to create a ConnectedApp in the Salesforce Service Cloud for the connection to work.

From this connected app, you can then copy the client ID and secret. You can find these under PLATFORM TOOLS > Apps > App Manager. Click on New Connected App in the upper right corner. Give it a name (e.g. LoyJoy connection) and set the API (Enable OAuth Settings) checkbox. In the area Callback URL add the following URL.

https://app-cloud.loyjoy.com/auth/oauth2/salesforce_service_cloud/callback

LoyJoy needs the api and refresh_token OAuth Scopes.

grafik

Click Save and you will be redirected to the settings of the connected app. Here you can find the Consumer Key and Secret which you can view by clicking on Manage Consumer Details. Verify yourself and copy the Consumer Key and Consumer Secret to the LoyJoy module.

grafik

Lastly, your My Domain Name is required. To acquire this, follow the instruction in the official Salesforce Documentation. After you have adjusted the settings in Salesforce Service Cloud and entered the information in LoyJoy, you can authenticate LoyJoy by clicking on Authorize in the Salesforce Module in LoyJoy.

grafik

Chatflow Example

This is an example flow which first registers a customer, asks them for their first and last name and then creates / updates a contact in Salesforce Service Cloud accordingly:

grafik