woodsportal-client-sdk 1.1.4-dev.56 → 1.1.4-dev.57
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/README.md +16 -0
- package/dist/adapters/angular/index.js +2 -2
- package/dist/adapters/react/index.js +2 -2
- package/dist/adapters/vue/index.js +2 -2
- package/dist/{chunk-YSASAXVN.js → chunk-HSJU2Z2S.js} +222 -5
- package/dist/chunk-HSJU2Z2S.js.map +1 -0
- package/dist/{chunk-XZM2KSXY.js → chunk-YQLDJJ5M.js} +3 -3
- package/dist/{chunk-XZM2KSXY.js.map → chunk-YQLDJJ5M.js.map} +1 -1
- package/dist/index.d.ts +97 -1
- package/dist/index.js +1 -1
- package/package.json +2 -1
- package/dist/chunk-YSASAXVN.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { uploaderStore, actions2, syncStore, actions5, emailStore, actions4, noteStore, actions3, multiObjectStore, actions6, tableStore, actions } from './chunk-
|
|
1
|
+
import { uploaderStore, actions2, syncStore, actions5, emailStore, actions4, noteStore, actions3, multiObjectStore, actions6, tableStore, actions } from './chunk-HSJU2Z2S.js';
|
|
2
2
|
|
|
3
3
|
// src/adapters/shared/createAdapterHooks.ts
|
|
4
4
|
function createAdapterHooks(createComposable) {
|
|
@@ -13,5 +13,5 @@ function createAdapterHooks(createComposable) {
|
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
export { createAdapterHooks };
|
|
16
|
-
//# sourceMappingURL=chunk-
|
|
17
|
-
//# sourceMappingURL=chunk-
|
|
16
|
+
//# sourceMappingURL=chunk-YQLDJJ5M.js.map
|
|
17
|
+
//# sourceMappingURL=chunk-YQLDJJ5M.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/adapters/shared/createAdapterHooks.ts"],"names":["actions"],"mappings":";;;AA0BO,SAAS,mBAAmB,gBAAA,EAAqC;AACpE,EAAA,OAAO;AAAA,IACH,QAAA,EAAU,gBAAA,CAAkD,UAAA,EAAY,OAAY,CAAA;AAAA,IACpF,qBAAA,EAAuB,gBAAA,CAAiB,gBAAA,EAAkBA,QAAkB,CAAA;AAAA,IAC5E,OAAA,EAAS,gBAAA,CAAgD,SAAA,EAAWA,QAAW,CAAA;AAAA,IAC/E,QAAA,EAAU,gBAAA,CAAkD,UAAA,EAAYA,QAAY,CAAA;AAAA,IACpF,OAAA,EAAS,gBAAA,CAAgD,SAAA,EAAWA,QAAW,CAAA;AAAA,IAC/E,WAAA,EAAa,gBAAA,CAAwD,aAAA,EAAeA,QAAe;AAAA,GACvG;AACJ","file":"chunk-
|
|
1
|
+
{"version":3,"sources":["../src/adapters/shared/createAdapterHooks.ts"],"names":["actions"],"mappings":";;;AA0BO,SAAS,mBAAmB,gBAAA,EAAqC;AACpE,EAAA,OAAO;AAAA,IACH,QAAA,EAAU,gBAAA,CAAkD,UAAA,EAAY,OAAY,CAAA;AAAA,IACpF,qBAAA,EAAuB,gBAAA,CAAiB,gBAAA,EAAkBA,QAAkB,CAAA;AAAA,IAC5E,OAAA,EAAS,gBAAA,CAAgD,SAAA,EAAWA,QAAW,CAAA;AAAA,IAC/E,QAAA,EAAU,gBAAA,CAAkD,UAAA,EAAYA,QAAY,CAAA;AAAA,IACpF,OAAA,EAAS,gBAAA,CAAgD,SAAA,EAAWA,QAAW,CAAA;AAAA,IAC/E,WAAA,EAAa,gBAAA,CAAwD,aAAA,EAAeA,QAAe;AAAA,GACvG;AACJ","file":"chunk-YQLDJJ5M.js","sourcesContent":["import type { SubscribableStore } from \"./bindStoreWithActions\";\nimport {\n tableStore,\n tableActions,\n type TableState,\n multiObjectStore,\n multiObjectActions,\n noteStore,\n noteActions,\n type NoteState,\n emailStore,\n emailActions,\n type EmailState,\n syncStore,\n syncActions,\n type SyncState,\n uploaderStore,\n uploaderActions,\n type UploaderState,\n} from \"./stores\";\n\ntype ComposableFactory = <TState extends object, TActions extends object>(\n store: SubscribableStore<TState>,\n actions: TActions,\n) => () => TState & TActions;\n\nexport function createAdapterHooks(createComposable: ComposableFactory) {\n return {\n useTable: createComposable<TableState, typeof tableActions>(tableStore, tableActions),\n useMultiObjectActions: createComposable(multiObjectStore, multiObjectActions),\n useNote: createComposable<NoteState, typeof noteActions>(noteStore, noteActions),\n useEmail: createComposable<EmailState, typeof emailActions>(emailStore, emailActions),\n useSync: createComposable<SyncState, typeof syncActions>(syncStore, syncActions),\n useUploader: createComposable<UploaderState, typeof uploaderActions>(uploaderStore, uploaderActions),\n };\n}\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -298,6 +298,102 @@ type HubSpotActivityDateTimeParts = {
|
|
|
298
298
|
declare function formatHubSpotActivityDateTimeParts(timestamp: unknown, timeZone?: string): HubSpotActivityDateTimeParts | null;
|
|
299
299
|
declare function formatHubSpotActivityDateTime(timestamp: unknown, timeZone?: string): string;
|
|
300
300
|
|
|
301
|
+
type CachePurgeMode = "soft" | "hard";
|
|
302
|
+
type CachePurgeDomain = "crm_object_data" | "portal_object_config" | "user_session";
|
|
303
|
+
type CachePurgeView = "list" | "single" | "board" | "notes" | "emails" | "files";
|
|
304
|
+
type CachePurgeListQuery = {
|
|
305
|
+
sort?: string;
|
|
306
|
+
search?: string;
|
|
307
|
+
filterPropertyName?: string;
|
|
308
|
+
filterOperator?: string;
|
|
309
|
+
filterValue?: string;
|
|
310
|
+
page?: number;
|
|
311
|
+
limit?: number;
|
|
312
|
+
view?: "LIST" | "BOARD";
|
|
313
|
+
mediatorObjectTypeId?: string;
|
|
314
|
+
mediatorObjectRecordId?: string;
|
|
315
|
+
parentObjectTypeId?: string;
|
|
316
|
+
parentObjectRecordId?: string;
|
|
317
|
+
isPrimaryCompany?: boolean;
|
|
318
|
+
};
|
|
319
|
+
type CachePurgeTarget = {
|
|
320
|
+
domain: CachePurgeDomain;
|
|
321
|
+
objectTypeId?: string;
|
|
322
|
+
objectTypeIds?: string[];
|
|
323
|
+
recordIds?: string[];
|
|
324
|
+
fileIds?: string[];
|
|
325
|
+
views?: CachePurgeView[];
|
|
326
|
+
listQuery?: CachePurgeListQuery;
|
|
327
|
+
};
|
|
328
|
+
type CachePurgeRequest = {
|
|
329
|
+
mode: CachePurgeMode;
|
|
330
|
+
warm?: boolean;
|
|
331
|
+
confirmPortalWide?: boolean;
|
|
332
|
+
includeShortOnHard?: boolean;
|
|
333
|
+
includeContactAccess?: boolean;
|
|
334
|
+
targets: CachePurgeTarget[];
|
|
335
|
+
};
|
|
336
|
+
type CachePurgeJobStatus = "warming" | "completed" | "failed";
|
|
337
|
+
type PurgeResult = {
|
|
338
|
+
ok: boolean;
|
|
339
|
+
purgeJobId?: string;
|
|
340
|
+
status?: CachePurgeJobStatus;
|
|
341
|
+
evicted?: Record<string, string[]>;
|
|
342
|
+
warnings?: string[];
|
|
343
|
+
errorCode?: "PURGE_API_DISABLED" | "RATE_LIMITED" | "VALIDATION" | "WARM_FAILED" | "NETWORK" | "UNKNOWN";
|
|
344
|
+
message?: string;
|
|
345
|
+
};
|
|
346
|
+
type CreateCachePurgeJobOptions = {
|
|
347
|
+
idempotencyKey?: string;
|
|
348
|
+
waitForWarm?: boolean;
|
|
349
|
+
pollTimeoutMs?: number;
|
|
350
|
+
pollIntervalMs?: number;
|
|
351
|
+
};
|
|
352
|
+
type CrmCachePurgeOptions = {
|
|
353
|
+
objectTypeId: string;
|
|
354
|
+
objectTypeIds?: string[];
|
|
355
|
+
mode?: CachePurgeMode;
|
|
356
|
+
warm?: boolean;
|
|
357
|
+
listQuery?: CachePurgeListQuery;
|
|
358
|
+
views?: CachePurgeView[];
|
|
359
|
+
recordIds?: string[];
|
|
360
|
+
fileIds?: string[];
|
|
361
|
+
waitForWarm?: boolean;
|
|
362
|
+
idempotencyKey?: string;
|
|
363
|
+
};
|
|
364
|
+
|
|
365
|
+
declare function buildCrmListPurgeTarget(objectTypeId: string, listQuery?: CachePurgeListQuery): CachePurgeTarget;
|
|
366
|
+
declare function buildCrmSinglePurgeTarget(objectTypeId: string, recordIds: string[], listQuery?: CachePurgeListQuery): CachePurgeTarget;
|
|
367
|
+
declare function buildEngagementPurgeTarget(objectTypeId: string, recordIds: string[], views: Extract<CachePurgeView, "notes" | "emails" | "files">[], options?: {
|
|
368
|
+
fileIds?: string[];
|
|
369
|
+
listQuery?: CachePurgeListQuery;
|
|
370
|
+
}): CachePurgeTarget;
|
|
371
|
+
declare function buildUserSessionPurgeTarget(): CachePurgeTarget;
|
|
372
|
+
declare function buildPortalConfigPurgeTarget(objectTypeIds: string[]): CachePurgeTarget;
|
|
373
|
+
declare function mergePurgeTargets(...targets: CachePurgeTarget[]): CachePurgeTarget[];
|
|
374
|
+
declare function buildCachePurgeRequest(targets: CachePurgeTarget[], options?: {
|
|
375
|
+
mode?: "soft" | "hard";
|
|
376
|
+
warm?: boolean;
|
|
377
|
+
includeContactAccess?: boolean;
|
|
378
|
+
includeShortOnHard?: boolean;
|
|
379
|
+
confirmPortalWide?: boolean;
|
|
380
|
+
}): CachePurgeRequest;
|
|
381
|
+
|
|
382
|
+
declare function createCachePurgeJob(request: CachePurgeRequest, options?: CreateCachePurgeJobOptions): Promise<PurgeResult>;
|
|
383
|
+
|
|
384
|
+
declare function purgeCrmObjectDataCache(options: CrmCachePurgeOptions): Promise<boolean>;
|
|
385
|
+
declare function purgeCrmListCache(options: CrmCachePurgeOptions): Promise<PurgeResult>;
|
|
386
|
+
declare function purgeCrmRecordCache(options: CrmCachePurgeOptions & {
|
|
387
|
+
recordIds: string[];
|
|
388
|
+
}): Promise<PurgeResult>;
|
|
389
|
+
declare function purgeEngagementCaches(options: CrmCachePurgeOptions & {
|
|
390
|
+
recordIds: string[];
|
|
391
|
+
views: ("notes" | "emails" | "files")[];
|
|
392
|
+
}): Promise<PurgeResult>;
|
|
393
|
+
declare function purgeCrmCombined(options: CrmCachePurgeOptions & {
|
|
394
|
+
targets: CachePurgeTarget[];
|
|
395
|
+
}): Promise<PurgeResult>;
|
|
396
|
+
|
|
301
397
|
declare const Client: {
|
|
302
398
|
authentication: {
|
|
303
399
|
preLogin: (data: PreLoginPayload) => Promise<unknown>;
|
|
@@ -467,4 +563,4 @@ declare const routeParam: {
|
|
|
467
563
|
};
|
|
468
564
|
};
|
|
469
565
|
|
|
470
|
-
export { type ChangePasswordPayload, type Config, DEFAULT_HUBSPOT_TIMEZONE, type ForgetPasswordPayload, type HttpClientConfig, type HubSpotActivityDateTimeParts, type LoginPayload, type MutationOptions, type PreLoginPayload, type ResetPasswordPayload, type ResetPasswordVerifyTokenPayload, type VerifyEmailPayload, api, breadcrumbsDetails, index as clint, formatGmtOffset, formatHubSpotActivityDateTime, formatHubSpotActivityDateTimeParts, getCurrentTimeZone, getFieldErrors, getFormErrors, initializeHttpClient, normalizeToTimestamp, routeParam, store, url };
|
|
566
|
+
export { type CachePurgeDomain, type CachePurgeListQuery, type CachePurgeMode, type CachePurgeRequest, type CachePurgeTarget, type CachePurgeView, type ChangePasswordPayload, type Config, type CreateCachePurgeJobOptions, type CrmCachePurgeOptions, DEFAULT_HUBSPOT_TIMEZONE, type ForgetPasswordPayload, type HttpClientConfig, type HubSpotActivityDateTimeParts, type LoginPayload, type MutationOptions, type PreLoginPayload, type PurgeResult, type ResetPasswordPayload, type ResetPasswordVerifyTokenPayload, type VerifyEmailPayload, api, breadcrumbsDetails, buildCachePurgeRequest, buildCrmListPurgeTarget, buildCrmSinglePurgeTarget, buildEngagementPurgeTarget, buildPortalConfigPurgeTarget, buildUserSessionPurgeTarget, index as clint, createCachePurgeJob, formatGmtOffset, formatHubSpotActivityDateTime, formatHubSpotActivityDateTimeParts, getCurrentTimeZone, getFieldErrors, getFormErrors, initializeHttpClient, mergePurgeTargets, normalizeToTimestamp, purgeCrmCombined, purgeCrmListCache, purgeCrmObjectDataCache, purgeCrmRecordCache, purgeEngagementCaches, routeParam, store, url };
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DEFAULT_HUBSPOT_TIMEZONE, api, breadcrumbsDetails, client_exports as clint, formatGmtOffset, formatHubSpotActivityDateTime, formatHubSpotActivityDateTimeParts, getCurrentTimeZone, getFieldErrors, getFormErrors, initializeHttpClient, normalizeToTimestamp, routeParam, store, url } from './chunk-
|
|
1
|
+
export { DEFAULT_HUBSPOT_TIMEZONE, api, breadcrumbsDetails, buildCachePurgeRequest, buildCrmListPurgeTarget, buildCrmSinglePurgeTarget, buildEngagementPurgeTarget, buildPortalConfigPurgeTarget, buildUserSessionPurgeTarget, client_exports as clint, createCachePurgeJob, formatGmtOffset, formatHubSpotActivityDateTime, formatHubSpotActivityDateTimeParts, getCurrentTimeZone, getFieldErrors, getFormErrors, initializeHttpClient, mergePurgeTargets, normalizeToTimestamp, purgeCrmCombined, purgeCrmListCache, purgeCrmObjectDataCache, purgeCrmRecordCache, purgeEngagementCaches, routeParam, store, url } from './chunk-HSJU2Z2S.js';
|
|
2
2
|
import './chunk-2SYUOWTT.js';
|
|
3
3
|
//# sourceMappingURL=index.js.map
|
|
4
4
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "woodsportal-client-sdk",
|
|
3
|
-
"version": "1.1.4-dev.
|
|
3
|
+
"version": "1.1.4-dev.57",
|
|
4
4
|
"description": "Official TypeScript/JavaScript SDK for WoodsPortal API - Authentication, user management, pipelines, and more",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -40,6 +40,7 @@
|
|
|
40
40
|
"clean": "rimraf dist",
|
|
41
41
|
"build": "npm run clean && tsup",
|
|
42
42
|
"type-check": "tsc --noEmit",
|
|
43
|
+
"test": "node --import tsx --test 'src/**/*.test.ts'",
|
|
43
44
|
"test:consumer": "npm run build && cd examples/smoke-consumer && npm install && npm run smoke",
|
|
44
45
|
"test:consumer:live": "npm run build && cd examples/smoke-consumer && npm install && npm run smoke:live",
|
|
45
46
|
"prepublishOnly": "npm run build && npm run type-check && npm run test:consumer"
|