Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Updates the specified user pool with the specified attributes. You can get a list of the current user pool settings using DescribeUserPool. If you don't provide a value for an attribute, it will be set to the default value.
This action might generate an SMS text message. Starting June 1, 2021, US telecom carriers require you to register an origination phone number before you can send SMS messages to US phone numbers. If you use SMS text messages in Amazon Cognito, you must register a phone number with Amazon Pinpoint. Amazon Cognito uses the registered number automatically. Otherwise, Amazon Cognito users who must receive SMS messages might not be able to sign up, activate their accounts, or sign in.
If you have never used SMS text messages with Amazon Cognito or any other Amazon Web Service, Amazon Simple Notification Service might place your account in the SMS sandbox. In <https:docs.aws.amazon.comsnslatestdgsns-sms-sandbox.html sandbox mode> , you can send messages only to verified phone numbers. After you test your app while in the sandbox environment, you can move out of the sandbox and into production. For more information, see SMS message settings for Amazon Cognito user pools in the Amazon Cognito Developer Guide.
Synopsis
- data UpdateUserPool = UpdateUserPool' {
- accountRecoverySetting :: Maybe AccountRecoverySettingType
- adminCreateUserConfig :: Maybe AdminCreateUserConfigType
- autoVerifiedAttributes :: Maybe [VerifiedAttributeType]
- deletionProtection :: Maybe DeletionProtectionType
- deviceConfiguration :: Maybe DeviceConfigurationType
- emailConfiguration :: Maybe EmailConfigurationType
- emailVerificationMessage :: Maybe Text
- emailVerificationSubject :: Maybe Text
- lambdaConfig :: Maybe LambdaConfigType
- mfaConfiguration :: Maybe UserPoolMfaType
- policies :: Maybe UserPoolPolicyType
- smsAuthenticationMessage :: Maybe Text
- smsConfiguration :: Maybe SmsConfigurationType
- smsVerificationMessage :: Maybe Text
- userAttributeUpdateSettings :: Maybe UserAttributeUpdateSettingsType
- userPoolAddOns :: Maybe UserPoolAddOnsType
- userPoolTags :: Maybe (HashMap Text Text)
- verificationMessageTemplate :: Maybe VerificationMessageTemplateType
- userPoolId :: Text
- newUpdateUserPool :: Text -> UpdateUserPool
- updateUserPool_accountRecoverySetting :: Lens' UpdateUserPool (Maybe AccountRecoverySettingType)
- updateUserPool_adminCreateUserConfig :: Lens' UpdateUserPool (Maybe AdminCreateUserConfigType)
- updateUserPool_autoVerifiedAttributes :: Lens' UpdateUserPool (Maybe [VerifiedAttributeType])
- updateUserPool_deletionProtection :: Lens' UpdateUserPool (Maybe DeletionProtectionType)
- updateUserPool_deviceConfiguration :: Lens' UpdateUserPool (Maybe DeviceConfigurationType)
- updateUserPool_emailConfiguration :: Lens' UpdateUserPool (Maybe EmailConfigurationType)
- updateUserPool_emailVerificationMessage :: Lens' UpdateUserPool (Maybe Text)
- updateUserPool_emailVerificationSubject :: Lens' UpdateUserPool (Maybe Text)
- updateUserPool_lambdaConfig :: Lens' UpdateUserPool (Maybe LambdaConfigType)
- updateUserPool_mfaConfiguration :: Lens' UpdateUserPool (Maybe UserPoolMfaType)
- updateUserPool_policies :: Lens' UpdateUserPool (Maybe UserPoolPolicyType)
- updateUserPool_smsAuthenticationMessage :: Lens' UpdateUserPool (Maybe Text)
- updateUserPool_smsConfiguration :: Lens' UpdateUserPool (Maybe SmsConfigurationType)
- updateUserPool_smsVerificationMessage :: Lens' UpdateUserPool (Maybe Text)
- updateUserPool_userAttributeUpdateSettings :: Lens' UpdateUserPool (Maybe UserAttributeUpdateSettingsType)
- updateUserPool_userPoolAddOns :: Lens' UpdateUserPool (Maybe UserPoolAddOnsType)
- updateUserPool_userPoolTags :: Lens' UpdateUserPool (Maybe (HashMap Text Text))
- updateUserPool_verificationMessageTemplate :: Lens' UpdateUserPool (Maybe VerificationMessageTemplateType)
- updateUserPool_userPoolId :: Lens' UpdateUserPool Text
- data UpdateUserPoolResponse = UpdateUserPoolResponse' {
- httpStatus :: Int
- newUpdateUserPoolResponse :: Int -> UpdateUserPoolResponse
- updateUserPoolResponse_httpStatus :: Lens' UpdateUserPoolResponse Int
Creating a Request
data UpdateUserPool Source #
Represents the request to update the user pool.
See: newUpdateUserPool
smart constructor.
UpdateUserPool' | |
|
Instances
Create a value of UpdateUserPool
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
UpdateUserPool
, updateUserPool_accountRecoverySetting
- The available verified method a user can use to recover their password
when they call ForgotPassword
. You can use this setting to define a
preferred method when a user has more than one method available. With
this setting, SMS doesn't qualify for a valid password recovery
mechanism if the user also has SMS multi-factor authentication (MFA)
activated. In the absence of this setting, Amazon Cognito uses the
legacy behavior to determine the recovery method where SMS is preferred
through email.
UpdateUserPool
, updateUserPool_adminCreateUserConfig
- The configuration for AdminCreateUser
requests.
UpdateUserPool
, updateUserPool_autoVerifiedAttributes
- The attributes that are automatically verified when Amazon Cognito
requests to update user pools.
UpdateUserPool
, updateUserPool_deletionProtection
- When active, DeletionProtection
prevents accidental deletion of your
user pool. Before you can delete a user pool that you have protected
against deletion, you must deactivate this feature.
When you try to delete a protected user pool in a DeleteUserPool
API
request, Amazon Cognito returns an InvalidParameterException
error. To
delete a protected user pool, send a new DeleteUserPool
request after
you deactivate deletion protection in an UpdateUserPool
API request.
UpdateUserPool
, updateUserPool_deviceConfiguration
- The device-remembering configuration for a user pool. A null value
indicates that you have deactivated device remembering in your user
pool.
When you provide a value for any DeviceConfiguration
field, you
activate the Amazon Cognito device-remembering feature.
UpdateUserPool
, updateUserPool_emailConfiguration
- The email configuration of your user pool. The email configuration type
sets your preferred sending method, Amazon Web Services Region, and
sender for email invitation and verification messages from your user
pool.
UpdateUserPool
, updateUserPool_emailVerificationMessage
- This parameter is no longer used. See
VerificationMessageTemplateType.
UpdateUserPool
, updateUserPool_emailVerificationSubject
- This parameter is no longer used. See
VerificationMessageTemplateType.
UpdateUserPool
, updateUserPool_lambdaConfig
- The Lambda configuration information from the request to update the user
pool.
UpdateUserPool
, updateUserPool_mfaConfiguration
- Possible values include:
OFF
- MFA tokens aren't required and can't be specified during user registration.ON
- MFA tokens are required for all user registrations. You can only specify ON when you're initially creating a user pool. You can use the SetUserPoolMfaConfig API operation to turn MFA "ON" for existing user pools.OPTIONAL
- Users have the option when registering to create an MFA token.
UpdateUserPool
, updateUserPool_policies
- A container with the policies you want to update in a user pool.
UpdateUserPool
, updateUserPool_smsAuthenticationMessage
- The contents of the SMS authentication message.
UpdateUserPool
, updateUserPool_smsConfiguration
- The SMS configuration with the settings that your Amazon Cognito user
pool must use to send an SMS message from your Amazon Web Services
account through Amazon Simple Notification Service. To send SMS messages
with Amazon SNS in the Amazon Web Services Region that you want, the
Amazon Cognito user pool uses an Identity and Access Management (IAM)
role in your Amazon Web Services account.
UpdateUserPool
, updateUserPool_smsVerificationMessage
- This parameter is no longer used. See
VerificationMessageTemplateType.
UpdateUserPool
, updateUserPool_userAttributeUpdateSettings
- The settings for updates to user attributes. These settings include the
property AttributesRequireVerificationBeforeUpdate
, a user-pool
setting that tells Amazon Cognito how to handle changes to the value of
your users' email address and phone number attributes. For more
information, see
Verifying updates to email addresses and phone numbers.
UpdateUserPool
, updateUserPool_userPoolAddOns
- Enables advanced security risk detection. Set the key
AdvancedSecurityMode
to the value "AUDIT".
UpdateUserPool
, updateUserPool_userPoolTags
- The tag keys and values to assign to the user pool. A tag is a label
that you can use to categorize and manage user pools in different ways,
such as by purpose, owner, environment, or other criteria.
UpdateUserPool
, updateUserPool_verificationMessageTemplate
- The template for verification messages.
UpdateUserPool
, updateUserPool_userPoolId
- The user pool ID for the user pool you want to update.
Request Lenses
updateUserPool_accountRecoverySetting :: Lens' UpdateUserPool (Maybe AccountRecoverySettingType) Source #
The available verified method a user can use to recover their password
when they call ForgotPassword
. You can use this setting to define a
preferred method when a user has more than one method available. With
this setting, SMS doesn't qualify for a valid password recovery
mechanism if the user also has SMS multi-factor authentication (MFA)
activated. In the absence of this setting, Amazon Cognito uses the
legacy behavior to determine the recovery method where SMS is preferred
through email.
updateUserPool_adminCreateUserConfig :: Lens' UpdateUserPool (Maybe AdminCreateUserConfigType) Source #
The configuration for AdminCreateUser
requests.
updateUserPool_autoVerifiedAttributes :: Lens' UpdateUserPool (Maybe [VerifiedAttributeType]) Source #
The attributes that are automatically verified when Amazon Cognito requests to update user pools.
updateUserPool_deletionProtection :: Lens' UpdateUserPool (Maybe DeletionProtectionType) Source #
When active, DeletionProtection
prevents accidental deletion of your
user pool. Before you can delete a user pool that you have protected
against deletion, you must deactivate this feature.
When you try to delete a protected user pool in a DeleteUserPool
API
request, Amazon Cognito returns an InvalidParameterException
error. To
delete a protected user pool, send a new DeleteUserPool
request after
you deactivate deletion protection in an UpdateUserPool
API request.
updateUserPool_deviceConfiguration :: Lens' UpdateUserPool (Maybe DeviceConfigurationType) Source #
The device-remembering configuration for a user pool. A null value indicates that you have deactivated device remembering in your user pool.
When you provide a value for any DeviceConfiguration
field, you
activate the Amazon Cognito device-remembering feature.
updateUserPool_emailConfiguration :: Lens' UpdateUserPool (Maybe EmailConfigurationType) Source #
The email configuration of your user pool. The email configuration type sets your preferred sending method, Amazon Web Services Region, and sender for email invitation and verification messages from your user pool.
updateUserPool_emailVerificationMessage :: Lens' UpdateUserPool (Maybe Text) Source #
This parameter is no longer used. See VerificationMessageTemplateType.
updateUserPool_emailVerificationSubject :: Lens' UpdateUserPool (Maybe Text) Source #
This parameter is no longer used. See VerificationMessageTemplateType.
updateUserPool_lambdaConfig :: Lens' UpdateUserPool (Maybe LambdaConfigType) Source #
The Lambda configuration information from the request to update the user pool.
updateUserPool_mfaConfiguration :: Lens' UpdateUserPool (Maybe UserPoolMfaType) Source #
Possible values include:
OFF
- MFA tokens aren't required and can't be specified during user registration.ON
- MFA tokens are required for all user registrations. You can only specify ON when you're initially creating a user pool. You can use the SetUserPoolMfaConfig API operation to turn MFA "ON" for existing user pools.OPTIONAL
- Users have the option when registering to create an MFA token.
updateUserPool_policies :: Lens' UpdateUserPool (Maybe UserPoolPolicyType) Source #
A container with the policies you want to update in a user pool.
updateUserPool_smsAuthenticationMessage :: Lens' UpdateUserPool (Maybe Text) Source #
The contents of the SMS authentication message.
updateUserPool_smsConfiguration :: Lens' UpdateUserPool (Maybe SmsConfigurationType) Source #
The SMS configuration with the settings that your Amazon Cognito user pool must use to send an SMS message from your Amazon Web Services account through Amazon Simple Notification Service. To send SMS messages with Amazon SNS in the Amazon Web Services Region that you want, the Amazon Cognito user pool uses an Identity and Access Management (IAM) role in your Amazon Web Services account.
updateUserPool_smsVerificationMessage :: Lens' UpdateUserPool (Maybe Text) Source #
This parameter is no longer used. See VerificationMessageTemplateType.
updateUserPool_userAttributeUpdateSettings :: Lens' UpdateUserPool (Maybe UserAttributeUpdateSettingsType) Source #
The settings for updates to user attributes. These settings include the
property AttributesRequireVerificationBeforeUpdate
, a user-pool
setting that tells Amazon Cognito how to handle changes to the value of
your users' email address and phone number attributes. For more
information, see
Verifying updates to email addresses and phone numbers.
updateUserPool_userPoolAddOns :: Lens' UpdateUserPool (Maybe UserPoolAddOnsType) Source #
Enables advanced security risk detection. Set the key
AdvancedSecurityMode
to the value "AUDIT".
updateUserPool_userPoolTags :: Lens' UpdateUserPool (Maybe (HashMap Text Text)) Source #
The tag keys and values to assign to the user pool. A tag is a label that you can use to categorize and manage user pools in different ways, such as by purpose, owner, environment, or other criteria.
updateUserPool_verificationMessageTemplate :: Lens' UpdateUserPool (Maybe VerificationMessageTemplateType) Source #
The template for verification messages.
updateUserPool_userPoolId :: Lens' UpdateUserPool Text Source #
The user pool ID for the user pool you want to update.
Destructuring the Response
data UpdateUserPoolResponse Source #
Represents the response from the server when you make a request to update the user pool.
See: newUpdateUserPoolResponse
smart constructor.
UpdateUserPoolResponse' | |
|
Instances
newUpdateUserPoolResponse Source #
Create a value of UpdateUserPoolResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:httpStatus:UpdateUserPoolResponse'
, updateUserPoolResponse_httpStatus
- The response's http status code.
Response Lenses
updateUserPoolResponse_httpStatus :: Lens' UpdateUserPoolResponse Int Source #
The response's http status code.