AWS/Cognito when creating a user pool through CDK, how can I set string length for standard attributes.
I tried to find it but had no luck like there is none for that. I am using Typescript.
My user pool looks like this:
const userPool = new cognito.UserPool(this, `name-of-user-pool-${stage}`, {
signInAliases: {
email: true,
username: false,
},
standardAttributes: {
fullname: { required: true, mutable: true },
},
passwordPolicy: {
minLength: 8,
requireDigits: true,
requireLowercase: true,
requireUppercase: true,
requireSymbols: true,
},
selfSignUpEnabled: true,
userVerification: {
emailSubject: 'Verify your email !',
emailBody: 'Thank you for signing up to our app! Your verification code is {####}',
emailStyle: cognito.VerificationEmailStyle.CODE,
},
accountRecovery: cognito.AccountRecovery.EMAIL_ONLY,
});