public class ChangePasswordRequest
extends com.amazonaws.AmazonWebServiceRequest
implements java.io.Serializable
Changes the password for a specified user in a user pool.
Amazon Cognito doesn't evaluate Identity and Access Management (IAM) policies in requests for this API operation. For this operation, you can't use IAM credentials to authorize requests, and you can't grant IAM permissions in policies. For more information about authorization models in Amazon Cognito, see Using the Amazon Cognito native and OIDC APIs.
| Constructor and Description |
|---|
ChangePasswordRequest() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getAccessToken()
A valid access token that Amazon Cognito issued to the user whose
password you want to change.
|
java.lang.String |
getPreviousPassword()
The old password.
|
java.lang.String |
getProposedPassword()
The new password.
|
int |
hashCode() |
void |
setAccessToken(java.lang.String accessToken)
A valid access token that Amazon Cognito issued to the user whose
password you want to change.
|
void |
setPreviousPassword(java.lang.String previousPassword)
The old password.
|
void |
setProposedPassword(java.lang.String proposedPassword)
The new password.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
ChangePasswordRequest |
withAccessToken(java.lang.String accessToken)
A valid access token that Amazon Cognito issued to the user whose
password you want to change.
|
ChangePasswordRequest |
withPreviousPassword(java.lang.String previousPassword)
The old password.
|
ChangePasswordRequest |
withProposedPassword(java.lang.String proposedPassword)
The new password.
|
clone, copyBaseTo, getCloneRoot, getCloneSource, getGeneralProgressListener, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, withGeneralProgressListener, withRequestMetricCollectorpublic java.lang.String getPreviousPassword()
The old password.
Constraints:
Length: - 256
Pattern: [\S]+
The old password.
public void setPreviousPassword(java.lang.String previousPassword)
The old password.
Constraints:
Length: - 256
Pattern: [\S]+
previousPassword - The old password.
public ChangePasswordRequest withPreviousPassword(java.lang.String previousPassword)
The old password.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 256
Pattern: [\S]+
previousPassword - The old password.
public java.lang.String getProposedPassword()
The new password.
Constraints:
Length: - 256
Pattern: [\S]+
The new password.
public void setProposedPassword(java.lang.String proposedPassword)
The new password.
Constraints:
Length: - 256
Pattern: [\S]+
proposedPassword - The new password.
public ChangePasswordRequest withProposedPassword(java.lang.String proposedPassword)
The new password.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: - 256
Pattern: [\S]+
proposedPassword - The new password.
public java.lang.String getAccessToken()
A valid access token that Amazon Cognito issued to the user whose password you want to change.
Constraints:
Pattern: [A-Za-z0-9-_=.]+
A valid access token that Amazon Cognito issued to the user whose password you want to change.
public void setAccessToken(java.lang.String accessToken)
A valid access token that Amazon Cognito issued to the user whose password you want to change.
Constraints:
Pattern: [A-Za-z0-9-_=.]+
accessToken - A valid access token that Amazon Cognito issued to the user whose password you want to change.
public ChangePasswordRequest withAccessToken(java.lang.String accessToken)
A valid access token that Amazon Cognito issued to the user whose password you want to change.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Pattern: [A-Za-z0-9-_=.]+
accessToken - A valid access token that Amazon Cognito issued to the user whose password you want to change.
public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Object