Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

Sample Lambda integration flow in Amazon Connect - Amazon Connect

Sample Lambda integration flow in Amazon Connect

Note

This topic explains a sample flow that is included with Amazon Connect. For information about locating the sample flows in your instance, see Sample flows in Amazon Connect.

Type: Flow (inbound)

This flow shows you how to invoke a Lambda function and do a data dip, that is, retrieve information about the customer. The data dip uses the caller's phone number to look up the US state they are calling from. If the customer is using chat, it returns a fun fact. Here's how it works:

  1. A prompt tells the customer that a data dip is being performed.

  2. The Invoke Lambda function block triggers sampleLambdaFlowFunction. This sample Lambda function determines the location of the phone number. The function times out in 4 seconds. If it times out, it plays a prompt that says "Sorry, we failed to find the state for your phone number's area code."

  3. In the first Check contact attributes block, it checks the channel the customer is using: voice, chat, task. If chat, it returns a fun fact.

  4. If voice, the second Check contact attributes block is triggered. It checks the match conditions of State, which is an external attribute. It uses an external contact attribute because it's getting data by using a process that's external to Amazon Connect

  5. A prompt tells you that it's returning you back to Sample inbound flow, and then starts the Transfer flow block.

  6. If the transfer fails, it plays a prompt and then disconnects the contact.

For more information about using attributes, see Store a value from a Lambda functions as a contact attribute in Amazon Connect.

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.