CloudFlare's 1.1.1.1 DNS service in NodeJS.
npm install one-dot
const oneDot = require("one-dot");
oneDot({ domain: "richie-bendall.ml", type: "a" }).then(console.log);
//=> [{ domain: 'richie-bendall.ml.', type: "A", ttl: 200, data: '104.28.8.130' }, { domain: 'richie-bendall.ml.', type: "A", ttl: 200, data: '104.28.9.130' }]
Type: object
Type: string
The domain name to obtain the DNS records for.
Type: string or number
The type of DNS record to obtain.
- Removed the
method
option. Instead useoneDot
oroneDot.https
for HTTPS andoneDot.tls
for TLS. - The Promise system has been changed to use native Promises via async/await instead of Bluebird.
- Callback support has been removed.
TypeError
s instead ofReferenceError
s are now returned if an invaliddomain
ortype
is provided.