GetDomainDetail
Source:
src/AWS/Route53Domains/GetDomainDetail.ts
Runtime binding for route53domains:GetDomainDetail — return detailed
information (nameservers, contacts, expiry, DNSSEC keys, status list)
about a domain registered with the current AWS account.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:GetDomainDetail on *. Calls are pinned to us-east-1,
the only region that serves the Route 53 Domains API, regardless of where
the function runs.
Requesting detail for a domain that is not registered in the current
account fails with a typed DomainNotFound error. Provide the
implementation with
Effect.provide(AWS.Route53Domains.GetDomainDetailHttp).
Reading Domain Details
Section titled “Reading Domain Details”Get the Nameservers of an Owned Domain
// initconst getDomainDetail = yield* AWS.Route53Domains.GetDomainDetail();
// runtimeconst detail = yield* getDomainDetail({ DomainName: "example.com" });const nameservers = (detail.Nameservers ?? []).map((ns) => ns.Name);Handle a Domain That Is Not in the Account
const detail = yield* getDomainDetail({ DomainName: "example.com" }).pipe( Effect.catchTag("DomainNotFound", () => Effect.succeed(undefined)),);