npm install @skiddph/domain-checker
const domainChecker = require('@skiddph/domain-checker')
const query = 'domain.com' // format: 'domain.com' or 'domain'
const vendor = 'google' // Google Domains
await domainChecker(query)[vendor]()
.then(e => {
if(e.success) {
console.log('vendor:', e.title)
console.log('website:', e.website)
console.log('result count:', e.result.length)
console.table(e.result)
} else throw e.message
})
.catch(e => {
console.log(e.message)
})
success: Boolean
error: Boolean
message: String
title: String
website: Sting
result: # Array
- available: Boolean
sld: String
tld: String
currency: String
price: Number
+----------+----------------+
| Key | Name |
+----------+----------------+
| google | Google Domains |
| freenom | Freenom |
+----------+----------------+
Apache-2.0@skiddph