Newer Version Available
Contact Flow: Agent Transfer
This contact flow illustrates the customer experience when a call is
transferred from one agent to another agent.
The agent transfer flow is used to Speed Dial (also described as Quick Connect in Amazon Connect terminology) a particular agent.

| Block | Description |
|---|---|
| Set logging behavior [1] | This block turns on logging in Amazon Connect for this flow. We recommend logging for debugging and evaluating the contact flow. |
| Loop [2] | This block sets up a loop so that we can try to invoke the Lambda function up to two times. We try twice in case that the Lambda isn’t warmed up and it times out. (See Keep the InvokeTelephonyIntegrationApiFunction Lambda Function Warm to prevent this scenario from ever occurring.) |
| Invoke AWS Lambda function [3] |
This block calls the InvokeTelephonyIntegrationApiFunction Lambda Function, which is used to create a VoiceCall record for a transfer (createTransferVC) in Salesforce. Salesforce provides the InvokeTelephonyIntegrationApiFunction Lambda Function with Voice. |
| Set contact attributes [4] | This block executes only if the Lambda invocation fails multiple times and the loop completes. This block adds an error attribute in the Amazon contact trace record (CTR) to help you see which calls experienced an error. Some errors are recoverable and don’t prevent the call from being handled. |
| Set contact attributes [5] | This block sets a voiceCallId attribute in the contact flow. The voiceCallId is the ID of the VoiceCall record. This value is case-sensitive and is required to fetch the VoiceCall record when the call is routed to the agent. |
| Set recording and analytics behavior [6] | This block sets the recording behavior to On. This action records the audio conversation between the agent and the customer, which can be accessed later from the VoiceCall record. |
| Transfer to agent [7] | This block transfers the caller to the agent. |