Domain name for API request: cdb.intl.tencentcloudapi.com.
This API is used to modify the password complexity of a cloud database instance.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: ModifyInstancePasswordComplexity. |
| Version | Yes | String | Common Params. The value used for this API: 2017-03-20. |
| Region | Yes | String | Common Params. For more information, please see the list of regions supported by the product. |
| InstanceIds.N | Yes | Array of String | Instance ID of the instance for which the password complexity needs to be modified. The DescribeDBInstances API can be called to obtain it. Description: Support multiple instance IDs for modification. |
| ParamList.N | No | Array of Parameter | Options to modify password complexity. Each option is written in metric combinations. A group includes Name and CurrentValue. Among them, Name refers to the parameter name of the corresponding option, and CurrentValue represents the parameter value. For example: [{"Name": "validate_password.length", "CurrentValue": "10"}] means changing the minimum number of characters in a password to 10. Description: The options for modifying password complexity vary by database version of instances as follows. 1. MySQL 8.0: The option validate_password.policy means the switch for password complexity. A value of LOW means disabling; a value of MEDIUM means enabling. The option validate_password.length indicates the minimum number of characters for the total code length. The option validate_password.mixed_case_count indicates the minimum number of lowercase and uppercase letters. Option validate_password.number_count indicates the minimum number of digits. The option validate_password.special_char_count indicates the minimum number of special characters. 2. MySQL 5.6,MySQL 5.7: The option validate_password_policy means the password complexity switch. A value of LOW means disabling; a value of MEDIUM means enabling. The option validate_password_length indicates the minimum number of characters for the total code length. The option validate_password_mixed_case_count means the minimum number of uppercase and lowercase letters. Option validate_password_number_count means the minimum number of digits. Option validate_password_special_char_count indicates the minimum number of special characters. |
| Parameter Name | Type | Description |
|---|---|---|
| AsyncRequestId | String | Async task ID, which can be used to query task progress. |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
POST / HTTP/1.1
Host: cdb.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: ModifyInstancePasswordComplexity
<Common request parameters>
{
"InstanceIds": [
"cdb-93hvf1d"
],
"ParamList": [
{
"Name": "validate_password.length",
"CurrentValue": "10"
}
]
}
{
"Response": {
"AsyncRequestId": "988d3e5b-4cc7bac7-b92977cf-274603c0",
"RequestId": "11fa4b07-11b0-4c48-a472-2d835d9bf165"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| AuthFailure | CAM signature/authentication error. |
| AuthFailure.SubAccountDenied | The sub-account has no permissions. |
| CdbError | Backend or process error. |
| InternalError.DBOperationError | Database operation failed. |
| InternalError.InternalHttpServerError | An exception occurred while executing the request. |
| InternalError.InternalServiceErrorErr | An error occurred while accessing internal service. |
| InternalError.UndefinedError | Unknown error |
| InternalError.UnknownError | Unknown error |
| InvalidParameter | Parameter error. |
| InvalidParameter.ExceptionParam | Parameter exception. |
| InvalidParameter.InstanceNotFound | The instance does not exist. |
| InvalidParameterValue.DataConvertError | Data conversion failed. |
| InvalidParameterValue.InvalidParameterValueError | Invalid parameter value |
| OperationDenied | Operation denied. |
| ResourceNotFound.CdbInstanceNotFoundError | The instance cannot be found. Please check whether your instance status is normal. |
| ResourceNotFound.InstanceNotFundError | The instance does not exist. |
| UnsupportedOperation | Unsupported operation. |
フィードバック