# CfnEndpointGroupProps

Properties for defining a `CfnEndpointGroup`.

Used as props by: [CfnEndpointGroup](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_globalaccelerator.CfnEndpointGroup.html)

- Source: Generated at build time
- Type last changed: v2.227.0 · 21 Nov 2025

## Example

TypeScript:

```ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_globalaccelerator as globalaccelerator } from 'aws-cdk-lib';
const cfnEndpointGroupProps: globalaccelerator.CfnEndpointGroupProps = {
  endpointGroupRegion: 'endpointGroupRegion',
  listenerArn: 'listenerArn',

  // the properties below are optional
  endpointConfigurations: [{
    endpointId: 'endpointId',

    // the properties below are optional
    attachmentArn: 'attachmentArn',
    clientIpPreservationEnabled: false,
    weight: 123,
  }],
  healthCheckIntervalSeconds: 123,
  healthCheckPath: 'healthCheckPath',
  healthCheckPort: 123,
  healthCheckProtocol: 'healthCheckProtocol',
  portOverrides: [{
    endpointPort: 123,
    listenerPort: 123,
  }],
  thresholdCount: 123,
  trafficDialPercentage: 123,
};
```

Python:

```python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_globalaccelerator as globalaccelerator

cfn_endpoint_group_props = globalaccelerator.CfnEndpointGroupProps(
    endpoint_group_region="endpointGroupRegion",
    listener_arn="listenerArn",

    # the properties below are optional
    endpoint_configurations=[globalaccelerator.CfnEndpointGroup.EndpointConfigurationProperty(
        endpoint_id="endpointId",

        # the properties below are optional
        attachment_arn="attachmentArn",
        client_ip_preservation_enabled=False,
        weight=123
    )],
    health_check_interval_seconds=123,
    health_check_path="healthCheckPath",
    health_check_port=123,
    health_check_protocol="healthCheckProtocol",
    port_overrides=[globalaccelerator.CfnEndpointGroup.PortOverrideProperty(
        endpoint_port=123,
        listener_port=123
    )],
    threshold_count=123,
    traffic_dial_percentage=123
)
```

Java:

```java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.globalaccelerator.*;

CfnEndpointGroupProps cfnEndpointGroupProps = CfnEndpointGroupProps.builder()
        .endpointGroupRegion("endpointGroupRegion")
        .listenerArn("listenerArn")

        // the properties below are optional
        .endpointConfigurations(List.of(EndpointConfigurationProperty.builder()
                .endpointId("endpointId")

                // the properties below are optional
                .attachmentArn("attachmentArn")
                .clientIpPreservationEnabled(false)
                .weight(123)
                .build()))
        .healthCheckIntervalSeconds(123)
        .healthCheckPath("healthCheckPath")
        .healthCheckPort(123)
        .healthCheckProtocol("healthCheckProtocol")
        .portOverrides(List.of(PortOverrideProperty.builder()
                .endpointPort(123)
                .listenerPort(123)
                .build()))
        .thresholdCount(123)
        .trafficDialPercentage(123)
        .build();
```

C# / .NET:

```csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.GlobalAccelerator;

var cfnEndpointGroupProps = new CfnEndpointGroupProps {
    EndpointGroupRegion = "endpointGroupRegion",
    ListenerArn = "listenerArn",

    // the properties below are optional
    EndpointConfigurations = new [] { new EndpointConfigurationProperty {
        EndpointId = "endpointId",

        // the properties below are optional
        AttachmentArn = "attachmentArn",
        ClientIpPreservationEnabled = false,
        Weight = 123
    } },
    HealthCheckIntervalSeconds = 123,
    HealthCheckPath = "healthCheckPath",
    HealthCheckPort = 123,
    HealthCheckProtocol = "healthCheckProtocol",
    PortOverrides = new [] { new PortOverrideProperty {
        EndpointPort = 123,
        ListenerPort = 123
    } },
    ThresholdCount = 123,
    TrafficDialPercentage = 123
};
```

Golang:

```go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

cfnEndpointGroupProps := &CfnEndpointGroupProps{
	EndpointGroupRegion: jsii.String("endpointGroupRegion"),
	ListenerArn: jsii.String("listenerArn"),

	// the properties below are optional
	EndpointConfigurations: []interface{}{
		&EndpointConfigurationProperty{
			EndpointId: jsii.String("endpointId"),

			// the properties below are optional
			AttachmentArn: jsii.String("attachmentArn"),
			ClientIpPreservationEnabled: jsii.Boolean(false),
			Weight: jsii.Number(123),
		},
	},
	HealthCheckIntervalSeconds: jsii.Number(123),
	HealthCheckPath: jsii.String("healthCheckPath"),
	HealthCheckPort: jsii.Number(123),
	HealthCheckProtocol: jsii.String("healthCheckProtocol"),
	PortOverrides: []interface{}{
		&PortOverrideProperty{
			EndpointPort: jsii.Number(123),
			ListenerPort: jsii.Number(123),
		},
	},
	ThresholdCount: jsii.Number(123),
	TrafficDialPercentage: jsii.Number(123),
}
```

## Properties

- `endpointConfigurations`: [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnEndpointGroup.EndpointConfigurationProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_globalaccelerator.CfnEndpointGroup.EndpointConfigurationProperty.html)[] — The list of endpoint objects.

- `endpointGroupRegion`: string (required) — The AWS Regions where the endpoint group is located.

- `healthCheckIntervalSeconds`: number = 30 — The time—10 seconds or 30 seconds—between health checks for each endpoint.

  The default value is 30.

- `healthCheckPath`: string = "/" — If the protocol is HTTP/S, then this value provides the ping path that Global Accelerator uses for the destination on the endpoints for health checks.

  The default is slash (/).

- `healthCheckPort`: number = -1 — The port that Global Accelerator uses to perform health checks on endpoints that are part of this endpoint group.

  The default port is the port for the listener that this endpoint group is associated with. If the listener port is a list, Global Accelerator uses the first specified port in the list of ports.

- `healthCheckProtocol`: string = "TCP" — The protocol that Global Accelerator uses to perform health checks on endpoints that are part of this endpoint group.

  The default value is TCP.

- `listenerArn`: string | [IListenerRef](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.interfaces.aws_globalaccelerator.IListenerRef.html) (required) — The Amazon Resource Name (ARN) of the listener.

- `portOverrides`: [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnEndpointGroup.PortOverrideProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_globalaccelerator.CfnEndpointGroup.PortOverrideProperty.html)[] — Allows you to override the destination ports used to route traffic to an endpoint.

  Using a port override lets you map a list of external destination ports (that your users send traffic to) to a list of internal destination ports that you want an application endpoint to receive traffic on.

- `thresholdCount`: number = 3 — The number of consecutive health checks required to set the state of a healthy endpoint to unhealthy, or to set an unhealthy endpoint to healthy.

  The default value is 3.

- `trafficDialPercentage`: number = 100 — The percentage of traffic to send to an AWS Regions .

  Additional traffic is distributed to other endpoint groups for this listener.

  Use this action to increase (dial up) or decrease (dial down) traffic to a specific Region. The percentage is applied to the traffic that would otherwise have been routed to the Region based on optimal routing.

  The default value is 100.
