-
Notifications
You must be signed in to change notification settings - Fork 4.5k
aws-cognito: UserPoolIdentityProviderOidc does not support email_verified as attributeMapping #30467
Description
Describe the bug
Hi all,
I'm configuring a custom OpenId provide on my cognito user pool. I'd like to auto_verified emails since the openId provider give me this information.
I noticed that in the AWS console I can map the email_verified field on a field that my OpenId provided provides to me but looks like that the email_verified field is not expose as a property of the construct UserPoolIdentityProviderOidc under attributeMapping key.
I expect to use this code:
new cognito.UserPoolIdentityProviderOidc(this, 'custom',{
name: '...',
userPool: this.userPool,
clientId: '...',
attributeMapping: {
email: cognito.ProviderAttribute.other('email'),
email_verified: cognito.ProviderAttribute.other('email_verified'),
}
)
Expected Behavior
I expect that using this field the email is automatically verified at the signup time
Current Behavior
Actually this field is not available as property of the object attributeMapping
Reproduction Steps
Using this code:
new cognito.UserPoolIdentityProviderOidc(this, 'custom',{
name: '...',
userPool: this.userPool,
clientId: '...',
attributeMapping: {
email: cognito.ProviderAttribute.other('email'),
email_verified: cognito.ProviderAttribute.other('email_verified'),
}
)
Typescript notifies that email_verified is not a know property.
Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.1628.0
Framework Version
No response
Node.js Version
18.18.2
OS
MacOs 14.5
Language
TypeScript
Language Version
No response
Other information
No response