Skip to content
v2.274.0

StandardAttributes Struct ​

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

Example ​

ts
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 ​

addressoptionalStandardAttributeaddressoptionalStandardAttributeaddressoptionalStandardAttributeAddressoptionalStandardAttributeAddressoptionalStandardAttribute#
The user's postal address.

Default: see the defaults under StandardAttribute

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

Default: see the defaults under StandardAttribute

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

Default: see the defaults under StandardAttribute

familyNameoptionalStandardAttributefamily_nameoptionalStandardAttributefamilyNameoptionalStandardAttributeFamilyNameoptionalStandardAttributeFamilyNameoptionalStandardAttribute#
The surname or last name of the user.

Default: see the defaults under StandardAttribute

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

Default: see the defaults under StandardAttribute

genderoptionalStandardAttributegenderoptionalStandardAttributegenderoptionalStandardAttributeGenderoptionalStandardAttributeGenderoptionalStandardAttribute#
The user's gender.

Default: see the defaults under StandardAttribute

givenNameoptionalStandardAttributegiven_nameoptionalStandardAttributegivenNameoptionalStandardAttributeGivenNameoptionalStandardAttributeGivenNameoptionalStandardAttribute#
The user's first name or give name.

Default: see the defaults under StandardAttribute

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

Default: see the defaults under StandardAttribute

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

Default: see the defaults under StandardAttribute

middleNameoptionalStandardAttributemiddle_nameoptionalStandardAttributemiddleNameoptionalStandardAttributeMiddleNameoptionalStandardAttributeMiddleNameoptionalStandardAttribute#
The user's middle name.

Default: see the defaults under StandardAttribute

nicknameoptionalStandardAttributenicknameoptionalStandardAttributenicknameoptionalStandardAttributeNicknameoptionalStandardAttributeNicknameoptionalStandardAttribute#
The user's nickname or casual name.

Default: see the defaults under StandardAttribute

phoneNumberoptionalStandardAttributephone_numberoptionalStandardAttributephoneNumberoptionalStandardAttributePhoneNumberoptionalStandardAttributePhoneNumberoptionalStandardAttribute#
The user's telephone number.

Default: see the defaults under StandardAttribute

preferredUsernameoptionalStandardAttributepreferred_usernameoptionalStandardAttributepreferredUsernameoptionalStandardAttributePreferredUsernameoptionalStandardAttributePreferredUsernameoptionalStandardAttribute#
The user's preferred username, different from the immutable user name.

Default: see the defaults under StandardAttribute

profilePageoptionalStandardAttributeprofile_pageoptionalStandardAttributeprofilePageoptionalStandardAttributeProfilePageoptionalStandardAttributeProfilePageoptionalStandardAttribute#
The URL to the user's profile page.

Default: see the defaults under StandardAttribute

profilePictureoptionalStandardAttributeprofile_pictureoptionalStandardAttributeprofilePictureoptionalStandardAttributeProfilePictureoptionalStandardAttributeProfilePictureoptionalStandardAttribute#
The URL to the user's profile picture.

Default: see the defaults under StandardAttribute

timezoneoptionalStandardAttributetimezoneoptionalStandardAttributetimezoneoptionalStandardAttributeTimezoneoptionalStandardAttributeTimezoneoptionalStandardAttribute#
The user's time zone.

Default: see the defaults under StandardAttribute

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

Default: see the defaults under StandardAttribute