You can call this opeation to modify an IP address whitelist of an AnalyticDB for MySQL cluster.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ModifyDBClusterAccessWhiteList

The operation that you want to perform. Set the value to

ModifyDbClusterAccessWhiteList.

DBClusterId String Yes rm-uf6wjk5xxxxxxxxxx

The ID of the cluster.

SecurityIps String Yes 10.23.12.24

The IP addresses in an IP address whitelist of a cluster. Separate multiple IP addresses with commas (,). You can add a maximum of 500 different IP addresses to a whitelist. The following formats are supported:

  • IP addresses. Example: 10.23.12.24.
  • CIDR blocks. Example: 10.23.12.24/24. 24 indicates that the prefix of the CIDR block is 24-bit long. You can replace 24 with a value within the range of 1 to 32.

This parameter must be specified unless the ModifyMode parameter is set to Delete.

DBClusterIPArrayName String No test

The name of the IP address whitelist to be modified. Default value: Default.

The name of an IP address whitelist must be 2 to 32 characters in length. The name must contain lowercase letters, digits, and underscores (_). The name must start with a lowercase letter and end with a digit or lowercase letter.

You can create up to 50 whitelists for a cluster.

DBClusterIPArrayAttribute String No hidden

The attribute of the whitelist. This parameter is empty by default.

The IP address whitelists that have the hidden attribute are not displayed in the AnalyticDB for MySQL console. These IP address whitelists are used to access Alibaba Cloud services such as Data Transmission Service (DTS) and PolarDB-X.

ModifyMode String No Cover

The method used to modify the whitelist. Valid values:

  • Cover: overwrites the original IP address whitelist.
  • Append: adds one or more IP addresses.
  • Delete: deletes one or more IP addresses.

Default value: Cover.

Response parameters

Parameter Type Example Description
DBClusterId String rm-uf6wjk5xxxxxxxxxx

The ID of the cluster.

RequestId String D0CEC6AC-7760-409A-A0D5-E6CD8660E9CC

The ID of the request.

TaskId Integer 1564657730

The ID of the task.

Examples

Sample requests

http(s)://[Endpoint]/? Action=ModifyDBClusterAccessWhiteList
&DBClusterId=rm-uf6wjk5xxxxxxxxxx
&SecurityIps=10.23.12.24
&<Common request parameters>

Sample responses

XML format

<TaskId>1564657730</TaskId>
<RequestId>D0CEC6AC-7760-409A-A0D5-E6CD8660E9CC</RequestId>
<DBClusterId>rm-uf6wjk5xxxxxxxxxx</DBClusterId>

JSON format

{
    "TaskId": 1564657730,
    "RequestId": "D0CEC6AC-7760-409A-A0D5-E6CD8660E9CC",
    "DBClusterId": "rm-uf6wjk5xxxxxxxxxx"
}

Error codes

HttpCode Error code Error message Description
404 InvalidDBCluster.NotFound The DBClusterId provided does not exist in our records. The error message returned because the specified cluster ID does not exist. Check whether you specify the cluster ID value correctly.

For a list of error codes, visit the API Error Center.