woodsportal-client-sdk 4.0.7-dev.0 → 4.0.7-dev.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/adapters/angular/index.js +6 -6
- package/dist/adapters/react/index.js +6 -6
- package/dist/adapters/vue/index.js +6 -6
- package/dist/auth-interceptor-policy-CKXBTGBT.js +5 -0
- package/dist/{auth-interceptor-policy-BSY5KIIA.js.map → auth-interceptor-policy-CKXBTGBT.js.map} +1 -1
- package/dist/auth-utils-LT4JXJER.js +5 -0
- package/dist/{auth-utils-XIHNYE63.js.map → auth-utils-LT4JXJER.js.map} +1 -1
- package/dist/{chunk-ADOV2R3A.js → chunk-5NONTYJA.js} +237 -11
- package/dist/chunk-5NONTYJA.js.map +1 -0
- package/dist/{chunk-YOT5RW3R.js → chunk-6XIX6R4X.js} +8 -5
- package/dist/chunk-6XIX6R4X.js.map +1 -0
- package/dist/{chunk-7OGXVANB.js → chunk-AR6QQMVD.js} +4 -4
- package/dist/{chunk-7OGXVANB.js.map → chunk-AR6QQMVD.js.map} +1 -1
- package/dist/{chunk-OF5OLEE5.js → chunk-DKWFLCSO.js} +3 -3
- package/dist/{chunk-OF5OLEE5.js.map → chunk-DKWFLCSO.js.map} +1 -1
- package/dist/{chunk-U66LWTVC.js → chunk-JKB2SWUN.js} +62 -10
- package/dist/chunk-JKB2SWUN.js.map +1 -0
- package/dist/{chunk-4IKGBHFJ.js → chunk-JVM47MG5.js} +82 -31
- package/dist/chunk-JVM47MG5.js.map +1 -0
- package/dist/{chunk-WNBF6FKG.js → chunk-PQQSIYD3.js} +19 -8
- package/dist/chunk-PQQSIYD3.js.map +1 -0
- package/dist/{chunk-DZC3DJUO.js → chunk-PRGN3FF6.js} +13 -4
- package/dist/chunk-PRGN3FF6.js.map +1 -0
- package/dist/{chunk-GVXA7OKY.js → chunk-QIM5H7OG.js} +23 -6
- package/dist/chunk-QIM5H7OG.js.map +1 -0
- package/dist/{chunk-6ROV3EE2.js → chunk-UDAPRD7Z.js} +16 -5
- package/dist/chunk-UDAPRD7Z.js.map +1 -0
- package/dist/{chunk-J33YFZCS.js → chunk-XIKYPNO5.js} +8 -7
- package/dist/chunk-XIKYPNO5.js.map +1 -0
- package/dist/cross-tab-session-WEIUJDZN.js +9 -0
- package/dist/{cross-tab-session-OJKWJSNT.js.map → cross-tab-session-WEIUJDZN.js.map} +1 -1
- package/dist/entries/auth.d.ts +5 -2
- package/dist/entries/auth.js +8 -8
- package/dist/entries/auth.js.map +1 -1
- package/dist/entries/crm.d.ts +2 -2
- package/dist/entries/crm.js +9 -7
- package/dist/entries/crm.js.map +1 -1
- package/dist/{http-errors-_XPPqJ_a.d.ts → http-errors-CCCQECil.d.ts} +21 -2
- package/dist/index.d.ts +18 -4
- package/dist/index.js +15 -13
- package/dist/index.js.map +1 -1
- package/dist/{cache-purge-Ca4idzyy.d.ts → pipeline-ui-DbEzI_v1.d.ts} +13 -1
- package/dist/storage-migration-2NVJ3GNQ.js +4 -0
- package/dist/{storage-migration-OCOML7VA.js.map → storage-migration-2NVJ3GNQ.js.map} +1 -1
- package/package.json +1 -1
- package/dist/auth-interceptor-policy-BSY5KIIA.js +0 -5
- package/dist/auth-utils-XIHNYE63.js +0 -5
- package/dist/chunk-4IKGBHFJ.js.map +0 -1
- package/dist/chunk-6ROV3EE2.js.map +0 -1
- package/dist/chunk-ADOV2R3A.js.map +0 -1
- package/dist/chunk-DZC3DJUO.js.map +0 -1
- package/dist/chunk-GVXA7OKY.js.map +0 -1
- package/dist/chunk-J33YFZCS.js.map +0 -1
- package/dist/chunk-U66LWTVC.js.map +0 -1
- package/dist/chunk-WNBF6FKG.js.map +0 -1
- package/dist/chunk-YOT5RW3R.js.map +0 -1
- package/dist/cross-tab-session-OJKWJSNT.js +0 -9
- package/dist/refresh-lock-UW5RRRTD.js +0 -72
- package/dist/refresh-lock-UW5RRRTD.js.map +0 -1
- package/dist/storage-migration-OCOML7VA.js +0 -4
package/dist/entries/auth.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { p as preLogin, l as login, c as clientSession, h as handoff, a as logout, r as register, v as verifyEmail, b as registerExistingUser, f as forgetPassword, d as resetPassword, e as resetPasswordVerifyToken, g as verifyEmailResend, i as resendEmail, j as changePassword, m as me, k as profile, n as profileUpdate, o as verifyOtp, s as sendMfaOtp, q as pendingPasskeyOptions, t as pendingPasskeyVerify, u as getMfaStatus, w as setMfaPreferences, x as startPhoneVerify, y as confirmPhoneVerify, z as totpEnrollStart, A as totpEnrollVerify, B as totpDisable, C as phoneUnverify, D as backupCodesRegenerate, E as mfaOptOut, F as webauthnRegisterOptions, G as webauthnRegisterVerify, H as webauthnAuthOptions, I as webauthnAuthVerify, J as listWebauthnCredentials, K as deleteWebauthnCredential, L as passkeyLoginOptions, M as passkeyLoginVerify, N as getSecurityOverview, O as getSecurityLoginActivity, P as getSecuritySessions, Q as revokeSecuritySession, R as revokeOtherSecuritySessions, S as getLoginBootstrap, T as getSsoDetails, U as generateSsoUrl, V as ssoCallback, W as getRefreshToken, X as refreshSession, Y as getAuthRefreshToken, Z as getAccessToken, _ as
|
|
2
|
-
export {
|
|
1
|
+
import { p as preLogin, l as login, c as clientSession, h as handoff, a as logout, r as register, v as verifyEmail, b as registerExistingUser, f as forgetPassword, d as resetPassword, e as resetPasswordVerifyToken, g as verifyEmailResend, i as resendEmail, j as changePassword, m as me, k as profile, n as profileUpdate, o as verifyOtp, s as sendMfaOtp, q as pendingPasskeyOptions, t as pendingPasskeyVerify, u as getMfaStatus, w as setMfaPreferences, x as startPhoneVerify, y as confirmPhoneVerify, z as totpEnrollStart, A as totpEnrollVerify, B as totpDisable, C as phoneUnverify, D as backupCodesRegenerate, E as mfaOptOut, F as webauthnRegisterOptions, G as webauthnRegisterVerify, H as webauthnAuthOptions, I as webauthnAuthVerify, J as listWebauthnCredentials, K as deleteWebauthnCredential, L as passkeyLoginOptions, M as passkeyLoginVerify, N as getSecurityOverview, O as getSecurityLoginActivity, P as getSecuritySessions, Q as revokeSecuritySession, R as revokeOtherSecuritySessions, S as getLoginBootstrap, T as getSsoDetails, U as generateSsoUrl, V as ssoCallback, W as getRefreshToken, X as refreshSession, Y as getAuthRefreshToken, Z as getAccessToken, _ as setAccessToken, $ as clearAccessToken, a0 as isAuthenticated, a1 as isAuthenticateApp, a2 as isAccessTokenExpired, a3 as isExpiresAccessToken, a4 as hasRefreshSession, a5 as hasValidAccessToken, a6 as didLastRefreshFail, a7 as isSessionRefreshExhausted, a8 as isRefreshInFlight, a9 as resetSessionAuthState, aa as clearSessionRefreshExhaustedState, ab as hydrateSessionRefreshState, ac as SessionContractInput } from '../http-errors-CCCQECil.js';
|
|
2
|
+
export { az as ActiveSession, aA as ApiErrorPayload, aB as AuthErrorAction, aC as AuthErrorCode, aD as AuthErrorCodeValue, aE as AuthFunnelState, aF as AuthInterceptorPolicyConfig, aG as AuthPolicyRoutes, aH as AuthRouteAction, bu as EditorPreviewMockHandler, bv as EditorPreviewMockResult, aI as HttpClientConfig, aJ as HttpErrorKind, aK as HydrateMfaPendingAccessTokenInput, bw as LoginBootstrapMfaPolicy, bx as LoginBootstrapPortal, by as LoginBootstrapResponse, bz as LoginBootstrapSsoProvider, aM as LoginHistoryRow, aN as LoginResponseData, aO as MfaBootRecoveryResult, aP as MfaEnrollmentStatus, aQ as MfaMethod, aR as MfaMethodOption, aS as MfaPendingAccessToken, aT as MfaPortalScopeContext, aU as MfaStorageLane, aV as PaginationResponse, aW as SERVICE_UNAVAILABLE_MESSAGE, aX as SecurityOverview, aZ as StoredAuthError, ae as TwoFaVerificationRequest, a_ as UnauthorizedPageCopy, a$ as WoodsportalRequestConfig, b0 as classifyHttpError, b1 as clearMfaPendingAccessToken, b3 as getFieldErrors, b4 as getFormErrors, b5 as getHttpErrorMessage, b7 as getUnauthorizedPageCopy, b8 as hasAuthenticatedAccess, b9 as hasValidAccess, ba as hydrateMfaPendingAccessToken, bb as initializeHttpClient, bc as isFullyAuthenticated, bd as isMfaPendingAccessSession, be as isMfaPendingSession, bf as isOptionalAuthFailureUrl, bg as isServiceUnavailableError, bh as isSessionProbeUrl, bi as parseApiErrorPayload, bj as persistAuthError, bk as readMfaPendingAccessToken, bl as readPersistedAuthError, bm as recoverMfaGateOnBoot, bo as resolveAuthErrorAction, bp as resolveAuthRouteAction, bA as setEditorPreviewMockHandler, bq as setSessionLifecycleListener, br as startVisibilityRefreshScheduler, bs as stopVisibilityRefreshScheduler, bt as storeMfaPendingAccessToken } from '../http-errors-CCCQECil.js';
|
|
3
3
|
export { C as ChangePasswordPayload, F as ForgetPasswordPayload, L as LoginPayload, P as PreLoginPayload, a as ResetPasswordPayload, R as ResetPasswordVerifyTokenPayload, V as VerifyEmailPayload } from '../index-Bh9eY8sA.js';
|
|
4
4
|
import 'axios';
|
|
5
5
|
|
|
@@ -65,6 +65,7 @@ declare const api: {
|
|
|
65
65
|
refreshSession: typeof refreshSession;
|
|
66
66
|
refreshAccessToken: typeof getAuthRefreshToken;
|
|
67
67
|
getAccessToken: typeof getAccessToken;
|
|
68
|
+
setAccessToken: typeof setAccessToken;
|
|
68
69
|
clearAccessToken: typeof clearAccessToken;
|
|
69
70
|
isAuthenticated: typeof isAuthenticated;
|
|
70
71
|
isAuthenticateApp: typeof isAuthenticateApp;
|
|
@@ -77,6 +78,8 @@ declare const api: {
|
|
|
77
78
|
isSessionRefreshExhausted: typeof isSessionRefreshExhausted;
|
|
78
79
|
isRefreshInFlight: typeof isRefreshInFlight;
|
|
79
80
|
resetSessionAuthState: typeof resetSessionAuthState;
|
|
81
|
+
clearSessionRefreshExhaustedState: typeof clearSessionRefreshExhaustedState;
|
|
82
|
+
hydrateSessionRefreshState: typeof hydrateSessionRefreshState;
|
|
80
83
|
contract: () => SessionContractInput;
|
|
81
84
|
isFullyAuthenticated: () => boolean;
|
|
82
85
|
hasAuthenticatedAccess: () => boolean;
|
package/dist/entries/auth.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { authApi } from '../chunk-
|
|
2
|
-
export { hasAuthenticatedAccess, hasValidAccess, isFullyAuthenticated, isMfaPendingSession, recoverMfaGateOnBoot, resolveAuthRouteAction } from '../chunk-
|
|
3
|
-
export { isOptionalAuthFailureUrl, isSessionProbeUrl, persistAuthError, readPersistedAuthError, resolveAuthErrorAction } from '../chunk-
|
|
4
|
-
export { SERVICE_UNAVAILABLE_MESSAGE, classifyHttpError, getFieldErrors, getFormErrors, getHttpErrorMessage, initializeHttpClient, isServiceUnavailableError, setEditorPreviewMockHandler, startVisibilityRefreshScheduler, stopVisibilityRefreshScheduler } from '../chunk-
|
|
5
|
-
import '../chunk-
|
|
6
|
-
export { setSessionLifecycleListener } from '../chunk-
|
|
1
|
+
import { authApi } from '../chunk-PQQSIYD3.js';
|
|
2
|
+
export { hasAuthenticatedAccess, hasValidAccess, isFullyAuthenticated, isMfaPendingSession, recoverMfaGateOnBoot, resolveAuthRouteAction } from '../chunk-PQQSIYD3.js';
|
|
3
|
+
export { isOptionalAuthFailureUrl, isSessionProbeUrl, persistAuthError, readPersistedAuthError, resolveAuthErrorAction } from '../chunk-PRGN3FF6.js';
|
|
4
|
+
export { SERVICE_UNAVAILABLE_MESSAGE, classifyHttpError, getFieldErrors, getFormErrors, getHttpErrorMessage, initializeHttpClient, isServiceUnavailableError, setEditorPreviewMockHandler, startVisibilityRefreshScheduler, stopVisibilityRefreshScheduler } from '../chunk-JVM47MG5.js';
|
|
5
|
+
import '../chunk-JKB2SWUN.js';
|
|
6
|
+
export { clearMfaPendingAccessToken, hydrateMfaPendingAccessToken, isMfaPendingAccessSession, readMfaPendingAccessToken, setSessionLifecycleListener, storeMfaPendingAccessToken } from '../chunk-5NONTYJA.js';
|
|
7
7
|
export { AuthErrorCode, getUnauthorizedPageCopy, parseApiErrorPayload } from '../chunk-COHBSTHF.js';
|
|
8
|
-
import '../chunk-
|
|
9
|
-
import '../chunk-
|
|
8
|
+
import '../chunk-6XIX6R4X.js';
|
|
9
|
+
import '../chunk-UDAPRD7Z.js';
|
|
10
10
|
|
|
11
11
|
// src/main/entries/auth.ts
|
|
12
12
|
var api = {
|
package/dist/entries/auth.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/main/entries/auth.ts"],"names":[],"mappings":";;;;;;;;;;;
|
|
1
|
+
{"version":3,"sources":["../../src/main/entries/auth.ts"],"names":[],"mappings":";;;;;;;;;;;AA8EO,IAAM,GAAA,GAAM;AAAA,EACf,IAAA,EAAM;AACV","file":"auth.js","sourcesContent":["/**\n * Auth-only subpath export — login, MFA, security, SSO, token helpers.\n * Does not import CRM feature modules.\n */\nimport { authApi } from '../api/nested-auth-api'\n\nexport { initializeHttpClient, getFormErrors, getFieldErrors, setEditorPreviewMockHandler } from '../core/http/http-client'\nexport { setSessionLifecycleListener } from '../core/http/token-store'\nexport type { HttpClientConfig, EditorPreviewMockHandler, EditorPreviewMockResult } from '../core/http/http-client'\n\nexport { classifyHttpError, getHttpErrorMessage, isServiceUnavailableError, SERVICE_UNAVAILABLE_MESSAGE } from '../core/http/http-errors'\nexport type { HttpErrorKind } from '../core/http/http-errors'\n\nexport {\n AuthErrorCode,\n parseApiErrorPayload,\n getUnauthorizedPageCopy,\n resolveAuthErrorAction,\n isOptionalAuthFailureUrl,\n isSessionProbeUrl,\n persistAuthError,\n readPersistedAuthError,\n hasValidAccess,\n isFullyAuthenticated,\n isMfaPendingSession,\n hasAuthenticatedAccess,\n recoverMfaGateOnBoot,\n startVisibilityRefreshScheduler,\n stopVisibilityRefreshScheduler,\n resolveAuthRouteAction,\n storeMfaPendingAccessToken,\n readMfaPendingAccessToken,\n clearMfaPendingAccessToken,\n hydrateMfaPendingAccessToken,\n isMfaPendingAccessSession\n} from '../core/auth/index.js'\nexport type {\n ApiErrorPayload,\n StoredAuthError,\n AuthErrorCodeValue,\n UnauthorizedPageCopy,\n AuthErrorAction,\n AuthPolicyRoutes,\n AuthInterceptorPolicyConfig,\n WoodsportalRequestConfig,\n SessionContractInput,\n MfaBootRecoveryResult,\n AuthRouteAction,\n AuthFunnelState,\n MfaStorageLane,\n MfaPendingAccessToken,\n HydrateMfaPendingAccessTokenInput\n} from '../core/auth/index.js'\n\nexport type {\n PreLoginPayload,\n LoginPayload,\n VerifyEmailPayload,\n ResetPasswordVerifyTokenPayload,\n ResetPasswordPayload,\n ForgetPasswordPayload,\n ChangePasswordPayload,\n MfaMethod,\n MfaMethodOption,\n MfaPortalScopeContext,\n LoginBootstrapResponse,\n LoginBootstrapMfaPolicy,\n LoginBootstrapPortal,\n LoginBootstrapSsoProvider,\n LoginResponseData,\n TwoFaVerificationRequest,\n MfaEnrollmentStatus,\n SecurityOverview,\n LoginHistoryRow,\n ActiveSession,\n PaginationResponse\n} from '../core/types'\n\nexport const api = {\n auth: authApi\n}\n"]}
|
package/dist/entries/crm.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { T as TableUiState, a as TableState, U as UserState, N as NoteState, E as EmailState, S as SyncState } from '../use-sync-DpazhM4d.js';
|
|
2
|
-
import { l as list, a as list$1, b as list$2, s as sideBarList, f as form, o as objectFormOptions, d as details, u as update, c as create, e as createExisting, r as removeExisting, g as list$3, h as create$1, i as update$1, j as list$4, k as create$2, m as update$2, n as list$5, p as details$1, q as download, t as addFolder, v as addFile, w as imageUpload, x as attachmentUpload, y as purge, z as purgeStatus } from '../
|
|
3
|
-
export { G as CachePurgeDomain, B as CachePurgeListQuery, H as CachePurgeMode, A as CachePurgeRequest, C as CachePurgeTarget, D as CachePurgeView, E as CreateCachePurgeJobOptions, F as CrmCachePurgeOptions, P as PurgeResult } from '../
|
|
2
|
+
import { l as list, a as list$1, b as list$2, s as sideBarList, f as form, o as objectFormOptions, d as details, u as update, c as create, e as createExisting, r as removeExisting, g as list$3, h as create$1, i as update$1, j as list$4, k as create$2, m as update$2, n as list$5, p as details$1, q as download, t as addFolder, v as addFile, w as imageUpload, x as attachmentUpload, y as purge, z as purgeStatus } from '../pipeline-ui-DbEzI_v1.js';
|
|
3
|
+
export { G as CachePurgeDomain, B as CachePurgeListQuery, H as CachePurgeMode, A as CachePurgeRequest, C as CachePurgeTarget, D as CachePurgeView, E as CreateCachePurgeJobOptions, F as CrmCachePurgeOptions, I as HUBSPOT_DEALS_OBJECT_TYPE_ID, J as HUBSPOT_TICKETS_OBJECT_TYPE_ID, K as PIPELINE_BOARD_OBJECT_TYPE_IDS, L as PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS, P as PurgeResult, M as isPipelineBoardObjectType, N as isPipelineBoardObjectTypeId, O as shouldShowPipelineSelector, Q as supportsBoardView } from '../pipeline-ui-DbEzI_v1.js';
|
|
4
4
|
import '../index-Bh9eY8sA.js';
|
|
5
5
|
|
|
6
6
|
declare const api: {
|
package/dist/entries/crm.js
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
import { crmApi } from '../chunk-
|
|
1
|
+
import { crmApi } from '../chunk-QIM5H7OG.js';
|
|
2
|
+
export { isPipelineBoardObjectType, shouldShowPipelineSelector, supportsBoardView } from '../chunk-QIM5H7OG.js';
|
|
2
3
|
import '../chunk-55MIERLJ.js';
|
|
3
|
-
import { navigationApi } from '../chunk-
|
|
4
|
-
import '../chunk-
|
|
5
|
-
import { actions8, syncStore, actions5, emailStore, actions4, noteStore, actions6, userStore, actions2, tableStore, tableUiActions, tableUiStore } from '../chunk-
|
|
6
|
-
|
|
4
|
+
import { navigationApi } from '../chunk-JVM47MG5.js';
|
|
5
|
+
import '../chunk-DKWFLCSO.js';
|
|
6
|
+
import { actions8, syncStore, actions5, emailStore, actions4, noteStore, actions6, userStore, actions2, tableStore, tableUiActions, tableUiStore } from '../chunk-JKB2SWUN.js';
|
|
7
|
+
export { HUBSPOT_DEALS_OBJECT_TYPE_ID, HUBSPOT_TICKETS_OBJECT_TYPE_ID, PIPELINE_BOARD_OBJECT_TYPE_IDS, PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS, isPipelineBoardObjectTypeId } from '../chunk-JKB2SWUN.js';
|
|
8
|
+
import { storage } from '../chunk-5NONTYJA.js';
|
|
7
9
|
import '../chunk-COHBSTHF.js';
|
|
8
|
-
import '../chunk-
|
|
9
|
-
import '../chunk-
|
|
10
|
+
import '../chunk-6XIX6R4X.js';
|
|
11
|
+
import '../chunk-UDAPRD7Z.js';
|
|
10
12
|
|
|
11
13
|
// src/main/entries/crm.ts
|
|
12
14
|
var api = {
|
package/dist/entries/crm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/main/entries/crm.ts"],"names":["actions"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../src/main/entries/crm.ts"],"names":["actions"],"mappings":";;;;;;;;;;;;;AAqBO,IAAM,GAAA,GAAM;AAAA,EACf,GAAA,EAAK,MAAA;AAAA,EACL,UAAA,EAAY;AAChB;AAEO,IAAM,KAAA,GAAQ;AAAA,EACjB,OAAA;AAAA,EACA,OAAA,EAAS,EAAE,KAAA,EAAO,YAAA,EAAc,SAAS,cAAA,EAAe;AAAA,EACxD,KAAA,EAAO,EAAE,KAAA,EAAO,UAAA,WAAYA,QAAA,EAAsB;AAAA,EAClD,IAAA,EAAM,EAAE,KAAA,EAAO,SAAA,EAAW,SAASA,QAAAA,EAAY;AAAA,EAC/C,IAAA,EAAM,EAAE,KAAA,EAAO,SAAA,EAAW,SAASA,QAAAA,EAAY;AAAA,EAC/C,KAAA,EAAO,EAAE,KAAA,EAAO,UAAA,EAAY,SAASA,QAAAA,EAAa;AAAA,EAClD,IAAA,EAAM,EAAE,KAAA,EAAO,SAAA,EAAW,SAASA,QAAAA;AACvC","file":"crm.js","sourcesContent":["/**\n * CRM subpath export — pipelines, objects, notes, emails, files, cache purge, navigation, state.\n */\nimport { crmApi } from '../api/nested-crm-api'\nimport { navigationApi } from '../api/navigation-api'\nimport {\n tableStore,\n tableActions,\n tableUiStore,\n tableUiActions,\n userStore,\n userActions,\n noteStore,\n noteActions,\n emailStore,\n emailActions,\n syncStore,\n syncActions\n} from '../state'\nimport { storage } from '../core/utils/localStorage'\n\nexport const api = {\n crm: crmApi,\n navigation: navigationApi\n}\n\nexport const store = {\n storage,\n tableUi: { store: tableUiStore, actions: tableUiActions },\n table: { store: tableStore, actions: tableActions },\n user: { store: userStore, actions: userActions },\n note: { store: noteStore, actions: noteActions },\n email: { store: emailStore, actions: emailActions },\n sync: { store: syncStore, actions: syncActions }\n}\n\nexport {\n HUBSPOT_DEALS_OBJECT_TYPE_ID,\n HUBSPOT_TICKETS_OBJECT_TYPE_ID,\n PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS,\n PIPELINE_BOARD_OBJECT_TYPE_IDS,\n isPipelineBoardObjectTypeId\n} from '../core/constants/hubspot-object-type-ids'\nexport { isPipelineBoardObjectType, supportsBoardView, shouldShowPipelineSelector } from '../core/constants/pipeline-ui'\n\nexport type { CrmCachePurgeOptions } from '../core/types/cache-purge'\nexport type {\n CachePurgeRequest,\n CachePurgeTarget,\n CachePurgeListQuery,\n CachePurgeView,\n CachePurgeDomain,\n CachePurgeMode,\n PurgeResult,\n CreateCachePurgeJobOptions\n} from '../core/types/cache-purge'\n"]}
|
|
@@ -384,6 +384,8 @@ declare function getAuthRefreshToken(refreshToken: string | null): Promise<{
|
|
|
384
384
|
|
|
385
385
|
declare function getAccessToken(): string | null;
|
|
386
386
|
declare function setSessionLifecycleListener(listener: (() => void) | null): void;
|
|
387
|
+
declare function hydrateSessionRefreshState(): void;
|
|
388
|
+
declare function clearSessionRefreshExhaustedState(): void;
|
|
387
389
|
declare function clearAccessToken(): void;
|
|
388
390
|
declare function resetSessionAuthState(): void;
|
|
389
391
|
declare function didLastRefreshFail(): boolean;
|
|
@@ -400,6 +402,7 @@ declare function isAccessTokenExpired(): boolean;
|
|
|
400
402
|
declare function hasRefreshSession(): boolean;
|
|
401
403
|
declare function hasValidAccessToken(): boolean;
|
|
402
404
|
|
|
405
|
+
declare function setAccessToken(token: string, expiresIn?: number): Promise<unknown>;
|
|
403
406
|
declare function getRefreshToken(): string | null;
|
|
404
407
|
|
|
405
408
|
declare function getSsoDetails(options?: MutationOptions<any, any>): {
|
|
@@ -714,8 +717,24 @@ type MfaBootRecoveryInput = {
|
|
|
714
717
|
hasRefreshToken: () => boolean;
|
|
715
718
|
clearMfaOrphan: () => void;
|
|
716
719
|
clearStaleAccessToken: () => void;
|
|
720
|
+
tryHydrateMfaAccessToken?: () => boolean | Promise<boolean>;
|
|
717
721
|
};
|
|
718
|
-
declare function recoverMfaGateOnBoot(input: MfaBootRecoveryInput): MfaBootRecoveryResult
|
|
722
|
+
declare function recoverMfaGateOnBoot(input: MfaBootRecoveryInput): Promise<MfaBootRecoveryResult>;
|
|
723
|
+
|
|
724
|
+
type MfaStorageLane = 'c' | 'a';
|
|
725
|
+
type MfaPendingAccessToken = {
|
|
726
|
+
token: string;
|
|
727
|
+
expiresAt: number;
|
|
728
|
+
};
|
|
729
|
+
declare function storeMfaPendingAccessToken(token: string, expiresInSeconds: number | undefined, lane?: MfaStorageLane): void;
|
|
730
|
+
declare function readMfaPendingAccessToken(lane?: MfaStorageLane): MfaPendingAccessToken | null;
|
|
731
|
+
declare function clearMfaPendingAccessToken(lane?: MfaStorageLane): void;
|
|
732
|
+
declare function isMfaPendingAccessSession(lane?: MfaStorageLane): boolean;
|
|
733
|
+
type HydrateMfaPendingAccessTokenInput = {
|
|
734
|
+
lane?: MfaStorageLane;
|
|
735
|
+
setAccessToken: (token: string, expiresInSeconds?: number) => void | Promise<void>;
|
|
736
|
+
};
|
|
737
|
+
declare function hydrateMfaPendingAccessToken(input: HydrateMfaPendingAccessTokenInput): Promise<boolean>;
|
|
719
738
|
|
|
720
739
|
type AuthRouteAction = {
|
|
721
740
|
kind: 'allow';
|
|
@@ -753,4 +772,4 @@ declare function classifyHttpError(error: unknown): HttpErrorKind;
|
|
|
753
772
|
declare function isServiceUnavailableError(error: unknown): boolean;
|
|
754
773
|
declare function getHttpErrorMessage(error: unknown): string;
|
|
755
774
|
|
|
756
|
-
export {
|
|
775
|
+
export { clearAccessToken as $, totpEnrollVerify as A, totpDisable as B, phoneUnverify as C, backupCodesRegenerate as D, mfaOptOut as E, webauthnRegisterOptions as F, webauthnRegisterVerify as G, webauthnAuthOptions as H, webauthnAuthVerify as I, listWebauthnCredentials as J, deleteWebauthnCredential as K, passkeyLoginOptions as L, passkeyLoginVerify as M, getSecurityOverview as N, getSecurityLoginActivity as O, getSecuritySessions as P, revokeSecuritySession as Q, revokeOtherSecuritySessions as R, getLoginBootstrap as S, getSsoDetails as T, generateSsoUrl as U, ssoCallback as V, getRefreshToken as W, refreshSession as X, getAuthRefreshToken as Y, getAccessToken as Z, setAccessToken as _, logout as a, type WoodsportalRequestConfig as a$, isAuthenticated as a0, isAuthenticateApp as a1, isAccessTokenExpired as a2, isExpiresAccessToken as a3, hasRefreshSession as a4, hasValidAccessToken as a5, didLastRefreshFail as a6, isSessionRefreshExhausted as a7, isRefreshInFlight as a8, resetSessionAuthState as a9, type ApiErrorPayload as aA, type AuthErrorAction as aB, AuthErrorCode as aC, type AuthErrorCodeValue as aD, type AuthFunnelState as aE, type AuthInterceptorPolicyConfig as aF, type AuthPolicyRoutes as aG, type AuthRouteAction as aH, type HttpClientConfig as aI, type HttpErrorKind as aJ, type HydrateMfaPendingAccessTokenInput as aK, type LogLevel as aL, type LoginHistoryRow as aM, type LoginResponseData as aN, type MfaBootRecoveryResult as aO, type MfaEnrollmentStatus as aP, type MfaMethod as aQ, type MfaMethodOption as aR, type MfaPendingAccessToken as aS, type MfaPortalScopeContext as aT, type MfaStorageLane as aU, type PaginationResponse as aV, SERVICE_UNAVAILABLE_MESSAGE as aW, type SecurityOverview as aX, type StorageKeyConfig as aY, type StoredAuthError as aZ, type UnauthorizedPageCopy as a_, clearSessionRefreshExhaustedState as aa, hydrateSessionRefreshState as ab, type SessionContractInput as ac, type LoggerConfig as ad, type TwoFaVerificationRequest as ae, type MfaOtpSendRequest as af, type MfaPendingPasskeyOptionsRequest as ag, type MfaPendingPasskeyVerifyRequest as ah, type MfaStatusQuery as ai, type MfaPreferenceRequest as aj, type PhoneVerifyStartRequest as ak, type PhoneVerifyConfirmRequest as al, type TotpEnrollVerifyRequest as am, type TotpDisableRequest as an, type PhoneUnverifyRequest as ao, type BackupCodesRegenerateRequest as ap, type MfaBackupCodesResponse as aq, type MfaOptOutRequest as ar, type WebAuthnVerifyRequest as as, type PasskeyLoginOptionsRequest as at, type PasskeyLoginVerifyRequest as au, type SecurityOverviewQuery as av, type SecurityLoginActivityQuery as aw, type SecuritySessionsQuery as ax, type RevokeSecuritySessionPayload as ay, type ActiveSession as az, registerExistingUser as b, classifyHttpError as b0, clearMfaPendingAccessToken as b1, configureStorageKeys as b2, getFieldErrors as b3, getFormErrors as b4, getHttpErrorMessage as b5, getStorageKeys as b6, getUnauthorizedPageCopy as b7, hasAuthenticatedAccess as b8, hasValidAccess as b9, setEditorPreviewMockHandler as bA, hydrateMfaPendingAccessToken as ba, initializeHttpClient as bb, isFullyAuthenticated as bc, isMfaPendingAccessSession as bd, isMfaPendingSession as be, isOptionalAuthFailureUrl as bf, isServiceUnavailableError as bg, isSessionProbeUrl as bh, parseApiErrorPayload as bi, persistAuthError as bj, readMfaPendingAccessToken as bk, readPersistedAuthError as bl, recoverMfaGateOnBoot as bm, resetStorageKeysForTests as bn, resolveAuthErrorAction as bo, resolveAuthRouteAction as bp, setSessionLifecycleListener as bq, startVisibilityRefreshScheduler as br, stopVisibilityRefreshScheduler as bs, storeMfaPendingAccessToken as bt, type EditorPreviewMockHandler as bu, type EditorPreviewMockResult as bv, type LoginBootstrapMfaPolicy as bw, type LoginBootstrapPortal as bx, type LoginBootstrapResponse as by, type LoginBootstrapSsoProvider as bz, clientSession as c, resetPassword as d, resetPasswordVerifyToken as e, forgetPassword as f, verifyEmailResend as g, handoff as h, resendEmail as i, changePassword as j, profile as k, login as l, me as m, profileUpdate as n, verifyOtp as o, preLogin as p, pendingPasskeyOptions as q, register as r, sendMfaOtp as s, pendingPasskeyVerify as t, getMfaStatus as u, verifyEmail as v, setMfaPreferences as w, startPhoneVerify as x, confirmPhoneVerify as y, totpEnrollStart as z };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { T as TableUiState, a as TableState, U as UserState, N as NoteState, E as EmailState, S as SyncState } from './use-sync-DpazhM4d.js';
|
|
2
|
-
import { l as list, a as list$1, b as list$2, s as sideBarList, f as form, o as objectFormOptions, d as details, u as update, c as create, e as createExisting, r as removeExisting, g as list$3, h as create$1, i as update$1, j as list$4, k as create$2, m as update$2, n as list$5, p as details$1, q as download, t as addFolder, v as addFile, w as imageUpload, x as attachmentUpload, y as purge, z as purgeStatus, C as CachePurgeTarget, A as CachePurgeRequest, B as CachePurgeListQuery, D as CachePurgeView, E as CreateCachePurgeJobOptions, P as PurgeResult, F as CrmCachePurgeOptions } from './
|
|
3
|
-
export { G as CachePurgeDomain, H as CachePurgeMode } from './
|
|
4
|
-
import { p as preLogin, l as login, c as clientSession, h as handoff, a as logout, r as register, v as verifyEmail, b as registerExistingUser, f as forgetPassword, d as resetPassword, e as resetPasswordVerifyToken, g as verifyEmailResend, i as resendEmail, j as changePassword, m as me, k as profile, n as profileUpdate, o as verifyOtp, s as sendMfaOtp, q as pendingPasskeyOptions, t as pendingPasskeyVerify, u as getMfaStatus, w as setMfaPreferences, x as startPhoneVerify, y as confirmPhoneVerify, z as totpEnrollStart, A as totpEnrollVerify, B as totpDisable, C as phoneUnverify, D as backupCodesRegenerate, E as mfaOptOut, F as webauthnRegisterOptions, G as webauthnRegisterVerify, H as webauthnAuthOptions, I as webauthnAuthVerify, J as listWebauthnCredentials, K as deleteWebauthnCredential, L as passkeyLoginOptions, M as passkeyLoginVerify, N as getSecurityOverview, O as getSecurityLoginActivity, P as getSecuritySessions, Q as revokeSecuritySession, R as revokeOtherSecuritySessions, S as getLoginBootstrap, T as getSsoDetails, U as generateSsoUrl, V as ssoCallback, W as getRefreshToken, X as refreshSession, Y as getAuthRefreshToken, Z as getAccessToken, _ as
|
|
5
|
-
export {
|
|
2
|
+
import { l as list, a as list$1, b as list$2, s as sideBarList, f as form, o as objectFormOptions, d as details, u as update, c as create, e as createExisting, r as removeExisting, g as list$3, h as create$1, i as update$1, j as list$4, k as create$2, m as update$2, n as list$5, p as details$1, q as download, t as addFolder, v as addFile, w as imageUpload, x as attachmentUpload, y as purge, z as purgeStatus, C as CachePurgeTarget, A as CachePurgeRequest, B as CachePurgeListQuery, D as CachePurgeView, E as CreateCachePurgeJobOptions, P as PurgeResult, F as CrmCachePurgeOptions } from './pipeline-ui-DbEzI_v1.js';
|
|
3
|
+
export { G as CachePurgeDomain, H as CachePurgeMode, I as HUBSPOT_DEALS_OBJECT_TYPE_ID, J as HUBSPOT_TICKETS_OBJECT_TYPE_ID, K as PIPELINE_BOARD_OBJECT_TYPE_IDS, L as PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS, M as isPipelineBoardObjectType, N as isPipelineBoardObjectTypeId, O as shouldShowPipelineSelector, Q as supportsBoardView } from './pipeline-ui-DbEzI_v1.js';
|
|
4
|
+
import { p as preLogin, l as login, c as clientSession, h as handoff, a as logout, r as register, v as verifyEmail, b as registerExistingUser, f as forgetPassword, d as resetPassword, e as resetPasswordVerifyToken, g as verifyEmailResend, i as resendEmail, j as changePassword, m as me, k as profile, n as profileUpdate, o as verifyOtp, s as sendMfaOtp, q as pendingPasskeyOptions, t as pendingPasskeyVerify, u as getMfaStatus, w as setMfaPreferences, x as startPhoneVerify, y as confirmPhoneVerify, z as totpEnrollStart, A as totpEnrollVerify, B as totpDisable, C as phoneUnverify, D as backupCodesRegenerate, E as mfaOptOut, F as webauthnRegisterOptions, G as webauthnRegisterVerify, H as webauthnAuthOptions, I as webauthnAuthVerify, J as listWebauthnCredentials, K as deleteWebauthnCredential, L as passkeyLoginOptions, M as passkeyLoginVerify, N as getSecurityOverview, O as getSecurityLoginActivity, P as getSecuritySessions, Q as revokeSecuritySession, R as revokeOtherSecuritySessions, S as getLoginBootstrap, T as getSsoDetails, U as generateSsoUrl, V as ssoCallback, W as getRefreshToken, X as refreshSession, Y as getAuthRefreshToken, Z as getAccessToken, _ as setAccessToken, $ as clearAccessToken, a0 as isAuthenticated, a1 as isAuthenticateApp, a2 as isAccessTokenExpired, a3 as isExpiresAccessToken, a4 as hasRefreshSession, a5 as hasValidAccessToken, a6 as didLastRefreshFail, a7 as isSessionRefreshExhausted, a8 as isRefreshInFlight, a9 as resetSessionAuthState, aa as clearSessionRefreshExhaustedState, ab as hydrateSessionRefreshState, ac as SessionContractInput, ad as LoggerConfig, ae as TwoFaVerificationRequest, af as MfaOtpSendRequest, ag as MfaPendingPasskeyOptionsRequest, ah as MfaPendingPasskeyVerifyRequest, ai as MfaStatusQuery, aj as MfaPreferenceRequest, ak as PhoneVerifyStartRequest, al as PhoneVerifyConfirmRequest, am as TotpEnrollVerifyRequest, an as TotpDisableRequest, ao as PhoneUnverifyRequest, ap as BackupCodesRegenerateRequest, aq as MfaBackupCodesResponse, ar as MfaOptOutRequest, as as WebAuthnVerifyRequest, at as PasskeyLoginOptionsRequest, au as PasskeyLoginVerifyRequest, av as SecurityOverviewQuery, aw as SecurityLoginActivityQuery, ax as SecuritySessionsQuery, ay as RevokeSecuritySessionPayload } from './http-errors-CCCQECil.js';
|
|
5
|
+
export { az as ActiveSession, aA as ApiErrorPayload, aB as AuthErrorAction, aC as AuthErrorCode, aD as AuthErrorCodeValue, aE as AuthFunnelState, aF as AuthInterceptorPolicyConfig, aG as AuthPolicyRoutes, aH as AuthRouteAction, aI as HttpClientConfig, aJ as HttpErrorKind, aK as HydrateMfaPendingAccessTokenInput, aL as LogLevel, aM as LoginHistoryRow, aN as LoginResponseData, aO as MfaBootRecoveryResult, aP as MfaEnrollmentStatus, aQ as MfaMethod, aR as MfaMethodOption, aS as MfaPendingAccessToken, aT as MfaPortalScopeContext, aU as MfaStorageLane, aV as PaginationResponse, aW as SERVICE_UNAVAILABLE_MESSAGE, aX as SecurityOverview, aY as StorageKeyConfig, aZ as StoredAuthError, a_ as UnauthorizedPageCopy, a$ as WoodsportalRequestConfig, b0 as classifyHttpError, b1 as clearMfaPendingAccessToken, b2 as configureStorageKeys, b3 as getFieldErrors, b4 as getFormErrors, b5 as getHttpErrorMessage, b6 as getStorageKeys, b7 as getUnauthorizedPageCopy, b8 as hasAuthenticatedAccess, b9 as hasValidAccess, ba as hydrateMfaPendingAccessToken, bb as initializeHttpClient, bc as isFullyAuthenticated, bd as isMfaPendingAccessSession, be as isMfaPendingSession, bf as isOptionalAuthFailureUrl, bg as isServiceUnavailableError, bh as isSessionProbeUrl, bi as parseApiErrorPayload, bj as persistAuthError, bk as readMfaPendingAccessToken, bl as readPersistedAuthError, bm as recoverMfaGateOnBoot, bn as resetStorageKeysForTests, bo as resolveAuthErrorAction, bp as resolveAuthRouteAction, bq as setSessionLifecycleListener, br as startVisibilityRefreshScheduler, bs as stopVisibilityRefreshScheduler, bt as storeMfaPendingAccessToken } from './http-errors-CCCQECil.js';
|
|
6
6
|
import { P as PreLoginPayload, L as LoginPayload, V as VerifyEmailPayload, R as ResetPasswordVerifyTokenPayload, a as ResetPasswordPayload, F as ForgetPasswordPayload, C as ChangePasswordPayload } from './index-Bh9eY8sA.js';
|
|
7
7
|
export { b as Config, M as MutationOptions } from './index-Bh9eY8sA.js';
|
|
8
8
|
import 'axios';
|
|
@@ -18,6 +18,7 @@ declare const WP_STORAGE_KEYS: {
|
|
|
18
18
|
readonly sub: "wp.c.auth.sub";
|
|
19
19
|
readonly emailOk: "wp.c.auth.emailOk";
|
|
20
20
|
readonly err: "wp.c.auth.err";
|
|
21
|
+
readonly refreshExhausted: "wp.c.auth.refreshExhausted";
|
|
21
22
|
readonly rev: "wp.c.auth.rev";
|
|
22
23
|
readonly refreshLock: "wp.c.auth.refreshLock";
|
|
23
24
|
readonly iframeRtPrefix: "wp.c.auth.rt.";
|
|
@@ -32,6 +33,10 @@ declare const WP_STORAGE_KEYS: {
|
|
|
32
33
|
readonly force: "wp.c.login.force";
|
|
33
34
|
readonly passkey: "wp.c.login.passkey";
|
|
34
35
|
readonly done: "wp.c.login.done";
|
|
36
|
+
readonly outcome: "wp.c.login.outcome";
|
|
37
|
+
readonly registerPayload: "wp.c.login.registerPayload";
|
|
38
|
+
readonly awaitingVerify: "wp.c.login.awaitingVerify";
|
|
39
|
+
readonly returnPath: "wp.c.login.returnPath";
|
|
35
40
|
};
|
|
36
41
|
readonly mfa: {
|
|
37
42
|
readonly methods: "wp.c.mfa.methods";
|
|
@@ -44,6 +49,9 @@ declare const WP_STORAGE_KEYS: {
|
|
|
44
49
|
readonly enrolled: "wp.c.mfa.enrolled";
|
|
45
50
|
readonly emailOk: "wp.c.mfa.emailOk";
|
|
46
51
|
readonly phoneOk: "wp.c.mfa.phoneOk";
|
|
52
|
+
readonly pendingToken: "wp.c.mfa.pendingToken";
|
|
53
|
+
readonly pendingTokenExp: "wp.c.mfa.pendingTokenExp";
|
|
54
|
+
readonly otpSend: "wp.c.mfa.otpSend";
|
|
47
55
|
};
|
|
48
56
|
readonly sso: {
|
|
49
57
|
readonly cb: "wp.c.sso.cb";
|
|
@@ -89,6 +97,9 @@ declare const WP_STORAGE_KEYS: {
|
|
|
89
97
|
readonly enrolled: "wp.a.mfa.enrolled";
|
|
90
98
|
readonly emailOk: "wp.a.mfa.emailOk";
|
|
91
99
|
readonly phoneOk: "wp.a.mfa.phoneOk";
|
|
100
|
+
readonly pendingToken: "wp.a.mfa.pendingToken";
|
|
101
|
+
readonly pendingTokenExp: "wp.a.mfa.pendingTokenExp";
|
|
102
|
+
readonly otpSend: "wp.a.mfa.otpSend";
|
|
92
103
|
};
|
|
93
104
|
readonly sso: {
|
|
94
105
|
readonly cbPrefix: "wp.a.sso.cb.";
|
|
@@ -170,6 +181,7 @@ declare const api: {
|
|
|
170
181
|
refreshSession: typeof refreshSession;
|
|
171
182
|
refreshAccessToken: typeof getAuthRefreshToken;
|
|
172
183
|
getAccessToken: typeof getAccessToken;
|
|
184
|
+
setAccessToken: typeof setAccessToken;
|
|
173
185
|
clearAccessToken: typeof clearAccessToken;
|
|
174
186
|
isAuthenticated: typeof isAuthenticated;
|
|
175
187
|
isAuthenticateApp: typeof isAuthenticateApp;
|
|
@@ -182,6 +194,8 @@ declare const api: {
|
|
|
182
194
|
isSessionRefreshExhausted: typeof isSessionRefreshExhausted;
|
|
183
195
|
isRefreshInFlight: typeof isRefreshInFlight;
|
|
184
196
|
resetSessionAuthState: typeof resetSessionAuthState;
|
|
197
|
+
clearSessionRefreshExhaustedState: typeof clearSessionRefreshExhaustedState;
|
|
198
|
+
hydrateSessionRefreshState: typeof hydrateSessionRefreshState;
|
|
185
199
|
contract: () => SessionContractInput;
|
|
186
200
|
isFullyAuthenticated: () => boolean;
|
|
187
201
|
hasAuthenticatedAccess: () => boolean;
|
package/dist/index.js
CHANGED
|
@@ -1,18 +1,20 @@
|
|
|
1
|
-
export { applyCrossTabSessionRevocation, clearClientSdkSession, installCrossTabSessionListener, resetSessionStores, signalSessionChanged } from './chunk-
|
|
2
|
-
import { authApi } from './chunk-
|
|
3
|
-
export { hasAuthenticatedAccess, hasValidAccess, isFullyAuthenticated, isMfaPendingSession, recoverMfaGateOnBoot, resolveAuthRouteAction } from './chunk-
|
|
4
|
-
export { isOptionalAuthFailureUrl, isSessionProbeUrl, persistAuthError, readPersistedAuthError, resolveAuthErrorAction } from './chunk-
|
|
5
|
-
import { crmApi } from './chunk-
|
|
1
|
+
export { applyCrossTabSessionRevocation, clearClientSdkSession, installCrossTabSessionListener, resetSessionStores, signalSessionChanged } from './chunk-XIKYPNO5.js';
|
|
2
|
+
import { authApi } from './chunk-PQQSIYD3.js';
|
|
3
|
+
export { hasAuthenticatedAccess, hasValidAccess, isFullyAuthenticated, isMfaPendingSession, recoverMfaGateOnBoot, resolveAuthRouteAction } from './chunk-PQQSIYD3.js';
|
|
4
|
+
export { isOptionalAuthFailureUrl, isSessionProbeUrl, persistAuthError, readPersistedAuthError, resolveAuthErrorAction } from './chunk-PRGN3FF6.js';
|
|
5
|
+
import { crmApi } from './chunk-QIM5H7OG.js';
|
|
6
|
+
export { isPipelineBoardObjectType, shouldShowPipelineSelector, supportsBoardView } from './chunk-QIM5H7OG.js';
|
|
6
7
|
import './chunk-55MIERLJ.js';
|
|
7
|
-
import { navigationApi } from './chunk-
|
|
8
|
-
export { Client, SERVICE_UNAVAILABLE_MESSAGE, buildCachePurgeRequest, buildCrmListPurgeTarget, buildCrmSinglePurgeTarget, buildEngagementPurgeTarget, buildPortalConfigPurgeTarget, buildUserSessionPurgeTarget, classifyHttpError, createCachePurgeJob, extractEngagementItemIdFromWriteResponse, extractHubspotRecordIdFromWriteResponse, getFieldErrors, getFormErrors, getHttpErrorMessage, initializeHttpClient, isServiceUnavailableError, mergePurgeTargets, purgeCrmCombined, purgeCrmDetailAndListAfterCrmWrite, purgeCrmListCache, purgeCrmListCacheAfterCrmWrite, purgeCrmObjectDataCache, purgeCrmRecordCache, purgeEngagementCaches, purgeEngagementCachesAfterCrmWrite, resolveCrmListPurgeQuery, startVisibilityRefreshScheduler, stopVisibilityRefreshScheduler, toCachePurgeListQuery } from './chunk-
|
|
9
|
-
import './chunk-
|
|
10
|
-
import { actions8, syncStore, actions5, emailStore, actions4, noteStore, actions6, userStore, actions2, tableStore, tableUiActions, tableUiStore } from './chunk-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
import { navigationApi } from './chunk-JVM47MG5.js';
|
|
9
|
+
export { Client, SERVICE_UNAVAILABLE_MESSAGE, buildCachePurgeRequest, buildCrmListPurgeTarget, buildCrmSinglePurgeTarget, buildEngagementPurgeTarget, buildPortalConfigPurgeTarget, buildUserSessionPurgeTarget, classifyHttpError, createCachePurgeJob, extractEngagementItemIdFromWriteResponse, extractHubspotRecordIdFromWriteResponse, getFieldErrors, getFormErrors, getHttpErrorMessage, initializeHttpClient, isServiceUnavailableError, mergePurgeTargets, purgeCrmCombined, purgeCrmDetailAndListAfterCrmWrite, purgeCrmListCache, purgeCrmListCacheAfterCrmWrite, purgeCrmObjectDataCache, purgeCrmRecordCache, purgeEngagementCaches, purgeEngagementCachesAfterCrmWrite, resolveCrmListPurgeQuery, startVisibilityRefreshScheduler, stopVisibilityRefreshScheduler, toCachePurgeListQuery } from './chunk-JVM47MG5.js';
|
|
10
|
+
import './chunk-DKWFLCSO.js';
|
|
11
|
+
import { actions8, syncStore, actions5, emailStore, actions4, noteStore, actions6, userStore, actions2, tableStore, tableUiActions, tableUiStore } from './chunk-JKB2SWUN.js';
|
|
12
|
+
export { HUBSPOT_DEALS_OBJECT_TYPE_ID, HUBSPOT_TICKETS_OBJECT_TYPE_ID, PIPELINE_BOARD_OBJECT_TYPE_IDS, PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS, isPipelineBoardObjectTypeId } from './chunk-JKB2SWUN.js';
|
|
13
|
+
import { storage } from './chunk-5NONTYJA.js';
|
|
14
|
+
export { clearMfaPendingAccessToken, configureLogger, config as hubContext, hydrateMfaPendingAccessToken, isMfaPendingAccessSession, readMfaPendingAccessToken, setConfig as setHubContext, setSessionLifecycleListener, storeMfaPendingAccessToken } from './chunk-5NONTYJA.js';
|
|
13
15
|
export { AuthErrorCode, getUnauthorizedPageCopy, parseApiErrorPayload } from './chunk-COHBSTHF.js';
|
|
14
|
-
export { clearClientAuthCookies, clearClientIframeRefreshLocalKeys, clearClientSessionStorageKeys, clearStaleIframeRefreshForOtherHubs, configureStorageKeys, getClientAuthCookieNamesToClear, getStorageKeys, migrateLegacyStorageKeys, resetStorageKeysForTests } from './chunk-
|
|
15
|
-
export { WP_STORAGE_KEYS, WP_UI_THEME, wpClientIframeRefreshExpKey, wpClientIframeRefreshKey } from './chunk-
|
|
16
|
+
export { clearClientAuthCookies, clearClientIframeRefreshLocalKeys, clearClientSessionStorageKeys, clearStaleIframeRefreshForOtherHubs, configureStorageKeys, getClientAuthCookieNamesToClear, getStorageKeys, migrateLegacyStorageKeys, resetStorageKeysForTests } from './chunk-6XIX6R4X.js';
|
|
17
|
+
export { WP_STORAGE_KEYS, WP_UI_THEME, wpClientIframeRefreshExpKey, wpClientIframeRefreshKey } from './chunk-UDAPRD7Z.js';
|
|
16
18
|
|
|
17
19
|
// src/main/api/compose-api.ts
|
|
18
20
|
var api = {
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/main/api/compose-api.ts","../src/main/core/utils/datetime.ts","../src/main/index.ts"],"names":["actions"],"mappings":"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","file":"index.js","sourcesContent":["import { authApi } from './nested-auth-api'\nimport { crmApi } from './nested-crm-api'\nimport { navigationApi } from './navigation-api'\n\n/** Public API — nested domains only (SDK 4.0). */\nexport const api = {\n auth: authApi,\n crm: crmApi,\n navigation: navigationApi\n}\n","/** HubSpot portal default; override when portal timezone is available from config. */\nexport const DEFAULT_HUBSPOT_TIMEZONE = 'Asia/Kolkata'\n\n/**\n * Detect the runtime/browser IANA timezone (e.g. `Asia/Kolkata`).\n * Falls back to the WoodsPortal default timezone when unavailable.\n */\nexport function getCurrentTimeZone(): string {\n try {\n return Intl.DateTimeFormat().resolvedOptions().timeZone || DEFAULT_HUBSPOT_TIMEZONE\n } catch {\n return DEFAULT_HUBSPOT_TIMEZONE\n }\n}\n\n/**\n * Coerce HubSpot-style timestamps (ms string/number) to epoch milliseconds.\n */\nexport function normalizeToTimestamp(value: unknown): number | null {\n if (value == null || value === '') return null\n\n if (typeof value === 'number') {\n return value > 100_000_000_000 ? value : null\n }\n\n if (typeof value === 'string' && /^\\d+$/.test(value)) {\n const n = Number(value)\n return n > 100_000_000_000 ? n : null\n }\n\n if (typeof value === 'string' || value instanceof Date) {\n const date = new Date(value)\n return Number.isNaN(date.getTime()) ? null : date.getTime()\n }\n\n return null\n}\n\n/**\n * GMT offset label aligned with HubSpot activity timeline (e.g. `GMT+5:30`).\n */\nexport function formatGmtOffset(timeZone: string = getCurrentTimeZone(), date: Date = new Date()): string {\n const raw = new Intl.DateTimeFormat('en-US', {\n timeZone,\n timeZoneName: 'longOffset'\n })\n .formatToParts(date)\n .find((part) => part.type === 'timeZoneName')?.value\n\n if (!raw) return ''\n\n // Intl may emit GMT+05:30; HubSpot uses GMT+5:30.\n return raw.replace(/GMT([+-])0(\\d)(?=:)/, 'GMT$1$2')\n}\n\nexport type HubSpotActivityDateTimeParts = {\n date: string\n time: string\n gmtOffset: string\n /** Full HubSpot-style label, e.g. `May 27, 2026 at 11:31 PM GMT+5:30`. */\n formatted: string\n}\n\n/**\n * Format a HubSpot epoch-ms timestamp like the CRM activity timeline.\n */\nexport function formatHubSpotActivityDateTimeParts(timestamp: unknown, timeZone: string = getCurrentTimeZone()): HubSpotActivityDateTimeParts | null {\n const ms = normalizeToTimestamp(timestamp)\n if (ms == null) return null\n\n const date = new Date(ms)\n const datePart = new Intl.DateTimeFormat('en-US', {\n timeZone,\n month: 'long',\n day: 'numeric',\n year: 'numeric'\n }).format(date)\n const timePart = new Intl.DateTimeFormat('en-US', {\n timeZone,\n hour: 'numeric',\n minute: '2-digit',\n hour12: true\n }).format(date)\n const gmtOffset = formatGmtOffset(timeZone, date)\n\n return {\n date: datePart,\n time: timePart,\n gmtOffset,\n formatted: `${datePart} at ${timePart} ${gmtOffset}`.trim()\n }\n}\n\n/**\n * @returns HubSpot activity string, e.g. `May 27, 2026 at 11:31 PM GMT+5:30`, or empty string.\n */\nexport function formatHubSpotActivityDateTime(timestamp: unknown, timeZone: string = getCurrentTimeZone()): string {\n return formatHubSpotActivityDateTimeParts(timestamp, timeZone)?.formatted ?? ''\n}\n","/**\n * WoodsPortal client SDK — public entry module.\n *\n * Configure HTTP once with {@link initializeHttpClient} in production, then use\n * {@link api}, {@link store}, and {@link api.navigation}.\n */\nimport { api } from './api/compose-api'\nimport {\n tableStore,\n tableActions,\n tableUiStore,\n tableUiActions,\n userStore,\n userActions,\n noteStore,\n noteActions,\n emailStore,\n emailActions,\n syncStore,\n syncActions\n} from './state'\nimport { storage } from './core/utils/localStorage'\n\nexport {\n DEFAULT_HUBSPOT_TIMEZONE,\n getCurrentTimeZone,\n formatGmtOffset,\n formatHubSpotActivityDateTime,\n formatHubSpotActivityDateTimeParts,\n normalizeToTimestamp\n} from './core/utils/datetime'\nexport type { HubSpotActivityDateTimeParts } from './core/utils/datetime'\nexport {\n purgeCrmObjectDataCache,\n purgeCrmListCache,\n purgeCrmListCacheAfterCrmWrite,\n purgeCrmDetailAndListAfterCrmWrite,\n purgeCrmRecordCache,\n purgeEngagementCaches,\n purgeEngagementCachesAfterCrmWrite,\n purgeCrmCombined,\n buildCachePurgeRequest,\n buildCrmListPurgeTarget,\n buildCrmSinglePurgeTarget,\n buildEngagementPurgeTarget,\n buildPortalConfigPurgeTarget,\n buildUserSessionPurgeTarget,\n mergePurgeTargets,\n createCachePurgeJob,\n extractHubspotRecordIdFromWriteResponse,\n extractEngagementItemIdFromWriteResponse,\n resolveCrmListPurgeQuery,\n toCachePurgeListQuery\n} from './core/utils/cache'\nexport type { CrmCachePurgeOptions } from './core/types/cache-purge'\nexport type {\n CachePurgeRequest,\n CachePurgeTarget,\n CachePurgeListQuery,\n CachePurgeView,\n CachePurgeDomain,\n CachePurgeMode,\n PurgeResult,\n CreateCachePurgeJobOptions\n} from './core/types/cache-purge'\n\n/** Axios setup, error helpers, and {@link HttpClientConfig}. */\nexport { initializeHttpClient, getFormErrors, getFieldErrors } from './core/http/http-client'\nexport type { HttpClientConfig, StorageKeyConfig } from './core/http/http-client'\n\n/** Shared auth contract (client + admin consistency). */\nexport {\n AuthErrorCode,\n parseApiErrorPayload,\n getUnauthorizedPageCopy,\n resolveAuthErrorAction,\n isOptionalAuthFailureUrl,\n isSessionProbeUrl,\n persistAuthError,\n readPersistedAuthError,\n hasValidAccess,\n isFullyAuthenticated,\n isMfaPendingSession,\n hasAuthenticatedAccess,\n recoverMfaGateOnBoot,\n startVisibilityRefreshScheduler,\n stopVisibilityRefreshScheduler,\n resolveAuthRouteAction\n} from './core/auth/index.js'\nexport type {\n ApiErrorPayload,\n StoredAuthError,\n AuthErrorCodeValue,\n UnauthorizedPageCopy,\n AuthErrorAction,\n AuthPolicyRoutes,\n AuthInterceptorPolicyConfig,\n WoodsportalRequestConfig,\n SessionContractInput,\n MfaBootRecoveryResult,\n AuthRouteAction,\n AuthFunnelState\n} from './core/auth/index.js'\nexport { classifyHttpError, getHttpErrorMessage, isServiceUnavailableError, SERVICE_UNAVAILABLE_MESSAGE } from './core/http/http-errors'\nexport type { HttpErrorKind } from './core/http/http-errors'\n\nexport { configureLogger } from './core/logging/logger'\nexport type { LogLevel, LoggerConfig } from './core/logging/logger-types'\n\nexport { Client } from './core/http/client-assembler'\nexport { config as hubContext, setConfig as setHubContext } from './core/utils/hub-context'\n\nexport { WP_STORAGE_KEYS, WP_UI_THEME, wpClientIframeRefreshKey, wpClientIframeRefreshExpKey } from './core/utils/wp-storage-keys'\nexport {\n migrateLegacyStorageKeys,\n getClientAuthCookieNamesToClear,\n clearClientSessionStorageKeys,\n clearClientIframeRefreshLocalKeys,\n clearStaleIframeRefreshForOtherHubs\n} from './core/utils/storage-migration'\nexport { clearClientAuthCookies } from './core/utils/cookie'\nexport { clearClientSdkSession, resetSessionStores } from './core/http/session-teardown'\nexport { setSessionLifecycleListener } from './core/http/token-store'\nexport { signalSessionChanged, installCrossTabSessionListener, applyCrossTabSessionRevocation } from './core/http/cross-tab-session'\nexport { configureStorageKeys, getStorageKeys, resetStorageKeysForTests } from './core/utils/storage-keys'\n\nexport type {\n Config,\n MutationOptions,\n PreLoginPayload,\n LoginPayload,\n VerifyEmailPayload,\n ResetPasswordVerifyTokenPayload,\n ResetPasswordPayload,\n ForgetPasswordPayload,\n ChangePasswordPayload,\n MfaMethod,\n MfaMethodOption,\n MfaPortalScopeContext,\n LoginResponseData,\n TwoFaVerificationRequest,\n MfaEnrollmentStatus,\n SecurityOverview,\n LoginHistoryRow,\n ActiveSession,\n PaginationResponse\n} from './core/types'\n\nexport { api }\n\n/** Storage helpers and CRM stores. */\nexport const store = {\n storage,\n tableUi: { store: tableUiStore, actions: tableUiActions },\n table: { store: tableStore, actions: tableActions },\n user: { store: userStore, actions: userActions },\n note: { store: noteStore, actions: noteActions },\n email: { store: emailStore, actions: emailActions },\n sync: { store: syncStore, actions: syncActions }\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/main/api/compose-api.ts","../src/main/core/utils/datetime.ts","../src/main/index.ts"],"names":["actions"],"mappings":"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","file":"index.js","sourcesContent":["import { authApi } from './nested-auth-api'\nimport { crmApi } from './nested-crm-api'\nimport { navigationApi } from './navigation-api'\n\n/** Public API — nested domains only (SDK 4.0). */\nexport const api = {\n auth: authApi,\n crm: crmApi,\n navigation: navigationApi\n}\n","/** HubSpot portal default; override when portal timezone is available from config. */\nexport const DEFAULT_HUBSPOT_TIMEZONE = 'Asia/Kolkata'\n\n/**\n * Detect the runtime/browser IANA timezone (e.g. `Asia/Kolkata`).\n * Falls back to the WoodsPortal default timezone when unavailable.\n */\nexport function getCurrentTimeZone(): string {\n try {\n return Intl.DateTimeFormat().resolvedOptions().timeZone || DEFAULT_HUBSPOT_TIMEZONE\n } catch {\n return DEFAULT_HUBSPOT_TIMEZONE\n }\n}\n\n/**\n * Coerce HubSpot-style timestamps (ms string/number) to epoch milliseconds.\n */\nexport function normalizeToTimestamp(value: unknown): number | null {\n if (value == null || value === '') return null\n\n if (typeof value === 'number') {\n return value > 100_000_000_000 ? value : null\n }\n\n if (typeof value === 'string' && /^\\d+$/.test(value)) {\n const n = Number(value)\n return n > 100_000_000_000 ? n : null\n }\n\n if (typeof value === 'string' || value instanceof Date) {\n const date = new Date(value)\n return Number.isNaN(date.getTime()) ? null : date.getTime()\n }\n\n return null\n}\n\n/**\n * GMT offset label aligned with HubSpot activity timeline (e.g. `GMT+5:30`).\n */\nexport function formatGmtOffset(timeZone: string = getCurrentTimeZone(), date: Date = new Date()): string {\n const raw = new Intl.DateTimeFormat('en-US', {\n timeZone,\n timeZoneName: 'longOffset'\n })\n .formatToParts(date)\n .find((part) => part.type === 'timeZoneName')?.value\n\n if (!raw) return ''\n\n // Intl may emit GMT+05:30; HubSpot uses GMT+5:30.\n return raw.replace(/GMT([+-])0(\\d)(?=:)/, 'GMT$1$2')\n}\n\nexport type HubSpotActivityDateTimeParts = {\n date: string\n time: string\n gmtOffset: string\n /** Full HubSpot-style label, e.g. `May 27, 2026 at 11:31 PM GMT+5:30`. */\n formatted: string\n}\n\n/**\n * Format a HubSpot epoch-ms timestamp like the CRM activity timeline.\n */\nexport function formatHubSpotActivityDateTimeParts(timestamp: unknown, timeZone: string = getCurrentTimeZone()): HubSpotActivityDateTimeParts | null {\n const ms = normalizeToTimestamp(timestamp)\n if (ms == null) return null\n\n const date = new Date(ms)\n const datePart = new Intl.DateTimeFormat('en-US', {\n timeZone,\n month: 'long',\n day: 'numeric',\n year: 'numeric'\n }).format(date)\n const timePart = new Intl.DateTimeFormat('en-US', {\n timeZone,\n hour: 'numeric',\n minute: '2-digit',\n hour12: true\n }).format(date)\n const gmtOffset = formatGmtOffset(timeZone, date)\n\n return {\n date: datePart,\n time: timePart,\n gmtOffset,\n formatted: `${datePart} at ${timePart} ${gmtOffset}`.trim()\n }\n}\n\n/**\n * @returns HubSpot activity string, e.g. `May 27, 2026 at 11:31 PM GMT+5:30`, or empty string.\n */\nexport function formatHubSpotActivityDateTime(timestamp: unknown, timeZone: string = getCurrentTimeZone()): string {\n return formatHubSpotActivityDateTimeParts(timestamp, timeZone)?.formatted ?? ''\n}\n","/**\n * WoodsPortal client SDK — public entry module.\n *\n * Configure HTTP once with {@link initializeHttpClient} in production, then use\n * {@link api}, {@link store}, and {@link api.navigation}.\n */\nimport { api } from './api/compose-api'\nimport {\n tableStore,\n tableActions,\n tableUiStore,\n tableUiActions,\n userStore,\n userActions,\n noteStore,\n noteActions,\n emailStore,\n emailActions,\n syncStore,\n syncActions\n} from './state'\nimport { storage } from './core/utils/localStorage'\n\nexport {\n DEFAULT_HUBSPOT_TIMEZONE,\n getCurrentTimeZone,\n formatGmtOffset,\n formatHubSpotActivityDateTime,\n formatHubSpotActivityDateTimeParts,\n normalizeToTimestamp\n} from './core/utils/datetime'\nexport type { HubSpotActivityDateTimeParts } from './core/utils/datetime'\nexport {\n purgeCrmObjectDataCache,\n purgeCrmListCache,\n purgeCrmListCacheAfterCrmWrite,\n purgeCrmDetailAndListAfterCrmWrite,\n purgeCrmRecordCache,\n purgeEngagementCaches,\n purgeEngagementCachesAfterCrmWrite,\n purgeCrmCombined,\n buildCachePurgeRequest,\n buildCrmListPurgeTarget,\n buildCrmSinglePurgeTarget,\n buildEngagementPurgeTarget,\n buildPortalConfigPurgeTarget,\n buildUserSessionPurgeTarget,\n mergePurgeTargets,\n createCachePurgeJob,\n extractHubspotRecordIdFromWriteResponse,\n extractEngagementItemIdFromWriteResponse,\n resolveCrmListPurgeQuery,\n toCachePurgeListQuery\n} from './core/utils/cache'\nexport type { CrmCachePurgeOptions } from './core/types/cache-purge'\nexport type {\n CachePurgeRequest,\n CachePurgeTarget,\n CachePurgeListQuery,\n CachePurgeView,\n CachePurgeDomain,\n CachePurgeMode,\n PurgeResult,\n CreateCachePurgeJobOptions\n} from './core/types/cache-purge'\n\n/** Axios setup, error helpers, and {@link HttpClientConfig}. */\nexport { initializeHttpClient, getFormErrors, getFieldErrors } from './core/http/http-client'\nexport type { HttpClientConfig, StorageKeyConfig } from './core/http/http-client'\n\n/** Shared auth contract (client + admin consistency). */\nexport {\n AuthErrorCode,\n parseApiErrorPayload,\n getUnauthorizedPageCopy,\n resolveAuthErrorAction,\n isOptionalAuthFailureUrl,\n isSessionProbeUrl,\n persistAuthError,\n readPersistedAuthError,\n hasValidAccess,\n isFullyAuthenticated,\n isMfaPendingSession,\n hasAuthenticatedAccess,\n recoverMfaGateOnBoot,\n startVisibilityRefreshScheduler,\n stopVisibilityRefreshScheduler,\n resolveAuthRouteAction,\n storeMfaPendingAccessToken,\n readMfaPendingAccessToken,\n clearMfaPendingAccessToken,\n hydrateMfaPendingAccessToken,\n isMfaPendingAccessSession\n} from './core/auth/index.js'\nexport type {\n ApiErrorPayload,\n StoredAuthError,\n AuthErrorCodeValue,\n UnauthorizedPageCopy,\n AuthErrorAction,\n AuthPolicyRoutes,\n AuthInterceptorPolicyConfig,\n WoodsportalRequestConfig,\n SessionContractInput,\n MfaBootRecoveryResult,\n AuthRouteAction,\n AuthFunnelState,\n MfaStorageLane,\n MfaPendingAccessToken,\n HydrateMfaPendingAccessTokenInput\n} from './core/auth/index.js'\nexport { classifyHttpError, getHttpErrorMessage, isServiceUnavailableError, SERVICE_UNAVAILABLE_MESSAGE } from './core/http/http-errors'\nexport type { HttpErrorKind } from './core/http/http-errors'\n\nexport { configureLogger } from './core/logging/logger'\nexport type { LogLevel, LoggerConfig } from './core/logging/logger-types'\n\nexport { Client } from './core/http/client-assembler'\nexport { config as hubContext, setConfig as setHubContext } from './core/utils/hub-context'\n\nexport { WP_STORAGE_KEYS, WP_UI_THEME, wpClientIframeRefreshKey, wpClientIframeRefreshExpKey } from './core/utils/wp-storage-keys'\nexport {\n migrateLegacyStorageKeys,\n getClientAuthCookieNamesToClear,\n clearClientSessionStorageKeys,\n clearClientIframeRefreshLocalKeys,\n clearStaleIframeRefreshForOtherHubs\n} from './core/utils/storage-migration'\nexport { clearClientAuthCookies } from './core/utils/cookie'\nexport { clearClientSdkSession, resetSessionStores } from './core/http/session-teardown'\nexport { setSessionLifecycleListener } from './core/http/token-store'\nexport { signalSessionChanged, installCrossTabSessionListener, applyCrossTabSessionRevocation } from './core/http/cross-tab-session'\nexport { configureStorageKeys, getStorageKeys, resetStorageKeysForTests } from './core/utils/storage-keys'\n\nexport {\n HUBSPOT_DEALS_OBJECT_TYPE_ID,\n HUBSPOT_TICKETS_OBJECT_TYPE_ID,\n PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS,\n PIPELINE_BOARD_OBJECT_TYPE_IDS,\n isPipelineBoardObjectTypeId\n} from './core/constants/hubspot-object-type-ids'\nexport { isPipelineBoardObjectType, supportsBoardView, shouldShowPipelineSelector } from './core/constants/pipeline-ui'\n\nexport type {\n Config,\n MutationOptions,\n PreLoginPayload,\n LoginPayload,\n VerifyEmailPayload,\n ResetPasswordVerifyTokenPayload,\n ResetPasswordPayload,\n ForgetPasswordPayload,\n ChangePasswordPayload,\n MfaMethod,\n MfaMethodOption,\n MfaPortalScopeContext,\n LoginResponseData,\n TwoFaVerificationRequest,\n MfaEnrollmentStatus,\n SecurityOverview,\n LoginHistoryRow,\n ActiveSession,\n PaginationResponse\n} from './core/types'\n\nexport { api }\n\n/** Storage helpers and CRM stores. */\nexport const store = {\n storage,\n tableUi: { store: tableUiStore, actions: tableUiActions },\n table: { store: tableStore, actions: tableActions },\n user: { store: userStore, actions: userActions },\n note: { store: noteStore, actions: noteActions },\n email: { store: emailStore, actions: emailActions },\n sync: { store: syncStore, actions: syncActions }\n}\n"]}
|
|
@@ -230,7 +230,19 @@ type CrmCachePurgeOptions = {
|
|
|
230
230
|
warmListDelayMs?: number;
|
|
231
231
|
engagementItemIds?: string[];
|
|
232
232
|
waitForWarm?: boolean;
|
|
233
|
+
pollTimeoutMs?: number;
|
|
234
|
+
pollIntervalMs?: number;
|
|
233
235
|
idempotencyKey?: string;
|
|
234
236
|
};
|
|
235
237
|
|
|
236
|
-
|
|
238
|
+
declare const HUBSPOT_DEALS_OBJECT_TYPE_ID = "0-3";
|
|
239
|
+
declare const HUBSPOT_TICKETS_OBJECT_TYPE_ID = "0-5";
|
|
240
|
+
declare const PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS: readonly ["0-421", "0-162", "0-970", "0-420", "0-410"];
|
|
241
|
+
declare const PIPELINE_BOARD_OBJECT_TYPE_IDS: readonly ["0-3", "0-5", "0-421", "0-162", "0-970", "0-420", "0-410"];
|
|
242
|
+
declare function isPipelineBoardObjectTypeId(objectTypeId: string | undefined | null): boolean;
|
|
243
|
+
|
|
244
|
+
declare function isPipelineBoardObjectType(objectTypeId: string | undefined | null): boolean;
|
|
245
|
+
declare function supportsBoardView(objectTypeId: string | undefined | null): boolean;
|
|
246
|
+
declare function shouldShowPipelineSelector(objectTypeId: string | undefined | null, pipelineCount: number): boolean;
|
|
247
|
+
|
|
248
|
+
export { type CachePurgeRequest as A, type CachePurgeListQuery as B, type CachePurgeTarget as C, type CachePurgeView as D, type CreateCachePurgeJobOptions as E, type CrmCachePurgeOptions as F, type CachePurgeDomain as G, type CachePurgeMode as H, HUBSPOT_DEALS_OBJECT_TYPE_ID as I, HUBSPOT_TICKETS_OBJECT_TYPE_ID as J, PIPELINE_BOARD_OBJECT_TYPE_IDS as K, PIPELINE_REQUIRED_MANAGED_OBJECT_TYPE_IDS as L, isPipelineBoardObjectType as M, isPipelineBoardObjectTypeId as N, shouldShowPipelineSelector as O, type PurgeResult as P, supportsBoardView as Q, list$1 as a, list$2 as b, create as c, details as d, createExisting as e, form as f, list$3 as g, create$1 as h, update$1 as i, list$4 as j, create$2 as k, list as l, update$2 as m, list$5 as n, objectFormOptions as o, details$1 as p, download as q, removeExisting as r, sideBarList as s, addFolder as t, update as u, addFile as v, imageUpload as w, attachmentUpload as x, purge as y, purgeStatus as z };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { clearClientIframeRefreshLocalKeys, clearClientSessionStorageKeys, clearStaleIframeRefreshForOtherHubs, getClientAuthCookieNamesToClear, migrateLegacyStorageKeys } from './chunk-6XIX6R4X.js';
|
|
2
|
+
import './chunk-UDAPRD7Z.js';
|
|
3
|
+
//# sourceMappingURL=storage-migration-2NVJ3GNQ.js.map
|
|
4
|
+
//# sourceMappingURL=storage-migration-2NVJ3GNQ.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":[],"names":[],"mappings":"","file":"storage-migration-
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"storage-migration-2NVJ3GNQ.js"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "woodsportal-client-sdk",
|
|
3
|
-
"version": "4.0.7-dev.
|
|
3
|
+
"version": "4.0.7-dev.10",
|
|
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",
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export { isOptionalAuthFailureUrl, isSessionProbeUrl, persistAuthError, readPersistedAuthError, resolveAuthErrorAction } from './chunk-DZC3DJUO.js';
|
|
2
|
-
import './chunk-COHBSTHF.js';
|
|
3
|
-
import './chunk-6ROV3EE2.js';
|
|
4
|
-
//# sourceMappingURL=auth-interceptor-policy-BSY5KIIA.js.map
|
|
5
|
-
//# sourceMappingURL=auth-interceptor-policy-BSY5KIIA.js.map
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
export { getPortal, getProfile, getRefreshToken, getSubscriptionType, setAccessToken, setLoggedInDetails, setPortal, setProfileDetails, setRefreshToken, setSubscriptionType } from './chunk-ADOV2R3A.js';
|
|
2
|
-
import './chunk-YOT5RW3R.js';
|
|
3
|
-
import './chunk-6ROV3EE2.js';
|
|
4
|
-
//# sourceMappingURL=auth-utils-XIHNYE63.js.map
|
|
5
|
-
//# sourceMappingURL=auth-utils-XIHNYE63.js.map
|