AWS Amplify Cognito from Android - InvalidLambdaResponseException

0

I try to log in to Cognito by doing this:

Amplify.Auth.signIn( "prueba", "prueba1234aB", result -> Log.i("AuthQuickstart", result.isSignInComplete() ? "Sign in succeeded" : "Sign in not complete"), error -> Log.e("AuthQuickstart", error.toString()) );

and get this error:

AuthException{message=Sign in failed, cause=com.amazonaws.services.cognitoidentityprovider.model.InvalidLambdaResponseException: Unrecognizable lambda output (Service: AmazonCognitoIdentityProvider; Status Code: 400; Error Code: InvalidLambdaResponseException; Request ID: [...]

My goal is to get the user credentials, so I can work with them when it comes to using other AWS services.

I tried logging in from the web interface Amazon provides to test users and it did work, so it should not be the user fields' fault.

What am I doing wrong exactly? Is it something about the code? Or maybe something about the pre-authentication triggered Lambda? If so, how should I deal with the response I'm returning from that Lambda?

Thanks in advance!

답변 없음

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠