@mitrajit/simple-whois 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
1
  import { ParsedDomainData } from "./parser";
2
2
  export default function main(domain: string, options: {
3
- proxy: string;
3
+ proxy: string | null;
4
4
  }): Promise<ParsedDomainData>;
package/dist/servers.json CHANGED
@@ -494,7 +494,7 @@
494
494
  "edu.cn": "whois.edu.cn",
495
495
  "cn": "whois.cnnic.cn",
496
496
  "uk.co": "whois.uk.co",
497
- "co": "whois.nic.co",
497
+ "co": "whois.registry.co",
498
498
  "cr": "whois.nic.cr",
499
499
  "cu": null,
500
500
  "cv": null,
package/dist/test.d.ts ADDED
@@ -0,0 +1 @@
1
+ export {};
package/dist/test.js ADDED
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ const whois_1 = __importDefault(require("./whois"));
7
+ const util_1 = require("util");
8
+ const lookup = (0, util_1.promisify)(whois_1.default.lookup);
9
+ const PROXY = "socks5://oidmmwnn-rotate:xxxx@p.webshare.io:80";
10
+ const DOMAIN = "aigtmagentusa.co";
11
+ async function run() {
12
+ console.log("Lookup without proxy...");
13
+ const withoutProxy = await lookup(DOMAIN, {});
14
+ console.log("--- Without proxy ---\n", typeof withoutProxy === "string" ? withoutProxy.slice(0, 500) : withoutProxy);
15
+ console.log("\nLookup with proxy...");
16
+ const withProxy = await lookup(DOMAIN, { proxy: PROXY });
17
+ console.log("--- With proxy ---\n", typeof withProxy === "string" ? withProxy.slice(0, 500) : withProxy);
18
+ }
19
+ run().catch(console.error);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mitrajit/simple-whois",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "Package to check the whois data by the domain name",
5
5
  "keywords": [
6
6
  "whois",
@@ -32,9 +32,14 @@
32
32
  "publish": "npm publish --access public"
33
33
  },
34
34
  "devDependencies": {
35
+ "@types/node": "^25.3.2",
36
+ "@types/punycode": "^2.1.4",
35
37
  "typescript": "^4.9.5"
36
38
  },
37
39
  "dependencies": {
38
- "punycode": "^2.3.1"
40
+ "punycode": "^2.3.1",
41
+ "simple-whois": "link:../../Library/pnpm/global/5/node_modules/@mitrajit/simple-whois",
42
+ "socks": "^2.8.7",
43
+ "underscore": "^1.13.8"
39
44
  }
40
45
  }