Skip to content

ListProfileResourceAssociations

Source: src/AWS/Route53Profiles/ListProfileResourceAssociations.ts

Runtime binding for route53profiles:ListProfileResourceAssociations — enumerate the DNS resources attached to the bound Profile (private hosted zones, Resolver rules, DNS Firewall rule groups; each item carries the resource’s ARN, type, properties, and Status), so an ops function can audit what DNS configuration a shared profile bundles. The profile’s id is injected automatically.

Provide AWS.Route53Profiles.ListProfileResourceAssociationsHttp on the hosting Lambda Function to satisfy the requirement.

// init — grants route53profiles:ListProfileResourceAssociations
const listProfileResourceAssociations =
yield* AWS.Route53Profiles.ListProfileResourceAssociations(profile);
// runtime
const { ProfileResourceAssociations = [] } =
yield* listProfileResourceAssociations();
for (const association of ProfileResourceAssociations) {
yield* Effect.log(`${association.ResourceType}: ${association.ResourceArn}`);
}