Socket
Book a DemoInstallSign in
Socket

gtlds

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gtlds

A list of all gGTLD names from the ICANN registry.

2.1.0
latest
Source
npmnpm
Version published
Weekly downloads
7
600%
Maintainers
1
Weekly downloads
 
Created
Source

gtlds Build Status codecov

gTLD utilities

A list of all gTLDs from the ICANN registry, including the registry operator and whether the gTLD has been terminated.

The list is a JSON file and can be used anywhere.

Install

$ npm install gtlds

Usage

const gtlds = require('gtlds');

gtlds.random();
/*
{
  "contractTerminated":false,
  "gTLD":"google",
  "registryOperator":"Charleston Road Registry Inc."
}
*/

API

.all

Type: Array

gTLDs in alphabetical order.

.names

Type: Array

gTLD names in alphabetical order.

.random()

Type: Function

Random gTLD.

Updating

A node script is available to sync gTLD data via npm run sync. It will fetch, parse, and overwrite the gtlds.json file.

License

MIT © Chris Vogt

Keywords

TLD

FAQs

Package last updated on 04 Jul 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.