Open fredleger opened 4 years ago
Having the same issue. I created exact same 2 pools and was not able to import users all users together. It is working only per one user.
I was able to fix the error UnhandledPromiseRejectionWarning: InvalidParameterException: No email provided but desired delivery medium was Email
by commenting that part.
instead of
} else if (UsernameAttributes.includes('phone_number')) { params.Username = pluckValue(user.Attributes, 'phone_number') as string; params.DesiredDeliveryMediums = ['EMAIL', 'SMS'] }
i changed to
} else if (UsernameAttributes.includes('phone_number')) { params.Username = pluckValue(user.Attributes, 'phone_number') as string; params.DesiredDeliveryMediums = ['SMS'] }
Then run with npm start
where we can run cbr cli commands
NOTE: THIS WILL SEND SMS TO ALL THOSE USERS IMPORTED. TO AVOID THIS YOU CAN SET SNS SPEND LIMIT AS $1 OR $0, SO THAT IT CANT SEND SMS.
Hope it helps
When restoring a users pool got the following error:
Both pools configured exactly the same with terraform creation.
Actually it seems doing the job one by one user and issue the error right after restoring it. It would be nice to have at least a "continue on error" option if some users are buggy