Employee Identity (EIAM)
Verify Original Password When Changing User Password
API
# Permissions
The Identity Management API is authorized at the application dimension. Before calling the interface, you need to set interface permissions for different applications. For details, please refer to API Permissions.
| Permission Code | Description |
|---|---|
| user_all | Read and write permissions for user management interfaces |
| all | Read and write permissions for all interfaces |
# Request Description
PUT https://{your_domain}/api/v2/tenant/users/{user_id}/change-password-verify
# Request Headers
| Parameter Name | Chinese Name | Required | Type | Description |
|---|---|---|---|---|
| Authorization | Authorization | Yes | String | Format: Bearer {access_token} |
| Content-Type | Content Type | Yes | String | Fixed value: application/json; charset=utf-8 |
# Request Example
{
"password":"P@ssw0rd123456",
"old_password":"P@ssw0rd12345"
}
1
2
3
4
2
3
4
# Request Parameters
| Parameter Name | Chinese Name | Required | Type | Description |
|---|---|---|---|---|
| user_id | User ID | Yes | String | Target User ID |
| password | New Password | Yes | String | |
| old_password | Original Password | Yes | String |
# Response Example
Success Example:
HTTP/1.1 200 OK
{
"user_id": "20201028102749564-9082-DC8CD2722"
}
Error Example:
{
"error_msg": "User does not exist",
"error_code": "USER.0001"
}
1
2
3
4
5
6
7
8
9
10
11
2
3
4
5
6
7
8
9
10
11
# Response Parameters
| Parameter Name | Chinese Name | Type | Description |
|---|---|---|---|
| user_id | User ID | String |
# Error Codes
| Status Code | Error Code | Error Message | Handling Measures |
|---|---|---|---|
| 400 | USER.0001 | User does not exist | Please check if the corresponding user exists |
| User does not exist | |||
| 400 | PWD.0001 | Password cannot be empty | Please check if the password field in the input parameters is empty |
| Password cannot be empty | |||
| 400 | PWD.0002 | Password length is {0}~{1} characters | Please check if the password length meets the validation rules |
| Password length is {0}~{1} characters | |||
| 400 | PWD.0003 | Password cannot match username | Please check if the password matches the username |
| Password cannot match username | |||
| 400 | PWD.0004 | Password does not allow reverse writing of username | Please check if the password uses the reverse writing of the username |
| Password does not allow reverse writing of username | |||
| 400 | PWD.0005 | The password does not meet the verification rules, {0} | Please enhance the complexity of the password according to the password policy, or check if the password contains unsupported characters |
| The password does not meet the verification rules, {0} | |||
| 400 | PWD.0006 | The password is weak | The password is weak, please change to another password |
| The password is weak | |||
| 400 | PWD.0007 | History passwords are not allowed | The password is a previously used historical password, please change it |
| History passwords are not allowed | |||
| 400 | PWD.0008 | Maximum number of characters to repeat in password cannot exceed {0} | Please check if the maximum number of character repetitions in the password exceeds {0} |
| Maximum number of characters to repeat in password cannot exceed {0} | |||
| 400 | PWD.0009 | Passwords are not allowed to include: username, mobile phone number, email prefix, name pinyin | Please check if the password contains: username, mobile phone number, email prefix, name pinyin |
| Passwords are not allowed to include: username, mobile phone number, email prefix, name pinyin | |||
| 400 | PWD.0011 | The original password cannot be empty | Please check if the original password field in the input parameters is empty |
| The original password cannot be empty | |||
| 400 | PWD.0014 | The old password is incorrect | Please check if the entered old password is correct |
| The old password is incorrect |
Please provide the Markdown content you need translated.
