@dynamic-labs-sdk/client 0.12.0 → 0.12.1
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-Dj1fpM2M.cjs.js → InvalidParamError-B83QXOQl.cjs.js} +4 -4
- package/dist/{InvalidParamError-Dj1fpM2M.cjs.js.map → InvalidParamError-B83QXOQl.cjs.js.map} +1 -1
- package/dist/{InvalidParamError-DNXaHtXP.esm.js → InvalidParamError-Dyhydv4X.esm.js} +3 -3
- package/dist/{InvalidParamError-DNXaHtXP.esm.js.map → InvalidParamError-Dyhydv4X.esm.js.map} +1 -1
- package/dist/{NotWaasWalletAccountError-DVph5-w8.esm.js → NotWaasWalletAccountError-By6DOi1X.esm.js} +3 -3
- package/dist/{NotWaasWalletAccountError-DVph5-w8.esm.js.map → NotWaasWalletAccountError-By6DOi1X.esm.js.map} +1 -1
- package/dist/{NotWaasWalletAccountError-Cy_46Mkg.cjs.js → NotWaasWalletAccountError-C_XzpX9u.cjs.js} +3 -3
- package/dist/{NotWaasWalletAccountError-Cy_46Mkg.cjs.js.map → NotWaasWalletAccountError-C_XzpX9u.cjs.js.map} +1 -1
- package/dist/core.cjs.js +5 -5
- package/dist/core.esm.js +5 -5
- package/dist/{getNetworkProviderFromNetworkId-Dvi65YCc.cjs.js → getNetworkProviderFromNetworkId-BRin5Ty5.cjs.js} +3 -3
- package/dist/{getNetworkProviderFromNetworkId-Dvi65YCc.cjs.js.map → getNetworkProviderFromNetworkId-BRin5Ty5.cjs.js.map} +1 -1
- package/dist/{getNetworkProviderFromNetworkId-27Zwy4je.esm.js → getNetworkProviderFromNetworkId-D2FjIIXH.esm.js} +3 -3
- package/dist/{getNetworkProviderFromNetworkId-27Zwy4je.esm.js.map → getNetworkProviderFromNetworkId-D2FjIIXH.esm.js.map} +1 -1
- package/dist/{getSignedSessionId-BEjBh8ML.esm.js → getSignedSessionId-BE84R-V_.esm.js} +3 -3
- package/dist/{getSignedSessionId-BEjBh8ML.esm.js.map → getSignedSessionId-BE84R-V_.esm.js.map} +1 -1
- package/dist/{getSignedSessionId-1yP68jni.cjs.js → getSignedSessionId-DqowqxuJ.cjs.js} +3 -3
- package/dist/{getSignedSessionId-1yP68jni.cjs.js.map → getSignedSessionId-DqowqxuJ.cjs.js.map} +1 -1
- package/dist/{getVerifiedCredentialForWalletAccount-DsCAOgMb.esm.js → getVerifiedCredentialForWalletAccount-B5WBFgF2.esm.js} +2 -2
- package/dist/{getVerifiedCredentialForWalletAccount-DsCAOgMb.esm.js.map → getVerifiedCredentialForWalletAccount-B5WBFgF2.esm.js.map} +1 -1
- package/dist/{getVerifiedCredentialForWalletAccount-CnHwYXVQ.cjs.js → getVerifiedCredentialForWalletAccount-CsHHUt3-.cjs.js} +3 -3
- package/dist/{getVerifiedCredentialForWalletAccount-CnHwYXVQ.cjs.js.map → getVerifiedCredentialForWalletAccount-CsHHUt3-.cjs.js.map} +1 -1
- package/dist/index.cjs.js +5 -5
- package/dist/index.esm.js +5 -5
- package/dist/{isMfaRequiredForAction-BG_7iYqV.esm.js → isMfaRequiredForAction-BHmylnPq.esm.js} +2 -2
- package/dist/{isMfaRequiredForAction-BG_7iYqV.esm.js.map → isMfaRequiredForAction-BHmylnPq.esm.js.map} +1 -1
- package/dist/{isMfaRequiredForAction-zmF7uoM7.cjs.js → isMfaRequiredForAction-BzWbWDdR.cjs.js} +2 -2
- package/dist/{isMfaRequiredForAction-zmF7uoM7.cjs.js.map → isMfaRequiredForAction-BzWbWDdR.cjs.js.map} +1 -1
- package/dist/modules/storageSync/schema.d.ts +1 -1
- package/dist/modules/wallets/unverifiedWalletAccounts/schema.d.ts +1 -1
- package/dist/tsconfig.lib.tsbuildinfo +1 -1
- package/dist/waas.cjs.js +4 -4
- package/dist/waas.esm.js +3 -3
- package/dist/waasCore.cjs.js +4 -4
- package/dist/waasCore.esm.js +3 -3
- package/package.json +3 -3
package/dist/index.cjs.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const require_getNetworkProviderFromNetworkId = require('./getNetworkProviderFromNetworkId-
|
|
2
|
-
const require_InvalidParamError = require('./InvalidParamError-
|
|
3
|
-
const require_getVerifiedCredentialForWalletAccount = require('./getVerifiedCredentialForWalletAccount-
|
|
4
|
-
const require_isMfaRequiredForAction = require('./isMfaRequiredForAction-
|
|
5
|
-
const require_NotWaasWalletAccountError = require('./NotWaasWalletAccountError-
|
|
1
|
+
const require_getNetworkProviderFromNetworkId = require('./getNetworkProviderFromNetworkId-BRin5Ty5.cjs.js');
|
|
2
|
+
const require_InvalidParamError = require('./InvalidParamError-B83QXOQl.cjs.js');
|
|
3
|
+
const require_getVerifiedCredentialForWalletAccount = require('./getVerifiedCredentialForWalletAccount-CsHHUt3-.cjs.js');
|
|
4
|
+
const require_isMfaRequiredForAction = require('./isMfaRequiredForAction-BzWbWDdR.cjs.js');
|
|
5
|
+
const require_NotWaasWalletAccountError = require('./NotWaasWalletAccountError-C_XzpX9u.cjs.js');
|
|
6
6
|
let _dynamic_labs_sdk_assert_package_version = require("@dynamic-labs-sdk/assert-package-version");
|
|
7
7
|
let _dynamic_labs_sdk_api_core = require("@dynamic-labs/sdk-api-core");
|
|
8
8
|
let zod_mini = require("zod/mini");
|
package/dist/index.esm.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { A as version, D as BaseError, O as getCore, S as CLIENT_SDK_NAME, T as setDefaultClient, _ as getBuffer, a as DYNAMIC_ICONIC_SPRITE_URL, b as ValueMustBeDefinedError, c as CHAINS_INFO_MAP, d as MfaRateLimitedError, f as MfaInvalidOtpError, h as APIError, k as name, l as createApiClient, m as InvalidExternalAuthError, o as SDK_API_CORE_VERSION, p as LinkCredentialError, s as getChainFromVerifiedCredentialChain, t as InvalidParamError, u as SandboxMaximumThresholdReachedError, v as isCookieEnabled, w as getDefaultClient, x as randomString, y as assertDefined } from "./InvalidParamError-
|
|
2
|
-
import { C as isServerSideRendering, D as REFRESH_USER_STATE_FROM_COOKIE_TRACKER_KEY, E as INITIALIZE_STORAGE_SYNC_TRACKER_KEY, M as subscribeWithSelector, N as isEqualShallow, O as createStorageKeySchema, S as createDeferredPromise, T as GENERATE_SESSION_KEYS_TRACKER_KEY, _ as NoNetworkProvidersError, a as updateWalletProviderKeysForVerifiedCredentials, c as createSignInMessageStatement, d as createVisit, f as hasExtension, g as WalletAlreadyLinkedToAnotherUserError, h as isCaptchaRequired, i as getNetworksData, j as createLocalStorageAdapter, k as createStorage, l as formatSignInMessage, m as consumeCaptchaToken, o as verifyMessageSignatureOwnership, p as setCaptchaToken, s as removeUnverifiedWalletAccount, t as getNetworkProviderFromNetworkId, u as setUnverifiedWalletAccounts, v as createLogger, w as FETCH_PROJECT_SETTINGS_TRACKER_KEY, x as CannotTrackError, y as createCrossTabBroadcast } from "./getNetworkProviderFromNetworkId-
|
|
3
|
-
import { D as onceEvent, E as onEvent, O as setCookie, S as splitWalletProviderKey, T as offEvent, _ as getWalletAccounts, b as formatWalletAccountId, c as getWalletProviders, d as DYNAMIC_AUTH_COOKIE_NAME, f as getWalletProviderFromWalletAccount, g as NoWalletProviderFoundError, i as restoreUserSharesForAllWalletAccounts, l as checkAndRaiseWalletAccountsChangedEvent, n as getWalletProviderByKey, r as updateAuthFromVerifyResponse, t as getVerifiedCredentialForWalletAccount, u as emitWalletAccountsChangedEvent, w as emitEvent, x as normalizeAddress } from "./getVerifiedCredentialForWalletAccount-
|
|
4
|
-
import { i as bufferToHex, n as getMfaMethods, r as consumeMfaToken, t as isMfaRequiredForAction } from "./isMfaRequiredForAction-
|
|
5
|
-
import { n as refreshAuth, t as NotWaasWalletAccountError } from "./NotWaasWalletAccountError-
|
|
1
|
+
import { A as version, D as BaseError, O as getCore, S as CLIENT_SDK_NAME, T as setDefaultClient, _ as getBuffer, a as DYNAMIC_ICONIC_SPRITE_URL, b as ValueMustBeDefinedError, c as CHAINS_INFO_MAP, d as MfaRateLimitedError, f as MfaInvalidOtpError, h as APIError, k as name, l as createApiClient, m as InvalidExternalAuthError, o as SDK_API_CORE_VERSION, p as LinkCredentialError, s as getChainFromVerifiedCredentialChain, t as InvalidParamError, u as SandboxMaximumThresholdReachedError, v as isCookieEnabled, w as getDefaultClient, x as randomString, y as assertDefined } from "./InvalidParamError-Dyhydv4X.esm.js";
|
|
2
|
+
import { C as isServerSideRendering, D as REFRESH_USER_STATE_FROM_COOKIE_TRACKER_KEY, E as INITIALIZE_STORAGE_SYNC_TRACKER_KEY, M as subscribeWithSelector, N as isEqualShallow, O as createStorageKeySchema, S as createDeferredPromise, T as GENERATE_SESSION_KEYS_TRACKER_KEY, _ as NoNetworkProvidersError, a as updateWalletProviderKeysForVerifiedCredentials, c as createSignInMessageStatement, d as createVisit, f as hasExtension, g as WalletAlreadyLinkedToAnotherUserError, h as isCaptchaRequired, i as getNetworksData, j as createLocalStorageAdapter, k as createStorage, l as formatSignInMessage, m as consumeCaptchaToken, o as verifyMessageSignatureOwnership, p as setCaptchaToken, s as removeUnverifiedWalletAccount, t as getNetworkProviderFromNetworkId, u as setUnverifiedWalletAccounts, v as createLogger, w as FETCH_PROJECT_SETTINGS_TRACKER_KEY, x as CannotTrackError, y as createCrossTabBroadcast } from "./getNetworkProviderFromNetworkId-D2FjIIXH.esm.js";
|
|
3
|
+
import { D as onceEvent, E as onEvent, O as setCookie, S as splitWalletProviderKey, T as offEvent, _ as getWalletAccounts, b as formatWalletAccountId, c as getWalletProviders, d as DYNAMIC_AUTH_COOKIE_NAME, f as getWalletProviderFromWalletAccount, g as NoWalletProviderFoundError, i as restoreUserSharesForAllWalletAccounts, l as checkAndRaiseWalletAccountsChangedEvent, n as getWalletProviderByKey, r as updateAuthFromVerifyResponse, t as getVerifiedCredentialForWalletAccount, u as emitWalletAccountsChangedEvent, w as emitEvent, x as normalizeAddress } from "./getVerifiedCredentialForWalletAccount-B5WBFgF2.esm.js";
|
|
4
|
+
import { i as bufferToHex, n as getMfaMethods, r as consumeMfaToken, t as isMfaRequiredForAction } from "./isMfaRequiredForAction-BHmylnPq.esm.js";
|
|
5
|
+
import { n as refreshAuth, t as NotWaasWalletAccountError } from "./NotWaasWalletAccountError-By6DOi1X.esm.js";
|
|
6
6
|
import { assertPackageVersion } from "@dynamic-labs-sdk/assert-package-version";
|
|
7
7
|
import { AuthModeEnum, ExchangeKeyEnum, JwtVerifiedCredentialFormatEnum, MFAAction, MfaBackupCodeAcknowledgement, ProviderEnum, WaasBackupOptionsEnum } from "@dynamic-labs/sdk-api-core";
|
|
8
8
|
import * as z from "zod/mini";
|
package/dist/{isMfaRequiredForAction-BG_7iYqV.esm.js → isMfaRequiredForAction-BHmylnPq.esm.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { O as getCore, l as createApiClient, w as getDefaultClient, y as assertDefined } from "./InvalidParamError-
|
|
1
|
+
import { O as getCore, l as createApiClient, w as getDefaultClient, y as assertDefined } from "./InvalidParamError-Dyhydv4X.esm.js";
|
|
2
2
|
|
|
3
3
|
//#region src/utils/bufferToHex/bufferToHex.ts
|
|
4
4
|
/**
|
|
@@ -66,4 +66,4 @@ const isMfaRequiredForAction = async ({ mfaAction }, client = getDefaultClient()
|
|
|
66
66
|
|
|
67
67
|
//#endregion
|
|
68
68
|
export { bufferToHex as i, getMfaMethods as n, consumeMfaToken as r, isMfaRequiredForAction as t };
|
|
69
|
-
//# sourceMappingURL=isMfaRequiredForAction-
|
|
69
|
+
//# sourceMappingURL=isMfaRequiredForAction-BHmylnPq.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isMfaRequiredForAction-
|
|
1
|
+
{"version":3,"file":"isMfaRequiredForAction-BHmylnPq.esm.js","names":[],"sources":["../src/utils/bufferToHex/bufferToHex.ts","../src/modules/mfa/consumeMfaToken/consumeMfaToken.ts","../src/modules/mfa/getMfaMethods/getMfaMethods.ts","../src/modules/mfa/isMfaRequiredForAction/isMfaRequiredForAction.ts"],"sourcesContent":["/**\n * Converts an ArrayBuffer to a hex-encoded string\n */\nexport const bufferToHex = (buffer: ArrayBufferLike) =>\n [...new Uint8Array(buffer)]\n .map((x) => x.toString(16).padStart(2, '0'))\n .join('');\n","import { getCore } from '../../../client/core/getCore';\nimport { getDefaultClient } from '../../../client/defaultClient';\nimport { assertDefined } from '../../../utils/assertDefined';\n\n/**\n * Consumes and clears the current MFA token from the client state.\n *\n * This function retrieves the MFA token obtained from a successful MFA authentication,\n * and removes it from the client, to prevent it from being used again.\n *\n * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.\n * @returns The MFA token that was consumed.\n * @throws Error if no MFA token is found.\n */\nexport const consumeMfaToken = (client = getDefaultClient()) => {\n const core = getCore(client);\n\n const mfaToken = core.state.get().mfaToken;\n\n assertDefined(mfaToken, 'No MFA token found');\n\n core.state.set({\n mfaToken: null,\n });\n\n return mfaToken;\n};\n","import { getCore } from '../../../client/core/getCore';\nimport { getDefaultClient } from '../../../client/defaultClient';\nimport { createApiClient } from '../../apiClient';\n\n/**\n * Retrieves the available MFA methods for the current user.\n *\n * This function fetches information about which multi-factor authentication\n * methods are available and configured for the user's account.\n *\n * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.\n * @returns A promise that resolves to the user's MFA methods configuration.\n */\nexport const getMfaMethods = async (client = getDefaultClient()) => {\n const core = getCore(client);\n const apiClient = createApiClient({}, client);\n\n const userMfaMethods = await apiClient.getUserMfaMethods({\n environmentId: core.environmentId,\n verifiedOnly: true,\n });\n\n return userMfaMethods;\n};\n","import type { MFAAction } from '@dynamic-labs/sdk-api-core';\n\nimport { getDefaultClient } from '../../../client/defaultClient';\nimport { getMfaMethods } from '../getMfaMethods';\n\ntype IsMfaRequiredForActionParams = {\n mfaAction: MFAAction;\n};\n\n/**\n * Checks if MFA is required for a specific action.\n *\n * This function determines whether multi-factor authentication is required\n * for the specified action based on project settings and user configuration.\n *\n * @param params.mfaAction - The action to check MFA requirements for.\n * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.\n * @returns A promise that resolves to true if MFA is required for the action, false otherwise.\n */\nexport const isMfaRequiredForAction = async (\n { mfaAction }: IsMfaRequiredForActionParams,\n client = getDefaultClient()\n) => {\n const projectSettings = client.projectSettings;\n\n const isRequiredForAction = projectSettings?.security?.mfa?.actions?.some(\n (action) => action.action === mfaAction && action.required\n );\n\n // if mfa is not required for the action, return false\n // no matter if general mfa is set to required or not\n if (!isRequiredForAction) {\n return false;\n }\n\n const isMfaMethodRequired = projectSettings?.security?.mfa?.required;\n\n // if mfa is required for the action and also set as required in general, return true\n if (isMfaMethodRequired) {\n return true;\n }\n\n const mfaMethods = await getMfaMethods(client);\n // if general mfa is optional, but user has registered methods,\n // then it should be required for the action\n return mfaMethods.userHasVerifiedMfaMethods;\n};\n"],"mappings":";;;;;;AAGA,MAAa,eAAe,WAC1B,CAAC,GAAG,IAAI,WAAW,OAAO,CAAC,CACxB,KAAK,MAAM,EAAE,SAAS,GAAG,CAAC,SAAS,GAAG,IAAI,CAAC,CAC3C,KAAK,GAAG;;;;;;;;;;;;;;ACQb,MAAa,mBAAmB,SAAS,kBAAkB,KAAK;CAC9D,MAAM,OAAO,QAAQ,OAAO;CAE5B,MAAM,WAAW,KAAK,MAAM,KAAK,CAAC;AAElC,eAAc,UAAU,qBAAqB;AAE7C,MAAK,MAAM,IAAI,EACb,UAAU,MACX,CAAC;AAEF,QAAO;;;;;;;;;;;;;;ACZT,MAAa,gBAAgB,OAAO,SAAS,kBAAkB,KAAK;CAClE,MAAM,OAAO,QAAQ,OAAO;AAQ5B,QALuB,MAFL,gBAAgB,EAAE,EAAE,OAAO,CAEN,kBAAkB;EACvD,eAAe,KAAK;EACpB,cAAc;EACf,CAAC;;;;;;;;;;;;;;;ACDJ,MAAa,yBAAyB,OACpC,EAAE,aACF,SAAS,kBAAkB,KACxB;CACH,MAAM,kBAAkB,OAAO;AAQ/B,KAAI,CANwB,iBAAiB,UAAU,KAAK,SAAS,MAClE,WAAW,OAAO,WAAW,aAAa,OAAO,SACnD,CAKC,QAAO;AAMT,KAH4B,iBAAiB,UAAU,KAAK,SAI1D,QAAO;AAMT,SAHmB,MAAM,cAAc,OAAO,EAG5B"}
|
package/dist/{isMfaRequiredForAction-zmF7uoM7.cjs.js → isMfaRequiredForAction-BzWbWDdR.cjs.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_InvalidParamError = require('./InvalidParamError-
|
|
1
|
+
const require_InvalidParamError = require('./InvalidParamError-B83QXOQl.cjs.js');
|
|
2
2
|
|
|
3
3
|
//#region src/utils/bufferToHex/bufferToHex.ts
|
|
4
4
|
/**
|
|
@@ -89,4 +89,4 @@ Object.defineProperty(exports, 'isMfaRequiredForAction', {
|
|
|
89
89
|
return isMfaRequiredForAction;
|
|
90
90
|
}
|
|
91
91
|
});
|
|
92
|
-
//# sourceMappingURL=isMfaRequiredForAction-
|
|
92
|
+
//# sourceMappingURL=isMfaRequiredForAction-BzWbWDdR.cjs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"isMfaRequiredForAction-
|
|
1
|
+
{"version":3,"file":"isMfaRequiredForAction-BzWbWDdR.cjs.js","names":["getDefaultClient","getCore","getDefaultClient","getCore","createApiClient","getDefaultClient"],"sources":["../src/utils/bufferToHex/bufferToHex.ts","../src/modules/mfa/consumeMfaToken/consumeMfaToken.ts","../src/modules/mfa/getMfaMethods/getMfaMethods.ts","../src/modules/mfa/isMfaRequiredForAction/isMfaRequiredForAction.ts"],"sourcesContent":["/**\n * Converts an ArrayBuffer to a hex-encoded string\n */\nexport const bufferToHex = (buffer: ArrayBufferLike) =>\n [...new Uint8Array(buffer)]\n .map((x) => x.toString(16).padStart(2, '0'))\n .join('');\n","import { getCore } from '../../../client/core/getCore';\nimport { getDefaultClient } from '../../../client/defaultClient';\nimport { assertDefined } from '../../../utils/assertDefined';\n\n/**\n * Consumes and clears the current MFA token from the client state.\n *\n * This function retrieves the MFA token obtained from a successful MFA authentication,\n * and removes it from the client, to prevent it from being used again.\n *\n * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.\n * @returns The MFA token that was consumed.\n * @throws Error if no MFA token is found.\n */\nexport const consumeMfaToken = (client = getDefaultClient()) => {\n const core = getCore(client);\n\n const mfaToken = core.state.get().mfaToken;\n\n assertDefined(mfaToken, 'No MFA token found');\n\n core.state.set({\n mfaToken: null,\n });\n\n return mfaToken;\n};\n","import { getCore } from '../../../client/core/getCore';\nimport { getDefaultClient } from '../../../client/defaultClient';\nimport { createApiClient } from '../../apiClient';\n\n/**\n * Retrieves the available MFA methods for the current user.\n *\n * This function fetches information about which multi-factor authentication\n * methods are available and configured for the user's account.\n *\n * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.\n * @returns A promise that resolves to the user's MFA methods configuration.\n */\nexport const getMfaMethods = async (client = getDefaultClient()) => {\n const core = getCore(client);\n const apiClient = createApiClient({}, client);\n\n const userMfaMethods = await apiClient.getUserMfaMethods({\n environmentId: core.environmentId,\n verifiedOnly: true,\n });\n\n return userMfaMethods;\n};\n","import type { MFAAction } from '@dynamic-labs/sdk-api-core';\n\nimport { getDefaultClient } from '../../../client/defaultClient';\nimport { getMfaMethods } from '../getMfaMethods';\n\ntype IsMfaRequiredForActionParams = {\n mfaAction: MFAAction;\n};\n\n/**\n * Checks if MFA is required for a specific action.\n *\n * This function determines whether multi-factor authentication is required\n * for the specified action based on project settings and user configuration.\n *\n * @param params.mfaAction - The action to check MFA requirements for.\n * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.\n * @returns A promise that resolves to true if MFA is required for the action, false otherwise.\n */\nexport const isMfaRequiredForAction = async (\n { mfaAction }: IsMfaRequiredForActionParams,\n client = getDefaultClient()\n) => {\n const projectSettings = client.projectSettings;\n\n const isRequiredForAction = projectSettings?.security?.mfa?.actions?.some(\n (action) => action.action === mfaAction && action.required\n );\n\n // if mfa is not required for the action, return false\n // no matter if general mfa is set to required or not\n if (!isRequiredForAction) {\n return false;\n }\n\n const isMfaMethodRequired = projectSettings?.security?.mfa?.required;\n\n // if mfa is required for the action and also set as required in general, return true\n if (isMfaMethodRequired) {\n return true;\n }\n\n const mfaMethods = await getMfaMethods(client);\n // if general mfa is optional, but user has registered methods,\n // then it should be required for the action\n return mfaMethods.userHasVerifiedMfaMethods;\n};\n"],"mappings":";;;;;;AAGA,MAAa,eAAe,WAC1B,CAAC,GAAG,IAAI,WAAW,OAAO,CAAC,CACxB,KAAK,MAAM,EAAE,SAAS,GAAG,CAAC,SAAS,GAAG,IAAI,CAAC,CAC3C,KAAK,GAAG;;;;;;;;;;;;;;ACQb,MAAa,mBAAmB,SAASA,4CAAkB,KAAK;CAC9D,MAAM,OAAOC,kCAAQ,OAAO;CAE5B,MAAM,WAAW,KAAK,MAAM,KAAK,CAAC;AAElC,yCAAc,UAAU,qBAAqB;AAE7C,MAAK,MAAM,IAAI,EACb,UAAU,MACX,CAAC;AAEF,QAAO;;;;;;;;;;;;;;ACZT,MAAa,gBAAgB,OAAO,SAASC,4CAAkB,KAAK;CAClE,MAAM,OAAOC,kCAAQ,OAAO;AAQ5B,QALuB,MAFLC,0CAAgB,EAAE,EAAE,OAAO,CAEN,kBAAkB;EACvD,eAAe,KAAK;EACpB,cAAc;EACf,CAAC;;;;;;;;;;;;;;;ACDJ,MAAa,yBAAyB,OACpC,EAAE,aACF,SAASC,4CAAkB,KACxB;CACH,MAAM,kBAAkB,OAAO;AAQ/B,KAAI,CANwB,iBAAiB,UAAU,KAAK,SAAS,MAClE,WAAW,OAAO,WAAW,aAAa,OAAO,SACnD,CAKC,QAAO;AAMT,KAH4B,iBAAiB,UAAU,KAAK,SAI1D,QAAO;AAMT,SAHmB,MAAM,cAAc,OAAO,EAG5B"}
|
|
@@ -10,7 +10,7 @@ export declare const stateStorageKeySchema: import("../../services/storage").Sto
|
|
|
10
10
|
walletProviderKey: string;
|
|
11
11
|
addressesWithTypes?: {
|
|
12
12
|
address: string;
|
|
13
|
-
type: "ordinals" | "payment" | "cosmos" | "evm" | "ton";
|
|
13
|
+
type: "ordinals" | "payment" | "cosmos" | "evm" | "stellar" | "ton";
|
|
14
14
|
publicKey?: string | undefined;
|
|
15
15
|
}[] | undefined;
|
|
16
16
|
hardwareWalletVendor?: "ledger" | undefined;
|
|
@@ -5,7 +5,7 @@ export declare const unverifiedWalletAccountSchema: z.ZodMiniObject<{
|
|
|
5
5
|
addressesWithTypes: z.ZodMiniOptional<z.ZodMiniArray<z.ZodMiniObject<{
|
|
6
6
|
address: z.ZodMiniString<string>;
|
|
7
7
|
publicKey: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
8
|
-
type: z.ZodMiniCustom<"ordinals" | "payment" | "cosmos" | "evm" | "ton", "ordinals" | "payment" | "cosmos" | "evm" | "ton">;
|
|
8
|
+
type: z.ZodMiniCustom<"ordinals" | "payment" | "cosmos" | "evm" | "stellar" | "ton", "ordinals" | "payment" | "cosmos" | "evm" | "stellar" | "ton">;
|
|
9
9
|
}, z.core.$strip>>>;
|
|
10
10
|
chain: z.ZodMiniCustom<Chain, Chain>;
|
|
11
11
|
hardwareWalletVendor: z.ZodMiniOptional<z.ZodMiniCustom<"ledger", "ledger">>;
|