interface CustomAttributeConfig
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.Cognito.CustomAttributeConfig |
Java | software.amazon.awscdk.services.cognito.CustomAttributeConfig |
Python | aws_cdk.aws_cognito.CustomAttributeConfig |
TypeScript (source) | @aws-cdk/aws-cognito » CustomAttributeConfig |
Obtainable from
Boolean
.bind()
, Date
.bind()
, Number
.bind()
, String
.bind()
Configuration that will be fed into CloudFormation for any custom attribute type.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cognito from '@aws-cdk/aws-cognito';
const customAttributeConfig: cognito.CustomAttributeConfig = {
dataType: 'dataType',
// the properties below are optional
mutable: false,
numberConstraints: {
max: 123,
min: 123,
},
stringConstraints: {
maxLen: 123,
minLen: 123,
},
};
Properties
Name | Type | Description |
---|---|---|
data | string | The data type of the custom attribute. |
mutable? | boolean | Specifies whether the value of the attribute can be changed. |
number | Number | The constraints for a custom attribute of the 'Number' data type. |
string | String | The constraints for a custom attribute of 'String' data type. |
dataType
Type:
string
The data type of the custom attribute.
mutable?
Type:
boolean
(optional, default: false)
Specifies whether the value of the attribute can be changed.
For any user pool attribute that's mapped to an identity provider attribute, you must set this parameter to true. Amazon Cognito updates mapped attributes when users sign in to your application through an identity provider. If an attribute is immutable, Amazon Cognito throws an error when it attempts to update the attribute.
numberConstraints?
Type:
Number
(optional, default: None.)
The constraints for a custom attribute of the 'Number' data type.
stringConstraints?
Type:
String
(optional, default: None.)
The constraints for a custom attribute of 'String' data type.