@dereekb/zoho 13.11.2 → 13.11.4
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/cli/index.js +2 -2
- package/cli/package.json +7 -7
- package/index.cjs.js +37 -0
- package/index.esm.js +37 -0
- package/nestjs/package.json +5 -5
- package/package.json +8 -8
- package/src/lib/accounts/accounts.d.ts +1 -0
- package/src/lib/accounts/accounts.factory.d.ts +2 -0
- package/src/lib/crm/crm.api.d.ts +5 -0
- package/src/lib/crm/crm.api.notes.d.ts +1 -0
- package/src/lib/crm/crm.api.tags.d.ts +1 -0
- package/src/lib/crm/crm.factory.d.ts +1 -0
- package/src/lib/desk/desk.api.activities.d.ts +1 -0
- package/src/lib/desk/desk.api.agents.d.ts +1 -0
- package/src/lib/desk/desk.api.contacts.d.ts +1 -0
- package/src/lib/desk/desk.api.page.d.ts +1 -0
- package/src/lib/desk/desk.api.threads.d.ts +1 -0
- package/src/lib/desk/desk.api.tickets.d.ts +2 -0
- package/src/lib/desk/desk.factory.d.ts +1 -0
- package/src/lib/recruit/recruit.api.candidates.d.ts +2 -0
- package/src/lib/recruit/recruit.api.d.ts +5 -0
- package/src/lib/recruit/recruit.api.notes.d.ts +1 -0
- package/src/lib/recruit/recruit.api.tags.d.ts +1 -0
- package/src/lib/recruit/recruit.factory.d.ts +1 -0
- package/src/lib/sign/sign.api.d.ts +1 -0
- package/src/lib/sign/sign.api.page.d.ts +1 -0
- package/src/lib/sign/sign.factory.d.ts +1 -0
- package/src/lib/zoho.api.page.d.ts +1 -0
- package/src/lib/zoho.error.api.d.ts +3 -0
- package/src/lib/zoho.limit.d.ts +1 -0
package/src/lib/crm/crm.api.d.ts
CHANGED
|
@@ -445,6 +445,7 @@ export type ZohoCrmSearchRecordsPageFactory = <T = ZohoCrmRecord>(input: ZohoCrm
|
|
|
445
445
|
* const firstPage = await fetchPage.fetchNext();
|
|
446
446
|
* const secondPage = await firstPage.fetchNext();
|
|
447
447
|
* ```
|
|
448
|
+
* @__NO_SIDE_EFFECTS__
|
|
448
449
|
*/
|
|
449
450
|
export declare function zohoCrmSearchRecordsPageFactory(context: ZohoCrmContext): ZohoCrmSearchRecordsPageFactory;
|
|
450
451
|
export interface ZohoCrmGetRelatedRecordsFunctionConfig {
|
|
@@ -505,6 +506,7 @@ export type ZohoCrmGetRelatedRecordsFunction<T = ZohoCrmRecord> = (input: ZohoCr
|
|
|
505
506
|
* ```
|
|
506
507
|
*
|
|
507
508
|
* @see https://www.zoho.com/crm/developer-guide/apiv2/get-related-records.html
|
|
509
|
+
* @__NO_SIDE_EFFECTS__
|
|
508
510
|
*/
|
|
509
511
|
export declare function zohoCrmGetRelatedRecordsFunctionFactory(context: ZohoCrmContext): ZohoCrmGetRelatedRecordsFunctionFactory;
|
|
510
512
|
/**
|
|
@@ -586,6 +588,7 @@ export type ZohoCrmGetEmailsForRecordPageFactory = FetchPageFactory<ZohoCrmGetEm
|
|
|
586
588
|
* ```
|
|
587
589
|
*
|
|
588
590
|
* @see https://www.zoho.com/crm/developer/docs/api/v8/get-email-rel-list.html
|
|
591
|
+
* @__NO_SIDE_EFFECTS__
|
|
589
592
|
*/
|
|
590
593
|
export declare function zohoCrmGetEmailsForRecordPageFactory(context: ZohoCrmContext): ZohoCrmGetEmailsForRecordPageFactory;
|
|
591
594
|
/**
|
|
@@ -659,6 +662,7 @@ export type ZohoCrmGetAttachmentsForRecordPageFactory = FetchPageFactory<ZohoCrm
|
|
|
659
662
|
* ```
|
|
660
663
|
*
|
|
661
664
|
* @see https://www.zoho.com/crm/developer-guide/apiv2/get-related-records.html
|
|
665
|
+
* @__NO_SIDE_EFFECTS__
|
|
662
666
|
*/
|
|
663
667
|
export declare function zohoCrmGetAttachmentsForRecordPageFactory(context: ZohoCrmContext): ZohoCrmGetAttachmentsForRecordPageFactory;
|
|
664
668
|
/**
|
|
@@ -856,6 +860,7 @@ export type ZohoCrmExecuteRestApiFunctionFunction = (input: ZohoCrmExecuteRestAp
|
|
|
856
860
|
* apiUrl: 'production'
|
|
857
861
|
* });
|
|
858
862
|
* ```
|
|
863
|
+
* @__NO_SIDE_EFFECTS__
|
|
859
864
|
*/
|
|
860
865
|
export declare function zohoCrmExecuteRestApiFunction(context: ZohoCrmContext): ZohoCrmExecuteRestApiFunctionFunction;
|
|
861
866
|
/**
|
|
@@ -77,6 +77,7 @@ export type ZohoCrmGetNotesForRecordPageFactory = FetchPageFactory<ZohoCrmGetNot
|
|
|
77
77
|
*
|
|
78
78
|
* @param context - Authenticated Zoho CRM context for making API calls
|
|
79
79
|
* @returns Page factory for paginating through notes for a record
|
|
80
|
+
* @__NO_SIDE_EFFECTS__
|
|
80
81
|
*/
|
|
81
82
|
export declare function zohoCrmGetNotesForRecordPageFactory(context: ZohoCrmContext): ZohoCrmGetNotesForRecordPageFactory;
|
|
82
83
|
/**
|
|
@@ -106,6 +106,7 @@ export type ZohoCrmGetTagsForModulePageFactory = (input: ZohoCrmGetTagsRequest,
|
|
|
106
106
|
*
|
|
107
107
|
* @param context - Authenticated Zoho CRM context for making API calls
|
|
108
108
|
* @returns Page factory for paginating through tags in a module
|
|
109
|
+
* @__NO_SIDE_EFFECTS__
|
|
109
110
|
*/
|
|
110
111
|
export declare function zohoCrmGetTagsForModulePageFactory(context: ZohoCrmContext): ZohoCrmGetTagsForModulePageFactory;
|
|
111
112
|
/**
|
|
@@ -54,5 +54,6 @@ export type ZohoCrmFactory = (config: ZohoCrmConfig) => ZohoCrm;
|
|
|
54
54
|
* // Use the CRM context for API calls:
|
|
55
55
|
* const { crmContext } = zohoCrm;
|
|
56
56
|
* ```
|
|
57
|
+
* @__NO_SIDE_EFFECTS__
|
|
57
58
|
*/
|
|
58
59
|
export declare function zohoCrmFactory(factoryConfig: ZohoCrmFactoryConfig): ZohoCrmFactory;
|
|
@@ -39,5 +39,6 @@ export type ZohoDeskGetTicketActivitiesPageFactory = (input: ZohoDeskGetTicketAc
|
|
|
39
39
|
*
|
|
40
40
|
* @param context - Authenticated Zoho Desk context
|
|
41
41
|
* @returns Page factory for iterating over activity results
|
|
42
|
+
* @__NO_SIDE_EFFECTS__
|
|
42
43
|
*/
|
|
43
44
|
export declare function zohoDeskGetTicketActivitiesPageFactory(context: ZohoDeskContext): ZohoDeskGetTicketActivitiesPageFactory;
|
|
@@ -87,5 +87,6 @@ export type ZohoDeskGetAgentsPageFactory = (input: ZohoDeskGetAgentsInput, optio
|
|
|
87
87
|
*
|
|
88
88
|
* @param context - Authenticated Zoho Desk context
|
|
89
89
|
* @returns Page factory for iterating over agent results
|
|
90
|
+
* @__NO_SIDE_EFFECTS__
|
|
90
91
|
*/
|
|
91
92
|
export declare function zohoDeskGetAgentsPageFactory(context: ZohoDeskContext): ZohoDeskGetAgentsPageFactory;
|
|
@@ -77,5 +77,6 @@ export type ZohoDeskGetContactsPageFactory = (input: ZohoDeskGetContactsInput, o
|
|
|
77
77
|
*
|
|
78
78
|
* @param context - Authenticated Zoho Desk context
|
|
79
79
|
* @returns Page factory for iterating over contact results
|
|
80
|
+
* @__NO_SIDE_EFFECTS__
|
|
80
81
|
*/
|
|
81
82
|
export declare function zohoDeskGetContactsPageFactory(context: ZohoDeskContext): ZohoDeskGetContactsPageFactory;
|
|
@@ -68,5 +68,6 @@ export type ZohoDeskFetchPageFetchFunction<I extends ZohoDeskPageFilter, R exten
|
|
|
68
68
|
* const secondPage = await firstPage.fetchNext();
|
|
69
69
|
* }
|
|
70
70
|
* ```
|
|
71
|
+
* @__NO_SIDE_EFFECTS__
|
|
71
72
|
*/
|
|
72
73
|
export declare function zohoDeskFetchPageFactory<I extends ZohoDeskPageFilter, R extends ZohoDeskPageResult<any>>(fetch: ZohoDeskFetchPageFetchFunction<I, R>, defaults?: Maybe<FetchPageFactoryConfigDefaults>): import("@dereekb/util/fetch").FetchPageFactory<I, R>;
|
|
@@ -56,5 +56,6 @@ export type ZohoDeskGetTicketThreadsPageFactory = (input: ZohoDeskGetTicketThrea
|
|
|
56
56
|
*
|
|
57
57
|
* @param context - Authenticated Zoho Desk context
|
|
58
58
|
* @returns Page factory for iterating over thread results
|
|
59
|
+
* @__NO_SIDE_EFFECTS__
|
|
59
60
|
*/
|
|
60
61
|
export declare function zohoDeskGetTicketThreadsPageFactory(context: ZohoDeskContext): ZohoDeskGetTicketThreadsPageFactory;
|
|
@@ -212,6 +212,7 @@ export type ZohoDeskGetTicketsPageFactory = (input: ZohoDeskGetTicketsInput, opt
|
|
|
212
212
|
*
|
|
213
213
|
* @param context - Authenticated Zoho Desk context
|
|
214
214
|
* @returns Page factory for iterating over ticket results
|
|
215
|
+
* @__NO_SIDE_EFFECTS__
|
|
215
216
|
*/
|
|
216
217
|
export declare function zohoDeskGetTicketsPageFactory(context: ZohoDeskContext): ZohoDeskGetTicketsPageFactory;
|
|
217
218
|
/**
|
|
@@ -223,5 +224,6 @@ export type ZohoDeskSearchTicketsPageFactory = (input: ZohoDeskSearchTicketsInpu
|
|
|
223
224
|
*
|
|
224
225
|
* @param context - Authenticated Zoho Desk context
|
|
225
226
|
* @returns Page factory for iterating over search results
|
|
227
|
+
* @__NO_SIDE_EFFECTS__
|
|
226
228
|
*/
|
|
227
229
|
export declare function zohoDeskSearchTicketsPageFactory(context: ZohoDeskContext): ZohoDeskSearchTicketsPageFactory;
|
|
@@ -43,5 +43,6 @@ export type ZohoDeskFactory = (config: ZohoDeskConfig) => ZohoDesk;
|
|
|
43
43
|
*
|
|
44
44
|
* @param factoryConfig - Configuration providing account credentials and optional overrides
|
|
45
45
|
* @returns A factory function that creates authenticated Zoho Desk clients
|
|
46
|
+
* @__NO_SIDE_EFFECTS__
|
|
46
47
|
*/
|
|
47
48
|
export declare function zohoDeskFactory(factoryConfig: ZohoDeskFactoryConfig): ZohoDeskFactory;
|
|
@@ -105,6 +105,7 @@ export declare function zohoRecruitSearchCandidateAssociatedJobOpeningRecords<T
|
|
|
105
105
|
*
|
|
106
106
|
* @param context - Zoho Recruit API context providing fetch and authentication
|
|
107
107
|
* @returns Page factory for iterating through associated job openings
|
|
108
|
+
* @__NO_SIDE_EFFECTS__
|
|
108
109
|
*/
|
|
109
110
|
export declare function zohoRecruitSearchCandidateAssociatedJobOpeningRecordsPageFactory<T extends ZohoRecruitRecord>(context: ZohoRecruitContext): import("@dereekb/util/fetch").FetchPageFactory<ZohoRecruitSearchCandidateAssociatedJobOpeningRecordsInput, ZohoRecruitSearchAssociatedRecordsResponse<T>>;
|
|
110
111
|
/**
|
|
@@ -125,5 +126,6 @@ export declare function zohoRecruitSearchJobOpeningAssociatedCandidateRecords<T
|
|
|
125
126
|
*
|
|
126
127
|
* @param context - Zoho Recruit API context providing fetch and authentication
|
|
127
128
|
* @returns Page factory for iterating through associated candidates
|
|
129
|
+
* @__NO_SIDE_EFFECTS__
|
|
128
130
|
*/
|
|
129
131
|
export declare function zohoRecruitSearchJobOpeningAssociatedCandidateRecordsPageFactory<T extends ZohoRecruitRecord>(context: ZohoRecruitContext): import("@dereekb/util/fetch").FetchPageFactory<ZohoRecruitSearchJobOpeningAssociatedCandidateRecordsInput, ZohoRecruitSearchAssociatedRecordsResponse<T>>;
|
|
@@ -440,6 +440,7 @@ export type ZohoRecruitSearchRecordsPageFactory = <T = ZohoRecruitRecord>(input:
|
|
|
440
440
|
* const firstPage = await fetchPage.fetchNext();
|
|
441
441
|
* const secondPage = await firstPage.fetchNext();
|
|
442
442
|
* ```
|
|
443
|
+
* @__NO_SIDE_EFFECTS__
|
|
443
444
|
*/
|
|
444
445
|
export declare function zohoRecruitSearchRecordsPageFactory(context: ZohoRecruitContext): ZohoRecruitSearchRecordsPageFactory;
|
|
445
446
|
/**
|
|
@@ -513,6 +514,7 @@ export type ZohoRecruitGetRelatedRecordsFunction<T = ZohoRecruitRecord> = (input
|
|
|
513
514
|
* ```
|
|
514
515
|
*
|
|
515
516
|
* @see https://www.zoho.com/recruit/developer-guide/apiv2/get-related-records.html
|
|
517
|
+
* @__NO_SIDE_EFFECTS__
|
|
516
518
|
*/
|
|
517
519
|
export declare function zohoRecruitGetRelatedRecordsFunctionFactory(context: ZohoRecruitContext): ZohoRecruitGetRelatedRecordsFunctionFactory;
|
|
518
520
|
/**
|
|
@@ -583,6 +585,7 @@ export type ZohoRecruitGetEmailsForRecordPageFactory = FetchPageFactory<ZohoRecr
|
|
|
583
585
|
* ```
|
|
584
586
|
*
|
|
585
587
|
* @see https://www.zoho.com/recruit/developer-guide/apiv2/get-related-records.html
|
|
588
|
+
* @__NO_SIDE_EFFECTS__
|
|
586
589
|
*/
|
|
587
590
|
export declare function zohoRecruitGetEmailsForRecordPageFactory(context: ZohoRecruitContext): ZohoRecruitGetEmailsForRecordPageFactory;
|
|
588
591
|
/**
|
|
@@ -660,6 +663,7 @@ export type ZohoRecruitGetAttachmentsForRecordPageFactory = FetchPageFactory<Zoh
|
|
|
660
663
|
* ```
|
|
661
664
|
*
|
|
662
665
|
* @see https://www.zoho.com/recruit/developer-guide/apiv2/get-related-records.html
|
|
666
|
+
* @__NO_SIDE_EFFECTS__
|
|
663
667
|
*/
|
|
664
668
|
export declare function zohoRecruitGetAttachmentsForRecordPageFactory(context: ZohoRecruitContext): ZohoRecruitGetAttachmentsForRecordPageFactory;
|
|
665
669
|
/**
|
|
@@ -929,6 +933,7 @@ export type ZohoRecruitExecuteRestApiFunctionFunction = (input: ZohoRecruitExecu
|
|
|
929
933
|
* apiUrl: 'production'
|
|
930
934
|
* });
|
|
931
935
|
* ```
|
|
936
|
+
* @__NO_SIDE_EFFECTS__
|
|
932
937
|
*/
|
|
933
938
|
export declare function zohoRecruitExecuteRestApiFunction(context: ZohoRecruitContext): ZohoRecruitExecuteRestApiFunctionFunction;
|
|
934
939
|
/**
|
|
@@ -134,6 +134,7 @@ export type ZohoRecruitGetNotesForRecordPageFactory = FetchPageFactory<ZohoRecru
|
|
|
134
134
|
*
|
|
135
135
|
* @param context - Authenticated Zoho Recruit context providing fetch and rate limiting
|
|
136
136
|
* @returns Page factory for iterating over record notes
|
|
137
|
+
* @__NO_SIDE_EFFECTS__
|
|
137
138
|
*/
|
|
138
139
|
export declare function zohoRecruitGetNotesForRecordPageFactory(context: ZohoRecruitContext): ZohoRecruitGetNotesForRecordPageFactory;
|
|
139
140
|
/**
|
|
@@ -106,6 +106,7 @@ export type ZohoRecruitGetTagsForModulePageFactory = (input: ZohoRecruitGetTagsR
|
|
|
106
106
|
*
|
|
107
107
|
* @param context - Authenticated Zoho Recruit context providing fetch and rate limiting
|
|
108
108
|
* @returns Page factory for iterating over module tags
|
|
109
|
+
* @__NO_SIDE_EFFECTS__
|
|
109
110
|
*/
|
|
110
111
|
export declare function zohoRecruitGetTagsForModulePageFactory(context: ZohoRecruitContext): ZohoRecruitGetTagsForModulePageFactory;
|
|
111
112
|
/**
|
|
@@ -54,5 +54,6 @@ export type ZohoRecruitFactory = (config: ZohoRecruitConfig) => ZohoRecruit;
|
|
|
54
54
|
* // Use the recruit context for API calls:
|
|
55
55
|
* const { recruitContext } = zohoRecruit;
|
|
56
56
|
* ```
|
|
57
|
+
* @__NO_SIDE_EFFECTS__
|
|
57
58
|
*/
|
|
58
59
|
export declare function zohoRecruitFactory(factoryConfig: ZohoRecruitFactoryConfig): ZohoRecruitFactory;
|
|
@@ -102,6 +102,7 @@ export declare function zohoSignGetDocuments(context: ZohoSignContext): ZohoSign
|
|
|
102
102
|
* const firstPage = await fetchPage.fetchNext();
|
|
103
103
|
* const secondPage = await firstPage.fetchNext();
|
|
104
104
|
* ```
|
|
105
|
+
* @__NO_SIDE_EFFECTS__
|
|
105
106
|
*/
|
|
106
107
|
export declare function zohoSignGetDocumentsPageFactory(context: ZohoSignContext): import("@dereekb/util/fetch").FetchPageFactory<ZohoSignGetDocumentsInput, ZohoSignGetDocumentsResponse>;
|
|
107
108
|
export interface ZohoSignGetDocumentFormDataInput {
|
|
@@ -105,5 +105,6 @@ export type ZohoSignFetchPageFetchFunction<I extends ZohoSignPageFilter, R exten
|
|
|
105
105
|
* const secondPage = await firstPage.fetchNext();
|
|
106
106
|
* }
|
|
107
107
|
* ```
|
|
108
|
+
* @__NO_SIDE_EFFECTS__
|
|
108
109
|
*/
|
|
109
110
|
export declare function zohoSignFetchPageFactory<I extends ZohoSignPageFilter, R extends ZohoSignPageResult<any>>(fetch: ZohoSignFetchPageFetchFunction<I, R>, defaults?: Maybe<FetchPageFactoryConfigDefaults>): import("@dereekb/util/fetch").FetchPageFactory<I, R>;
|
|
@@ -54,5 +54,6 @@ export type ZohoSignFactory = (config: ZohoSignConfig) => ZohoSign;
|
|
|
54
54
|
* // Use the sign context for API calls:
|
|
55
55
|
* const { signContext } = zohoSign;
|
|
56
56
|
* ```
|
|
57
|
+
* @__NO_SIDE_EFFECTS__
|
|
57
58
|
*/
|
|
58
59
|
export declare function zohoSignFactory(factoryConfig: ZohoSignFactoryConfig): ZohoSignFactory;
|
|
@@ -91,5 +91,6 @@ export type ZohoFetchPageFetchFunction<I extends ZohoPageFilter, R extends ZohoP
|
|
|
91
91
|
* const secondPage = await firstPage.fetchNext();
|
|
92
92
|
* }
|
|
93
93
|
* ```
|
|
94
|
+
* @__NO_SIDE_EFFECTS__
|
|
94
95
|
*/
|
|
95
96
|
export declare function zohoFetchPageFactory<I extends ZohoPageFilter, R extends ZohoPageResult<any>>(fetch: ZohoFetchPageFetchFunction<I, R>, defaults?: Maybe<FetchPageFactoryConfigDefaults>): import("@dereekb/util/fetch").FetchPageFactory<I, R>;
|
|
@@ -126,6 +126,7 @@ export interface LogZohoServerErrorFunctionConfig {
|
|
|
126
126
|
* @param zohoApiNamePrefix - Prefix to use when logging (e.g. 'ZohoRecruit', 'ZohoSign')
|
|
127
127
|
* @param options - Optional configuration for controlling which error types are logged
|
|
128
128
|
* @returns A function that logs Zoho server errors to the console
|
|
129
|
+
* @__NO_SIDE_EFFECTS__
|
|
129
130
|
*/
|
|
130
131
|
export declare function logZohoServerErrorFunction(zohoApiNamePrefix: string, options?: LogZohoServerErrorFunctionConfig): LogZohoServerErrorFunction;
|
|
131
132
|
/**
|
|
@@ -143,6 +144,7 @@ export type ParseZohoFetchResponseErrorFunction = (responseError: FetchResponseE
|
|
|
143
144
|
* @param parseZohoError - Function that parses a fetch response error into a Zoho-specific error
|
|
144
145
|
* @param defaultLogError - Default error logging function used when no custom logger is provided
|
|
145
146
|
* @returns Factory that wraps a ConfiguredFetch with Zoho error handling
|
|
147
|
+
* @__NO_SIDE_EFFECTS__
|
|
146
148
|
*/
|
|
147
149
|
export declare function handleZohoErrorFetchFactory(parseZohoError: ParseZohoFetchResponseErrorFunction, defaultLogError: LogZohoServerErrorFunction): HandleZohoErrorFetchFactory;
|
|
148
150
|
export type ParseZohoServerErrorResponseData = (zohoServerErrorResponseData: ZohoServerErrorResponseData, fetchResponseError: FetchResponseError) => ParsedZohoServerError;
|
|
@@ -151,6 +153,7 @@ export type ParseZohoServerErrorResponseData = (zohoServerErrorResponseData: Zoh
|
|
|
151
153
|
*
|
|
152
154
|
* @param parseZohoServerErrorResponseData - Function that parses raw error response data into a structured error
|
|
153
155
|
* @returns Interceptor function that detects and throws hidden errors in 200 responses
|
|
156
|
+
* @__NO_SIDE_EFFECTS__
|
|
154
157
|
*/
|
|
155
158
|
export declare function interceptZohoErrorResponseFactory(parseZohoServerErrorResponseData: ParseZohoServerErrorResponseData): FetchJsonInterceptJsonResponseFunction;
|
|
156
159
|
/**
|
package/src/lib/zoho.limit.d.ts
CHANGED
|
@@ -112,6 +112,7 @@ export interface MakeZohoRateLimitedFetchHandlerConfig extends ZohoRateLimitedFe
|
|
|
112
112
|
*
|
|
113
113
|
* @param config - Configuration including the service-specific header reader, rate limit, reset period, and 429 handling
|
|
114
114
|
* @returns A rate-limited fetch handler with the underlying rate limiter accessible via `_rateLimiter`
|
|
115
|
+
* @__NO_SIDE_EFFECTS__
|
|
115
116
|
*/
|
|
116
117
|
export declare function makeZohoRateLimitedFetchHandler(config: MakeZohoRateLimitedFetchHandlerConfig): ZohoRateLimitedFetchHandler;
|
|
117
118
|
/**
|