All Products
Search
Document Center

Global Accelerator:GetHealthStatus

Last Updated:Apr 10, 2024

Queries the health status of the endpoints and endpoint groups of a listener.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
ga:GetHealthStatusRead
  • Listener
    acs:ga:{#regionId}:{#accountId}:listener/{#listenerId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The ID of the region where the Global Accelerator (GA) instance is deployed. Set the value to cn-hangzhou.

cn-hangzhou
ClientTokenstringNo

The client token that is used to ensure the idempotence of the request.

You can use the client to generate the token, but you must make sure that the token is unique among different requests. The token can contain only ASCII characters and cannot exceed 64 characters in length.

Note If you do not specify this parameter, the system automatically uses the request ID as the client token. The request ID may be different for each request.
123e4567-e89b-12d3-a456-426655440000
DryRunbooleanNo

Specifies whether only to precheck the request. Valid values:

  • true: prechecks the request only. The health status of the listener is not queried. The system prechecks the required parameters, request syntax, and limits. If the request fails the precheck, an error message is returned. If the request passes the precheck, the DryRunOperation error code is returned.
  • false (default): sends a normal request. If the request passes the precheck, a 2xx HTTP status code is returned and the health status of the listener is obtained.
true
AcceleratorIdstringYes

The ID of the GA instance that you want to query.

ga-bp1odcab8tmno0hdq****
ListenerIdstringYes

The ID of the listener.

lsr-bp1bpn0kn908w4nbw****

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

RequestIdstring

The ID of the request.

64ADAB1E-0B7F-4FD8-A404-3BECC0E9CCFF
ListenerIdstring

The ID of the listener.

lsr-bp1bpn0kn908w4nbw****
HealthStatusstring

The health status of endpoints and endpoint groups. Valid values:

  • normal
  • abnormal
  • partiallyAbnormal
normal
EndpointGroupsobject []

The information about the endpoint groups.

EndpointGroupIdstring

The ID of the endpoint group.

epg-bp14sz7ftcwwjgrdm****
EndpointGroupTypestring

The type of the endpoint group. Valid values:

  • default: the default endpoint group.
  • virtual: a virtual endpoint group.
default
HealthStatusstring

The health status of the endpoint group. Valid values:

  • init: The endpoint group is being initialized.
  • normal: The endpoint group is normal.
  • abnormal: The endpoint group is abnormal.
  • partiallyAbnormal: The endpoint group is partially abnormal.
normal
ForwardingRuleIdsarray

The IDs of the forwarding rules.

string

The ID of the forwarding rule.

frule-bp134k63nmtwmnwee****
Endpointsobject []

The information about the endpoints.

EndpointIdstring

The ID of the endpoint.

ep-hp33b2e43fays7s8****
Addressstring

The IP address of the endpoint.

47.0.XX.XX
HealthStatusstring

The health status of the endpoint. Valid values:

  • init: The endpoint is being initialized.
  • normal: The endpoint is normal.
  • abnormal: The endpoint is abnormal.
normal
HealthDetailstring

The health check details of the endpoint.

Note This parameter is unavailable.
null
Portlong

The port that is used to connect to the endpoint.

80
Typestring

The type of the endpoint. Valid values:

  • Domain: a custom domain name.
  • Ip: a custom IP address.
  • PublicIp: a public IP address provided by Alibaba Cloud.
  • ECS: an Elastic Compute Service (ECS) instance.
  • SLB: a Classic Load Balancer (CLB) instance.
  • ALB: an Application Load Balancer (ALB) instance.
  • OSS: an Object Storage Service (OSS) bucket.
  • ENI: an elastic network interface (ENI).
  • NLB: a Network Load Balancer (NLB) instance.
Ip

Examples

Sample success responses

JSONformat

{
  "RequestId": "64ADAB1E-0B7F-4FD8-A404-3BECC0E9CCFF",
  "ListenerId": "lsr-bp1bpn0kn908w4nbw****",
  "HealthStatus": "normal",
  "EndpointGroups": [
    {
      "EndpointGroupId": "epg-bp14sz7ftcwwjgrdm****",
      "EndpointGroupType": "default",
      "HealthStatus": "normal",
      "ForwardingRuleIds": [
        "frule-bp134k63nmtwmnwee****"
      ],
      "Endpoints": [
        {
          "EndpointId": "ep-hp33b2e43fays7s8****",
          "Address": "47.0.XX.XX",
          "HealthStatus": "normal",
          "HealthDetail": "null",
          "Port": 80,
          "Type": "Ip"
        }
      ]
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history