All Products
Search
Document Center

Edge Security Acceleration:ListLoadBalancers

Last Updated:Jul 07, 2026

Queries the list of load balancers under a site and returns load balancing information. You can query by load balancer name. Paging is supported.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

esa:ListLoadBalancers

list

*Site

acs:esa:{#regionId}:{#accountId}:site/{#SiteId}

None None

Request parameters

Parameter

Type

Required

Description

Example

PageNumber

integer

No

The page number settings for the paging query. The value must be greater than or equal to 1.

2

PageSize

integer

No

The number of entries per page for the paging query. Valid values: 1 to 500.

20

Name

string

No

The load balancing name. You can query by name.

lb.example.com

MatchType

string

No

The name matching strategy when querying by name. Valid values:

  • fuzzy: fuzzy match.

  • exact: exact match.

fuzzy

OrderBy

string

No

The sort field. Currently, only sorting by ID is supported. id indicates ascending order by ID, and -id indicates descending order by ID. The ID value is positively correlated with the creation time. If this parameter is not specified, the default sort order is descending by ID.

id

SiteId

integer

Yes

The site ID. You can call the ListSites operation to obtain the site ID.

21655860979****

Response elements

Element

Type

Description

Example

object

Schema of Response

RequestId

string

The request ID.

CB1A380B-09F0-41BB-A198-72F8FD6DA2FE

LoadBalancers

array<object>

The list of load balancing instances returned in array format.

array<object>

The details of a load balancing instance.

Id

integer

The unique identity ID of the load balancing instance.

998676487607104

Name

string

The name of the load balancing instance.

lb.example.com

SiteId

integer

The ID of the site to which the load balancing instance belongs.

1159101787****

Enabled

boolean

Indicates whether the load balancing instance is enabled. Valid values:

  • true: Enabled.

  • false: Disabled.

false

Ttl

integer

The TTL value, which specifies the time-to-live of the DNS record. Default value: 30.

30

SessionAffinity

string

The session persistence mode. Valid values:

  • off: Disabled.

  • ip: IP-based session persistence.

  • cookie: Cookie-based session persistence.

  • http_header: HTTP header-based session persistence.

ip

FallbackPool

integer

The ID of the fallback address pool. When all other address pools are unavailable, traffic is redirected to this address pool.

96228666776****

SteeringPolicy

string

The load balancing policy.

order

Description

string

The description of the load balancing instance.

test

AdaptiveRouting

object

The cross-origin address pool back-to-origin configuration.

FailoverAcrossPools

boolean

Indicates whether to enable failover across pools.

  • true: Enabled.

  • false: Disabled.

true

OriginLevelRetry

boolean

true

DefaultPools

array

The list of default address pool IDs.

integer

The default address pool.

96228666776****

RandomSteering

object

The weighted round-robin configuration, which controls the traffic distribution weight across different address pools.

DefaultWeight

integer

The default weight applied to any pool not defined in PoolWeights. The weight determines the proportion of traffic sent to the pool.

50

PoolWeights

object

The weight configuration for each backend pool, where the key is the pool ID and the value is the weight.

integer

The weight value for a pool. Valid values range from 0 to 100. A value of 0 routes no traffic to this pool.

50

Rules

array<object>

The list of rule configurations that define behaviors under specific conditions.

array<object>

The rule configuration in the rule set.

FixedResponse

object

Specifies the response to return when a rule matches.

ContentType

string

The Content-Type header.

application/json

Location

string

The Location response header.

http://www.example.com/index.html

MessageBody

string

The content of the response body.

Hello World.

StatusCode

integer

The status code.

200

Overrides

any

The load balancer settings to override when a rule matches. Any field you specify overwrites the load balancer's corresponding setting.

{ "adaptive_routing": { "failover_across_pools": true }, "sub_region_pools": { "GB": [ 96228666776**** ], "US": [ 96228666776**** ] }, "default_pools": [ 96228666776****, 96228666776**** ], "fallback_pool": 96228666776****, "location_strategy": { "mode": "resolver_ip", "prefer_ecs": "always" }, "random_steering": { "default_weight": 30, "pool_weights": { "96228666776****": 70, "96228666776****": 80 } }, "region_pools": { "ENAM": [ 96228666776****, 92843536908**** ], "WNAM": [ 92843536908**** ] }, "session_affinity": "cookie", "session_affinity_attributes": { "drain_duration": 100, "headers": ["none"], "require_all_headers": false, "samesite": "Auto", "secure": "Auto", "zero_downtime_failover": "sticky" }, "session_affinity_ttl": 1800, "steering_policy": "dynamic_latency", "ttl": 30 }

Rule

string

The rule expression that matches user requests. This parameter is not required for global configurations. Use cases:

  • To match all incoming requests, set the value to true.

  • To match specific requests, set the value to a custom expression, such as (http.host eq "video.example.com").

http.request.uri.path contains "/testing"

RuleName

string

The name of the rule. This parameter is not required for global configurations.

r2

RuleEnable

string

Indicates whether the rule is enabled. This parameter is not required for global configurations. Valid values:

  • on: Enabled.

  • off: Disabled.

on

Sequence

integer

The execution priority of the rule. Higher values indicate higher priority.

1

Terminates

boolean

Specifies whether to stop executing subsequent rules after this rule matches.

  • true: Stops executing subsequent rules.

  • false: Continues to execute subsequent rules. This is the default value.

true

Monitor

object

The monitor configuration.

Type

string

The protocol for the health check, such as HTTP. Set to off to disable health checks.

HTTP

Method

string

The method used for the health check.

GET

Port

integer

The destination port for the health check.

80

Path

string

The path to request for the health check.

/

Interval

integer

The interval between health checks, in seconds.

60

ExpectedCodes

string

The expected HTTP status codes that indicate a successful health check, such as 200 or 202.

200,202

FollowRedirects

boolean

Indicates whether the health check should follow redirects.

  • true: Follows redirects.

  • false: Does not follow redirects.

true

ConsecutiveUp

integer

The number of consecutive successful health checks required to consider a pool healthy. For example, 3.

3

ConsecutiveDown

integer

The number of consecutive failed health checks required to consider a pool unhealthy. For example, 5.

5

Header

any

The HTTP headers to include in the health check probe.

{ "host": [ "example1.com", "example2.com" ] }

Timeout

integer

The timeout for a single health check, in seconds.

5

MonitoringRegion

string

The probe locations for health checks. The default is Global. Valid values:

  • Global: Sends probes from global locations.

  • ChineseMainland: Sends probes from locations within the Chinese mainland.

  • OutsideChineseMainland: Sends probes from global locations outside the Chinese mainland.

Global

Status

string

The status of the load balancing instance.

healthy

SubRegionPools

any

The address pools mapped to secondary regions. When multiple secondary regions share the same set of address pools, the secondary region names can be concatenated with commas as the key.

{"AL,MO": [92298024898****],"CN-SH,CN-SX,CN-SC":[92304347804****,92843536908****]}

RegionPools

any

The address pools mapped to primary regions.

{ "ENAM": [ 12345678**** ], "WNAM": [ 23456789****, 23456789**** ] }

PageNumber

integer

The page number, which is the same as the PageNumber request parameter.

1

PageSize

integer

The number of entries per page.

10

TotalCount

integer

The total number of entries.

100

TotalPage

integer

The total number of pages.

10

Examples

Success response

JSON format

{
  "RequestId": "CB1A380B-09F0-41BB-A198-72F8FD6DA2FE",
  "LoadBalancers": [
    {
      "Id": 998676487607104,
      "Name": "lb.example.com\n",
      "SiteId": 0,
      "Enabled": false,
      "Ttl": 30,
      "SessionAffinity": "ip",
      "FallbackPool": 0,
      "SteeringPolicy": "order",
      "Description": "test",
      "AdaptiveRouting": {
        "FailoverAcrossPools": true,
        "OriginLevelRetry": true
      },
      "DefaultPools": [
        0
      ],
      "RandomSteering": {
        "DefaultWeight": 50,
        "PoolWeights": {
          "key": 50
        }
      },
      "Rules": [
        {
          "FixedResponse": {
            "ContentType": "application/json\n",
            "Location": "http://www.example.com/index.html\n",
            "MessageBody": "Hello World.\n",
            "StatusCode": 200
          },
          "Overrides": "{\n            \"adaptive_routing\": {\n                \"failover_across_pools\": true\n            },\n            \"sub_region_pools\": {\n                \"GB\": [\n                    96228666776****\n                ],\n                \"US\": [\n                    96228666776****\n                ]\n            },\n            \"default_pools\": [\n                96228666776****,\n                96228666776****\n            ],\n            \"fallback_pool\": 96228666776****,\n            \"location_strategy\": {\n                \"mode\": \"resolver_ip\",\n                \"prefer_ecs\": \"always\"\n            },\n            \"random_steering\": {\n                \"default_weight\": 30,\n                \"pool_weights\": {\n                    \"96228666776****\": 70,\n                    \"96228666776****\": 80\n                }\n            },\n            \"region_pools\": {\n                \"ENAM\": [\n                    96228666776****,\n                    92843536908****\n                ],\n                \"WNAM\": [\n                    92843536908****\n                ]\n            },\n            \"session_affinity\": \"cookie\",\n            \"session_affinity_attributes\": {\n                \"drain_duration\": 100,\n                \"headers\": [\"none\"],\n                \"require_all_headers\": false,\n                \"samesite\": \"Auto\",\n                \"secure\": \"Auto\",\n                \"zero_downtime_failover\": \"sticky\"\n            },\n            \"session_affinity_ttl\": 1800,\n            \"steering_policy\": \"dynamic_latency\",\n            \"ttl\": 30\n        }",
          "Rule": "http.request.uri.path contains \"/testing\"\n",
          "RuleName": "r2",
          "RuleEnable": "on",
          "Sequence": 1,
          "Terminates": true
        }
      ],
      "Monitor": {
        "Type": "HTTP\n",
        "Method": "GET\n",
        "Port": 80,
        "Path": "/\n",
        "Interval": 60,
        "ExpectedCodes": "200,202\n",
        "FollowRedirects": true,
        "ConsecutiveUp": 3,
        "ConsecutiveDown": 5,
        "Header": "{\n        \"host\": [\n            \"example1.com\",\n            \"example2.com\"\n        ]\n    }",
        "Timeout": 5,
        "MonitoringRegion": "Global"
      },
      "Status": "healthy",
      "SubRegionPools": "{\"AL,MO\": [92298024898****],\"CN-SH,CN-SX,CN-SC\":[92304347804****,92843536908****]}",
      "RegionPools": "{\n  \"ENAM\": [\n    12345678****\n  ],\n  \"WNAM\": [\n    23456789****,\n    23456789****\n  ]\n}"
    }
  ],
  "PageNumber": 1,
  "PageSize": 10,
  "TotalCount": 100,
  "TotalPage": 10
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidParameter The specified parameter is invalid. The specified parameter is invalid.
400 InternalException Failed to call the service. Try again later or contact technical support. Failed to call the service. Try again later or contact technical support.
404 SiteNotFound The website does not exist or does not belong to you. The website does not exist or does not belong to you.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.