Username parameter, you can use the username or user alias. The method used to send the confirmation code is sent according to the specified AccountRecoverySetting. For more information, see Recovering User Accounts in the Amazon Cognito Developer Guide. If neither a verified phone number nor a verified email exists, an InvalidParameterException is thrown. To use the confirmation code for resetting the password, call ConfirmForgotPassword. curl --location --request POST '/' \
--header 'X-Amz-Target;' \
--header 'Content-Type: application/json' \
--data-raw '{
"ClientId": "string",
"SecretHash": "string",
"UserContextData": {
"IpAddress": "string",
"EncodedData": "string"
},
"Username": "string",
"AnalyticsMetadata": {},
"ClientMetadata": {
"property1": "string",
"property2": "string"
}
}'{
"CodeDeliveryDetails": {
"Destination": "string",
"DeliveryMedium": "SMS",
"AttributeName": "string"
}
}