Queries the access control settings of a listener.

Make the API call

You can use OpenAPI Explorer to make API calls, search for API calls, perform debugging, and generate SDK example code.

Request parameters

Parameter Type Required? Example value Description
Action String Yes DescribeListenerAccessControlAttribute

The name of this action.

Value: DescribeListenerAccessControlAttribute

RegionId String Yes cn-hangzhou

The ID of the region to which the Server Load Balancer (SLB) instance belongs.

To query the region ID, refer to the list of regions and zones or call DescribeRegions.

ListenerPort Integer Yes 80

The frontend port used by the listener.

Value range: 1 to 65535

LoadBalancerId String Yes lb-8vb86hxixo8lvsja86jaz

The ID of the SLB instance.

Response parameters

Parameter Type Example value Description
AccessControlStatus String open_white_list

Indicates whether access control is enabled.

  • open_white_list: The whitelist function is enabled as the access control method of the listener.
  • close: The access control function is disabled.
SourceItems String 1.1.1.1,1.1.1.0/24

The IP addresses in the whitelist.

RequestId String 365F4154-92F6-4AE4-92F8-7FF34B540710

The ID of the request.

Examples

Request example


http(s)://[Endpoint]/? Action=DescribeListenerAccessControlAttribute
&ListenerPort=80
&LoadBalancerId=lb-8vb86hxixo8lvsja86jaz
&<CommonParameters>

Response example

XML format

<DescribeListenerAccessControlAttributeResponse>
	  <RequestId>365F4154-92F6-4AE4-92F8-7FF34B540710</RequestId>
	  <AccessControlStatus>open_white_list</AccessControlStatus>
	  <SourceItems>1.1.1.1,1.1.1.0/24</SourceItems>
</DescribeListenerAccessControlAttributeResponse>

JSON format

{
	"RequestId":"365F4154-92F6-4AE4-92F8-7FF34B540710",
	"SourceItems":"1.1.1.1,1.1.1.0/24",
	"AccessControlStatus":"open_white_list"
}

Errors

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