Modifies the configuration of an endpoint group.

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 UpdateEndpointGroup

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

RegionId String Yes cn-hangzhou

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

ClientToken String No 123e4567-e89b-12d3-a456-426655440000

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

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

EndpointGroupId String Yes epg-bp1dmlohjjz4kqaun****

The ID of the endpoint group.

Name String No group1

The name of the endpoint group.

The name must be 2 to 128 characters in length, and can contain letters, digits, underscores (_), and hyphens (-). The name must start with a letter.

Description String No EndpointGroup

The description of the endpoint group.

EndpointGroupRegion String Yes cn-hangzhou

The ID of the region in which the endpoint group is deployed.

TrafficPercentage Integer No 20

The weight of the listener if the listener is associated with multiple endpoint groups.

HealthCheckIntervalSeconds Integer No 3

The interval at which health checks are performed. Unit: seconds.

HealthCheckPath String No /healthcheck

The health check path.

HealthCheckPort Integer No 20

The port that is used for health checks.

HealthCheckProtocol String No tcp

The protocol that is used for health checks. Valid values:

  • tcp
  • http
  • https
ThresholdCount Integer No 3

The number of consecutive failed health checks that must occur before an endpoint can be considered unhealthy.

EndpointRequestProtocol String No HTTP

The protocol used by the backend service. Valid values:

  • HTTP
  • HTTPS
Note
  • You can set this parameter only when you create an endpoint group for an HTTP or HTTPS listener.
  • For an HTTP listener, the backend service protocol can only be HTTP.
HealthCheckEnabled Boolean No true

Specifies whether to enable the health check feature. Default value: true. Valid values:

  • true: enables the health check feature.
  • false: disables the health check feature.
EndpointConfigurations.N.Type String Yes Ip

The type of the endpoints. 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 Server Load Balancer (SLB) instance
Note If you set this parameter to ECS or SLB and the service-linked role does not exist, the system automatically creates a service-linked role named AliyunServiceRoleForGaVpcEndpoint. For more information, see Service-linked roles.
EndpointConfigurations.N.EnableClientIPPreservation Boolean No false

Specifies whether to reserve client IP addresses. Default value: false. Valid values:

  • true: reserves client IP addresses.
  • false: reserves no client IP addresses.
EndpointConfigurations.N.Weight Integer Yes 20

The weight of the endpoint.

Valid values: 0 to 255.

Note If you set the weight of an endpoint to 0, GA does not route network traffic to the endpoint. Proceed with caution.
EndpointConfigurations.N.Endpoint String Yes 120.XX.XX.21

The IP address or domain name of the endpoint.

PortOverrides.N.ListenerPort Integer No 443

The listening port for port mapping.

Note
  • You can configure port mapping only when you create an endpoint group for an HTTP or HTTPS listener.
  • The listening port for port mapping must be the same as that used by the current listener.
PortOverrides.N.EndpointPort Integer No 80

The endpoint port for port mapping.

Response parameters

Parameter Type Example Description
RequestId String 6FEA0CF3-D3B9-43E5-A304-D217037876A8

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=UpdateEndpointGroup
&EndpointConfigurations.1.Endpoint=120.XX.XX.21 
&EndpointConfigurations.1.Type=Ip
&EndpointConfigurations.1.Weight=20
&EndpointGroupId=epg-bp1dmlohjjz4kqaun****
&EndpointGroupRegion=cn-hangzhou
&RegionId=cn-hangzhou
&<Common request parameters>|

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<UpdateEndpointGroupResponse>
    <RequestId>6FEA0CF3-D3B9-43E5-A304-D217037876A8</RequestId>
</UpdateEndpointGroupResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "6FEA0CF3-D3B9-43E5-A304-D217037876A8"
}

Error codes

HTTP status code Error code Error message Description
400 NoPermission.EnableHealthCheck You do not have permission to enable health check. The error message returned because you are not authorized to enable the health check feature. You must apply for the required permissions.
400 NotExist.EndPointGroup The endpoint group does not exist. The error message returned because the specified endpoint group does not exist.
400 StateError.EndPointGroup The specified state of endpoint group is invalid. The error message returned because the specified endpoint group is in an invalid status.
400 NotExist.Listener The listener does not exist. The error message returned because the specified listener does not exist.
400 NotActive.Listener The state of the listener is not active. The error message returned because the specified listener is unstable.
400 NotExist.Accelerator The accelerated instance does not exist. The error message returned because the specified GA instance does not exist.
400 StateError.Accelerator The state of the accelerated instance is invalid. The error message returned because the specified GA instance is invalid.
400 QuotaExceeded.EndPoint The maximum number of endpoints is exceeded. The error message returned because the number of endpoints has reached the upper limit.
400 NoPermission.VpcEndpoint You are not authorized to perform the operation. The error message returned because you are unauthorized to create the service-linked role. Contact the owner of the Alibaba Cloud account or the permission administrator to grant the current user the AliyunGlobalAccelerationFullAccess permission or the required custom permissions. The custom permissions allow you to create the service-linked role. A custom permission policy contains the following information: 1. service name: vpcendpoint.ga.aliyuncs.com. 2. service-linked role: AliyunServiceRoleForGaVpcEndpoint. 3. required permissions: ram:CreateServiceLinkedRole.
400 QuotaExceeded.PortOverride The number of port override exceeds the limit. The error message returned because the number of port overrides has reached the upper limit.

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