Modifies an IP address whitelist of a PolarDB-X instance.

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 ModifySecurityIps

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

RegionId String Yes cn-hangzhou

The region ID of the instance.

DBInstanceName String Yes pxc-hzjasd****

The ID of the instance.

GroupName String Yes default

The name of the IP address whitelist.

SecurityIPList String Yes 127.0.0.1,192.168.0.0

The IP addresses and CIDR blocks that you want to specify in the new IP address whitelist. Separate multiple IP address settings with commas (,).

ModifyMode String Yes 1

The method that is used to modify the IP address whitelist. Valid values:

  • 0: overwrites the original IP address whitelist with the new IP address whitelist.
  • 1: creates an IP address whitelist.
  • 2: deletes the original IP address whitelist.

Response parameters

Parameter Type Example Description
Message String success

The information returned for the request. If "success" is returned, the request is successful. If an error code is returned, the request failed.

RequestId String FEA5DC20-6D8A-5979-97AA-FC57546ADC20

The ID of the request.

Success Boolean true

Indicates whether the request is successful.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ModifySecurityIps
&RegionId=cn-hangzhou
&DBInstanceName=pxc-hzjasd****
&GroupName=default
&SecurityIPList=127.0.0.1,192.168.0.0
&ModifyMode=1
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<ModifySecurityIpsResponse>
    <Message>success</Message>
    <RequestId>FEA5DC20-6D8A-5979-97AA-FC57546ADC20</RequestId>
    <Success>true</Success>
</ModifySecurityIpsResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "Message" : "success",
  "RequestId" : "FEA5DC20-6D8A-5979-97AA-FC57546ADC20",
  "Success" : true
}

Error codes

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