leadmeteor 0.0.2 → 0.0.3

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,27 +1,14 @@
1
1
  import { type ClientOptions } from "./client";
2
- import { People } from "./resources/people";
3
- import { Companies } from "./resources/companies";
4
- import * as _EmailsModule from "./types/emails";
5
- import * as _DomainsModule from "./types/domains";
6
- interface Leadmeteor {
7
- emails: Leadmeteor.Emails;
8
- people: People;
9
- companies: Companies;
10
- domains: Leadmeteor.Domains;
11
- }
12
- declare function Leadmeteor(this: Leadmeteor | void, apiKey: string, options?: Omit<ClientOptions, "apiKey">): Leadmeteor;
13
- declare namespace Leadmeteor {
14
- export import Emails = _EmailsModule.Emails;
15
- interface Emails {
16
- verify(params: Emails.EmailVerificationParams): Promise<Emails.EmailVerification>;
17
- lookup(params: Emails.LookupParams): Promise<unknown>;
18
- search(params: Emails.SearchParams): Promise<unknown>;
19
- }
20
- export import Domains = _DomainsModule.Domains;
21
- interface Domains {
22
- lookup(params: Domains.DomainLookupParams): Promise<Domains.DomainLookup>;
23
- }
2
+ import { EmailsResource } from "./resources/emails";
3
+ import { DomainsResource } from "./resources/domains";
4
+ import { CompaniesResource } from "./resources/companies";
5
+ import { PeopleResource } from "./resources/people";
6
+ declare class Leadmeteor {
7
+ readonly emails: EmailsResource;
8
+ readonly domains: DomainsResource;
9
+ readonly companies: CompaniesResource;
10
+ readonly people: PeopleResource;
11
+ constructor(apiKey: string, options?: Omit<ClientOptions, "apiKey">);
24
12
  }
13
+ export { Leadmeteor } from "./types";
25
14
  export default Leadmeteor;
26
- export { Leadmeteor };
27
- export { LeadmeteorError } from "./error";
package/dist/index.js CHANGED
@@ -1,33 +1,23 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.LeadmeteorError = void 0;
4
- exports.Leadmeteor = Leadmeteor;
5
3
  const client_1 = require("./client");
6
4
  const emails_1 = require("./resources/emails");
7
- const people_1 = require("./resources/people");
8
- const companies_1 = require("./resources/companies");
9
5
  const domains_1 = require("./resources/domains");
10
- function Leadmeteor(apiKey, options) {
11
- if (!(this instanceof Leadmeteor)) {
12
- return new Leadmeteor(apiKey, options);
6
+ const companies_1 = require("./resources/companies");
7
+ const people_1 = require("./resources/people");
8
+ class Leadmeteor {
9
+ emails;
10
+ domains;
11
+ companies;
12
+ people;
13
+ constructor(apiKey, options) {
14
+ const client = new client_1.Client({ apiKey, ...options });
15
+ this.emails = new emails_1.EmailsResource(client);
16
+ this.people = new people_1.PeopleResource(client);
17
+ this.companies = new companies_1.CompaniesResource(client);
18
+ this.domains = new domains_1.DomainsResource(client);
13
19
  }
14
- const client = new client_1.Client({ apiKey, ...options });
15
- this.emails = new emails_1.EmailsResource(client);
16
- this.people = new people_1.People(client);
17
- this.companies = new companies_1.Companies(client);
18
- this.domains = new domains_1.DomainsResource(client);
19
- return this;
20
20
  }
21
- (function (Leadmeteor) {
22
- })(Leadmeteor || (exports.Leadmeteor = Leadmeteor = {}));
23
- exports.default = Leadmeteor;
24
- var error_1 = require("./error");
25
- Object.defineProperty(exports, "LeadmeteorError", { enumerable: true, get: function () { return error_1.LeadmeteorError; } });
26
- // Support both CJS patterns:
27
- // const Leadmeteor = require('leadmeteor'); new Leadmeteor('sk_test_...');
28
- // const leadmeteor = require('leadmeteor')('sk_test_...');
21
+ // Exports
29
22
  module.exports = Leadmeteor;
30
- module.exports.default = Leadmeteor;
31
- module.exports.Leadmeteor = Leadmeteor;
32
- // eslint-disable-next-line @typescript-eslint/no-require-imports
33
- module.exports.LeadmeteorError = require("./error").LeadmeteorError;
23
+ exports.default = Leadmeteor;
@@ -1,5 +1,5 @@
1
1
  import type { Client } from "../client";
2
- export declare class Companies {
2
+ export declare class CompaniesResource {
3
3
  private readonly client;
4
4
  constructor(client: Client);
5
5
  lookup(params: Record<string, string>): Promise<unknown>;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Companies = void 0;
4
- class Companies {
3
+ exports.CompaniesResource = void 0;
4
+ class CompaniesResource {
5
5
  client;
6
6
  constructor(client) {
7
7
  this.client = client;
@@ -13,4 +13,4 @@ class Companies {
13
13
  return this.client.request("GET", "/v1/companies/search", params);
14
14
  }
15
15
  }
16
- exports.Companies = Companies;
16
+ exports.CompaniesResource = CompaniesResource;
@@ -1,7 +1,7 @@
1
1
  import type { Client } from "../client";
2
- import type { Domains } from "../types/domains";
2
+ import type { Leadmeteor } from "../types";
3
3
  export declare class DomainsResource {
4
4
  private readonly client;
5
5
  constructor(client: Client);
6
- lookup(params: Domains.DomainLookupParams): Promise<Domains.DomainLookup>;
6
+ lookup(params: Leadmeteor.Domains.DomainLookupParams): Promise<Leadmeteor.Domains.DomainLookup>;
7
7
  }
@@ -1,9 +1,9 @@
1
1
  import type { Client } from "../client";
2
- import type { Emails } from "../types/emails";
2
+ import type { Leadmeteor } from "../types";
3
3
  export declare class EmailsResource {
4
4
  private readonly client;
5
5
  constructor(client: Client);
6
- verify(params: Emails.EmailVerificationParams): Promise<Emails.EmailVerification>;
7
- lookup(params: Emails.LookupParams): Promise<unknown>;
8
- search(params: Emails.SearchParams): Promise<unknown>;
6
+ verify(params: Leadmeteor.Emails.EmailVerificationParams): Promise<Leadmeteor.Emails.EmailVerification>;
7
+ lookup(params: Leadmeteor.Emails.LookupParams): Promise<unknown>;
8
+ search(params: Leadmeteor.Emails.SearchParams): Promise<unknown>;
9
9
  }
@@ -1,5 +1,5 @@
1
1
  import type { Client } from "../client";
2
- export declare class People {
2
+ export declare class PeopleResource {
3
3
  private readonly client;
4
4
  constructor(client: Client);
5
5
  lookup(params: Record<string, string>): Promise<unknown>;
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.People = void 0;
4
- class People {
3
+ exports.PeopleResource = void 0;
4
+ class PeopleResource {
5
5
  client;
6
6
  constructor(client) {
7
7
  this.client = client;
@@ -13,4 +13,4 @@ class People {
13
13
  return this.client.request("GET", "/v1/people/search", params);
14
14
  }
15
15
  }
16
- exports.People = People;
16
+ exports.PeopleResource = PeopleResource;
@@ -1,2 +1,60 @@
1
- export * from "./emails";
2
- //# sourceMappingURL=index.d.ts.map
1
+ export declare namespace Leadmeteor {
2
+ namespace Emails {
3
+ type EmailVerificationParams = {
4
+ email: string;
5
+ };
6
+ type EmailVerification = {
7
+ email: string;
8
+ status: string;
9
+ checks: {
10
+ format: {
11
+ status: string;
12
+ passed: boolean;
13
+ reason?: string;
14
+ };
15
+ dns: {
16
+ status: string;
17
+ passed: boolean;
18
+ reason?: string;
19
+ };
20
+ mx: {
21
+ status: string;
22
+ passed: boolean;
23
+ reason?: string;
24
+ };
25
+ smtp: {
26
+ status: string;
27
+ passed: boolean;
28
+ reason?: string;
29
+ };
30
+ };
31
+ is_disposable: boolean;
32
+ is_free_provider: boolean;
33
+ is_role_based: boolean;
34
+ id: string;
35
+ object: string;
36
+ created_at: number;
37
+ };
38
+ type LookupParams = EmailVerificationParams | {
39
+ name: string;
40
+ company: string;
41
+ } | {
42
+ linkedin_url: string;
43
+ };
44
+ type SearchParams = {
45
+ domain: string;
46
+ email?: string;
47
+ };
48
+ }
49
+ namespace Domains {
50
+ type DomainLookupParams = {
51
+ domain: string;
52
+ };
53
+ type DomainLookup = {
54
+ domain: string;
55
+ expires_at?: string;
56
+ registered_at?: string;
57
+ registrar?: string;
58
+ };
59
+ }
60
+ }
@@ -1,19 +1,3 @@
1
1
  "use strict";
2
2
  // Auto-generated from our API
3
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
4
- if (k2 === undefined) k2 = k;
5
- var desc = Object.getOwnPropertyDescriptor(m, k);
6
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
7
- desc = { enumerable: true, get: function() { return m[k]; } };
8
- }
9
- Object.defineProperty(o, k2, desc);
10
- }) : (function(o, m, k, k2) {
11
- if (k2 === undefined) k2 = k;
12
- o[k2] = m[k];
13
- }));
14
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
16
- };
17
3
  Object.defineProperty(exports, "__esModule", { value: true });
18
- __exportStar(require("./emails"), exports);
19
- //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "leadmeteor",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "Official Leadmeteor SDK for Node.js",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -14,18 +14,12 @@
14
14
  },
15
15
  "keywords": [
16
16
  "leadmeteor",
17
- "lead",
18
- "leads",
19
- "email",
20
- "emails",
21
17
  "email verification",
22
- "email checker",
23
- "email verifier",
24
- "js",
25
- "node",
26
- "sdk"
18
+ "bulk emails checker",
19
+ "leads verifier"
27
20
  ],
28
21
  "license": "MIT",
22
+ "dependencies": {},
29
23
  "devDependencies": {
30
24
  "@types/node": "^25.5.0",
31
25
  "typescript": "^5.9.3"