AWS Cognito with Lambda for custom validation -


using aws lambda cognito can autoverify email using below code.

event.response.autoconfirmuser = true; event.response.autoverifyemail = true; 

how can custom request validation here?

like if want send promo code while cognito signup can have code validate promo code , reject registration request if invalid promocode.

you can setup triggers customize userpool workflow: http://docs.aws.amazon.com/cognito/latest/developerguide/cognito-user-identity-pools-working-with-aws-lambda-triggers.html

in case, setting pre sign-up trigger should fine.


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -