We recommend new projects start with resources from the AWS provider.
aws-native.cognito.UserPoolUser
Explore with Pulumi AI
We recommend new projects start with resources from the AWS provider.
Resource Type definition for AWS::Cognito::UserPoolUser
Create UserPoolUser Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new UserPoolUser(name: string, args: UserPoolUserArgs, opts?: CustomResourceOptions);@overload
def UserPoolUser(resource_name: str,
                 args: UserPoolUserArgs,
                 opts: Optional[ResourceOptions] = None)
@overload
def UserPoolUser(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 user_pool_id: Optional[str] = None,
                 client_metadata: Optional[Mapping[str, str]] = None,
                 desired_delivery_mediums: Optional[Sequence[str]] = None,
                 force_alias_creation: Optional[bool] = None,
                 message_action: Optional[str] = None,
                 user_attributes: Optional[Sequence[UserPoolUserAttributeTypeArgs]] = None,
                 username: Optional[str] = None,
                 validation_data: Optional[Sequence[UserPoolUserAttributeTypeArgs]] = None)func NewUserPoolUser(ctx *Context, name string, args UserPoolUserArgs, opts ...ResourceOption) (*UserPoolUser, error)public UserPoolUser(string name, UserPoolUserArgs args, CustomResourceOptions? opts = null)
public UserPoolUser(String name, UserPoolUserArgs args)
public UserPoolUser(String name, UserPoolUserArgs args, CustomResourceOptions options)
type: aws-native:cognito:UserPoolUser
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args UserPoolUserArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args UserPoolUserArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args UserPoolUserArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args UserPoolUserArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args UserPoolUserArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
UserPoolUser Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The UserPoolUser resource accepts the following input properties:
- UserPool stringId 
- The ID of the user pool where you want to create a user.
- ClientMetadata Dictionary<string, string>
- A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers. - You create custom workflows by assigning AWS Lambda functions to user pool triggers. When you use the AdminCreateUser API action, Amazon Cognito invokes the function that is assigned to the pre sign-up trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a - ClientMetadataattribute, which provides the data that you assigned to the ClientMetadata parameter in your AdminCreateUser request. In your function code in AWS Lambda , you can process the- clientMetadatavalue to enhance your workflow for your specific needs.- For more information, see Using Lambda triggers in the Amazon Cognito Developer Guide . - When you use the - ClientMetadataparameter, note that Amazon Cognito won't do the following:- Store the ClientMetadatavalue. This data is available only to AWS Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, theClientMetadataparameter serves no purpose.
- Validate the ClientMetadatavalue.
- Encrypt the ClientMetadatavalue. Don't send sensitive information in this parameter.
 
- Store the 
- DesiredDelivery List<string>Mediums 
- Specify EMAILif email will be used to send the welcome message. SpecifySMSif the phone number will be used. The default value isSMS. You can specify more than one value.
- ForceAlias boolCreation 
- This parameter is used only if the - phone_number_verifiedor- email_verifiedattribute is set to- True. Otherwise, it is ignored.- If this parameter is set to - Trueand the phone number or email address specified in the- UserAttributesparameter already exists as an alias with a different user, this request migrates the alias from the previous user to the newly-created user. The previous user will no longer be able to log in using that alias.- If this parameter is set to - False, the API throws an- AliasExistsExceptionerror if the alias already exists. The default value is- False.
- MessageAction string
- Set to RESENDto resend the invitation message to a user that already exists, and to reset the temporary-password duration with a new temporary password. Set toSUPPRESSto suppress sending the message. You can specify only one value.
- UserAttributes List<Pulumi.Aws Native. Cognito. Inputs. User Pool User Attribute Type> 
- An array of name-value pairs that contain user attributes and attribute values to be set for the user to be created. You can create a user without specifying any attributes other than - Username. However, any attributes that you specify as required (when creating a user pool or in the Attributes tab of the console) either you should supply (in your call to- AdminCreateUser) or the user should supply (when they sign up in response to your welcome message).- For custom attributes, you must prepend the - custom:prefix to the attribute name.- To send a message inviting the user to sign up, you must specify the user's email address or phone number. You can do this in your call to AdminCreateUser or in the Users tab of the Amazon Cognito console for managing your user pools. - You must also provide an email address or phone number when you expect the user to do passwordless sign-in with an email or SMS OTP. These attributes must be provided when passwordless options are the only available, or when you don't submit a - TemporaryPassword.- In your call to - AdminCreateUser, you can set the- email_verifiedattribute to- True, and you can set the- phone_number_verifiedattribute to- True.- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the email_verifiedattribute is set toTrue, or if"EMAIL"is specified in theDesiredDeliveryMediumsparameter.
- phone_number : The phone number of the user to whom the message that contains the code and username will be sent. Required if the phone_number_verifiedattribute is set toTrue, or if"SMS"is specified in theDesiredDeliveryMediumsparameter.
 
- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the 
- Username string
- The value that you want to set as the username sign-in attribute. The following conditions apply to the username parameter.- The username can't be a duplicate of another username in the same user pool.
- You can't change the value of a username after you create it.
- You can only provide a value if usernames are a valid sign-in attribute for your user pool. If your user pool only supports phone numbers or email addresses as sign-in attributes, Amazon Cognito automatically generates a username value. For more information, see Customizing sign-in attributes .
 
- ValidationData List<Pulumi.Aws Native. Cognito. Inputs. User Pool User Attribute Type> 
- Temporary user attributes that contribute to the outcomes of your pre sign-up Lambda trigger. This set of key-value pairs are for custom validation of information that you collect from your users but don't need to retain. - Your Lambda function can analyze this additional data and act on it. Your function can automatically confirm and verify select users or perform external API operations like logging user attributes and validation data to Amazon CloudWatch Logs. - For more information about the pre sign-up Lambda trigger, see Pre sign-up Lambda trigger . 
- UserPool stringId 
- The ID of the user pool where you want to create a user.
- ClientMetadata map[string]string
- A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers. - You create custom workflows by assigning AWS Lambda functions to user pool triggers. When you use the AdminCreateUser API action, Amazon Cognito invokes the function that is assigned to the pre sign-up trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a - ClientMetadataattribute, which provides the data that you assigned to the ClientMetadata parameter in your AdminCreateUser request. In your function code in AWS Lambda , you can process the- clientMetadatavalue to enhance your workflow for your specific needs.- For more information, see Using Lambda triggers in the Amazon Cognito Developer Guide . - When you use the - ClientMetadataparameter, note that Amazon Cognito won't do the following:- Store the ClientMetadatavalue. This data is available only to AWS Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, theClientMetadataparameter serves no purpose.
- Validate the ClientMetadatavalue.
- Encrypt the ClientMetadatavalue. Don't send sensitive information in this parameter.
 
- Store the 
- DesiredDelivery []stringMediums 
- Specify EMAILif email will be used to send the welcome message. SpecifySMSif the phone number will be used. The default value isSMS. You can specify more than one value.
- ForceAlias boolCreation 
- This parameter is used only if the - phone_number_verifiedor- email_verifiedattribute is set to- True. Otherwise, it is ignored.- If this parameter is set to - Trueand the phone number or email address specified in the- UserAttributesparameter already exists as an alias with a different user, this request migrates the alias from the previous user to the newly-created user. The previous user will no longer be able to log in using that alias.- If this parameter is set to - False, the API throws an- AliasExistsExceptionerror if the alias already exists. The default value is- False.
- MessageAction string
- Set to RESENDto resend the invitation message to a user that already exists, and to reset the temporary-password duration with a new temporary password. Set toSUPPRESSto suppress sending the message. You can specify only one value.
- UserAttributes []UserPool User Attribute Type Args 
- An array of name-value pairs that contain user attributes and attribute values to be set for the user to be created. You can create a user without specifying any attributes other than - Username. However, any attributes that you specify as required (when creating a user pool or in the Attributes tab of the console) either you should supply (in your call to- AdminCreateUser) or the user should supply (when they sign up in response to your welcome message).- For custom attributes, you must prepend the - custom:prefix to the attribute name.- To send a message inviting the user to sign up, you must specify the user's email address or phone number. You can do this in your call to AdminCreateUser or in the Users tab of the Amazon Cognito console for managing your user pools. - You must also provide an email address or phone number when you expect the user to do passwordless sign-in with an email or SMS OTP. These attributes must be provided when passwordless options are the only available, or when you don't submit a - TemporaryPassword.- In your call to - AdminCreateUser, you can set the- email_verifiedattribute to- True, and you can set the- phone_number_verifiedattribute to- True.- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the email_verifiedattribute is set toTrue, or if"EMAIL"is specified in theDesiredDeliveryMediumsparameter.
- phone_number : The phone number of the user to whom the message that contains the code and username will be sent. Required if the phone_number_verifiedattribute is set toTrue, or if"SMS"is specified in theDesiredDeliveryMediumsparameter.
 
- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the 
- Username string
- The value that you want to set as the username sign-in attribute. The following conditions apply to the username parameter.- The username can't be a duplicate of another username in the same user pool.
- You can't change the value of a username after you create it.
- You can only provide a value if usernames are a valid sign-in attribute for your user pool. If your user pool only supports phone numbers or email addresses as sign-in attributes, Amazon Cognito automatically generates a username value. For more information, see Customizing sign-in attributes .
 
- ValidationData []UserPool User Attribute Type Args 
- Temporary user attributes that contribute to the outcomes of your pre sign-up Lambda trigger. This set of key-value pairs are for custom validation of information that you collect from your users but don't need to retain. - Your Lambda function can analyze this additional data and act on it. Your function can automatically confirm and verify select users or perform external API operations like logging user attributes and validation data to Amazon CloudWatch Logs. - For more information about the pre sign-up Lambda trigger, see Pre sign-up Lambda trigger . 
- userPool StringId 
- The ID of the user pool where you want to create a user.
- clientMetadata Map<String,String>
- A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers. - You create custom workflows by assigning AWS Lambda functions to user pool triggers. When you use the AdminCreateUser API action, Amazon Cognito invokes the function that is assigned to the pre sign-up trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a - ClientMetadataattribute, which provides the data that you assigned to the ClientMetadata parameter in your AdminCreateUser request. In your function code in AWS Lambda , you can process the- clientMetadatavalue to enhance your workflow for your specific needs.- For more information, see Using Lambda triggers in the Amazon Cognito Developer Guide . - When you use the - ClientMetadataparameter, note that Amazon Cognito won't do the following:- Store the ClientMetadatavalue. This data is available only to AWS Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, theClientMetadataparameter serves no purpose.
- Validate the ClientMetadatavalue.
- Encrypt the ClientMetadatavalue. Don't send sensitive information in this parameter.
 
- Store the 
- desiredDelivery List<String>Mediums 
- Specify EMAILif email will be used to send the welcome message. SpecifySMSif the phone number will be used. The default value isSMS. You can specify more than one value.
- forceAlias BooleanCreation 
- This parameter is used only if the - phone_number_verifiedor- email_verifiedattribute is set to- True. Otherwise, it is ignored.- If this parameter is set to - Trueand the phone number or email address specified in the- UserAttributesparameter already exists as an alias with a different user, this request migrates the alias from the previous user to the newly-created user. The previous user will no longer be able to log in using that alias.- If this parameter is set to - False, the API throws an- AliasExistsExceptionerror if the alias already exists. The default value is- False.
- messageAction String
- Set to RESENDto resend the invitation message to a user that already exists, and to reset the temporary-password duration with a new temporary password. Set toSUPPRESSto suppress sending the message. You can specify only one value.
- userAttributes List<UserPool User Attribute Type> 
- An array of name-value pairs that contain user attributes and attribute values to be set for the user to be created. You can create a user without specifying any attributes other than - Username. However, any attributes that you specify as required (when creating a user pool or in the Attributes tab of the console) either you should supply (in your call to- AdminCreateUser) or the user should supply (when they sign up in response to your welcome message).- For custom attributes, you must prepend the - custom:prefix to the attribute name.- To send a message inviting the user to sign up, you must specify the user's email address or phone number. You can do this in your call to AdminCreateUser or in the Users tab of the Amazon Cognito console for managing your user pools. - You must also provide an email address or phone number when you expect the user to do passwordless sign-in with an email or SMS OTP. These attributes must be provided when passwordless options are the only available, or when you don't submit a - TemporaryPassword.- In your call to - AdminCreateUser, you can set the- email_verifiedattribute to- True, and you can set the- phone_number_verifiedattribute to- True.- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the email_verifiedattribute is set toTrue, or if"EMAIL"is specified in theDesiredDeliveryMediumsparameter.
- phone_number : The phone number of the user to whom the message that contains the code and username will be sent. Required if the phone_number_verifiedattribute is set toTrue, or if"SMS"is specified in theDesiredDeliveryMediumsparameter.
 
- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the 
- username String
- The value that you want to set as the username sign-in attribute. The following conditions apply to the username parameter.- The username can't be a duplicate of another username in the same user pool.
- You can't change the value of a username after you create it.
- You can only provide a value if usernames are a valid sign-in attribute for your user pool. If your user pool only supports phone numbers or email addresses as sign-in attributes, Amazon Cognito automatically generates a username value. For more information, see Customizing sign-in attributes .
 
- validationData List<UserPool User Attribute Type> 
- Temporary user attributes that contribute to the outcomes of your pre sign-up Lambda trigger. This set of key-value pairs are for custom validation of information that you collect from your users but don't need to retain. - Your Lambda function can analyze this additional data and act on it. Your function can automatically confirm and verify select users or perform external API operations like logging user attributes and validation data to Amazon CloudWatch Logs. - For more information about the pre sign-up Lambda trigger, see Pre sign-up Lambda trigger . 
- userPool stringId 
- The ID of the user pool where you want to create a user.
- clientMetadata {[key: string]: string}
- A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers. - You create custom workflows by assigning AWS Lambda functions to user pool triggers. When you use the AdminCreateUser API action, Amazon Cognito invokes the function that is assigned to the pre sign-up trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a - ClientMetadataattribute, which provides the data that you assigned to the ClientMetadata parameter in your AdminCreateUser request. In your function code in AWS Lambda , you can process the- clientMetadatavalue to enhance your workflow for your specific needs.- For more information, see Using Lambda triggers in the Amazon Cognito Developer Guide . - When you use the - ClientMetadataparameter, note that Amazon Cognito won't do the following:- Store the ClientMetadatavalue. This data is available only to AWS Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, theClientMetadataparameter serves no purpose.
- Validate the ClientMetadatavalue.
- Encrypt the ClientMetadatavalue. Don't send sensitive information in this parameter.
 
- Store the 
- desiredDelivery string[]Mediums 
- Specify EMAILif email will be used to send the welcome message. SpecifySMSif the phone number will be used. The default value isSMS. You can specify more than one value.
- forceAlias booleanCreation 
- This parameter is used only if the - phone_number_verifiedor- email_verifiedattribute is set to- True. Otherwise, it is ignored.- If this parameter is set to - Trueand the phone number or email address specified in the- UserAttributesparameter already exists as an alias with a different user, this request migrates the alias from the previous user to the newly-created user. The previous user will no longer be able to log in using that alias.- If this parameter is set to - False, the API throws an- AliasExistsExceptionerror if the alias already exists. The default value is- False.
- messageAction string
- Set to RESENDto resend the invitation message to a user that already exists, and to reset the temporary-password duration with a new temporary password. Set toSUPPRESSto suppress sending the message. You can specify only one value.
- userAttributes UserPool User Attribute Type[] 
- An array of name-value pairs that contain user attributes and attribute values to be set for the user to be created. You can create a user without specifying any attributes other than - Username. However, any attributes that you specify as required (when creating a user pool or in the Attributes tab of the console) either you should supply (in your call to- AdminCreateUser) or the user should supply (when they sign up in response to your welcome message).- For custom attributes, you must prepend the - custom:prefix to the attribute name.- To send a message inviting the user to sign up, you must specify the user's email address or phone number. You can do this in your call to AdminCreateUser or in the Users tab of the Amazon Cognito console for managing your user pools. - You must also provide an email address or phone number when you expect the user to do passwordless sign-in with an email or SMS OTP. These attributes must be provided when passwordless options are the only available, or when you don't submit a - TemporaryPassword.- In your call to - AdminCreateUser, you can set the- email_verifiedattribute to- True, and you can set the- phone_number_verifiedattribute to- True.- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the email_verifiedattribute is set toTrue, or if"EMAIL"is specified in theDesiredDeliveryMediumsparameter.
- phone_number : The phone number of the user to whom the message that contains the code and username will be sent. Required if the phone_number_verifiedattribute is set toTrue, or if"SMS"is specified in theDesiredDeliveryMediumsparameter.
 
- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the 
- username string
- The value that you want to set as the username sign-in attribute. The following conditions apply to the username parameter.- The username can't be a duplicate of another username in the same user pool.
- You can't change the value of a username after you create it.
- You can only provide a value if usernames are a valid sign-in attribute for your user pool. If your user pool only supports phone numbers or email addresses as sign-in attributes, Amazon Cognito automatically generates a username value. For more information, see Customizing sign-in attributes .
 
- validationData UserPool User Attribute Type[] 
- Temporary user attributes that contribute to the outcomes of your pre sign-up Lambda trigger. This set of key-value pairs are for custom validation of information that you collect from your users but don't need to retain. - Your Lambda function can analyze this additional data and act on it. Your function can automatically confirm and verify select users or perform external API operations like logging user attributes and validation data to Amazon CloudWatch Logs. - For more information about the pre sign-up Lambda trigger, see Pre sign-up Lambda trigger . 
- user_pool_ strid 
- The ID of the user pool where you want to create a user.
- client_metadata Mapping[str, str]
- A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers. - You create custom workflows by assigning AWS Lambda functions to user pool triggers. When you use the AdminCreateUser API action, Amazon Cognito invokes the function that is assigned to the pre sign-up trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a - ClientMetadataattribute, which provides the data that you assigned to the ClientMetadata parameter in your AdminCreateUser request. In your function code in AWS Lambda , you can process the- clientMetadatavalue to enhance your workflow for your specific needs.- For more information, see Using Lambda triggers in the Amazon Cognito Developer Guide . - When you use the - ClientMetadataparameter, note that Amazon Cognito won't do the following:- Store the ClientMetadatavalue. This data is available only to AWS Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, theClientMetadataparameter serves no purpose.
- Validate the ClientMetadatavalue.
- Encrypt the ClientMetadatavalue. Don't send sensitive information in this parameter.
 
- Store the 
- desired_delivery_ Sequence[str]mediums 
- Specify EMAILif email will be used to send the welcome message. SpecifySMSif the phone number will be used. The default value isSMS. You can specify more than one value.
- force_alias_ boolcreation 
- This parameter is used only if the - phone_number_verifiedor- email_verifiedattribute is set to- True. Otherwise, it is ignored.- If this parameter is set to - Trueand the phone number or email address specified in the- UserAttributesparameter already exists as an alias with a different user, this request migrates the alias from the previous user to the newly-created user. The previous user will no longer be able to log in using that alias.- If this parameter is set to - False, the API throws an- AliasExistsExceptionerror if the alias already exists. The default value is- False.
- message_action str
- Set to RESENDto resend the invitation message to a user that already exists, and to reset the temporary-password duration with a new temporary password. Set toSUPPRESSto suppress sending the message. You can specify only one value.
- user_attributes Sequence[UserPool User Attribute Type Args] 
- An array of name-value pairs that contain user attributes and attribute values to be set for the user to be created. You can create a user without specifying any attributes other than - Username. However, any attributes that you specify as required (when creating a user pool or in the Attributes tab of the console) either you should supply (in your call to- AdminCreateUser) or the user should supply (when they sign up in response to your welcome message).- For custom attributes, you must prepend the - custom:prefix to the attribute name.- To send a message inviting the user to sign up, you must specify the user's email address or phone number. You can do this in your call to AdminCreateUser or in the Users tab of the Amazon Cognito console for managing your user pools. - You must also provide an email address or phone number when you expect the user to do passwordless sign-in with an email or SMS OTP. These attributes must be provided when passwordless options are the only available, or when you don't submit a - TemporaryPassword.- In your call to - AdminCreateUser, you can set the- email_verifiedattribute to- True, and you can set the- phone_number_verifiedattribute to- True.- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the email_verifiedattribute is set toTrue, or if"EMAIL"is specified in theDesiredDeliveryMediumsparameter.
- phone_number : The phone number of the user to whom the message that contains the code and username will be sent. Required if the phone_number_verifiedattribute is set toTrue, or if"SMS"is specified in theDesiredDeliveryMediumsparameter.
 
- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the 
- username str
- The value that you want to set as the username sign-in attribute. The following conditions apply to the username parameter.- The username can't be a duplicate of another username in the same user pool.
- You can't change the value of a username after you create it.
- You can only provide a value if usernames are a valid sign-in attribute for your user pool. If your user pool only supports phone numbers or email addresses as sign-in attributes, Amazon Cognito automatically generates a username value. For more information, see Customizing sign-in attributes .
 
- validation_data Sequence[UserPool User Attribute Type Args] 
- Temporary user attributes that contribute to the outcomes of your pre sign-up Lambda trigger. This set of key-value pairs are for custom validation of information that you collect from your users but don't need to retain. - Your Lambda function can analyze this additional data and act on it. Your function can automatically confirm and verify select users or perform external API operations like logging user attributes and validation data to Amazon CloudWatch Logs. - For more information about the pre sign-up Lambda trigger, see Pre sign-up Lambda trigger . 
- userPool StringId 
- The ID of the user pool where you want to create a user.
- clientMetadata Map<String>
- A map of custom key-value pairs that you can provide as input for any custom workflows that this action triggers. - You create custom workflows by assigning AWS Lambda functions to user pool triggers. When you use the AdminCreateUser API action, Amazon Cognito invokes the function that is assigned to the pre sign-up trigger. When Amazon Cognito invokes this function, it passes a JSON payload, which the function receives as input. This payload contains a - ClientMetadataattribute, which provides the data that you assigned to the ClientMetadata parameter in your AdminCreateUser request. In your function code in AWS Lambda , you can process the- clientMetadatavalue to enhance your workflow for your specific needs.- For more information, see Using Lambda triggers in the Amazon Cognito Developer Guide . - When you use the - ClientMetadataparameter, note that Amazon Cognito won't do the following:- Store the ClientMetadatavalue. This data is available only to AWS Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, theClientMetadataparameter serves no purpose.
- Validate the ClientMetadatavalue.
- Encrypt the ClientMetadatavalue. Don't send sensitive information in this parameter.
 
- Store the 
- desiredDelivery List<String>Mediums 
- Specify EMAILif email will be used to send the welcome message. SpecifySMSif the phone number will be used. The default value isSMS. You can specify more than one value.
- forceAlias BooleanCreation 
- This parameter is used only if the - phone_number_verifiedor- email_verifiedattribute is set to- True. Otherwise, it is ignored.- If this parameter is set to - Trueand the phone number or email address specified in the- UserAttributesparameter already exists as an alias with a different user, this request migrates the alias from the previous user to the newly-created user. The previous user will no longer be able to log in using that alias.- If this parameter is set to - False, the API throws an- AliasExistsExceptionerror if the alias already exists. The default value is- False.
- messageAction String
- Set to RESENDto resend the invitation message to a user that already exists, and to reset the temporary-password duration with a new temporary password. Set toSUPPRESSto suppress sending the message. You can specify only one value.
- userAttributes List<Property Map>
- An array of name-value pairs that contain user attributes and attribute values to be set for the user to be created. You can create a user without specifying any attributes other than - Username. However, any attributes that you specify as required (when creating a user pool or in the Attributes tab of the console) either you should supply (in your call to- AdminCreateUser) or the user should supply (when they sign up in response to your welcome message).- For custom attributes, you must prepend the - custom:prefix to the attribute name.- To send a message inviting the user to sign up, you must specify the user's email address or phone number. You can do this in your call to AdminCreateUser or in the Users tab of the Amazon Cognito console for managing your user pools. - You must also provide an email address or phone number when you expect the user to do passwordless sign-in with an email or SMS OTP. These attributes must be provided when passwordless options are the only available, or when you don't submit a - TemporaryPassword.- In your call to - AdminCreateUser, you can set the- email_verifiedattribute to- True, and you can set the- phone_number_verifiedattribute to- True.- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the email_verifiedattribute is set toTrue, or if"EMAIL"is specified in theDesiredDeliveryMediumsparameter.
- phone_number : The phone number of the user to whom the message that contains the code and username will be sent. Required if the phone_number_verifiedattribute is set toTrue, or if"SMS"is specified in theDesiredDeliveryMediumsparameter.
 
- email : The email address of the user to whom the message that contains the code and username will be sent. Required if the 
- username String
- The value that you want to set as the username sign-in attribute. The following conditions apply to the username parameter.- The username can't be a duplicate of another username in the same user pool.
- You can't change the value of a username after you create it.
- You can only provide a value if usernames are a valid sign-in attribute for your user pool. If your user pool only supports phone numbers or email addresses as sign-in attributes, Amazon Cognito automatically generates a username value. For more information, see Customizing sign-in attributes .
 
- validationData List<Property Map>
- Temporary user attributes that contribute to the outcomes of your pre sign-up Lambda trigger. This set of key-value pairs are for custom validation of information that you collect from your users but don't need to retain. - Your Lambda function can analyze this additional data and act on it. Your function can automatically confirm and verify select users or perform external API operations like logging user attributes and validation data to Amazon CloudWatch Logs. - For more information about the pre sign-up Lambda trigger, see Pre sign-up Lambda trigger . 
Outputs
All input properties are implicitly available as output properties. Additionally, the UserPoolUser resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Supporting Types
UserPoolUserAttributeType, UserPoolUserAttributeTypeArgs          
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.