You can call the AddListenerWhiteListItem API to add IP addresses or CIDR blocks to a listener whitelist.


Perform a debug in OpenAPI Explorer. We recommend that you use OpenAPI Explorer. By using OpenAPI Explorer, you can call APIs, generate SDK code examples automatically, and search APIs, allowing you to quickly and easily get started with using APIs on the cloud.

Request parameters

Name Type Required? Example value Description
Action String Yes AddListenerWhiteListItem

The action to perform. Valid value: AddListenerWhiteListItem

ListenerPort Integer Yes 80

The frontend port used by the SLB instance

LoadBalancerId String Yes 139a00604ad-cn-east-hangzhou-01

The ID of the SLB instance

RegionId String Yes cn-hangzhou

The ID of the region to which the SLB instance belongs

SourceItems String Yes,

Access control list.

This parameter takes effect when AccessControlStatus of the listener is set to open_white_list.

Both IP addresses and IP address segments (namely, CIDR blocks) are supported. Use commas (,) to separate multiple IP addresses or CIDR blocks. or is not allowed. You can call the SetListenerAccessControlStatus API to set AccessControlStatus to close to disable access control.

Response parameters

Name Type Example value Description
RequestId String CEF72CEB-54B6-4AE8-B225-F876FF7BA984

The ID of the request


Request example

http(s)://[Endpoint]/? Action=AddListenerWhiteListItem

Normal response examples

XML format


JSON format

	"RequestId":" CEF72CEB-54B6-4AE8-B225-F876FF7BA984"

Error codes

Click here to view the error codes.