What it's about
Salesforce Integration is used to automatically open a task for every call according the conditions (Queue, Call status or Outbound) set in the trigger: the Salesforce Task or Case that will be created automatically, will be populated with information about the call (managed on XCALLY) and displayed to the agent in the Salesforce environment.
When an Agent manages a call, his/her account email address will be searched in Salesforce: if the system finds the Salesforce Task will be assigned, otherwise the task will be assigned to the Salesforce Administrator Account specified in Motion-Salesforce integration. If all the configuration is properly set, the Salesforce Task will be opened as shown below:
Requirements
Salesforce Configuration
Create a New Connected App
Login to Salesforce with an Administrator account. Switch to Lightning Experience.
From the Homepage, access the Setup section
From Apps → App Manager, create a New Connected App
Enter the following data into the New Connected App:
Retrieve the Client ID and Secret
Login to Salesforce with an Administrator account
From Apps → App Manager → enter the app
In the API section, click on Manage Consumer Details
Verify your identity (email with verification code could be sent in the spam folder)
Copy the Consumer Key (Client ID) and Secret (Client Secret)
Retrieve the Token
When you set the Salesforce user password, you will receive an email with the Security Token. Save it!
If you don’t remember the token or want to reset it:
Login to Salesforce with an Administrator account
From the Homepage, access the Settings section
From My Personal Information → Reset My Security Token, click on Reset Security Token
You will receive an email with the actual security token. Save it!
Please note that any time you change the Salesforce user password, the Token becomes invalid and must be reset: remember to insert the new one on the XCALLY Salesforce Account to make integration work!
OAuth and OpenID Connect Settings
Finally you need to allow OAuth Username-Password Flows to avoid authentication failure
From Identity → OAuth and OpenID Connect Settings → switch on Allow OAuth Username-Password Flows
XCALLY Configuration
Create a Salesforce Account
To create a new Salesforce Account go in the Integrations section → Salesforce Accounts and click on
Enter the following details and click on Add Salesforce Account:
Name: enter a name for the integration
Type: chose New Tab: The task will be displayed in a new browser tab. Remember: this works only if the agent is logged in Motion interface.
Username: this value must be the same as the Salesforce Administrator Account Username
Password: same as a Salesforce Administrator Account Password
URL: your Salesforce URL i.e. https://my-company.my.salesforce.com
Client ID: Salesforce Consumer Key
Client Secret: Salesforce Consumer Secret
Security Token: Salesforce Security Token
Motion or Proxy IP Address: written as <protocol>://<ipaddress>[:<port>] form. It is required to use the Recording URL in the Task Configuration. Example: https://X.Y.Z.W
Description (optional)
Click on Add Salesforce Account
After the Account is created, you can view it in the list of accounts, edit the account parameters and remove the account.
You can verify if the account credentials are correct by clicking on Test Salesforce Account.
Edit the Salesforce Account
Find the account from the accounts list and Click on Edit Salesforce Account:
You will see two tabs: Account and Configurations:
In the Account tab, you can modify the account parameters and in the Configurations tab, you can create, update or delete Salesforce configurations.
A Salesforce configuration is used to design the content of the Salesforce task (Subject, Description and Fields) that is created and displayed for the Agent managing calls.
You can create multiple configurations for a single Salesforce Account and use them in different triggers. In this way, for example, you will be able to use different task layout for outbound and inbound calls.
Configuration changes are automatically applied, without any service restart.
To create a new configuration, Edit the Salesforce account, go under configurations tab and click on
Choose a Name, Channel (Voice).
Choose a Type:
Inbound in Queue
Outbound Call
Choose a Ticket Type:
Task
Case
Then, click on Add Salesforce Configuration.
This value is used during the startup of the configuration and is used by the system to generate the template: the configuration will be created with default Subject and Description settings that you can simply use without any modification.
You can also edit the configuration and customize the Subject, Description and Fields of the Salesforce Task according to your needs.
The default Subject and Description settings depends on the type of configuration.
For example, the default subject configuration for Queue Type is [xCALLY Ticket] Queue calleridnum while for Outbound Type it's [xCALLY Ticket] Outbound Call destcalleridnum.
Subjects
By default, you will find the following three fields already configured
the String [XCALLY Ticket]
the Queue Variable
the Caller number Variable
You can add more than one field in the Subject and all fields will be joined by the blank space.
Use button to add a new fields. New fields are added at the end of the field list.
You can insert 3 different type of fields:
String: static string e.g. a label as [xCALLY Ticket]
Variable: Motion System Variable, e.g. queue or calleridnum (see V3 Motion Variable List)
Custom Variable: any dynamic variable created under Tools > V3 Variables
Descriptions
You can add more than one field in the Description. All fields will be joined by new line.
Use button to add a new Description (it will be added at the bottom of the list).
You can insert two different type of fields:
String: static string e.g. *** Call Info ***
Key Value: name-value item in the form name: value
where the first field is a static string (e.g. Caller Number) and the second field could be filled with the following:
String: static string
Variable: System Variable like Caller Number (see V3 Motion Variable List)
Custom Variable: dynamic variable created under Tools > Variables
The colon character in the Key Value type is automatically added by the system
Fields
In the drop-down list you can find the complete list of fields available in your Salesforce account: Standard and Custom fields.
Use button to add a new field, choose the Standard or Custom field by scrolling the list of the values.
Define the Type:
String: static string (you must insert it)
Variable: a System Variable (choose it from the list: e.g. Queue, uniqueid, calleridnum, etc.)
Custom Variable: one of the dynamic variables (created under Tools > Variables)
Picklist: choose among the list of the integrated Application Fields. You can only select one of the predefined values available for that field (if any).
Repeat the steps above to add more fields.
The only custom fields that can be configured are those of the following type: string, int, picklist, boolean, email, textarea and phone (other field types are not proposed in the configuration)
Advanced
In this section you can set:
how to Search the Module as: Account, Lead, Contact, Contact&Lead, Contact&Lead&Account
how and if (nothing=no creation) to Create the Module as: Contact, Lead or Account
Lead Id, where to insert the Lead name (this field will be shown only if the Module Search field is or contains Lead)
Additional field where to search the customer phone number in the:
Account, if the Module Search value chosen is (or contains) Account
Contact, if the Module Search value chosen is (or contains) Contact
Lead, if the Module Search value chosen is (or contains) Lead
This is a field, in addition to Phone, to search for customers in Lead, Contact and Account: you can insert here the mobile or fax number field name you have on Salesforce
You can find Lead Field Name on Salesforce under Object Manager Menu → Lead → Fields & Relationship:
Configure the Trigger
It is mandatory to create a Trigger to make the Salesforce integration work.
Go to Tools → Triggers Section and click on .
Enter the trigger Name, select Voice Channel and click on Add Trigger.
Do not forget to set the trigger's status ON.
Add Trigger Conditions
You can use properties like Queue, Call status or outbound to define the conditions you want to trigger the Salesforce integration.
Example: the integration will be active for Calls in Sales Queue and when the call is answered.
For more information on trigger conditions, take a look at Voice Trigger Conditions.
Add Trigger Action
To execute the Salesforce integration when the conditions are met, click on Add Action and select Integrations and Salesforce.
You can then select one of the the Salesforce account you have created and the configuration you want to use.