amazon-connect / amazon-connect-realtime-transcription

Transcribe Live Customer Audio for Amazon Connect using Amazon Kinesis Video Streams and Amazon Transcribe
MIT No Attribution
163 stars 99 forks source link

java.lang.IllegalArgumentException: One of streamARN or inputFileName must be provided getting this error when Lambda is calling #28

Closed samrat-VF closed 3 years ago

samrat-VF commented 4 years ago

Hi Team ,

I need to fix the issue, we are recieving the below error when I am trying to call the Java Lambda. Let me know what its missing , This is working fine in another environment

2019-11-30 04:23:11 INFO KVSTranscribeStreamingLambda:98 - received request : streamARN=null, startFragmentNum=null, connectContactId=null, languageCode=Optional.empty, transcriptionEnabled=false, saveCallRecording=false 2019-11-30 04:23:11 INFO KVSTranscribeStreamingLambda:99 - received context: lambdainternal.api.LambdaContext@15a34df2 2019-11-30 04:23:11 ERROR KVSTranscribeStreamingLambda:123 - KVS to Transcribe Streaming failed with: java.lang.IllegalArgumentException: One of streamARN or inputFileName must be provided at com.amazonaws.kvstranscribestreaming.TranscriptionRequest.validate(TranscriptionRequest.java:121) at com.amazonaws.kvstranscribestreaming.KVSTranscribeStreamingLambda.handleRequest(KVSTranscribeStreamingLambda.java:103) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498)

efh365 commented 4 years ago

Hi, according to the error log line it looks like you are missing the stream arn and input file name. Those should both be passed to the lambda function in the kvsConsumerTrigger function.