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 |
Allows a user to enter a confirmation code to reset a forgotten password.
Synopsis
- data ConfirmForgotPassword = ConfirmForgotPassword' {}
- newConfirmForgotPassword :: Text -> Text -> Text -> Text -> ConfirmForgotPassword
- confirmForgotPassword_analyticsMetadata :: Lens' ConfirmForgotPassword (Maybe AnalyticsMetadataType)
- confirmForgotPassword_clientMetadata :: Lens' ConfirmForgotPassword (Maybe (HashMap Text Text))
- confirmForgotPassword_secretHash :: Lens' ConfirmForgotPassword (Maybe Text)
- confirmForgotPassword_userContextData :: Lens' ConfirmForgotPassword (Maybe UserContextDataType)
- confirmForgotPassword_clientId :: Lens' ConfirmForgotPassword Text
- confirmForgotPassword_username :: Lens' ConfirmForgotPassword Text
- confirmForgotPassword_confirmationCode :: Lens' ConfirmForgotPassword Text
- confirmForgotPassword_password :: Lens' ConfirmForgotPassword Text
- data ConfirmForgotPasswordResponse = ConfirmForgotPasswordResponse' {
- httpStatus :: Int
- newConfirmForgotPasswordResponse :: Int -> ConfirmForgotPasswordResponse
- confirmForgotPasswordResponse_httpStatus :: Lens' ConfirmForgotPasswordResponse Int
Creating a Request
data ConfirmForgotPassword Source #
The request representing the confirmation for a password reset.
See: newConfirmForgotPassword
smart constructor.
ConfirmForgotPassword' | |
|
Instances
newConfirmForgotPassword Source #
:: Text | |
-> Text | |
-> Text | |
-> Text | |
-> ConfirmForgotPassword |
Create a value of ConfirmForgotPassword
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:analyticsMetadata:ConfirmForgotPassword'
, confirmForgotPassword_analyticsMetadata
- The Amazon Pinpoint analytics metadata for collecting metrics for
ConfirmForgotPassword
calls.
$sel:clientMetadata:ConfirmForgotPassword'
, confirmForgotPassword_clientMetadata
- 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 Lambda functions to user pool
triggers. When you use the ConfirmForgotPassword API action, Amazon
Cognito invokes the function that is assigned to the post confirmation
trigger. When Amazon Cognito invokes this function, it passes a JSON
payload, which the function receives as input. This payload contains a
clientMetadata
attribute, which provides the data that you assigned to
the ClientMetadata parameter in your ConfirmForgotPassword request. In
your function code in Lambda, you can process the clientMetadata
value
to enhance your workflow for your specific needs.
For more information, see Customizing user pool Workflows with Lambda Triggers in the Amazon Cognito Developer Guide.
When you use the ClientMetadata parameter, remember that Amazon Cognito won't do the following:
- Store the ClientMetadata value. This data is available only to Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, the ClientMetadata parameter serves no purpose.
- Validate the ClientMetadata value.
- Encrypt the ClientMetadata value. Don't use Amazon Cognito to provide sensitive information.
$sel:secretHash:ConfirmForgotPassword'
, confirmForgotPassword_secretHash
- A keyed-hash message authentication code (HMAC) calculated using the
secret key of a user pool client and username plus the client ID in the
message.
$sel:userContextData:ConfirmForgotPassword'
, confirmForgotPassword_userContextData
- Contextual data about your user session, such as the device fingerprint,
IP address, or location. Amazon Cognito advanced security evaluates the
risk of an authentication event based on the context that your app
generates and passes to Amazon Cognito when it makes API requests.
ConfirmForgotPassword
, confirmForgotPassword_clientId
- The app client ID of the app associated with the user pool.
ConfirmForgotPassword
, confirmForgotPassword_username
- The user name of the user for whom you want to enter a code to retrieve
a forgotten password.
$sel:confirmationCode:ConfirmForgotPassword'
, confirmForgotPassword_confirmationCode
- The confirmation code from your user's request to reset their password.
For more information, see
ForgotPassword.
$sel:password:ConfirmForgotPassword'
, confirmForgotPassword_password
- The new password that your user wants to set.
Request Lenses
confirmForgotPassword_analyticsMetadata :: Lens' ConfirmForgotPassword (Maybe AnalyticsMetadataType) Source #
The Amazon Pinpoint analytics metadata for collecting metrics for
ConfirmForgotPassword
calls.
confirmForgotPassword_clientMetadata :: Lens' ConfirmForgotPassword (Maybe (HashMap Text Text)) Source #
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 Lambda functions to user pool
triggers. When you use the ConfirmForgotPassword API action, Amazon
Cognito invokes the function that is assigned to the post confirmation
trigger. When Amazon Cognito invokes this function, it passes a JSON
payload, which the function receives as input. This payload contains a
clientMetadata
attribute, which provides the data that you assigned to
the ClientMetadata parameter in your ConfirmForgotPassword request. In
your function code in Lambda, you can process the clientMetadata
value
to enhance your workflow for your specific needs.
For more information, see Customizing user pool Workflows with Lambda Triggers in the Amazon Cognito Developer Guide.
When you use the ClientMetadata parameter, remember that Amazon Cognito won't do the following:
- Store the ClientMetadata value. This data is available only to Lambda triggers that are assigned to a user pool to support custom workflows. If your user pool configuration doesn't include triggers, the ClientMetadata parameter serves no purpose.
- Validate the ClientMetadata value.
- Encrypt the ClientMetadata value. Don't use Amazon Cognito to provide sensitive information.
confirmForgotPassword_secretHash :: Lens' ConfirmForgotPassword (Maybe Text) Source #
A keyed-hash message authentication code (HMAC) calculated using the secret key of a user pool client and username plus the client ID in the message.
confirmForgotPassword_userContextData :: Lens' ConfirmForgotPassword (Maybe UserContextDataType) Source #
Contextual data about your user session, such as the device fingerprint, IP address, or location. Amazon Cognito advanced security evaluates the risk of an authentication event based on the context that your app generates and passes to Amazon Cognito when it makes API requests.
confirmForgotPassword_clientId :: Lens' ConfirmForgotPassword Text Source #
The app client ID of the app associated with the user pool.
confirmForgotPassword_username :: Lens' ConfirmForgotPassword Text Source #
The user name of the user for whom you want to enter a code to retrieve a forgotten password.
confirmForgotPassword_confirmationCode :: Lens' ConfirmForgotPassword Text Source #
The confirmation code from your user's request to reset their password. For more information, see ForgotPassword.
confirmForgotPassword_password :: Lens' ConfirmForgotPassword Text Source #
The new password that your user wants to set.
Destructuring the Response
data ConfirmForgotPasswordResponse Source #
The response from the server that results from a user's request to retrieve a forgotten password.
See: newConfirmForgotPasswordResponse
smart constructor.
ConfirmForgotPasswordResponse' | |
|
Instances
Generic ConfirmForgotPasswordResponse Source # | |
Read ConfirmForgotPasswordResponse Source # | |
Show ConfirmForgotPasswordResponse Source # | |
NFData ConfirmForgotPasswordResponse Source # | |
Defined in Amazonka.CognitoIdentityProvider.ConfirmForgotPassword rnf :: ConfirmForgotPasswordResponse -> () # | |
Eq ConfirmForgotPasswordResponse Source # | |
type Rep ConfirmForgotPasswordResponse Source # | |
Defined in Amazonka.CognitoIdentityProvider.ConfirmForgotPassword type Rep ConfirmForgotPasswordResponse = D1 ('MetaData "ConfirmForgotPasswordResponse" "Amazonka.CognitoIdentityProvider.ConfirmForgotPassword" "amazonka-cognito-idp-2.0-D1ERgMvEVPG9z8cOLXdU2" 'False) (C1 ('MetaCons "ConfirmForgotPasswordResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))) |
newConfirmForgotPasswordResponse Source #
Create a value of ConfirmForgotPasswordResponse
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:ConfirmForgotPasswordResponse'
, confirmForgotPasswordResponse_httpStatus
- The response's http status code.
Response Lenses
confirmForgotPasswordResponse_httpStatus :: Lens' ConfirmForgotPasswordResponse Int Source #
The response's http status code.