ClientMetadata not present in custom challenge triggers

2

I'm trying to implement an custom challenge using Amplify -> Cognito, the issue is that when I call: Auth.signIn({... , validationData: {foo: 'bar'}, {foo: 'bar'}}), the validationData or clientMetadata are present in Define Auth Challenge or Create Auth Challenge triggers as described in the documentation https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-lambda-define-auth-challenge.html

It's extremely important to be able to send context to Define and Create Auth Challenge from the client so we could define what challenge was chosen on the client-side, e.g Email, or Sms, or even sending the users language so during sending the challenge the language could be defined to send messages through SNS, and it seems people are managing that in a hacky way by answering a "dummy" challenge just be able to send context to the lambda, here's the discussion in Amplify repo. I'd like to know if someone else went through this issue and figured out another solution and if Cognito team has plan to fix it?

Thanks.

Aucune réponse

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions