@dynamic-labs-sdk/client 1.6.0 → 1.7.0
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/{InvalidParamError-DyXEKMWn.cjs → InvalidParamError-CTssOe86.cjs} +105 -993
- package/dist/InvalidParamError-CTssOe86.cjs.map +1 -0
- package/dist/{InvalidParamError-BIptAjbC.native.esm.js → InvalidParamError-Crwntjl7.native.esm.js} +90 -828
- package/dist/InvalidParamError-Crwntjl7.native.esm.js.map +1 -0
- package/dist/{InvalidParamError-BZ0LHaml.esm.js → InvalidParamError-fQLJaGBW.esm.js} +90 -795
- package/dist/InvalidParamError-fQLJaGBW.esm.js.map +1 -0
- package/dist/{NotWaasWalletAccountError-CElqwdQO.cjs → NotWaasWalletAccountError-2RaDipZu.cjs} +4 -4
- package/dist/NotWaasWalletAccountError-2RaDipZu.cjs.map +1 -0
- package/dist/{NotWaasWalletAccountError-nT4jrLbp.esm.js → NotWaasWalletAccountError-BJLGGYmU.native.esm.js} +4 -4
- package/dist/NotWaasWalletAccountError-BJLGGYmU.native.esm.js.map +1 -0
- package/dist/{NotWaasWalletAccountError-BbOA5rPd.native.esm.js → NotWaasWalletAccountError-DF_S7gqo.esm.js} +4 -4
- package/dist/NotWaasWalletAccountError-DF_S7gqo.esm.js.map +1 -0
- package/dist/core.cjs +23 -23
- package/dist/core.cjs.map +1 -1
- package/dist/core.esm.js +5 -5
- package/dist/core.native.esm.js +5 -5
- package/dist/{getNetworkProviderFromNetworkId-B7DIqT2T.native.esm.js → getNetworkProviderFromNetworkId-BCSmILlH.native.esm.js} +310 -39
- package/dist/getNetworkProviderFromNetworkId-BCSmILlH.native.esm.js.map +1 -0
- package/dist/{getNetworkProviderFromNetworkId-BkAPIdRC.esm.js → getNetworkProviderFromNetworkId-BWhaD23J.esm.js} +276 -38
- package/dist/getNetworkProviderFromNetworkId-BWhaD23J.esm.js.map +1 -0
- package/dist/{getNetworkProviderFromNetworkId-DbI5MZhq.cjs → getNetworkProviderFromNetworkId-C1p9Rrg3.cjs} +351 -44
- package/dist/getNetworkProviderFromNetworkId-C1p9Rrg3.cjs.map +1 -0
- package/dist/{getSignedSessionId-BF6n8gve.cjs → getSignedSessionId-CxxYNC_8.cjs} +3 -3
- package/dist/{getSignedSessionId-BF6n8gve.cjs.map → getSignedSessionId-CxxYNC_8.cjs.map} +1 -1
- package/dist/{getSignedSessionId-1TV-x__C.native.esm.js → getSignedSessionId-DPOXdh6y.native.esm.js} +3 -3
- package/dist/{getSignedSessionId-1TV-x__C.native.esm.js.map → getSignedSessionId-DPOXdh6y.native.esm.js.map} +1 -1
- package/dist/{getSignedSessionId-y3YtxFHZ.esm.js → getSignedSessionId-c7dS4PQ9.esm.js} +3 -3
- package/dist/{getSignedSessionId-y3YtxFHZ.esm.js.map → getSignedSessionId-c7dS4PQ9.esm.js.map} +1 -1
- package/dist/getVerifiedCredentialForWalletAccount-Cahp763h.esm.js +701 -0
- package/dist/getVerifiedCredentialForWalletAccount-Cahp763h.esm.js.map +1 -0
- package/dist/getVerifiedCredentialForWalletAccount-Di8dM5Wx.cjs +887 -0
- package/dist/getVerifiedCredentialForWalletAccount-Di8dM5Wx.cjs.map +1 -0
- package/dist/getVerifiedCredentialForWalletAccount-DuNbORNW.native.esm.js +701 -0
- package/dist/getVerifiedCredentialForWalletAccount-DuNbORNW.native.esm.js.map +1 -0
- package/dist/index.cjs +76 -76
- package/dist/index.cjs.map +1 -1
- package/dist/index.esm.js +14 -14
- package/dist/index.esm.js.map +1 -1
- package/dist/index.native.esm.js +14 -14
- package/dist/index.native.esm.js.map +1 -1
- package/dist/{isMfaRequiredForAction-Dy4-S3mr.esm.js → isMfaRequiredForAction-BjRvPrU6.esm.js} +2 -2
- package/dist/{isMfaRequiredForAction-Dy4-S3mr.esm.js.map → isMfaRequiredForAction-BjRvPrU6.esm.js.map} +1 -1
- package/dist/{isMfaRequiredForAction-B2vKX31S.native.esm.js → isMfaRequiredForAction-D8G5PBAd.native.esm.js} +2 -2
- package/dist/{isMfaRequiredForAction-B2vKX31S.native.esm.js.map → isMfaRequiredForAction-D8G5PBAd.native.esm.js.map} +1 -1
- package/dist/{isMfaRequiredForAction-K2Jh-3-j.cjs → isMfaRequiredForAction-hlhj0qAC.cjs} +2 -2
- package/dist/{isMfaRequiredForAction-K2Jh-3-j.cjs.map → isMfaRequiredForAction-hlhj0qAC.cjs.map} +1 -1
- package/dist/modules/apiClient/apiClient.types.d.ts +0 -12
- package/dist/modules/apiClient/apiClient.types.d.ts.map +1 -1
- package/dist/modules/apiClient/createApiClient.d.ts.map +1 -1
- package/dist/modules/auth/logoutReason.d.ts +1 -1
- package/dist/modules/auth/logoutReason.d.ts.map +1 -1
- package/dist/modules/auth/logoutWithReason/logoutWithReason.d.ts.map +1 -1
- package/dist/modules/deviceRegistration/getRegisteredDevices/getRegisteredDevices.d.ts.map +1 -1
- package/dist/modules/user/refreshAuth/refreshAuth.d.ts.map +1 -1
- package/dist/modules/waas/backupWaasKeySharesToGoogleDrive/backupWaasKeySharesToGoogleDrive.d.ts +12 -1
- package/dist/modules/waas/backupWaasKeySharesToGoogleDrive/backupWaasKeySharesToGoogleDrive.d.ts.map +1 -1
- package/dist/modules/waas/createWaasProvider/createWaasProvider.d.ts.map +1 -1
- package/dist/modules/waas/waas.types.d.ts +1 -0
- package/dist/modules/waas/waas.types.d.ts.map +1 -1
- package/dist/tsconfig.lib.tsbuildinfo +1 -1
- package/dist/waas.cjs +12 -9
- package/dist/waas.cjs.map +1 -1
- package/dist/waas.esm.js +6 -4
- package/dist/waas.esm.js.map +1 -1
- package/dist/waas.native.esm.js +6 -4
- package/dist/waas.native.esm.js.map +1 -1
- package/dist/waasCore.cjs +6 -4
- package/dist/waasCore.cjs.map +1 -1
- package/dist/waasCore.esm.js +5 -4
- package/dist/waasCore.esm.js.map +1 -1
- package/dist/waasCore.native.esm.js +5 -4
- package/dist/waasCore.native.esm.js.map +1 -1
- package/package.json +4 -2
- package/dist/InvalidParamError-BIptAjbC.native.esm.js.map +0 -1
- package/dist/InvalidParamError-BZ0LHaml.esm.js.map +0 -1
- package/dist/InvalidParamError-DyXEKMWn.cjs.map +0 -1
- package/dist/NotWaasWalletAccountError-BbOA5rPd.native.esm.js.map +0 -1
- package/dist/NotWaasWalletAccountError-CElqwdQO.cjs.map +0 -1
- package/dist/NotWaasWalletAccountError-nT4jrLbp.esm.js.map +0 -1
- package/dist/getNetworkProviderFromNetworkId-B7DIqT2T.native.esm.js.map +0 -1
- package/dist/getNetworkProviderFromNetworkId-BkAPIdRC.esm.js.map +0 -1
- package/dist/getNetworkProviderFromNetworkId-DbI5MZhq.cjs.map +0 -1
- package/dist/getVerifiedCredentialForWalletAccount-BfJ29erz.cjs +0 -346
- package/dist/getVerifiedCredentialForWalletAccount-BfJ29erz.cjs.map +0 -1
- package/dist/getVerifiedCredentialForWalletAccount-CLyC2nOl.native.esm.js +0 -269
- package/dist/getVerifiedCredentialForWalletAccount-CLyC2nOl.native.esm.js.map +0 -1
- package/dist/getVerifiedCredentialForWalletAccount-etV50QRH.esm.js +0 -269
- package/dist/getVerifiedCredentialForWalletAccount-etV50QRH.esm.js.map +0 -1
- package/dist/modules/apiClient/utils/sessionExpiryLogoutMiddleware/createSessionExpiryLogoutMiddleware.d.ts +0 -27
- package/dist/modules/apiClient/utils/sessionExpiryLogoutMiddleware/createSessionExpiryLogoutMiddleware.d.ts.map +0 -1
package/dist/index.esm.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { A as GENERATE_SESSION_KEYS_TRACKER_KEY, B as
|
|
3
|
-
import { a as parseElevatedAccessToken, d as isUserMissingMfaAuth, f as checkAndRaiseWalletAccountsChangedEvent, i as upsertElevatedAccessToken, n as getWalletProviderByKey, o as restoreUserSharesForAllWalletAccounts, r as updateAuthFromVerifyResponse, t as getVerifiedCredentialForWalletAccount, u as getWalletProviders } from "./getVerifiedCredentialForWalletAccount-
|
|
4
|
-
import { n as __refreshAuth_wrapped, t as NotWaasWalletAccountError } from "./NotWaasWalletAccountError-
|
|
5
|
-
import { n as getMfaMethods, r as __consumeMfaToken_wrapped, t as isMfaRequiredForAction } from "./isMfaRequiredForAction-
|
|
1
|
+
import { A as getUserAgent, B as getCore, C as isCookieEnabled, D as instrumentFunction, E as __getElevatedAccessToken_wrapped, F as NONCE_POOL_SIZE, H as version, I as getDefaultClient, L as setDefaultClient, M as randomString, O as scrubParameters, T as ValueMustBeDefinedError, V as name, _ as MfaRateLimitedError, a as DYNAMIC_ICONIC_SPRITE_URL, b as InvalidExternalAuthError, c as CHAINS_INFO_MAP, d as UnauthorizedError, g as SandboxMaximumThresholdReachedError, h as getNonce, j as extractSessionId, k as DEFAULT_PII_FIELDS, l as fetchAndStoreNonces, o as SDK_API_CORE_VERSION, s as getChainFromVerifiedCredentialChain, t as InvalidParamError, u as createApiClient, v as MfaInvalidOtpError, w as assertDefined, x as APIError, y as LinkCredentialError, z as BaseError } from "./InvalidParamError-fQLJaGBW.esm.js";
|
|
2
|
+
import { A as GENERATE_SESSION_KEYS_TRACKER_KEY, B as createStorage, C as createKeychainService, D as CannotTrackError, F as getBuffer, G as subscribeWithSelector, H as createLocalStorageAdapter, I as __logoutWithReason_wrapped, K as isEqualShallow, L as generateSessionKeys, M as REFRESH_USER_STATE_FROM_COOKIE_TRACKER_KEY, N as REFRESH_USER_STATE_FROM_VALID_TOKEN_TRACKER_KEY, O as createDeferredPromise, P as isServerSideRendering, R as fetchProjectSettings, S as createRealtimeService, T as createCrossTabBroadcast, U as isSignedIn, W as retryOnFail, _ as isCaptchaRequired, a as verifyMessageSignatureOwnership, b as NoNetworkProvidersError, c as formatSignInMessage, d as updateWalletProviderKeysForVerifiedCredentials, f as setUnverifiedWalletAccounts, g as consumeCaptchaToken, h as __setCaptchaToken_wrapped, i as getNetworksData, j as INITIALIZE_STORAGE_SYNC_TRACKER_KEY, k as FETCH_PROJECT_SETTINGS_TRACKER_KEY, l as getAppMetadata, m as hasExtension, o as removeUnverifiedWalletAccount, p as createVisit, s as createSignInMessageStatement, t as getNetworkProviderFromNetworkId, u as reconcileWalletAccountsAgainstClient, v as MethodNotImplementedError, w as createLogger, x as getKeychainIndexedDBName, y as WalletAlreadyLinkedToAnotherUserError, z as createStorageKeySchema } from "./getNetworkProviderFromNetworkId-BWhaD23J.esm.js";
|
|
3
|
+
import { A as onceEvent, C as formatWalletAccountId, D as emitEvent, O as offEvent, T as splitWalletProviderKey, _ as getWalletProviderRegistry, a as parseElevatedAccessToken, b as getWalletAccounts, d as isUserMissingMfaAuth, f as checkAndRaiseWalletAccountsChangedEvent, g as WalletProviderPriority, h as getWalletProviderFromWalletAccount, i as upsertElevatedAccessToken, k as onEvent, n as getWalletProviderByKey, o as restoreUserSharesForAllWalletAccounts, r as updateAuthFromVerifyResponse, t as getVerifiedCredentialForWalletAccount, u as getWalletProviders, w as normalizeAddress, y as NoWalletProviderFoundError } from "./getVerifiedCredentialForWalletAccount-Cahp763h.esm.js";
|
|
4
|
+
import { n as __refreshAuth_wrapped, t as NotWaasWalletAccountError } from "./NotWaasWalletAccountError-DF_S7gqo.esm.js";
|
|
5
|
+
import { n as getMfaMethods, r as __consumeMfaToken_wrapped, t as isMfaRequiredForAction } from "./isMfaRequiredForAction-BjRvPrU6.esm.js";
|
|
6
6
|
import { assertPackageVersion } from "@dynamic-labs-sdk/assert-package-version";
|
|
7
7
|
import { AuthModeEnum, ExchangeKeyEnum, JwtVerifiedCredentialFormatEnum, MFAAction, MfaBackupCodeAcknowledgement, ProviderEnum, TokenScope, WaasBackupOptionsEnum, WalletProviderEnum } from "@dynamic-labs/sdk-api-core";
|
|
8
8
|
import * as z from "zod/mini";
|
|
@@ -55,6 +55,14 @@ const appendConnectionUriToDeeplink = ({ connectionUri, deeplinkUrl }) => {
|
|
|
55
55
|
return url.href;
|
|
56
56
|
};
|
|
57
57
|
|
|
58
|
+
//#endregion
|
|
59
|
+
//#region src/utils/getNonce/prefetchNoncesIfNeeded/prefetchNoncesIfNeeded.ts
|
|
60
|
+
/** @not-instrumented */
|
|
61
|
+
const prefetchNoncesIfNeeded = async (client) => {
|
|
62
|
+
if (getCore(client).state.get().prefetchedNonces.length >= NONCE_POOL_SIZE) return;
|
|
63
|
+
await fetchAndStoreNonces(client);
|
|
64
|
+
};
|
|
65
|
+
|
|
58
66
|
//#endregion
|
|
59
67
|
//#region src/services/runtimeServices/createRuntimeServices/createRuntimeServices.ts
|
|
60
68
|
/**
|
|
@@ -72,14 +80,6 @@ const createRuntimeServices = () => {
|
|
|
72
80
|
};
|
|
73
81
|
};
|
|
74
82
|
|
|
75
|
-
//#endregion
|
|
76
|
-
//#region src/utils/getNonce/prefetchNoncesIfNeeded/prefetchNoncesIfNeeded.ts
|
|
77
|
-
/** @not-instrumented */
|
|
78
|
-
const prefetchNoncesIfNeeded = async (client) => {
|
|
79
|
-
if (getCore(client).state.get().prefetchedNonces.length >= NONCE_POOL_SIZE) return;
|
|
80
|
-
await fetchAndStoreNonces(client);
|
|
81
|
-
};
|
|
82
|
-
|
|
83
83
|
//#endregion
|
|
84
84
|
//#region src/modules/auth/initializeAuth/setLongTimeout/setLongTimeout.ts
|
|
85
85
|
/**
|
|
@@ -2984,7 +2984,7 @@ const detectDeviceRegistrationRedirect = ({ url }) => {
|
|
|
2984
2984
|
/** @not-instrumented */
|
|
2985
2985
|
const getRegisteredDevices = async (client = getDefaultClient()) => {
|
|
2986
2986
|
const core = getCore(client);
|
|
2987
|
-
const apiClient = createApiClient({
|
|
2987
|
+
const apiClient = createApiClient({}, client);
|
|
2988
2988
|
try {
|
|
2989
2989
|
return (await apiClient.listDeviceRegistrations({ environmentId: core.environmentId })).deviceRegistrations;
|
|
2990
2990
|
} catch (error) {
|