aws-cdk-lib.aws_cognito.StandardAttributes

interface StandardAttributes

LanguageType name
.NETAmazon.CDK.AWS.Cognito.StandardAttributes
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awscognito#StandardAttributes
Javasoftware.amazon.awscdk.services.cognito.StandardAttributes
Pythonaws_cdk.aws_cognito.StandardAttributes
TypeScript (source)aws-cdk-lib » aws_cognito » StandardAttributes

The set of standard attributes that can be marked as required or mutable.

See also: https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#cognito-user-pools-standard-attributes

Example

new cognito.UserPool(this, 'myuserpool', {
  // ...
  standardAttributes: {
    fullname: {
      required: true,
      mutable: false,
    },
    address: {
      required: false,
      mutable: true,
    },
  },
  customAttributes: {
    'myappid': new cognito.StringAttribute({ minLen: 5, maxLen: 15, mutable: false }),
    'callingcode': new cognito.NumberAttribute({ min: 1, max: 3, mutable: true }),
    'isEmployee': new cognito.BooleanAttribute({ mutable: true }),
    'joinedOn': new cognito.DateTimeAttribute(),
  },
});

Properties

NameTypeDescription
address?StandardAttributeThe user's postal address.
birthdate?StandardAttributeThe user's birthday, represented as an ISO 8601:2004 format.
email?StandardAttributeThe user's e-mail address, represented as an RFC 5322 [RFC5322] addr-spec.
familyName?StandardAttributeThe surname or last name of the user.
fullname?StandardAttributeThe user's full name in displayable form, including all name parts, titles and suffixes.
gender?StandardAttributeThe user's gender.
givenName?StandardAttributeThe user's first name or give name.
lastUpdateTime?StandardAttributeThe time, the user's information was last updated.
locale?StandardAttributeThe user's locale, represented as a BCP47 [RFC5646] language tag.
middleName?StandardAttributeThe user's middle name.
nickname?StandardAttributeThe user's nickname or casual name.
phoneNumber?StandardAttributeThe user's telephone number.
preferredUsername?StandardAttributeThe user's preffered username, different from the immutable user name.
profilePage?StandardAttributeThe URL to the user's profile page.
profilePicture?StandardAttributeThe URL to the user's profile picture.
timezone?StandardAttributeThe user's time zone.
website?StandardAttributeThe URL to the user's web page or blog.

address?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's postal address.


birthdate?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's birthday, represented as an ISO 8601:2004 format.


email?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's e-mail address, represented as an RFC 5322 [RFC5322] addr-spec.


familyName?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The surname or last name of the user.


fullname?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's full name in displayable form, including all name parts, titles and suffixes.


gender?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's gender.


givenName?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's first name or give name.


lastUpdateTime?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The time, the user's information was last updated.


locale?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's locale, represented as a BCP47 [RFC5646] language tag.


middleName?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's middle name.


nickname?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's nickname or casual name.


phoneNumber?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's telephone number.


preferredUsername?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's preffered username, different from the immutable user name.


profilePage?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The URL to the user's profile page.


profilePicture?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The URL to the user's profile picture.


timezone?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The user's time zone.


website?

Type: StandardAttribute (optional, default: see the defaults under StandardAttribute)

The URL to the user's web page or blog.