Menu
Elastic Load Balancing
API Reference (API Version 2015-12-01)

SetIpAddressType

Sets the type of IP addresses used by the subnets of the specified Application Load Balancer or Network Load Balancer.

Note that Network Load Balancers must use ipv4.

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

IpAddressType

The IP address type. The possible values are ipv4 (for IPv4 addresses) and dualstack (for IPv4 and IPv6 addresses). Internal load balancers must use ipv4.

Type: String

Valid Values: ipv4 | dualstack

Required: Yes

LoadBalancerArn

The Amazon Resource Name (ARN) of the load balancer.

Type: String

Required: Yes

Response Elements

The following element is returned by the service.

IpAddressType

The IP address type.

Type: String

Valid Values: ipv4 | dualstack

Errors

For information about the errors that are common to all actions, see Common Errors.

InvalidConfigurationRequest

The requested configuration is not valid.

HTTP Status Code: 400

InvalidSubnet

The specified subnet is out of available addresses.

HTTP Status Code: 400

LoadBalancerNotFound

The specified load balancer does not exist.

HTTP Status Code: 400

Example

Set the IP address type of a load balancer

This example sets the IP address type of the specified load balancer to dualstack to support IPv4 and IPv6 addresses.

Sample Request

https://elasticloadbalancing.amazonaws.com/?Action=SetIpAddressType
&LoadBalancerArn=arn:aws:elasticloadbalancing:us-west-2:123456789012:loadbalancer/app/my-load-balancer/50dc6c495c0c9188
&IpAddressType=dualstack
&Version=2015-12-01
&AUTHPARAMS

Sample Response

<SetIpAddressTypeResponse xmlns="http://elasticloadbalancing.amazonaws.com/doc/2015-12-01/">
  <SetIpAddressTypeResult>
    <IpAddressType>dualstack</IpAddressType>
  </SetSecurityGroupsResult> 
  <ResponseMetadata> 
    <RequestId>a127426b-f3ab-11e5-9192-3fff33344cfa</RequestId> 
  </ResponseMetadata> 
</SetIpAddressTypeResponse>

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: