@voltade/envoy-sdk 1.2.9 → 1.2.10
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/client.d.ts +1 -5
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +1 -2
- package/dist/client.js.map +1 -1
- package/dist/resources/companies/index.d.ts +6 -0
- package/dist/resources/companies/index.d.ts.map +1 -1
- package/dist/resources/companies/index.js +5 -0
- package/dist/resources/companies/index.js.map +1 -1
- package/dist/resources/companies/types.d.ts +14 -14
- package/dist/resources/company-members/index.d.ts +3 -3
- package/dist/resources/company-members/index.d.ts.map +1 -1
- package/dist/resources/company-members/index.js +6 -6
- package/dist/resources/company-members/index.js.map +1 -1
- package/dist/resources/company-members/types.d.ts +4 -4
- package/dist/resources/conversations/types.d.ts +105 -105
- package/dist/resources/inboxes/types.d.ts +6 -6
- package/dist/resources/orders/types.d.ts +7 -7
- package/dist/resources/webhooks/types.d.ts +766 -766
- package/package.json +1 -1
package/dist/client.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { HttpClient } from "./http-client.js";
|
|
2
|
-
import { Companies,
|
|
2
|
+
import { Companies, Conversations, Inboxes, Orders } from "./resources/index.js";
|
|
3
3
|
/**
|
|
4
4
|
* Configuration options for EnvoyClient
|
|
5
5
|
*/
|
|
@@ -43,10 +43,6 @@ export declare class EnvoyClient {
|
|
|
43
43
|
* Companies resource for managing companies
|
|
44
44
|
*/
|
|
45
45
|
readonly companies: Companies;
|
|
46
|
-
/**
|
|
47
|
-
* Company Members resource for managing contacts within companies
|
|
48
|
-
*/
|
|
49
|
-
readonly companyMembers: CompanyMembers;
|
|
50
46
|
/**
|
|
51
47
|
* Conversations resource for managing conversations and messages
|
|
52
48
|
*/
|
package/dist/client.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAyB,MAAM,kBAAkB,CAAC;AACrE,OAAO,EACL,SAAS,EACT,
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAyB,MAAM,kBAAkB,CAAC;AACrE,OAAO,EACL,SAAS,EACT,aAAa,EACb,OAAO,EACP,MAAM,EACP,MAAM,sBAAsB,CAAC;AAE9B;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,qBAAa,WAAW;IACtB,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAa;IAExC;;OAEG;IACH,SAAgB,SAAS,EAAE,SAAS,CAAC;IAErC;;OAEG;IACH,SAAgB,aAAa,EAAE,aAAa,CAAC;IAE7C;;OAEG;IACH,SAAgB,OAAO,EAAE,OAAO,CAAC;IAEjC;;OAEG;IACH,SAAgB,MAAM,EAAE,MAAM,CAAC;gBAEnB,MAAM,EAAE,iBAAiB;IAcrC;;;OAGG;IACH,aAAa,IAAI,UAAU;CAG5B"}
|
package/dist/client.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { HttpClient } from "./http-client.js";
|
|
2
|
-
import { Companies,
|
|
2
|
+
import { Companies, Conversations, Inboxes, Orders, } from "./resources/index.js";
|
|
3
3
|
/**
|
|
4
4
|
* Envoy API Client
|
|
5
5
|
* A comprehensive SDK for interacting with the Envoy API
|
|
@@ -36,7 +36,6 @@ export class EnvoyClient {
|
|
|
36
36
|
this.httpClient = new HttpClient(httpConfig);
|
|
37
37
|
// Initialize resources
|
|
38
38
|
this.companies = new Companies(this.httpClient);
|
|
39
|
-
this.companyMembers = new CompanyMembers(this.httpClient);
|
|
40
39
|
this.conversations = new Conversations(this.httpClient);
|
|
41
40
|
this.inboxes = new Inboxes(this.httpClient);
|
|
42
41
|
this.orders = new Orders(this.httpClient);
|
package/dist/client.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAyB,MAAM,kBAAkB,CAAC;AACrE,OAAO,EACL,SAAS,EACT,
|
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAyB,MAAM,kBAAkB,CAAC;AACrE,OAAO,EACL,SAAS,EACT,aAAa,EACb,OAAO,EACP,MAAM,GACP,MAAM,sBAAsB,CAAC;AAY9B;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,MAAM,OAAO,WAAW;IAuBtB,YAAY,MAAyB;QACnC,MAAM,UAAU,GAAqB;YACnC,GAAG,MAAM;SACV,CAAC;QAEF,IAAI,CAAC,UAAU,GAAG,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC;QAE7C,uBAAuB;QACvB,IAAI,CAAC,SAAS,GAAG,IAAI,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QAChD,IAAI,CAAC,aAAa,GAAG,IAAI,aAAa,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QACxD,IAAI,CAAC,OAAO,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QAC5C,IAAI,CAAC,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;IAC5C,CAAC;IAED;;;OAGG;IACH,aAAa;QACX,OAAO,IAAI,CAAC,UAAU,CAAC;IACzB,CAAC;CACF"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Provides functionality for managing companies in Envoy
|
|
4
4
|
*/
|
|
5
5
|
import type { HttpClient } from "../../http-client.js";
|
|
6
|
+
import { CompanyMembers } from "../company-members/index.js";
|
|
6
7
|
import type { CreateCompanyParams, CreateCompanyResponse, GetCompanyResponse, ListCompaniesParams, ListCompaniesResponse, SearchCompaniesResponse, UpdateCompanyParams, UpdateCompanyResponse } from "./types.js";
|
|
7
8
|
/**
|
|
8
9
|
* Base resource class that all resource classes extend from
|
|
@@ -15,6 +16,11 @@ declare abstract class BaseResource {
|
|
|
15
16
|
* Companies resource class for managing company-related operations
|
|
16
17
|
*/
|
|
17
18
|
export declare class Companies extends BaseResource {
|
|
19
|
+
/**
|
|
20
|
+
* Members sub-resource for managing contacts within companies
|
|
21
|
+
*/
|
|
22
|
+
readonly members: CompanyMembers;
|
|
23
|
+
constructor(client: HttpClient);
|
|
18
24
|
/**
|
|
19
25
|
* List all companies
|
|
20
26
|
* @param params - Pagination parameters
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../resources/companies/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,KAAK,EACV,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,YAAY,CAAC;AAEpB;;GAEG;AACH,uBAAe,YAAY;IACb,SAAS,CAAC,QAAQ,CAAC,MAAM,EAAE,UAAU;gBAAlB,MAAM,EAAE,UAAU;CAClD;AAED;;GAEG;AACH,qBAAa,SAAU,SAAQ,YAAY;IACzC;;;;;;;;;;;;;OAaG;IACG,IAAI,CAAC,MAAM,CAAC,EAAE,mBAAmB,GAAG,OAAO,CAAC,qBAAqB,CAAC;IAMxE;;;;;;;;;;;;OAYG;IACG,MAAM,CAAC,MAAM,EAAE,mBAAmB,GAAG,OAAO,CAAC,qBAAqB,CAAC;IAMzE;;;;;;;;;;OAUG;IACG,GAAG,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,kBAAkB,CAAC;IAIzD;;;;;;;;;;;;;OAaG;IACG,MAAM,CACV,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,mBAAmB,GAC1B,OAAO,CAAC,qBAAqB,CAAC;IAOjC;;;;;;;;;;;;;;OAcG;IACG,MAAM,CACV,KAAK,EAAE,MAAM,EACb,MAAM,CAAC,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;KAAE,GAC5C,OAAO,CAAC,uBAAuB,CAAC;IAMnC;;;;;;;;OAQG;IACG,MAAM,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAG/C;AAGD,YAAY,EACV,OAAO,EACP,mBAAmB,EACnB,oBAAoB,EACpB,qBAAqB,EACrB,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,aAAa,EACb,yBAAyB,EACzB,0BAA0B,EAC1B,2BAA2B,EAC3B,wBAAwB,EACxB,yBAAyB,EACzB,2BAA2B,EAC3B,2BAA2B,EAC3B,6BAA6B,EAC7B,yBAAyB,EACzB,0BAA0B,EAC1B,2BAA2B,GAC5B,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../resources/companies/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AACvD,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAC7D,OAAO,KAAK,EACV,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,EAClB,mBAAmB,EACnB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB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B,2BAA2B,EAC3B,wBAAwB,EACxB,yBAAyB,EACzB,2BAA2B,EAC3B,2BAA2B,EAC3B,6BAA6B,EAC7B,yBAAyB,EACzB,0BAA0B,EAC1B,2BAA2B,GAC5B,MAAM,YAAY,CAAC"}
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
* Companies resource module
|
|
3
3
|
* Provides functionality for managing companies in Envoy
|
|
4
4
|
*/
|
|
5
|
+
import { CompanyMembers } from "../company-members/index.js";
|
|
5
6
|
/**
|
|
6
7
|
* Base resource class that all resource classes extend from
|
|
7
8
|
*/
|
|
@@ -14,6 +15,10 @@ class BaseResource {
|
|
|
14
15
|
* Companies resource class for managing company-related operations
|
|
15
16
|
*/
|
|
16
17
|
export class Companies extends BaseResource {
|
|
18
|
+
constructor(client) {
|
|
19
|
+
super(client);
|
|
20
|
+
this.members = new CompanyMembers(client);
|
|
21
|
+
}
|
|
17
22
|
/**
|
|
18
23
|
* List all companies
|
|
19
24
|
* @param params - Pagination parameters
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../resources/companies/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../resources/companies/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAY7D;;GAEG;AACH,MAAe,YAAY;IACzB,YAA+B,MAAkB;QAAlB,WAAM,GAAN,MAAM,CAAY;IAAG,CAAC;CACtD;AAED;;GAEG;AACH,MAAM,OAAO,SAAU,SAAQ,YAAY;IAMzC,YAAY,MAAkB;QAC5B,KAAK,CAAC,MAAM,CAAC,CAAC;QACd,IAAI,CAAC,OAAO,GAAG,IAAI,cAAc,CAAC,MAAM,CAAC,CAAC;IAC5C,CAAC;IACD;;;;;;;;;;;;;OAaG;IACH,KAAK,CAAC,IAAI,CAAC,MAA4B;QACrC,OAAO,M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,GAC5B,MAAM,YAAY,CAAC"}
|
|
@@ -24,9 +24,9 @@ export declare const CompanySchema: z.ZodObject<{
|
|
|
24
24
|
}, "strip", z.ZodTypeAny, {
|
|
25
25
|
id: number;
|
|
26
26
|
name: string;
|
|
27
|
-
account_id?: number | undefined;
|
|
28
27
|
created_at?: number | undefined;
|
|
29
28
|
updated_at?: number | undefined;
|
|
29
|
+
account_id?: number | undefined;
|
|
30
30
|
contacts?: {
|
|
31
31
|
id: number;
|
|
32
32
|
name?: string | undefined;
|
|
@@ -36,9 +36,9 @@ export declare const CompanySchema: z.ZodObject<{
|
|
|
36
36
|
}, {
|
|
37
37
|
id: number;
|
|
38
38
|
name: string;
|
|
39
|
-
account_id?: number | undefined;
|
|
40
39
|
created_at?: number | undefined;
|
|
41
40
|
updated_at?: number | undefined;
|
|
41
|
+
account_id?: number | undefined;
|
|
42
42
|
contacts?: {
|
|
43
43
|
id: number;
|
|
44
44
|
name?: string | undefined;
|
|
@@ -81,9 +81,9 @@ export declare const ListCompaniesResponseSchema: z.ZodArray<z.ZodObject<{
|
|
|
81
81
|
}, "strip", z.ZodTypeAny, {
|
|
82
82
|
id: number;
|
|
83
83
|
name: string;
|
|
84
|
-
account_id?: number | undefined;
|
|
85
84
|
created_at?: number | undefined;
|
|
86
85
|
updated_at?: number | undefined;
|
|
86
|
+
account_id?: number | undefined;
|
|
87
87
|
contacts?: {
|
|
88
88
|
id: number;
|
|
89
89
|
name?: string | undefined;
|
|
@@ -93,9 +93,9 @@ export declare const ListCompaniesResponseSchema: z.ZodArray<z.ZodObject<{
|
|
|
93
93
|
}, {
|
|
94
94
|
id: number;
|
|
95
95
|
name: string;
|
|
96
|
-
account_id?: number | undefined;
|
|
97
96
|
created_at?: number | undefined;
|
|
98
97
|
updated_at?: number | undefined;
|
|
98
|
+
account_id?: number | undefined;
|
|
99
99
|
contacts?: {
|
|
100
100
|
id: number;
|
|
101
101
|
name?: string | undefined;
|
|
@@ -152,9 +152,9 @@ export declare const CreateCompanyResponseSchema: z.ZodObject<{
|
|
|
152
152
|
}, "strip", z.ZodTypeAny, {
|
|
153
153
|
id: number;
|
|
154
154
|
name: string;
|
|
155
|
-
account_id?: number | undefined;
|
|
156
155
|
created_at?: number | undefined;
|
|
157
156
|
updated_at?: number | undefined;
|
|
157
|
+
account_id?: number | undefined;
|
|
158
158
|
contacts?: {
|
|
159
159
|
id: number;
|
|
160
160
|
name?: string | undefined;
|
|
@@ -164,9 +164,9 @@ export declare const CreateCompanyResponseSchema: z.ZodObject<{
|
|
|
164
164
|
}, {
|
|
165
165
|
id: number;
|
|
166
166
|
name: string;
|
|
167
|
-
account_id?: number | undefined;
|
|
168
167
|
created_at?: number | undefined;
|
|
169
168
|
updated_at?: number | undefined;
|
|
169
|
+
account_id?: number | undefined;
|
|
170
170
|
contacts?: {
|
|
171
171
|
id: number;
|
|
172
172
|
name?: string | undefined;
|
|
@@ -199,9 +199,9 @@ export declare const GetCompanyResponseSchema: z.ZodObject<{
|
|
|
199
199
|
}, "strip", z.ZodTypeAny, {
|
|
200
200
|
id: number;
|
|
201
201
|
name: string;
|
|
202
|
-
account_id?: number | undefined;
|
|
203
202
|
created_at?: number | undefined;
|
|
204
203
|
updated_at?: number | undefined;
|
|
204
|
+
account_id?: number | undefined;
|
|
205
205
|
contacts?: {
|
|
206
206
|
id: number;
|
|
207
207
|
name?: string | undefined;
|
|
@@ -211,9 +211,9 @@ export declare const GetCompanyResponseSchema: z.ZodObject<{
|
|
|
211
211
|
}, {
|
|
212
212
|
id: number;
|
|
213
213
|
name: string;
|
|
214
|
-
account_id?: number | undefined;
|
|
215
214
|
created_at?: number | undefined;
|
|
216
215
|
updated_at?: number | undefined;
|
|
216
|
+
account_id?: number | undefined;
|
|
217
217
|
contacts?: {
|
|
218
218
|
id: number;
|
|
219
219
|
name?: string | undefined;
|
|
@@ -270,9 +270,9 @@ export declare const UpdateCompanyResponseSchema: z.ZodObject<{
|
|
|
270
270
|
}, "strip", z.ZodTypeAny, {
|
|
271
271
|
id: number;
|
|
272
272
|
name: string;
|
|
273
|
-
account_id?: number | undefined;
|
|
274
273
|
created_at?: number | undefined;
|
|
275
274
|
updated_at?: number | undefined;
|
|
275
|
+
account_id?: number | undefined;
|
|
276
276
|
contacts?: {
|
|
277
277
|
id: number;
|
|
278
278
|
name?: string | undefined;
|
|
@@ -282,9 +282,9 @@ export declare const UpdateCompanyResponseSchema: z.ZodObject<{
|
|
|
282
282
|
}, {
|
|
283
283
|
id: number;
|
|
284
284
|
name: string;
|
|
285
|
-
account_id?: number | undefined;
|
|
286
285
|
created_at?: number | undefined;
|
|
287
286
|
updated_at?: number | undefined;
|
|
287
|
+
account_id?: number | undefined;
|
|
288
288
|
contacts?: {
|
|
289
289
|
id: number;
|
|
290
290
|
name?: string | undefined;
|
|
@@ -351,9 +351,9 @@ export declare const SearchCompaniesResponseSchema: z.ZodObject<{
|
|
|
351
351
|
}, "strip", z.ZodTypeAny, {
|
|
352
352
|
id: number;
|
|
353
353
|
name: string;
|
|
354
|
-
account_id?: number | undefined;
|
|
355
354
|
created_at?: number | undefined;
|
|
356
355
|
updated_at?: number | undefined;
|
|
356
|
+
account_id?: number | undefined;
|
|
357
357
|
contacts?: {
|
|
358
358
|
id: number;
|
|
359
359
|
name?: string | undefined;
|
|
@@ -363,9 +363,9 @@ export declare const SearchCompaniesResponseSchema: z.ZodObject<{
|
|
|
363
363
|
}, {
|
|
364
364
|
id: number;
|
|
365
365
|
name: string;
|
|
366
|
-
account_id?: number | undefined;
|
|
367
366
|
created_at?: number | undefined;
|
|
368
367
|
updated_at?: number | undefined;
|
|
368
|
+
account_id?: number | undefined;
|
|
369
369
|
contacts?: {
|
|
370
370
|
id: number;
|
|
371
371
|
name?: string | undefined;
|
|
@@ -381,9 +381,9 @@ export declare const SearchCompaniesResponseSchema: z.ZodObject<{
|
|
|
381
381
|
payload: {
|
|
382
382
|
id: number;
|
|
383
383
|
name: string;
|
|
384
|
-
account_id?: number | undefined;
|
|
385
384
|
created_at?: number | undefined;
|
|
386
385
|
updated_at?: number | undefined;
|
|
386
|
+
account_id?: number | undefined;
|
|
387
387
|
contacts?: {
|
|
388
388
|
id: number;
|
|
389
389
|
name?: string | undefined;
|
|
@@ -399,9 +399,9 @@ export declare const SearchCompaniesResponseSchema: z.ZodObject<{
|
|
|
399
399
|
payload: {
|
|
400
400
|
id: number;
|
|
401
401
|
name: string;
|
|
402
|
-
account_id?: number | undefined;
|
|
403
402
|
created_at?: number | undefined;
|
|
404
403
|
updated_at?: number | undefined;
|
|
404
|
+
account_id?: number | undefined;
|
|
405
405
|
contacts?: {
|
|
406
406
|
id: number;
|
|
407
407
|
name?: string | undefined;
|
|
@@ -22,7 +22,7 @@ export declare class CompanyMembers extends BaseResource {
|
|
|
22
22
|
*
|
|
23
23
|
* @example
|
|
24
24
|
* ```typescript
|
|
25
|
-
* const members = await client.
|
|
25
|
+
* const members = await client.companies.members.list(456);
|
|
26
26
|
* console.log(members); // Array of contacts
|
|
27
27
|
* ```
|
|
28
28
|
*/
|
|
@@ -35,7 +35,7 @@ export declare class CompanyMembers extends BaseResource {
|
|
|
35
35
|
*
|
|
36
36
|
* @example
|
|
37
37
|
* ```typescript
|
|
38
|
-
* const members = await client.
|
|
38
|
+
* const members = await client.companies.members.add(456, {
|
|
39
39
|
* contact_ids: [101, 102, 103]
|
|
40
40
|
* });
|
|
41
41
|
* console.log(members); // Array of added contacts
|
|
@@ -49,7 +49,7 @@ export declare class CompanyMembers extends BaseResource {
|
|
|
49
49
|
*
|
|
50
50
|
* @example
|
|
51
51
|
* ```typescript
|
|
52
|
-
* await client.
|
|
52
|
+
* await client.companies.members.remove(456, {
|
|
53
53
|
* contact_ids: [101, 102]
|
|
54
54
|
* });
|
|
55
55
|
* ```
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../resources/company-members/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,M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rC;;;;;;;;;;;OAWG;IACG,MAAM,CACV,SAAS,EAAE,MAAM,EACjB,MAAM,EAAE,0BAA0B,GACjC,OAAO,CAAC,IAAI,CAAC;CAGjB;AAGD,YAAY,EACV,uBAAuB,EACvB,yBAAyB,EACzB,0BAA0B,EAC1B,0BAA0B,GAC3B,MAAM,YAAY,CAAC;AAGpB,OAAO,EACL,6BAA6B,EAC7B,+BAA+B,EAC/B,gCAAgC,EAChC,gCAAgC,GACjC,MAAM,YAAY,CAAC"}
|
|
@@ -21,12 +21,12 @@ export class CompanyMembers extends BaseResource {
|
|
|
21
21
|
*
|
|
22
22
|
* @example
|
|
23
23
|
* ```typescript
|
|
24
|
-
* const members = await client.
|
|
24
|
+
* const members = await client.companies.members.list(456);
|
|
25
25
|
* console.log(members); // Array of contacts
|
|
26
26
|
* ```
|
|
27
27
|
*/
|
|
28
28
|
async list(companyId) {
|
|
29
|
-
return await this.client.get(`/companies/${companyId}/
|
|
29
|
+
return await this.client.get(`/companies/${companyId}/members`);
|
|
30
30
|
}
|
|
31
31
|
/**
|
|
32
32
|
* Add contacts to a company
|
|
@@ -36,14 +36,14 @@ export class CompanyMembers extends BaseResource {
|
|
|
36
36
|
*
|
|
37
37
|
* @example
|
|
38
38
|
* ```typescript
|
|
39
|
-
* const members = await client.
|
|
39
|
+
* const members = await client.companies.members.add(456, {
|
|
40
40
|
* contact_ids: [101, 102, 103]
|
|
41
41
|
* });
|
|
42
42
|
* console.log(members); // Array of added contacts
|
|
43
43
|
* ```
|
|
44
44
|
*/
|
|
45
45
|
async add(companyId, params) {
|
|
46
|
-
return await this.client.post(`/companies/${companyId}/
|
|
46
|
+
return await this.client.post(`/companies/${companyId}/members`, params);
|
|
47
47
|
}
|
|
48
48
|
/**
|
|
49
49
|
* Remove contacts from a company
|
|
@@ -52,13 +52,13 @@ export class CompanyMembers extends BaseResource {
|
|
|
52
52
|
*
|
|
53
53
|
* @example
|
|
54
54
|
* ```typescript
|
|
55
|
-
* await client.
|
|
55
|
+
* await client.companies.members.remove(456, {
|
|
56
56
|
* contact_ids: [101, 102]
|
|
57
57
|
* });
|
|
58
58
|
* ```
|
|
59
59
|
*/
|
|
60
60
|
async remove(companyId, params) {
|
|
61
|
-
await this.client.delete(`/companies/${companyId}/
|
|
61
|
+
await this.client.delete(`/companies/${companyId}/members`, params);
|
|
62
62
|
}
|
|
63
63
|
}
|
|
64
64
|
// Re-export Zod schemas
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../resources/company-members/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAUH;;GAEG;AACH,MAAe,YAAY;IACzB,YAA+B,MAAkB;QAAlB,WAAM,GAAN,MAAM,CAAY;IAAG,CAAC;CACtD;AAED;;GAEG;AACH,MAAM,OAAO,cAAe,SAAQ,YAAY;IAC9C;;;;;;;;;;OAUG;IACH,KAAK,CAAC,IAAI,CAAC,SAAiB;QAC1B,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAC1B,cAAc,SAAS,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../resources/company-members/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAUH;;GAEG;AACH,MAAe,YAAY;IACzB,YAA+B,MAAkB;QAAlB,WAAM,GAAN,MAAM,CAAY;IAAG,CAAC;CACtD;AAED;;GAEG;AACH,MAAM,OAAO,cAAe,SAAQ,YAAY;IAC9C;;;;;;;;;;OAUG;IACH,KAAK,CAAC,IAAI,CAAC,SAAiB;QAC1B,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,CAC1B,cAAc,SAAS,UAAU,CAClC,CAAC;IACJ,CAAC;IAED;;;;;;;;;;;;;OAaG;IACH,KAAK,CAAC,GAAG,CACP,SAAiB,EACjB,MAA+B;QAE/B,OAAO,MAAM,IAAI,CAAC,MAAM,CAAC,IAAI,CAC3B,cAAc,SAAS,UAAU,EACjC,MAAM,CACP,CAAC;IACJ,CAAC;IAED;;;;;;;;;;;OAWG;IACH,KAAK,CAAC,MAAM,CACV,SAAiB,EACjB,MAAkC;QAElC,MAAM,IAAI,CAAC,MAAM,CAAC,MAAM,CAAO,cAAc,SAAS,UAAU,EAAE,MAAM,CAAC,CAAC;IAC5E,CAAC;CACF;AAUD,wBAAwB;AACxB,OAAO,EACL,6BAA6B,EAC7B,+BAA+B,EAC/B,gCAAgC,EAChC,gCAAgC,GACjC,MAAM,YAAY,CAAC"}
|
|
@@ -20,8 +20,8 @@ export declare const ListCompanyMembersResponseSchema: z.ZodArray<z.ZodObject<{
|
|
|
20
20
|
id: number;
|
|
21
21
|
name: string | null;
|
|
22
22
|
email: string | null;
|
|
23
|
-
phone_number: string | null;
|
|
24
23
|
thumbnail: string;
|
|
24
|
+
phone_number: string | null;
|
|
25
25
|
identifier: string | null;
|
|
26
26
|
additional_attributes: Record<string, unknown>;
|
|
27
27
|
custom_attributes: Record<string, unknown>;
|
|
@@ -33,8 +33,8 @@ export declare const ListCompanyMembersResponseSchema: z.ZodArray<z.ZodObject<{
|
|
|
33
33
|
id: number;
|
|
34
34
|
name: string | null;
|
|
35
35
|
email: string | null;
|
|
36
|
-
phone_number: string | null;
|
|
37
36
|
thumbnail: string;
|
|
37
|
+
phone_number: string | null;
|
|
38
38
|
identifier: string | null;
|
|
39
39
|
additional_attributes: Record<string, unknown>;
|
|
40
40
|
custom_attributes: Record<string, unknown>;
|
|
@@ -67,8 +67,8 @@ export declare const AddCompanyMembersResponseSchema: z.ZodArray<z.ZodObject<{
|
|
|
67
67
|
id: number;
|
|
68
68
|
name: string | null;
|
|
69
69
|
email: string | null;
|
|
70
|
-
phone_number: string | null;
|
|
71
70
|
thumbnail: string;
|
|
71
|
+
phone_number: string | null;
|
|
72
72
|
identifier: string | null;
|
|
73
73
|
additional_attributes: Record<string, unknown>;
|
|
74
74
|
custom_attributes: Record<string, unknown>;
|
|
@@ -80,8 +80,8 @@ export declare const AddCompanyMembersResponseSchema: z.ZodArray<z.ZodObject<{
|
|
|
80
80
|
id: number;
|
|
81
81
|
name: string | null;
|
|
82
82
|
email: string | null;
|
|
83
|
-
phone_number: string | null;
|
|
84
83
|
thumbnail: string;
|
|
84
|
+
phone_number: string | null;
|
|
85
85
|
identifier: string | null;
|
|
86
86
|
additional_attributes: Record<string, unknown>;
|
|
87
87
|
custom_attributes: Record<string, unknown>;
|