AWS Partner Network (APN) Blog

Integrating Amazon Connect Natively into Salesforce Using Service Cloud Voice

By Chintan Gandhi, Sr. Specialist Solutions Architect, Amazon Connect – AWS

Salesforce Service Cloud Voice (SCV) natively integrates the Amazon Connect contact center platform into Salesforce’s customer relationship management (CRM) software. This delivers a new contact center solution that brings together voice conversations, digital channels, and CRM data.

The pre-built integration makes voice channel native to Salesforce Service Cloud and enhances the agent and supervisor experience in several key ways:

  • Unified agent interface: Agent handles interactions across channels (voice and digital) using a unified agent interface, Omni-Channel.
  • Voice Call object: Each voice interaction in SCV is captured as a Salesforce data object which makes reporting and analytics native to Salesforce.
  • Real-time transcription: SCV’s out-of-the-box integration with Amazon Connect Contact Lens enables real-time transcription and analysis of the conversation. This can be leveraged for use cases such as supervisor monitoring, agent assist, and next best action.

In this post, I will explain the pre-built integrations, deployment options, and architectural mapping patterns pertaining to SCV. I will also provide an example of inbound customer journey with data flow and API calling sequence.

SCV Pre-Built Integrations

To provide Salesforce-native experience to users (agents, supervisors) and rapid development experience to developers, Salesforce provides pre-built integrations. Examples are:

Unified Agent Interface with Single Sign-On

Out-of-the-box single sign-on (SSO) configurations allow contact center agents to log in to Salesforce and get automatically logged in to Amazon Connect to receive voice calls. Amazon Connect supports identity federation by configuring SAML 2.0 with AWS Identity and Access Management (IAM) to enable web-based SSO from Salesforce to the underlying Amazon Connect instance.

Salesforce-Service-Cloud-Voice-1

Figure 1 – SAML authentication flow (conceptual).

SAML Authentication Flow

The diagram in Figure 1 shows a conceptual SAML authentication flow:

  1. Agent logs on to the Salesforce Service Console from a web browser. Once the agent changes the status to “Available” (or “Available for voice”) in Omni-Channel, SAML flow is triggered. The request is sent to the Connected App, which is configured for SAML integration with Amazon Connect.
  2. Connected App sends federation request to Salesforce identity provider (IdP) for authentication.
  3. IdP authenticates the user and returns authentication response.
  4. Connected App sends the SAML assertion to agent’s browser.
  5. Browser posts the SAML assertion to AWS sign-in SAML endpoint, and the AWS sign-in endpoint processes the request and forwards authentication token to Amazon Connect.
  6. Using authentication token, Amazon Connect authenticates the agent and makes the agent available to take calls.

SCV Out-of-the-Box APIs

In Service Cloud Voice, Salesforce provides out-of-the-box APIs in the form of AWS Lambda functions to automate provisioning of the required AWS resources and to enable rapid development of customer journeys.

At a high level, these Lambda functions can be divided into two categories:

  • Provisioning functions: These Lambda functions are used for provisioning and configuration of required AWS services for SCV integration. They are automatically triggered by the Salesforce backend process and no end user interaction is required.
  • Transactional functions: These Lambda functions are used during the call to enhance the customer and agent experience by fetching customer details, delivering real-time transcription, and enriching voice call data. Some of the functions need to be invoked from the contact flow or can be modified according to business requirements.

The following diagram depicts inbound call flow and data flow, as well as typical API calling sequence for transactional functions.

Salesforce-Service-Cloud-Voice-2

Figure 2 – Inbound customer journey (click image to magnify).

  1. Customer places a call and it lands on the Amazon Connect instance.
  2. Associated contact flow plays welcome prompt.
  3. Contact flow calls the InvokeSalesforceRestApiFunction Lambda function to look up customer details based on caller’s phone number.
  4. InvokeSalesforceRestApiFunction function runs query on Salesforce contact object and returns customer details; caller is greeted by name and offered self-service.
  5. Post self-service, the contact flow calls the InvokeTelephonyIntegrationApiFunction function to create voice call object in Salesforce, which represents a call in Salesforce and stores call metadata as well as user-defined data points.
  6. InvokeTelephonyIntegrationApiFunction function creates voice call object in Salesforce with call related fields and retunes voice call ID.
  7. Calls get transferred to agent logged on to Salesforce Omni-Channel and are connected to the agent.
  8. Once the conversation starts between the caller and agent, Amazon Kinesis Data Streams associated with Amazon Connect Contact Lens start streaming real-time transcript segments. That triggers the ContactLensConsumerFunction function with every new transcript segment in the stream.
  9. ContactLensConsumerFunction function extracts real-time transcript segments and transmits them to Salesforce to store and display.
  10. Once the call gets disconnected and the agent wraps up, Contact Record (CR, formerly known as Contact Trace Record) is generated in the Amazon Connect instance. This CR is streamed in the associated Kinesis Data Stream which triggers the CTRDataSyncFunction function.
  11. CTRDataSyncFunction function extracts call metadata—such as contact details, agent details, and queue details—from the CR and replicates into voice call object. As voice call object is native to Salesforce, call details are available across the Salesforce organization.

Deployment Models

There are two different deployment models that a customer can select from: SCV Bundle (also known as SCV) and SCV Bring Your Own Amazon (also known as BYOA or Salesforce Partner Telephony with Amazon Connect).

  • SCV Bundle: This deployment model requires AWS services to enable SCV running from a new AWS account created by Salesforce under Salesforce’s AWS Master Payer Account. Customer has root access to the AWS account but there is a Service Control Policy which allows customers to use fixed number of AWS services.
  • SCV BYOA: In this deployment model, required AWS services to enable SCV will run from a customer’s AWS account. In BYOA, a customer has the option to use additional AWS services beyond the scope of SCV.

In terms of SCV-specific features and functionality, there is no significant difference between these two deployment models. Following is a conceptual depiction of both.

Salesforce-Service-Cloud-Voice-3

Figure 3 – SCV deployment models (click image to magnify).

Architectural Mapping Patterns with Considerations

In Service Cloud Voice, there are multiple architectural patterns to map Amazon Connect instance(s) with Salesforce orgs. Customers should select the appropriate mapping pattern depending on their organization’s business architecture.

Following are some examples of mapping patterns with feasibility and considerations.

Salesforce-Service-Cloud-Voice-4

Figure 4 – SCV mapping patterns (click image to magnify).

Conclusion

In this post, I have explored some of the key aspects of Amazon Connect with Salesforce Service Cloud Voice (SCV), which provides pre-built integration of Amazon Connect into Salesforce.

SCV provides unified agent interface with pre-configured single sign-on to create Salesforce-native agent experience. SCV also provides out-of-the-box APIs to transact with Salesforce from Amazon Connect. Flexible deployment models and mapping patterns help to align SCV setup with a customer’s business architecture.

For a more in-depth exploration of SCV, please refer to the Service Cloud Voice workshop series.

.


Salesforce – AWS Partner Spotlight

Salesforce is an AWS Competency Partner that makes cloud-based software designed to help businesses find more prospects, close more deals, and wow customers with amazing service.

Contact Salesforce | Partner Overview | Case Studies