Initiate a forgotten password request
This document is automatically generated based on https://github.com/authing/authing-docs-factory based on the https://api-explorer.genauth.ai V3 API, and is consistent with the API parameters and return results. If the document description is incorrect, please refer to the V3 API.
When the user forgets the password, the password can be retrieved through this endpoint. The user needs to use relevant verification methods for verification. Currently, Email verification code and Mobile phone number verification code are supported.
Method name
AuthenticationClient.verify_reset_password_request
Request parameters
| Name | Type | Required | Default value | Description | Sample value |
|---|---|---|---|---|---|
| verifyMethod | string | Yes | - | Verification method used for forgotten password request: - EMAIL_PASSCODE: Verification by email verification code- PHONE_PASSCODE: Verification by phone number verification code | EMAIL_PASSCODE |
| phonePassCodePayload | <a ResetPasswordByPhonePassCodeDto | No | - | Data verified by phone number verification code | |
| emailPassCodePayload | <a ResetPasswordByEmailPassCodeDto | No | - | Data verified by email verification code |
Request response
Type: PasswordResetVerifyResp
| Name | Type | Description |
|---|---|---|
| statusCode | number | Business status code, which can be used to determine whether the operation is successful, 200 means success. |
| message | string | Description |
| apiCode | number | Segmented error code, which can be used to get the specific error type (not returned for successful requests). For a detailed list of error codes, see: API Code List |
| requestId | string | Request ID. Returned when the request fails. |
| data | <a ResetPasswordVerify | Response data |
Sample result:
json
{
"statusCode": 200,
"message": "Operation successful",
"requestId": "934108e5-9fbf-4d24-8da1-c330328abd6c",
"data": {}
}Data structure
ResetPasswordByPhonePassCodeDto
| Name | Type | Is it required? | Description | Sample value |
|---|---|---|---|---|
| phoneNumber | string | Yes | The phone number bound to this account, without the area code. If it is a foreign phone number, please specify the area code in the phoneCountryCode parameter. | 188xxxx8888 |
| passCode | string | Yes | SMS verification code. An SMS verification code can only be used once and is valid for one minute. You need to obtain it through the Send SMS interface. | 123456 |
| phoneCountryCode | string | No | Mobile phone area code. This field is optional for mainland China mobile phone numbers. The GenAuth SMS service does not yet support international mobile phone numbers. You need to configure the corresponding international SMS service in the GenAuth console. For a complete list of mobile phone area codes, please refer to https://en.wikipedia.org/wiki/List_of_country_calling_codes. | +86 |
ResetPasswordByEmailPassCodeDto
| Name | Type | Is it required? | Description | Sample value |
|---|---|---|---|---|
| string | No | The email address bound to this account, not case sensitive. | ||
| passCode | string | Yes | Email verification code. An SMS verification code can only be used once, and the default validity period is 5 minutes. You need to obtain it through the Send Email interface. |
ResetPasswordVerify
| Name | Type | Is it required? | Description | Sample value |
|---|---|---|---|---|
| passwordResetToken | string | Yes | Token used to reset password | |
| tokenExpiresIn | number | Yes | Expiration time, in seconds. |