Skip to content

ListResolverEndpointIpAddresses

Source: src/AWS/Route53Resolver/ListResolverEndpointIpAddresses.ts

Runtime binding for route53resolver:ListResolverEndpointIpAddresses — discover the IP addresses the bound ResolverEndpoint’s network interfaces answer/forward on (one per subnet); the endpoint ID is injected automatically.

The canonical runtime use: DNS bootstrap automation that reads an INBOUND endpoint’s IPs to configure on-premises conditional forwarders (or a VPN / DHCP option set) without hard-coding addresses.

Provide Route53Resolver.ListResolverEndpointIpAddressesHttp on the hosting Lambda Function to satisfy the requirement.

// init — grants route53resolver:ListResolverEndpointIpAddresses on the endpoint
const listIps = yield* AWS.Route53Resolver.ListResolverEndpointIpAddresses(endpoint);
// runtime
const { IpAddresses } = yield* listIps();
const ips = (IpAddresses ?? []).map((ip) => ip.Ip);