Data return and service recovery

The data return and service recovery components of the Agent Connect integration with Salesforce expand the basic capabilities of sending surveys after customer interactions.

With automated data return, Agent Connect sends back the results of customer surveys to be attached to the Salesforce case. With the completed survey data attached to a case, you can use a Salesforce Flow to automatically identify negative interactions and begin the service recovery process, ultimately resulting in a second survey to monitor the final results.

Note:
  • This guide is an addendum to the main configuration guide for the Salesforce integration. This guide assumes that you have already followed the configuration instructions in the main guide.

  • See the main guide for recommended testing procedures after configuration.

Configure a Flow to create service recovery cases

Create a Flow process to open service recovery cases when negative feedback is received. The Flow created should contain the criteria for creating a service recovery Case to perform a secondary outreach to a customer based on negative feedback from the initial Feedback survey.

  1. Enter Flow in the Quick Find box and select "New Flow".

  2. When the Flow Builder loads, select "Record-Triggered Flow".

  3. In the Object selection drop-down menu, search for and select "Agent Connect Response".

  4. Set the entry conditions based on your desired criteria for creating service recovery cases.

    In the following example, the condition is set when the Star Rating question from the Feedback survey receives a response less than or equal to 3, indicating a negative CSAT score.

    The Flow criteria should be customized to use the fields and conditions needed by your organization.

  5. Select "Optimize the Flow for Actions and Related Records", since this Flow will create a new case (or other object).

    example flow settings
  6. Save the Flow and provide a Flow Label, Flow API Name, and optional Description.​

Tip:

Suggested Flow Label & Description

  • Flow Label — Create Service Recovery Case

  • Description — This will automatically create a case when negative feedback is received from Agent Connect.

Next, add a Create Records element to the Flow to create the new service recovery case. Configure the element as seen below:

  • Label — Create Service Recovery Case

  • How Many Records to Create — One

  • How to Set the Record Fields — Use separate resources, and literal values

  • Create a Record of this Object — Case

  • Field Values for the Case:

    Note: The following Field Values are possible suggestions, but modifications and customizations may be necessary if your organization uses different fields.
    • Status — New

    • Subject — Service Recovery Case

    • Owner ID — Field reference OR user : map to a user or group ​(This should be the owner or group responsible for Service Recovery. It should never be a hard coded value as this will fail if that individual loses access to the Salesforce instance)

    • Contact ID — Field reference : map to contact ID of original request

    • Initial Request ID — Field reference: map to Request ID

    • Origin — Case Origin, relates to channel seen in Agent Connect Platform

    • Send Agent Connect Service Recovery Date Time Field — Blank Field to be populated when Case is Closed

    • Description — For the description field it is best to use a formula, such as:

      "Case: " & {!$Record.StellaConnect__Stella_Connect_Request__c.StellaConnect__Case_Lookup__c.CaseNumber} & " received a star rating of: "& Text({!$Record.StellaConnect__Star_Rating__c}) & " with the following comments: " & {!$Record.StellaConnect__Comments__c
    • (Optional) Add any other fields needed, such as Brand or Language.

Save and activate the Flow when finished.

example case settings

Configure data return

When enabled, Agent Connect will send completed survey data back to Salesforce, and the managed package will create Response records in Salesforce containing information about the surveys, including question scores and comments. Data is returned as soon as a survey is marked "Finished", which means either that the customer has completed the survey or the Survey is Marked Finished After value (configured on the Agent Connect Company Info page) has been reached.

Enable data return

To enable data return:

  1. Open the Integrations page in Agent Connect, then find the Salesforce section.

  2. Click Connect with Salesforce.

    image of the connect with salesforce button

    You may need to authenticate with Salesforce before moving forward.

  3. When Salesforce requests permission to allow access to "Stella Connect", click Allow.

    image of the salesforce allow access window
Note: If you have already authenticated for v1 of the managed package and you are upgrading to v2 of the package, you will need to authenticate again.

Review data return field mapping

In the Agent Connect Lightning Configuration tab, the Data Return Field Mapping tab is pre-populated with required mappings, and a few optional mappings, when the managed package is installed.

image of data return field mappings

Every type of question asked in your survey must have a related mapping here (including comment fields for different question types). If you ask a type of question that is not represented in the default mappings, follow the steps below to add a new mapping:

  1. In the Data Return Field Mapping tab, click New.

  2. In the New Mapping modal window that appears, enter the required information:

    • Name — Enter a unique name for a field that will hold the value returned from Agent Connect for this item.

      Make sure to add the field to the Response record, if it is not already present.

    • Data Return Path — Enter the path to the value in the expected payload from Agent Connect, using dot notation (for example, object.field_name).

    • Field — Select the name of a field in Salesforce to be used to store the value received.

      This field will be accessible to Salesforce for reporting or analyzing survey responses.

    • List Item Value — (Optional) If the field in the Data Return Path contains a list item, enter the name of the field within each list item where the relevant value is stored.

      For example, looking at "Areas for Improvement" in the default mappings, the Data Return Path is answers.areas_of_improvement.selected_options. The selected_options field is an array containing list items, and each list item includes a field named option_text that we are interested in. Thus, we use option_text for the List Item Value.

  3. Click Save when finished.

Configure service recovery

Service recovery refers to the process of automatically identifying negative interactions based on survey scores, re-engaging with the same customers to repair the relationship, and ultimately sending a followup survey to analyze the result.

The Agent Connect integration with Salesforce enhances the service recovery process to ensure that you can take every opportunity to follow up after a negative customer experience. With the service recovery component, follow-up cases are created in your Salesforce instance when a survey response that meets your criteria is received. Then, when a service recovery case is closed, a follow-up survey is sent to the customer.

Service recovery field mapping

In the Agent Connect Lightning Configuration tab, the Service Recovery Mapping tab maps data from Salesforce onto the required attributes for Agent Connect surveys. The fields on this tab will be used to create Request records in Salesforce and populate important parameters in the API requests from Salesforce to Agent Connect.

Service recovery mapping works much the same as the request field mapping, but requires fewer fields since service recovery records link to an initial request, which was generated based on the Request Field Mapping.

Note: The major difference between service-recovery Request records and initial survey Request records is value of the Request Type field in the record ("Initial Request" vs. "Service Recovery").
image of the service recovery mapping tab

Follow the steps below to configure this tab:

  1. Set the Requests Auto-triggering switch to "Test" to use your Test API Key if you're not ready to move to production, or switch it to "Production" to use the Production API Key.

  2. Select the object to create for service recovery.

    This is typically a case object.

  3. Select the relevant fields from the object selected in the previous step to map onto Agent Connect service-recovery requests.

    All of the necessary items to map are listed on the tab, with some providing additional guidance to help you select the relevant fields.

    For more information on the fields in this tab, see Field mappings and custom properties.

Service recovery request Flow (Record-Triggered Flow)

For service recovery, you will need a separate Flow that is nearly identical to the initial request Flow, with different values in a few places. The following notes cover the differences between the two. For information on the basics of the initial request Flow, see the main Salesforce integration guide.

Start block

example start block with the request type highlighted

In the Conditions section of the start block, set Request_Type_c to Service Recovery. This ensures that the next step is only performed for service-recovery interactions.

Create Records block

The next block will create a new service recovery case for agents.

example field values with the field mapping highlighted
  • In the Set Field Values section, set the "Field Mapping to be Used" to the name of the service-recovery field mapping you wish to use (found in the Agent Connect Lightning Configuration tab).

  • Set the "Request Type" to Service Recovery.

Agents can now work the new service recovery case as normal. When the new case is closed, the integration will trigger a follow-up survey, ultimately resulting in a new Response record that you can analyze to determine the impact of the service recovery interaction.