Queries the Layer 4 or Layer 7 health check configuration of a port forwarding rule.

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 DescribeHealthCheckList

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

NetworkRules String Yes [{"InstanceId":"ddoscoo-cn-mp91j1ao****","Protocol":"tcp","FrontendPort":8080}]

Details about the port forwarding rule. This parameter is a JSON string. The fields in the value are described as follows:

  • InstanceId: the ID of the instance. This field is required and must be of the STRING type.
  • Protocol: the forwarding protocol. This field is required and must be of the STRING type. Valid values: tcp and udp.
  • FrontendPort: the forwarding port. This field is required and must be of the INTEGER type.
RegionId String No cn-hangzhou

The region ID of the instance. Valid values:

  • cn-hangzhou: mainland China, which indicates an Anti-DDoS Pro instance
  • ap-southeast-1: outside mainland China, which indicates an Anti-DDoS Premium instance

Response parameters

Parameter Type Example Description
HealthCheckList Array

Details about the health check configuration.

FrontendPort Integer 8080

The forwarding port.

HealthCheck Struct

The health check configuration.

Domain String www.aliyun.com

The domain name that corresponds to the port forwarding rule.

Note This parameter is returned only when the Layer 7 health check configuration is queried.
Down Integer 3

The number of consecutive failed health checks that must occur before declaring a port unhealthy. Valid values: 1 to 10.

Interval Integer 15

The health check intervals. Valid values: 1 to 30. Unit: seconds.

Port Integer 8080

The port that was checked.

Timeout Integer 5

The response timeout period. Valid values: 1 to 30. Unit: seconds.

Type String tcp

The protocol type. Valid values:

  • tcp: The Layer 4 health check configuration was queried.
  • http: The Layer 7 health check configuration was queried.
Up Integer 3

The number of consecutive successful health checks that must occur before declaring a port healthy. Valid values: 1 to 10.

Uri String /abc

The check path.

Note This parameter is returned only when the Layer 7 health check configuration is queried.
InstanceId String ddoscoo-cn-mp91j1ao****

The ID of the instance.

Protocol String tcp

The forwarding protocol. Valid values:

  • tcp
  • udp
RequestId String 83B4AF42-E8EE-4DC9-BD73-87B7733A36F9

The ID of the request.

TotalCount String 1

The total number of returned health check configurations.

Examples

Sample requests

http(s)://[Endpoint]/?Action=DescribeHealthCheckList
&NetworkRules=[{"InstanceId":"ddoscoo-cn-mp91j1ao****","Protocol":"tcp","FrontendPort":8080}]
&<Common request parameters>

Sample success responses

XML format

<DescribeHealthCheckListResponse>
      <RequestId>83B4AF42-E8EE-4DC9-BD73-87B7733A36F9</RequestId>
      <HealthCheckList>
            <InstanceId>ddoscoo-cn-mp91j1ao****</InstanceId>
            <FrontendPort>8080</FrontendPort>
            <HealthCheck>
                  <Type>tcp</Type>
                  <Down>3</Down>
                  <Timeout>5</Timeout>
                  <Port>8080</Port>
                  <Up>3</Up>
                  <Interval>15</Interval>
            </HealthCheck>
            <Protocol>tcp</Protocol>
      </HealthCheckList>
      <TotalCount>1</TotalCount>
</DescribeHealthCheckListResponse>

JSON format

{
    "RequestId": "83B4AF42-E8EE-4DC9-BD73-87B7733A36F9",
    "HealthCheckList": [
        {
            "InstanceId": "ddoscoo-cn-mp91j1ao****",
            "FrontendPort": 8080,
            "HealthCheck": {
                "Type": "tcp",
                "Down": 3,
                "Timeout": 5,
                "Port": 8080,
                "Up": 3,
                "Interval": 15
            },
            "Protocol": "tcp"
        }
    ],
    "TotalCount": 1
}

Error codes

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