Queries Classic Load Balancer (CLB) instances.

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 DescribeLoadBalancers

The operation that you want to perform.

Set the value to DescribeLoadBalancers.

RegionId String Yes cn-hangzhou

The region where the CLB instance is created.

You can query region IDs from the Regions and zones list or by calling the DescribeRegions operation.

ServerId String No vm-server-23*****group

The ID of the Elastic Compute Service (ECS) instance that is specified as a backend server of the CLB instance.

AddressIPVersion String No ipv4

The IP version. Valid values: ipv4 and ipv6.

Note You can create IPv6 instances for high-performance CLB instances that are deployed in the following zones: Hangzhou Zone E and Hangzhou Zone F, Beijing Zone F and Beijing Zone G, Shanghai Zone D and Shanghai Zone E, Zhangjiakou Zone A and Zhangjiakou Zone B, or Shenzhen Zone D and Shenzhen Zone E.
LoadBalancerStatus String No active

The state of the CLB instance. Valid values:

  • inactive: If a CLB instance is in the inactive state, the listeners of the CLB instance do not forward traffic.
  • active: Newly created CLB instances are in the active state by default.
  • locked: The CLB instance is locked.
LoadBalancerId String No lb-bp1b6c719dfa****

The ID of the CLB instance.

You can specify up to 10 IDs in each request. Separate multiple IDs with commas (,).

LoadBalancerName String No lb-bp1o94dp5i6ea****

The name of the CLB instance.

The name must be 1 to 80 characters in length, and can contain digits, periods (.), underscores (_), and hyphens (-). It must start with a letter.

You can specify up to 10 names in each request. Separate multiple names with commas (,).

ServerIntranetAddress String No 10.XX.XX.6

The private IP address of the ECS instance that is specified as a backend server of the CLB instance.

You can specify multiple IP addresses to query CLB instances. Separate multiple IP addresses with commas (,).

AddressType String No intranet

The type of network where the CLB instance is deployed.

Valid values: intranetandinternet.

  • internet: After an Internet-facing CLB instance is created, the system allocates a public IP address to the CLB instance. Then, the CLB instance can forward requests from the Internet.
  • intranet: After an internal-facing CLB instance is created, the system allocates a private IP address to the CLB instance. Then, the CLB instance can forward only internal requests.
InternetChargeType String No paybybandwidth

The billing method of the Internet-facing CLB instance. Valid values:paybybandwidthandpaybytraffic.

  • paybybandwidth: pay-by-bandwidth.
  • paybytraffic: pay-by-data-transfer.
Note If you do not specify this parameter, the billing method of the CLB instance remains unchanged.
VpcId String No vpc-bp1aevy8sof****

The ID of the virtual private cloud (VPC) to which the CLB instance belongs.

VSwitchId String No vsw-bp12mw1f8k3****

The ID of the vSwitch to which the CLB instance belongs.

NetworkType String No vpc

The type of network where the internal-facing CLB instance is deployed. Valid values: vpc and classic.

  • vpc: a VPC
  • classic: a classic network
Address String No 192.XX.XX.6

The IP address that the CLB instance uses to provide services.

MasterZoneId String No cn-hangzhou-b

The ID of the primary zone to which the CLB instance belongs.

SlaveZoneId String No cn-hangzhou-d

The ID of the secondary zone to which the CLB instance belongs.

Multiple zones are not supported for users whose workloads are deployed on Alibaba Finance Cloud.

Tags String No [{"tagKey":"Key1","tagValue":"Value1"}]

The tags that are added to the CLB instances. The tags must be key-value pairs that are contained in a JSON dictionary.

You can specify up to 10 tags in each request.

PayType String No PayOnDemand

The billing method of the CLB instance. Valid values:PayOnDemandandPrePay.

  • PayOnDemand: pay-as-you-go
  • PrePay: subscription
ResourceGroupId String No rg-acfmxazb4p******

The ID of the resource group.

PageNumber Integer No 1

The number of the page to return.

PageSize Integer No 50

The number of entries to return on each page.

Valid values: 1 to 100.

Response parameters

Parameter Type Example Description
LoadBalancers Array of LoadBalancer

The list of CLB instances.

LoadBalancer
LoadBalancerId String lb-bp1b6c719dfa****

The ID of the CLB instance.

LoadBalancerName String lb-bp1o94dp5i6ea****

The name of the CLB instance.

LoadBalancerStatus String active

The state of the CLB instance. Valid values:

  • inactive: If a CLB instance is in the inactive state, the listeners of the CLB instance do not forward traffic.
  • active: Newly created CLB instances are in the active state by default.
  • locked: The CLB instance is locked.
Address String 100.XX.XX.28

The IP address of the CLB instance.

RegionId String cn-hangzhou

The ID of the region where the CLB instance is deployed.

RegionIdAlias String hangzhou

The name of the region where the CLB instance is deployed.

AddressType String intranet

The type of network where the CLB instance is deployed.

VSwitchId String vsw-255ecr****

The ID of the vSwitch to which the internal-facing CLB instance belongs.

VpcId String vpc-25dvzy9f8****

The ID of the VPC to which the internal-facing CLB instance belongs.

NetworkType String vpc

The type of network where the internal-facing SLB instance is deployed. Valid values:

  • vpc: a VPC
  • classic: a classic network
CreateTime String 2017-08-31T02:49:05Z

The time when the CLB instance was created.

MasterZoneId String cn-hangzhou-b

The ID of the primary zone where the CLB instance is deployed.

SlaveZoneId String cn-hangzhou-d

The ID of the secondary zone where the CLB instance is deployed.

AddressIPVersion String ipv4

The IP version. Valid values: ipv4 and ipv6.

CreateTimeStamp Long 1504147745000

The timestamp generated when the CLB instance was created.

InternetChargeType String paybybandwidth

The billing method of the Internet-facing CLB instance.

Valid values:paybybandwidthandpaybytraffic.

  • paybybandwidth: pay-by-bandwidth
  • paybytraffic (default): pay-by-data-transfer
    Note If the value of the PayType parameter is PrePay, only pay-by-bandwidth is supported.
ModificationProtectionReason String ManageInstance

The reason why the configuration read-only mode is enabled. The value must be 1 to 80 characters in length. It must start with a letter and can contain digits, periods (.), underscores (_), and hyphens (-).

Note This parameter is returned only when ModificationProtectionStatus is set to ConsoleProtection.
ModificationProtectionStatus String ConsoleProtection

Indicates whether the configuration read-only mode is enabled for the CLB instance.

  • NonProtection: the configuration read-only mode is disabled. After the configuration read-only mode is disabled, the value of ModificationProtectionReason is cleared.
  • ConsoleProtection: the configuration read-only mode is enabled.
PayType String PrePay

The billing method of the CLB instance. Valid values: PayOnDemand and PrePay.

ResourceGroupId String rg-atstuj3r****

The ID of the resource group.

PageNumber Integer 1

The number of the returned page.

PageSize Integer 50

The number of entries returned on the current page.

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

The ID of the request.

TotalCount Integer 1

The total number of CLB instances that are returned after the tags are matched against the specified conditions.

Examples

Sample requests

http(s)://[Endpoint]/? Action=DescribeLoadBalancers
&RegionId=cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

<DescribeLoadBalancersResponse>
      <PageNumber>1</PageNumber>
      <TotalCount>1</TotalCount>
      <PageSize>50</PageSize>
      <LoadBalancers>
            <LoadBalancer>
                  <CreateTimeStamp>1541679713000</CreateTimeStamp>
                  <LoadBalancerName>lb-bp1o94dp5i6ea*******</LoadBalancerName>
                  <RegionIdAlias>hangzhou</RegionIdAlias>
                  <ResourceGroupId>rg-acfmxaz*******y</ResourceGroupId>
                  <AddressIPVersion>ipv4</AddressIPVersion>
                  <LoadBalancerId>lb-bp1b6c********fuca5</LoadBalancerId>
                  <VSwitchId>vsw-bp12mw1f********bmlj</VSwitchId>
                  <InternetChargeType>4</InternetChargeType>
                  <VpcId>vpc-bp1aevy8*********5cm</VpcId>
                  <SlaveZoneId>cn-hangzhou-d</SlaveZoneId>
                  <NetworkType>vpc</NetworkType>
                  <MasterZoneId>cn-hangzhou-b</MasterZoneId>
                  <CreateTime>2018-11-08T20:21Z</CreateTime>
                  <Address>192.168.0. **</Address>
                  <RegionId>cn-hangzhou</RegionId>
                  <AddressType>intranet</AddressType>
                  <PayType>PayOnDemand</PayType>
                  <LoadBalancerStatus>active</LoadBalancerStatus>
            </LoadBalancer>
      </LoadBalancers>
      <RequestId>1C7445CB-C21C-4C19-9A3C-65C3190D1944</RequestId>
</DescribeLoadBalancersResponse>

JSON format

{
    "PageNumber": 1, 
    "TotalCount": 1, 
    "PageSize": 50, 
    "LoadBalancers": {
        "LoadBalancer": [
            {
                "CreateTimeStamp": 1541679713000, 
                "LoadBalancerName": "lb-bp1o94dp5i6ea*******", 
                "RegionIdAlias": "hangzhou", 
                "ResourceGroupId": "rg-acfmxazb4p****", 
                "AddressIPVersion": "ipv4", 
                "LoadBalancerId": "lb-bp1b6c719d******exfuca5", 
                "VSwitchId": "vsw-bp12mw1f8k******bmlj", 
                "InternetChargeType": "4", 
                "VpcId": "vpc-bp1aevy8sof*******5cm", 
                "SlaveZoneId": "cn-hangzhou-d", 
                "NetworkType": "vpc", 
                "MasterZoneId": "cn-hangzhou-b", 
                "CreateTime": "2018-11-08T20:21Z", 
                "Address": "192.168.0.6", 
                "RegionId": "cn-hangzhou", 
                "AddressType": "intranet", 
                "PayType": "PayOnDemand", 
                "LoadBalancerStatus": "active"
            }
        ]
    }, 
    "RequestId": "1C7445CB-C21C-4C19-9A3C-65C3190D1944"
}

Error codes

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