Salesforce Inbound Connector
About the Salesforce Inbound Connector
You can use the Salesforce inbound connector to load operational reporting data from your Salesforce account into XM Discover.
Required Setup in Salesforce
To connect XM Discover to Salesforce, you will need the following information about your Salesforce account:
- Your Salesforce Consumer Key (client ID)
- Your Salesforce Consumer Secret (client secret)
- Your Salesforce username and password
- Your Salesforce organization’s environment URL
- A valid Salesforce Object Query Language (SOQL) query to retrieve feedback or chat interactions
Qtip: SOQL enables you to search your organization’s Salesforce data for specific information. SOQL is similar to the “SELECT” statement in the widely used Structured Query Language (SQL) but is designed specifically for Salesforce data. For an introduction to SOQL, please see this Salesforce help page.
Additionally, you must perform the following in your Salesforce account:
- In your connected app, select Enable OAuth Settings. See this Salesforce help page for more information.
- Set the Callback URL to: https://data.us1.qualtrics.io/connectors?token_type=salesforce
- Select the following OAuth Scopes:
- Access custom permissions (custom_permissions)
- Access unique user identifiers (openid)
- Full access (full)
- Manage user data via APIs (api)
- Perform requests at any time (refresh_token, offline_access)
- Make sure PKCE is not enabled
- In the same connected map, select Manage OAuth Access Policies. See this Salesforce help page for more information.
- Choose the following options:
- Permitted User: All users may self-authorize.
- Refresh Token Policy: Refresh token is valid until revoked.
Setting Up a Salesforce Inbound Job
Qtip: The “Manage Jobs” permission is required to use this feature.
- On the Jobs page, click New Job.
- Select Salesforce.
- Give your job a name so you can identify it.
- Choose the project to load data into.
- Give your job a description so you know its purpose.
- Click Next.
- Choose a Salesforce account to use, or select Add New to add a new one.
- If adding a new account, enter the following information about your Salesforce account:
- Connection Name: Give the connection a name so you can identify it.
- Salesforce Client ID: Your Salesforce Consumer Key.
- Salesforce Client Secret: Your Salesforce Consumer Secret
- Salesforce Environment: Your Salesforce organization’s environment URL
- Test environment: If connecting to a test environment, enable this option.
- Click Authorize.
- If you want your credentials to expire, then configure the following options:
- Send Expiration Notifications: Select this option to allow your credentials to expire.
- Days prior expiration: If enabling expiration notifications, enter how many days you’d like to be notified before the expiration. You may enter a value between 1 to 100 days.
- Expiration Date: Set the date when the credentials will expire. Click on the box to open a calendar to pick the date.
- Click Next.
- Choose the type of feedback to upload from Salesforce:
- Salesforce Feedback: Upload regular feedback.
- Salesforce Chat: Upload agent/client interactions from Salesforce Chat.
- Salesforce SMS Text: Upload agent/client interactions from Salesforce LiveMessage.
- If uploading Salesforce Chat, select how agents and clients are identified:
- Auto-detect: Detect agents, chat assistants, and visitors automatically.
- The first participant is an agent: The first chat participant will be assigned as an agent.
- The first participant is a client: The second chat participant will be assigned as an agent.
- Select the API Version you’d like to use.
- Enter a custom SOQL statement to limit the data retrieved from Salesforce.
Qtip: To retrieve chat data, use the LiveChatTranscript object in the query.Attention: GROUP BY is not supported.Example: SELECT Id, CreatedDate, Body, ChatDuration FROM LiveChatTranscript. - Click Validate Query to test your SOQL statement.
- If the validation was successful, choose the date field used to identify data to be retrieved.
Qtip: This list only contains fields that are present in your SOQL query.
- Click Next
- If needed, adjust your data mappings. See the Data Mapping support page for detailed information on mapping fields in XM Discover. The Default Data Mapping section has information on the fields specific to this connector and the Mapping Conversational Fields section covers how to map data for conversational data.
- Click Next.
- If desired, you can add data substitution and redaction rules to hide sensitive data or automatically replace certain words and phrases in customer feedback and interactions. See the Data Substitution and Redaction support page.
Qtip: Click Download Sample Data to download an Excel file with sample data to your computer.
- Click Next.
- If desired, you can add a connector filter to filter the incoming data to limit what data is imported.
- You can also limit the number of records imported in a single job by entering a number in the Specify Record Limit box. Enter “All” if you would like to import all records.
Qtip: For conversational data, the limit is applied based on conversations rather than rows.
- Click Next.
- Choose when you’d like to be notified. See Job Notifications for more information.
- Click Next.
- Choose how duplicate documents are handled. See Duplicate Handling for more information.
- Choose Schedule Incremental Runs if you’d like your job to run periodically on a schedule, or Set Up One-Time Pull if you’d like the job to run just once. See Job Scheduling for more information.
- Click Next.
- Review your setup. If you need to change a specific setting, click the Edit button to be brought to that step in the connector setup.
- Click Finish to save the job.
Default Data Mapping
Attention: As field names are case-sensitive in Connectors, the first letter of the field name must be upper-case as displayed in the Data Sample to ensure data mappings are accurate and the job succeeds. The field names for Salesforce’s SOQL queries are case-insensitive.
This section contains information on the default fields for Salesforce inbound jobs.
- natural_id: A unique identifier of a document. It is highly recommended to have a unique ID for each document to process duplicates correctly. For Natural ID, you can select any text or numeric field from your data. Alternatively, you can automatically generate IDs by adding a custom field.
- document_date: The primary date field associated with a document. This date is used in XM Discover reports, trends, alerts, and so on. By default, this is mapped to the date field selected after specifying the SOQL query. You can choose one of the following options:
- CreatedDate (default): The date when the Salesforce object was created.
- ClosedDate (for chat data): The date when the case was closed.
- If your source data contains other date fields, you can choose one of them.
- You can also set a specific document date.
- feedback_provider: Identifies data obtained from a specific provider. For Salesforce uploads, this attribute’s value is set to “Salesforce” and cannot be changed.
- source_value: Identifies data obtained from a specific source. This can be anything that describes the origin of data, such as the name of a survey or a mobile marketing campaign. By default, this attribute’s value is set to “Salesforce.” Use custom transformations to set a custom value, define an expression, or map it to another field.
- feedback_type: Identifies data based on its type. This is useful for reporting when your project contains different types of data (for example, surveys and social media feedback). By default, this attribute’s value is set “Operational Reporting”. Use custom transformations to set a custom value, define an expression, or map it to another field.
- job_name: Identifies data based on the name of the job used to upload it. You can modify this attribute’s value during the setup via the Job Name field that is displayed at the top of each page during the setup.
- loadDate: Indicates when a document was uploaded into XM Discover. This field is set automatically and cannot be changed.
Qtip: See Mapping Conversational Fields for information on how to map conversational data.