Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
CTRDataSyncFunction Lambda Function
Configuration: This function is available to Salesforce Voice with Amazon Connect and Salesforce Voice with Partner Telephony from Amazon Connect customers who are using an Amazon Connect instance and connecting to a Kinesis stream. The configuration is automatically performed when you create a contact center in Voice.
Description: This function performs these actions:
- Synchronizes data between a contact record from Amazon and a VoiceCall record by taking the data from the Amazoncontact record and updating the VoiceCallrecord.
- As part of the update, if the function finds that a VoiceCall record doesn’t exist, it creates one. This behavior is useful for missed or abandoned calls.
- If the CallDisposition field in the VoiceCall record isn’t already set, sets it to Completed.
The following data is synced between the Data model for Amazon Connect contact records and a VoiceCall record:
| Amazon Connect Contact Record Attribute | VoiceCall Field | Notes |
|---|---|---|
| InitiationTimestamp | CallStartDateTime | |
| DisconnectTimestamp | CallEndDateTime | |
| InitiationTimestamp and DisconnectTimestamp |
CallDurationInSeconds |
CallDurationInSeconds is inferred from InitiationTimestamp and DisconnectTimestamp. |
| Agent.ConnectedToAgentTimestamp | CallAcceptDateTime | The CallAcceptDateTime value matches the Agent.ConnectedToAgentTimestamp value, even if it’s null. |
| Agent.CustomerHoldDuration | CustomerHoldDuration | The DurationInSeconds field on the VoiceCallRecording record gets its value by adding Agent.CustomerHoldDuration and Agent.AgentInteractionDuration from the Amazon contact record. |
| Agent.LongestHoldDuration | LongestHoldDuration | |
| Agent.NumberOfHolds | NumberOfHolds | |
| Agent.AgentInteractionDuration | This value isn’t mapped to a VoiceCall field. However, the DurationInSeconds field on the VoiceCallRecording record gets its value by adding Agent.CustomerHoldDuration and Agent.AgentInteractionDuration from the Amazon contact record. | |
| Queue.EnqueueTimestamp | CallQueuedDateTime | |
| Queue.Name | QueueName | |
| InitiationMethod | CallType (only when creating a new record) | This value is used to infer values for ToPhoneNumber and FromPhoneNumber.
Also used for the CallType field if creating a new VoiceCall record. Supported InitiationMethod values include:
|
| SystemEndpoint.Address | ToPhoneNumber or FromPhoneNumber |
If InitiationMethod is Inbound, the value is mapped to ToPhoneNumber (when creating a new record). If InitiationMethod is Outbound, this value is mapped to FromPhoneNumber. |
| CustomerEndpoint.Address | ToPhoneNumber or FromPhoneNumber | If InitiationMethod is Inbound, the value is mapped to FromPhoneNumber. If initiationMethod is Outbound, this value is mapped to ToPhoneNumber (when creating a new record). |
| Recording.Location | CallRecordingId | The VoiceCall record creates a reference to the VoiceCallRecording record using the CallRecordingId reference ID field. |
Usage: The data synchronization automatically starts when a contact record is generated. You don’t need to call this function manually.