Skip to content
IC Reactor

isMainnetHost

isMainnetHost(host?): boolean

Defined in: utils/helper.ts:177

Checks if a given host URL is a mainnet Internet Computer boundary node host.

Note this recognises only the canonical boundary domains: a mainnet dapp on a custom domain returns false. Do not use it as a “safe to trust local configuration” test — see allowsEnvRootKey.

string

The host URL to evaluate.

boolean

true if the host is a mainnet host, default to true if host is undefined, otherwise false.