AWS.Route53Domains reference
CheckDomainAvailability
Section titled “CheckDomainAvailability”Source:
src/AWS/Route53Domains/CheckDomainAvailability.ts
Runtime binding for route53domains:CheckDomainAvailability — check
whether a domain name is available for registration with Route 53.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:CheckDomainAvailability on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Note that if the returned Availability is PENDING you must submit
another request to determine the availability of the domain name.
Provide the implementation with
Effect.provide(AWS.Route53Domains.CheckDomainAvailabilityHttp).
CheckDomainAvailability: Checking Domain Availability
Section titled “CheckDomainAvailability: Checking Domain Availability”// initconst checkDomainAvailability = yield* AWS.Route53Domains.CheckDomainAvailability();
// runtimeconst result = yield* checkDomainAvailability({ DomainName: "example-startup-name.com",});if (result.Availability === "AVAILABLE") { // domain can be registered}CheckDomainTransferability
Section titled “CheckDomainTransferability”Source:
src/AWS/Route53Domains/CheckDomainTransferability.ts
Runtime binding for route53domains:CheckDomainTransferability — check
whether a domain can be transferred to Amazon Route 53 from another
registrar.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:CheckDomainTransferability on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.CheckDomainTransferabilityHttp).
CheckDomainTransferability: Checking Domain Transferability
Section titled “CheckDomainTransferability: Checking Domain Transferability”// initconst checkDomainTransferability = yield* AWS.Route53Domains.CheckDomainTransferability();
// runtimeconst result = yield* checkDomainTransferability({ DomainName: "example.com",});if (result.Transferability?.Transferable === "TRANSFERABLE") { // domain can be transferred to Route 53}GetDomainDetail
Section titled “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).
GetDomainDetail: Reading Domain Details
Section titled “GetDomainDetail: 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)),);GetDomainSuggestions
Section titled “GetDomainSuggestions”Source:
src/AWS/Route53Domains/GetDomainSuggestions.ts
Runtime binding for route53domains:GetDomainSuggestions — return a list
of suggested domain names based on a seed name, optionally restricted to
names that are currently available for registration.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:GetDomainSuggestions on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.GetDomainSuggestionsHttp).
GetDomainSuggestions: Suggesting Domain Names
Section titled “GetDomainSuggestions: Suggesting Domain Names”// initconst getDomainSuggestions = yield* AWS.Route53Domains.GetDomainSuggestions();
// runtimeconst result = yield* getDomainSuggestions({ DomainName: "example.com", SuggestionCount: 10, OnlyAvailable: true,});const names = (result.SuggestionsList ?? []).map((s) => s.DomainName);GetOperationDetail
Section titled “GetOperationDetail”Source:
src/AWS/Route53Domains/GetOperationDetail.ts
Runtime binding for route53domains:GetOperationDetail — return the
current status of an asynchronous Route 53 Domains operation (a domain
registration, renewal, transfer, or nameserver update identified by the
OperationId those calls return).
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:GetOperationDetail on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.GetOperationDetailHttp).
GetOperationDetail: Tracking Registration Operations
Section titled “GetOperationDetail: Tracking Registration Operations”// initconst getOperationDetail = yield* AWS.Route53Domains.GetOperationDetail();
// runtimeconst detail = yield* getOperationDetail({ OperationId: operationId }).pipe( Effect.repeat({ schedule: Schedule.spaced("10 seconds"), until: (d) => d.Status === "SUCCESSFUL" || d.Status === "ERROR", times: 8, }),);ListDomains
Section titled “ListDomains”Source:
src/AWS/Route53Domains/ListDomains.ts
Runtime binding for route53domains:ListDomains — list all domain names
registered with Route 53 for 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:ListDomains on *. Calls are pinned to us-east-1, the
only region that serves the Route 53 Domains API, regardless of where the
function runs.
Pass Marker from a previous response’s NextPageMarker to paginate.
Provide the implementation with
Effect.provide(AWS.Route53Domains.ListDomainsHttp).
ListDomains: Listing Registered Domains
Section titled “ListDomains: Listing Registered Domains”// initconst listDomains = yield* AWS.Route53Domains.ListDomains();
// runtimeconst result = yield* listDomains({ MaxItems: 100 });const names = (result.Domains ?? []).map((domain) => domain.DomainName);ListOperations
Section titled “ListOperations”Source:
src/AWS/Route53Domains/ListOperations.ts
Runtime binding for route53domains:ListOperations — list the
asynchronous Route 53 Domains operations (registrations, renewals,
transfers, nameserver updates) performed on domains registered by the
current AWS account, optionally filtered by status, type, or submission
date.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:ListOperations on *. Calls are pinned to us-east-1,
the only region that serves the Route 53 Domains API, regardless of where
the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.ListOperationsHttp).
ListOperations: Tracking Registration Operations
Section titled “ListOperations: Tracking Registration Operations”// initconst listOperations = yield* AWS.Route53Domains.ListOperations();
// runtimeconst result = yield* listOperations({ Status: ["IN_PROGRESS"], MaxItems: 20,});const ids = (result.Operations ?? []).map((op) => op.OperationId);ListPrices
Section titled “ListPrices”Source:
src/AWS/Route53Domains/ListPrices.ts
Runtime binding for route53domains:ListPrices — list registration,
transfer, renewal, restoration, and owner-change prices for the TLDs
supported by Route 53, or for one specific TLD.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:ListPrices on *. Calls are pinned to us-east-1, the
only region that serves the Route 53 Domains API, regardless of where the
function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.ListPricesHttp).
ListPrices: Looking Up Prices
Section titled “ListPrices: Looking Up Prices”// initconst listPrices = yield* AWS.Route53Domains.ListPrices();
// runtimeconst result = yield* listPrices({ Tld: "com" });const price = result.Prices?.[0]?.RegistrationPrice?.Price;RegisterDomain
Section titled “RegisterDomain”Source:
src/AWS/Route53Domains/RegisterDomain.ts
Runtime binding for route53domains:RegisterDomain — register a domain
name with Route 53 programmatically. Registration is asynchronous: the
response carries an OperationId you can poll with
AWS.Route53Domains.GetOperationDetail.
Registering a domain bills the AWS account for the registration fee,
so guard calls carefully (e.g. behind a
AWS.Route53Domains.CheckDomainAvailability check and explicit user
consent in a domain-reseller flow).
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:RegisterDomain plus route53:CreateHostedZone (the API
pre-validates that the caller can create the hosted zone Route 53
auto-creates during registration) on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.RegisterDomainHttp).
RegisterDomain: Registering Domains
Section titled “RegisterDomain: Registering Domains”// initconst registerDomain = yield* AWS.Route53Domains.RegisterDomain();
// runtimeconst result = yield* registerDomain({ DomainName: "example-customer-domain.com", DurationInYears: 1, AdminContact: contact, RegistrantContact: contact, TechContact: contact, AutoRenew: true,});// poll result.OperationId with GetOperationDetail until SUCCESSFULRenewDomain
Section titled “RenewDomain”Source:
src/AWS/Route53Domains/RenewDomain.ts
Runtime binding for route53domains:RenewDomain — renew a domain
registered in the current AWS account for the specified number of years.
Renewal is asynchronous: the response carries an OperationId you can
poll with AWS.Route53Domains.GetOperationDetail.
Renewing a domain bills the AWS account for the renewal fee, so guard
calls carefully. Renewing a domain that is not registered in the account
fails with a typed DomainNotFound error.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:RenewDomain on *. Calls are pinned to us-east-1, the
only region that serves the Route 53 Domains API, regardless of where the
function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.RenewDomainHttp).
RenewDomain: Renewing Domains
Section titled “RenewDomain: Renewing Domains”// initconst renewDomain = yield* AWS.Route53Domains.RenewDomain();
// runtimeconst result = yield* renewDomain({ DomainName: "example.com", DurationInYears: 1, CurrentExpiryYear: 2027,});// poll result.OperationId with GetOperationDetail until SUCCESSFULRetrieveDomainAuthCode
Section titled “RetrieveDomainAuthCode”Source:
src/AWS/Route53Domains/RetrieveDomainAuthCode.ts
Runtime binding for route53domains:RetrieveDomainAuthCode — retrieve
the authorization (transfer) code for a domain registered in the current
AWS account. The code is required to transfer the domain to another
registrar.
The returned AuthCode is a secret and is typed as
Redacted.Redacted<string> — unwrap with Redacted.value only at the
point of use. Requesting the code for a domain that is not registered in
the account fails with a typed DomainNotFound error.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:RetrieveDomainAuthCode on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.RetrieveDomainAuthCodeHttp).
RetrieveDomainAuthCode: Transferring Domains Out
Section titled “RetrieveDomainAuthCode: Transferring Domains Out”import * as Redacted from "effect/Redacted";
// initconst retrieveDomainAuthCode = yield* AWS.Route53Domains.RetrieveDomainAuthCode();
// runtimeconst result = yield* retrieveDomainAuthCode({ DomainName: "example.com" });const authCode = result.AuthCode !== undefined && typeof result.AuthCode !== "string" ? Redacted.value(result.AuthCode) : result.AuthCode;UpdateDomainNameservers
Section titled “UpdateDomainNameservers”Source:
src/AWS/Route53Domains/UpdateDomainNameservers.ts
Runtime binding for route53domains:UpdateDomainNameservers — replace
the nameservers for a domain registered in the current AWS account (e.g.
point a registered domain at the delegation set of a Route 53 hosted
zone). The update is asynchronous: the response carries an OperationId
you can poll with AWS.Route53Domains.GetOperationDetail.
Updating nameservers for a domain that is not registered in the account
fails with a typed DomainNotFound error.
Route 53 Domains is a global registration API with no resource-level IAM:
the binding takes no arguments and grants the function
route53domains:UpdateDomainNameservers on *. Calls are pinned to
us-east-1, the only region that serves the Route 53 Domains API,
regardless of where the function runs.
Provide the implementation with
Effect.provide(AWS.Route53Domains.UpdateDomainNameserversHttp).
UpdateDomainNameservers: Updating Nameservers
Section titled “UpdateDomainNameservers: Updating Nameservers”// initconst updateDomainNameservers = yield* AWS.Route53Domains.UpdateDomainNameservers();
// runtimeconst result = yield* updateDomainNameservers({ DomainName: "example.com", Nameservers: [ { Name: "ns-1.awsdns-01.org" }, { Name: "ns-2.awsdns-02.com" }, ],});// poll result.OperationId with GetOperationDetail until SUCCESSFUL