0

We are using Amazon connect which uses the "Get customer input" interact block to use the Amazon Lex which internally connects to Lambda so the flow will be like

Amazon Connect -> (using Get Customer Input, It connects to Amazon Lex) Amazon Lex -> (In Amazon Lex, the intent is pointed to Amazon Lambda) Amazon Lambda

Amazon connect -> Amazon Lex -> AWS Lambda 

The flow works for all the intents as expected.
but for a particular flow, We need to upload the file from lambda to S3 and return the s3 download link as a response to the lex, Since it has the operation of upload the file to S3, the AWS lambda takes 7 seconds to complete the request.

Now the Amazon Connect fails with Error in the Get Customer Input (which points to Amazon Lex),

So do I need to configure any timeout in Amazon Connect (Get Customer Input block / somewhere) which waits till the lambda process of 7 seconds gets completed?

Any help is appreciated.

Thanks,
Harry

John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
Harry
  • 3,072
  • 6
  • 43
  • 100
  • This is tricky - Amazon Connect has a hard timeout limit of 8 seconds for Lambda invocations. I'm not sure if Lex has something similar - one way I've heard people doing similar activities is to chain Lambda's together. So Lex lambda calls the Upload lambda to do the upload and LEX lambda returns immediately. How you go from there to letting the user know the files ready though I'm not sure. – Garreth May 24 '20 at 21:13
  • @Garreth you mentioned as increasing the DTMF helped the time for LEX too – Harry May 25 '20 at 02:20
  • Is it possible to break up the conversation into 2 parts? First an upload, with a Lex response of "Thank you the file is uploading" then ask if they want the link, "would you like to know the link to that file?" And if yes, then by this time, the upload should have completed and you can lookup the link. – Jay A. Little Jun 02 '20 at 07:08

2 Answers2

0

I won’t get into the call center user experience and advise against the use case because I believe you know the business case better.

For something like this what you would need to do is keep the customer waiting while is the file uploading, Once you confirmed the upload is triggered you can get the customer out of the lambda invocation and use the loop block and with each iteration, you check on the file status then continue the flow.

enter image description here

Ahmed Bebars
  • 367
  • 1
  • 13
-1

Amazon Connect is a call center solution where it would be a bad customer experience to make them wait for prompts even more than 3 seconds. The use case of performing and upload operation seems to be an operational job where it can trigger the process through Amazon Connect and the call can move on. Once the S3 upload is done then it can notify the concerned recipients on the status.