@dynamic-labs-sdk/client 1.12.1 → 1.13.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.
Files changed (538) hide show
  1. package/dist/{InvalidParamError-I6NfUdQL.esm.js → InvalidParamError-BeCPhfVz.esm.js} +79 -49
  2. package/dist/InvalidParamError-BeCPhfVz.esm.js.map +1 -0
  3. package/dist/{InvalidParamError-d0WFn5Ai.cjs → InvalidParamError-C7c-OLz1.cjs} +85 -49
  4. package/dist/InvalidParamError-C7c-OLz1.cjs.map +1 -0
  5. package/dist/{InvalidParamError-CKUis748.native.esm.js → InvalidParamError-CGiSxym5.native.esm.js} +54 -36
  6. package/dist/InvalidParamError-CGiSxym5.native.esm.js.map +1 -0
  7. package/dist/client/core/createCore/createCore.d.ts +1 -1
  8. package/dist/client/core/createCore/getInitialState.d.ts +1 -1
  9. package/dist/client/core/getCore/getCore.d.ts +1 -1
  10. package/dist/client/core/getCore/getCore.d.ts.map +1 -1
  11. package/dist/client/defaultClient/defaultClient.d.ts +2 -2
  12. package/dist/client/defaultClient/defaultClient.d.ts.map +1 -1
  13. package/dist/core.cjs +23 -23
  14. package/dist/core.cjs.map +1 -1
  15. package/dist/core.esm.js +23 -23
  16. package/dist/core.esm.js.map +1 -1
  17. package/dist/core.native.esm.js +25 -25
  18. package/dist/core.native.esm.js.map +1 -1
  19. package/dist/errors/WaasOnboardingIncompleteError.d.ts +18 -0
  20. package/dist/errors/WaasOnboardingIncompleteError.d.ts.map +1 -0
  21. package/dist/exports/index.d.ts +1 -0
  22. package/dist/exports/index.d.ts.map +1 -1
  23. package/dist/{getNetworkProviderFromNetworkId-DpiVLfs_.native.esm.js → getNetworkProviderFromNetworkId-Be_UK4_7.native.esm.js} +54 -54
  24. package/dist/getNetworkProviderFromNetworkId-Be_UK4_7.native.esm.js.map +1 -0
  25. package/dist/{getNetworkProviderFromNetworkId-D6ABmeNQ.esm.js → getNetworkProviderFromNetworkId-CP9gl1B1.esm.js} +44 -44
  26. package/dist/getNetworkProviderFromNetworkId-CP9gl1B1.esm.js.map +1 -0
  27. package/dist/{getNetworkProviderFromNetworkId-CfW0tOnr.cjs → getNetworkProviderFromNetworkId-D8cpx0xz.cjs} +45 -45
  28. package/dist/getNetworkProviderFromNetworkId-D8cpx0xz.cjs.map +1 -0
  29. package/dist/{getSignedSessionId-Bc-sYE2A.cjs → getSignedSessionId-BeK0vWep.cjs} +7 -7
  30. package/dist/getSignedSessionId-BeK0vWep.cjs.map +1 -0
  31. package/dist/{getSignedSessionId-IEoo2Kv9.esm.js → getSignedSessionId-Bq7xBsA3.esm.js} +7 -7
  32. package/dist/getSignedSessionId-Bq7xBsA3.esm.js.map +1 -0
  33. package/dist/{getSignedSessionId-C6LJdiSK.native.esm.js → getSignedSessionId-D9w3Wbhk.native.esm.js} +7 -7
  34. package/dist/getSignedSessionId-D9w3Wbhk.native.esm.js.map +1 -0
  35. package/dist/{getWaasWalletProviderFromWalletAccount-D1wxsNEI.native.esm.js → getWaasWalletProviderFromWalletAccount-BKHO68FO.esm.js} +4 -4
  36. package/dist/getWaasWalletProviderFromWalletAccount-BKHO68FO.esm.js.map +1 -0
  37. package/dist/{getWaasWalletProviderFromWalletAccount-DojjjSIP.esm.js → getWaasWalletProviderFromWalletAccount-BzpLoZTm.native.esm.js} +4 -4
  38. package/dist/getWaasWalletProviderFromWalletAccount-BzpLoZTm.native.esm.js.map +1 -0
  39. package/dist/{getWaasWalletProviderFromWalletAccount-CSmVAhr2.cjs → getWaasWalletProviderFromWalletAccount-CfqTF_82.cjs} +4 -4
  40. package/dist/getWaasWalletProviderFromWalletAccount-CfqTF_82.cjs.map +1 -0
  41. package/dist/{getWalletProviderByKey-DsTEubkT.esm.js → getWalletProviderByKey-BMzoL_69.esm.js} +16 -34
  42. package/dist/getWalletProviderByKey-BMzoL_69.esm.js.map +1 -0
  43. package/dist/{getWalletProviderByKey-B821GpaI.cjs → getWalletProviderByKey-DCKYAida.cjs} +17 -41
  44. package/dist/getWalletProviderByKey-DCKYAida.cjs.map +1 -0
  45. package/dist/{getWalletProviderByKey-RTW-S68o.native.esm.js → getWalletProviderByKey-DDDxBsdv.native.esm.js} +41 -47
  46. package/dist/getWalletProviderByKey-DDDxBsdv.native.esm.js.map +1 -0
  47. package/dist/index.cjs +195 -248
  48. package/dist/index.cjs.map +1 -1
  49. package/dist/index.esm.js +187 -241
  50. package/dist/index.esm.js.map +1 -1
  51. package/dist/index.native.esm.js +188 -242
  52. package/dist/index.native.esm.js.map +1 -1
  53. package/dist/{isDynamicWaasEnabled-vRyWP-1l.esm.js → isDynamicWaasEnabled-BMQq5uNX.esm.js} +3 -3
  54. package/dist/{isDynamicWaasEnabled-vRyWP-1l.esm.js.map → isDynamicWaasEnabled-BMQq5uNX.esm.js.map} +1 -1
  55. package/dist/{isDynamicWaasEnabled-CBOG0ITH.cjs → isDynamicWaasEnabled-BtbzDbdz.cjs} +4 -4
  56. package/dist/{isDynamicWaasEnabled-CBOG0ITH.cjs.map → isDynamicWaasEnabled-BtbzDbdz.cjs.map} +1 -1
  57. package/dist/{isDynamicWaasEnabled-CBLpFRnd.native.esm.js → isDynamicWaasEnabled-ChdeBFbN.native.esm.js} +3 -3
  58. package/dist/{isDynamicWaasEnabled-CBLpFRnd.native.esm.js.map → isDynamicWaasEnabled-ChdeBFbN.native.esm.js.map} +1 -1
  59. package/dist/{isMfaRequiredForAction-DL013-fR.cjs → isMfaRequiredForAction-CgWBU6kM.cjs} +11 -11
  60. package/dist/isMfaRequiredForAction-CgWBU6kM.cjs.map +1 -0
  61. package/dist/{isMfaRequiredForAction-C1-1spV9.esm.js → isMfaRequiredForAction-Diwsf9GB.esm.js} +11 -11
  62. package/dist/isMfaRequiredForAction-Diwsf9GB.esm.js.map +1 -0
  63. package/dist/{isMfaRequiredForAction-D1AYL99a.native.esm.js → isMfaRequiredForAction-dAtK8Pl6.native.esm.js} +4 -4
  64. package/dist/{isMfaRequiredForAction-D1AYL99a.native.esm.js.map → isMfaRequiredForAction-dAtK8Pl6.native.esm.js.map} +1 -1
  65. package/dist/isUserOnboardingComplete-D4Y3sdr3.esm.js +121 -0
  66. package/dist/isUserOnboardingComplete-D4Y3sdr3.esm.js.map +1 -0
  67. package/dist/isUserOnboardingComplete-DO2_gSAp.native.esm.js +121 -0
  68. package/dist/isUserOnboardingComplete-DO2_gSAp.native.esm.js.map +1 -0
  69. package/dist/isUserOnboardingComplete-OP4uyUlE.cjs +151 -0
  70. package/dist/isUserOnboardingComplete-OP4uyUlE.cjs.map +1 -0
  71. package/dist/modules/apiClient/createApiClient.d.ts +1 -1
  72. package/dist/modules/apiClient/utils/clientErrorMapper/clientErrorMapper.d.ts +1 -1
  73. package/dist/modules/apiClient/utils/convertToApiErrorMiddleware/convertToApiErrorMiddleware.d.ts +1 -1
  74. package/dist/modules/apiClient/utils/deviceSignatureHeadersMiddleware/createDeviceSignatureHeadersMiddleware.d.ts +1 -1
  75. package/dist/modules/apiClient/utils/deviceSignatureHeadersMiddleware/createDeviceSignatureHeadersMiddleware.d.ts.map +1 -1
  76. package/dist/modules/apiClient/utils/unauthorizedMiddleware/createUnauthorizedMiddleware.d.ts +1 -1
  77. package/dist/modules/apiClient/utils/unauthorizedMiddleware/createUnauthorizedMiddleware.d.ts.map +1 -1
  78. package/dist/modules/auth/createVisit/createVisit.d.ts +1 -1
  79. package/dist/modules/auth/createVisit/createVisit.d.ts.map +1 -1
  80. package/dist/modules/auth/decodeJwt/decodeJwt.d.ts +1 -1
  81. package/dist/modules/auth/extractSessionId/extractSessionId.d.ts +1 -1
  82. package/dist/modules/auth/getElevatedAccessToken/getElevatedAccessToken.d.ts +1 -1
  83. package/dist/modules/auth/initializeAuth/initializeAuth.d.ts +1 -1
  84. package/dist/modules/auth/initializeAuth/setLongTimeout/setLongTimeout.d.ts +1 -1
  85. package/dist/modules/auth/isSignedIn/isSignedIn.d.ts +1 -1
  86. package/dist/modules/auth/logout/logout.d.ts +1 -1
  87. package/dist/modules/auth/passkeys/getPasskeyAuthenticationOptions/getPasskeyAuthenticationOptions.d.ts +1 -1
  88. package/dist/modules/auth/passkeys/getPasskeyAuthenticationOptions/getPasskeyAuthenticationOptions.d.ts.map +1 -1
  89. package/dist/modules/auth/passkeys/getPasskeyAuthenticationSignInOptions/getPasskeyAuthenticationSignInOptions.d.ts +1 -1
  90. package/dist/modules/auth/passkeys/getPasskeyAuthenticationSignInOptions/getPasskeyAuthenticationSignInOptions.d.ts.map +1 -1
  91. package/dist/modules/auth/passkeys/getPasskeyRegistrationOptions/getPasskeyRegistrationOptions.d.ts +1 -1
  92. package/dist/modules/auth/passkeys/getPasskeyRegistrationOptions/getPasskeyRegistrationOptions.d.ts.map +1 -1
  93. package/dist/modules/auth/passkeys/getPasskeys/getPasskeys.d.ts +1 -1
  94. package/dist/modules/auth/passkeys/serverAuthenticatePasskey/serverAuthenticatePasskey.d.ts +1 -1
  95. package/dist/modules/auth/passkeys/serverAuthenticatePasskey/serverAuthenticatePasskey.d.ts.map +1 -1
  96. package/dist/modules/auth/passkeys/serverRegisterPasskey/serverRegisterPasskey.d.ts +1 -1
  97. package/dist/modules/auth/passkeys/serverRegisterPasskey/serverRegisterPasskey.d.ts.map +1 -1
  98. package/dist/modules/auth/passkeys/serverSigninPasskey/serverSigninPasskey.d.ts +1 -1
  99. package/dist/modules/auth/passkeys/serverSigninPasskey/serverSigninPasskey.d.ts.map +1 -1
  100. package/dist/modules/auth/social/getUserSocialAccounts/getUserSocialAccounts.d.ts +1 -1
  101. package/dist/modules/auth/social/oauth/detectOAuthRedirect/detectOAuthRedirect.d.ts +1 -1
  102. package/dist/modules/auth/social/oauth/detectSocialRedirectUrl/detectSocialRedirectUrl.d.ts +1 -1
  103. package/dist/modules/auth/social/oauth/processSocialCallback/processSocialCallback.d.ts +1 -1
  104. package/dist/modules/auth/social/oauth/processSocialCallback/processSocialCallback.d.ts.map +1 -1
  105. package/dist/modules/auth/social/oauth/signInWithSocialRedirect/buildOAuthUrl/addOAuthUrlParams/addOAuthUrlParams.d.ts +2 -2
  106. package/dist/modules/auth/social/oauth/signInWithSocialRedirect/buildOAuthUrl/buildOAuthUrl.d.ts +2 -2
  107. package/dist/modules/auth/social/oauth/signInWithSocialRedirect/buildOAuthUrl/getOAuthBaseUrl/getOAuthBaseUrl.d.ts +1 -1
  108. package/dist/modules/auth/social/removeDynamicOauthParamsFromUrl/removeDynamicOauthParamsFromUrl.d.ts +1 -1
  109. package/dist/modules/auth/social/removeDynamicOauthParamsFromUrl/removeDynamicOauthParamsFromUrl.d.ts.map +1 -1
  110. package/dist/modules/auth/updateAuthFromVerifyResponse/checkAndRaiseWalletAccountsChangedEvent/checkAndRaiseWalletAccountsChangedEvent.d.ts +1 -1
  111. package/dist/modules/auth/updateAuthFromVerifyResponse/checkAndRaiseWalletAccountsChangedEvent/checkAndRaiseWalletAccountsChangedEvent.d.ts.map +1 -1
  112. package/dist/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/normalizeScopes/normalizeScopes.d.ts +1 -1
  113. package/dist/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/parseElevatedAccessToken/parseElevatedAccessToken.d.ts +1 -1
  114. package/dist/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/upsertElevatedAccessToken/upsertElevatedAccessToken.d.ts +1 -1
  115. package/dist/modules/auth/updateAuthFromVerifyResponse/updateAuthFromVerifyResponse.d.ts +1 -1
  116. package/dist/modules/auth/updateAuthFromVerifyResponse/updateAuthFromVerifyResponse.d.ts.map +1 -1
  117. package/dist/modules/balances/getBalances/getBalances.d.ts +1 -1
  118. package/dist/modules/balances/getMultichainBalances/getMultichainBalances.d.ts +1 -1
  119. package/dist/modules/balances/getMultichainTokenBalances/getMultichainTokenBalances.d.ts +1 -1
  120. package/dist/modules/balances/getTokenBalances/getTokenBalances.d.ts +2 -2
  121. package/dist/modules/captcha/consumeCaptchaToken/consumeCaptchaToken.d.ts +1 -1
  122. package/dist/modules/captcha/isCaptchaRequired/isCaptchaRequired.d.ts +1 -1
  123. package/dist/modules/captcha/isCaptchaRequired/isCaptchaRequired.d.ts.map +1 -1
  124. package/dist/modules/checkout/getCheckoutTransaction/getCheckoutTransaction.d.ts +1 -1
  125. package/dist/modules/checkout/getCheckoutTransactionQuote/getCheckoutTransactionQuote.d.ts +1 -1
  126. package/dist/modules/checkout/getCheckouts/getCheckouts.d.ts +1 -1
  127. package/dist/modules/checkout/getCheckouts/getCheckouts.d.ts.map +1 -1
  128. package/dist/modules/checkout/trackCheckoutTransaction/trackCheckoutTransaction.d.ts +1 -1
  129. package/dist/modules/checkout/utils/clearCheckoutSessionToken/clearCheckoutSessionToken.d.ts +1 -1
  130. package/dist/modules/checkout/utils/createCheckoutApiClient/createCheckoutApiClient.d.ts +1 -1
  131. package/dist/modules/checkout/utils/createCheckoutApiClient/createCheckoutApiClient.d.ts.map +1 -1
  132. package/dist/modules/checkout/utils/createCheckoutSessionTokenStorageKey/createCheckoutSessionTokenStorageKey.d.ts +1 -1
  133. package/dist/modules/checkout/utils/createCheckoutSessionTokenStorageKey/createCheckoutSessionTokenStorageKey.d.ts.map +1 -1
  134. package/dist/modules/checkout/utils/createCheckoutTransactionChannelSchema/createCheckoutTransactionChannelSchema.d.ts +1 -1
  135. package/dist/modules/checkout/utils/requiresConversion/requiresConversion.d.ts +1 -1
  136. package/dist/modules/checkout/utils/subscribeToCheckoutTransaction/subscribeToCheckoutTransaction.d.ts +1 -1
  137. package/dist/modules/checkout/utils/withCheckoutSessionTokenCleanupOn401/withCheckoutSessionTokenCleanupOn401.d.ts +1 -1
  138. package/dist/modules/clientEvents/clientEvents.d.ts +4 -4
  139. package/dist/modules/crossTabEventSync/setupCrossTabEventSync/setupCrossTabEventSync.d.ts +1 -1
  140. package/dist/modules/deviceRegistration/detectDeviceRegistrationRedirect/detectDeviceRegistrationRedirect.d.ts +1 -1
  141. package/dist/modules/deviceRegistration/getDeviceRegistrationTokenFromUrl/getDeviceRegistrationTokenFromUrl.d.ts +1 -1
  142. package/dist/modules/deviceRegistration/getDeviceSigner/getDeviceSigner.d.ts +1 -1
  143. package/dist/modules/deviceRegistration/getDeviceSigner/getDeviceSigner.d.ts.map +1 -1
  144. package/dist/modules/deviceRegistration/getDeviceSigner/getOrCreateEnvironmentDeviceSigningKeys/getOrCreateEnvironmentDeviceSigningKeys.d.ts +1 -1
  145. package/dist/modules/deviceRegistration/getHeadersForNonceSignedByDeviceSigners/getHeadersForNonceSignedByDeviceSigners.d.ts +1 -1
  146. package/dist/modules/deviceRegistration/getHeadersForNonceSignedByDeviceSigners/getHeadersForNonceSignedByDeviceSigners.d.ts.map +1 -1
  147. package/dist/modules/deviceRegistration/getRegisteredDevices/getRegisteredDevices.d.ts +1 -1
  148. package/dist/modules/deviceRegistration/getRegisteredDevices/getRegisteredDevices.d.ts.map +1 -1
  149. package/dist/modules/deviceRegistration/isDeviceRegistrationRequired/isDeviceRegistrationRequired.d.ts +1 -1
  150. package/dist/modules/extension/hasExtension/hasExtension.d.ts +1 -1
  151. package/dist/modules/extension/registerExtension/registerExtension.d.ts +1 -1
  152. package/dist/modules/flow/getFlow/getFlow.d.ts +1 -1
  153. package/dist/modules/flow/getFlowQuote/getFlowQuote.d.ts +1 -1
  154. package/dist/modules/flow/utils/clearFlowSessionToken/clearFlowSessionToken.d.ts +1 -1
  155. package/dist/modules/flow/utils/createFlowApiClient/createFlowApiClient.d.ts +1 -1
  156. package/dist/modules/flow/utils/createFlowApiClient/createFlowApiClient.d.ts.map +1 -1
  157. package/dist/modules/flow/utils/createFlowSessionTokenStorageKey/createFlowSessionTokenStorageKey.d.ts +1 -1
  158. package/dist/modules/flow/utils/createFlowSessionTokenStorageKey/createFlowSessionTokenStorageKey.d.ts.map +1 -1
  159. package/dist/modules/flow/utils/withFlowSessionTokenCleanupOn401/withFlowSessionTokenCleanupOn401.d.ts +1 -1
  160. package/dist/modules/funding/coinbase/addCoinbaseOnrampOrderEventListener/addCoinbaseOnrampOrderEventListener.d.ts +1 -1
  161. package/dist/modules/funding/coinbase/getCoinbaseBuyUrl/getCoinbaseBuyUrl.d.ts +1 -1
  162. package/dist/modules/funding/coinbase/getMissingVerificationForCoinbaseOnrampOrder/getMissingVerificationForCoinbaseOnrampOrder.d.ts +1 -1
  163. package/dist/modules/funding/coinbase/utils/validateUserCredentialsForCoinbaseOnrampOrder/validateUserCredentialsForCoinbaseOnrampOrder.d.ts +1 -1
  164. package/dist/modules/funding/coinbase/utils/validateUserCredentialsForCoinbaseOnrampOrder/validateUserCredentialsForCoinbaseOnrampOrder.d.ts.map +1 -1
  165. package/dist/modules/funding/kraken/createKrakenExchangeTransfer/createKrakenExchangeTransfer.d.ts +1 -1
  166. package/dist/modules/funding/kraken/getKrakenAccounts/getKrakenAccounts.d.ts +2 -2
  167. package/dist/modules/funding/kraken/getKrakenWhitelistedAddresses/getKrakenWhitelistedAddresses.d.ts +1 -1
  168. package/dist/modules/initializeClient/waitForClientInitialized/waitForClientInitialized.d.ts +1 -1
  169. package/dist/modules/initializeClient/waitForProjectSettings/waitForProjectSettings.d.ts +1 -1
  170. package/dist/modules/initializeClient/waitForProjectSettings/waitForProjectSettings.d.ts.map +1 -1
  171. package/dist/modules/keychainMigration/migrateSessionKeyToKeychain/migrateSessionKeyToKeychain.d.ts +1 -1
  172. package/dist/modules/legacyWalletBook/excludeInstalledFromCatalog/collectInstalledGroupIds/collectInstalledGroupIds.d.ts +1 -1
  173. package/dist/modules/legacyWalletBook/excludeInstalledFromCatalog/excludeInstalledFromCatalog.d.ts +1 -1
  174. package/dist/modules/legacyWalletBook/fetchLegacyWalletBook/fetchLegacyWalletBook.d.ts +1 -1
  175. package/dist/modules/legacyWalletBook/fetchLegacyWalletBook/fetchWithTimeout/fetchWithTimeout.d.ts +1 -1
  176. package/dist/modules/legacyWalletBook/getSpriteUrl/getSpriteUrl.d.ts +1 -1
  177. package/dist/modules/legacyWalletBook/getWalletBookCdnUrl/getWalletBookCdnUrl.d.ts +1 -1
  178. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/getChainFromWalletSchema/getChainFromWalletSchema.d.ts +2 -2
  179. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/getChainsFromWalletSchema/getChainsFromWalletSchema.d.ts +1 -1
  180. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/getWalletConnectCatalog.d.ts +1 -1
  181. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/shouldFilterWalletForWalletConnect/shouldFilterWalletForWalletConnect.d.ts +1 -1
  182. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/transformGroup/transformGroup.d.ts +1 -1
  183. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/transformWallet/transformWallet.d.ts +1 -1
  184. package/dist/modules/legacyWalletBook/getWalletConnectCatalog/transformWalletBook/transformWalletBook.d.ts +1 -1
  185. package/dist/modules/legacyWalletBook/getWalletConnectCatalogWalletByWalletProviderKey/getWalletConnectCatalogWalletByWalletProviderKey.d.ts +1 -1
  186. package/dist/modules/legacyWalletBook/hasUsableDeeplink/hasUsableDeeplink.d.ts +1 -1
  187. package/dist/modules/legacyWalletBook/matchWalletProvidersToCatalogGroup/matchWalletProvidersToCatalogGroup.d.ts +1 -1
  188. package/dist/modules/legacyWalletBook/shouldFilterWallet/shouldFilterWallet.d.ts +2 -2
  189. package/dist/modules/mfa/authenticateMfaRecoveryCode/authenticateMfaRecoveryCode.d.ts +1 -1
  190. package/dist/modules/mfa/authenticatePasskeyMFA/authenticatePasskeyMFA.d.ts +1 -1
  191. package/dist/modules/mfa/authenticateTotpMfaDevice/authenticateTotpMfaDevice.d.ts +1 -1
  192. package/dist/modules/mfa/consumeMfaTokenIfRequiredForAction/consumeMfaTokenIfRequiredForAction.d.ts +1 -1
  193. package/dist/modules/mfa/consumeMfaTokenIfRequiredForAction/consumeMfaTokenIfRequiredForAction.d.ts.map +1 -1
  194. package/dist/modules/mfa/getMfaDevices/getMfaDevices.d.ts +1 -1
  195. package/dist/modules/mfa/getMfaMethods/getMfaMethods.d.ts +1 -1
  196. package/dist/modules/mfa/getMfaRecoveryCodes/getMfaRecoveryCodes.d.ts +1 -1
  197. package/dist/modules/mfa/isMfaRequiredForAction/isMfaRequiredForAction.d.ts +1 -1
  198. package/dist/modules/mfa/isPendingRecoveryCodesAcknowledgment/isPendingRecoveryCodesAcknowledgment.d.ts +1 -1
  199. package/dist/modules/mfa/isUserMissingMfaAuth/isUserMissingMfaAuth.d.ts +1 -1
  200. package/dist/modules/otp/verifyOTP/verifyOTPForUserSignIn/verifyOTPForUserSignIn.d.ts +1 -1
  201. package/dist/modules/otp/verifyOTP/verifyOTPForUserSignIn/verifyOTPForUserSignIn.d.ts.map +1 -1
  202. package/dist/modules/otp/verifyOTP/verifyOTPForUserUpdate/verifyOTPForUserUpdate.d.ts +1 -1
  203. package/dist/modules/otp/verifyOTP/verifyOTPForUserUpdate/verifyOTPForUserUpdate.d.ts.map +1 -1
  204. package/dist/modules/projectSettings/fetchProjectSettings/fetchProjectSettings.d.ts +1 -1
  205. package/dist/modules/projectSettings/isCookieEnabled/isCookieEnabled.d.ts +1 -1
  206. package/dist/modules/screenshotProtection/setScreenshotProtection/setScreenshotProtection.d.ts +1 -1
  207. package/dist/modules/sessionKeys/generateNonceSignature/generateNonceSignature.d.ts +1 -1
  208. package/dist/modules/sessionKeys/generateNonceSignature/generateNonceSignature.d.ts.map +1 -1
  209. package/dist/modules/sessionKeys/generateSessionKeys/generateSessionKeys.d.ts +1 -1
  210. package/dist/modules/sessionKeys/generateSessionKeys/generateSessionKeys.d.ts.map +1 -1
  211. package/dist/modules/sessionKeys/generateSessionSignature/generateSessionSignature.d.ts +1 -1
  212. package/dist/modules/sessionKeys/generateSessionSignature/generateSessionSignature.d.ts.map +1 -1
  213. package/dist/modules/sessionKeys/getSessionKeys/getSessionKeys.d.ts +1 -1
  214. package/dist/modules/sessionKeys/getSessionKeys/getSessionKeys.d.ts.map +1 -1
  215. package/dist/modules/sessionKeys/getSignedSessionId/getSignedSessionId.d.ts +1 -1
  216. package/dist/modules/sessionKeys/getSignedSessionId/getSignedSessionId.d.ts.map +1 -1
  217. package/dist/modules/state/raiseStateEvents/raiseStateEvents.d.ts +1 -1
  218. package/dist/modules/state/raiseStateEvents/raiseStateEvents.d.ts.map +1 -1
  219. package/dist/modules/storageSync/hydrateStateWithStorage/hydrateStateWithStorage.d.ts +1 -1
  220. package/dist/modules/storageSync/hydrateStateWithStorage/hydrateStateWithStorage.d.ts.map +1 -1
  221. package/dist/modules/storageSync/initializeStorageSync.d.ts +1 -1
  222. package/dist/modules/storageSync/initializeStorageSync.d.ts.map +1 -1
  223. package/dist/modules/storageSync/syncStateWithStorage/syncStateWithStorage.d.ts +1 -1
  224. package/dist/modules/storageSync/syncStateWithStorage/syncStateWithStorage.d.ts.map +1 -1
  225. package/dist/modules/swap/getSwapQuote/getSwapQuote.d.ts +1 -1
  226. package/dist/modules/swap/getSwapStatus/getSwapStatus.d.ts +1 -1
  227. package/dist/modules/swap/utils/ensureCorrectActiveNetwork/ensureCorrectActiveNetwork.d.ts +1 -1
  228. package/dist/modules/user/isUserOnboardingComplete/isUserOnboardingComplete.d.ts +10 -3
  229. package/dist/modules/user/isUserOnboardingComplete/isUserOnboardingComplete.d.ts.map +1 -1
  230. package/dist/modules/waas/backupWaasKeySharesToGoogleDrive/backupWaasKeySharesToGoogleDrive.d.ts +1 -1
  231. package/dist/modules/waas/createWaasClient/createNativeWaasSDKContainer.d.ts +1 -1
  232. package/dist/modules/waas/createWaasClient/createWaasClient.d.ts +1 -1
  233. package/dist/modules/waas/createWaasClient/createWaasClient.d.ts.map +1 -1
  234. package/dist/modules/waas/createWaasClient/createWaasSDKContainer.d.ts +1 -1
  235. package/dist/modules/waas/createWaasClient/translateNativeOpenError.d.ts +1 -1
  236. package/dist/modules/waas/createWaasProvider/createWaasProvider.d.ts +1 -1
  237. package/dist/modules/waas/createWaasProvider/createWaasProvider.d.ts.map +1 -1
  238. package/dist/modules/waas/createWaasWalletAccounts/createWaasWalletAccounts.d.ts +2 -2
  239. package/dist/modules/waas/delegateWaasKeyShares/delegateWaasKeyShares.d.ts +1 -1
  240. package/dist/modules/waas/exportWaasClientKeyshares/exportWaasClientKeyshares.d.ts +1 -1
  241. package/dist/modules/waas/exportWaasPrivateKey/exportWaasPrivateKey.d.ts +1 -1
  242. package/dist/modules/waas/exportWaasPrivateKeyToContainer/exportWaasPrivateKeyToContainer.d.ts +1 -1
  243. package/dist/modules/waas/findWaasWalletProviderByChain/findWaasWalletProviderByChain.d.ts +1 -1
  244. package/dist/modules/waas/findWaasWalletProviderByChain/findWaasWalletProviderByChain.d.ts.map +1 -1
  245. package/dist/modules/waas/getAllUserWaasAddressesForChain/getAllUserWaasAddressesForChain.d.ts +1 -1
  246. package/dist/modules/waas/getAllUserWaasAddressesForChain/getAllUserWaasAddressesForChain.d.ts.map +1 -1
  247. package/dist/modules/waas/getChainsMissingWaasWalletAccounts/getChainsMissingWaasWalletAccounts.d.ts +1 -1
  248. package/dist/modules/waas/getWaasChainNameFromChain/getWaasChainNameFromChain.d.ts +1 -1
  249. package/dist/modules/waas/getWaasChainNameFromChain/getWaasChainNameFromChain.d.ts.map +1 -1
  250. package/dist/modules/waas/getWaasWalletProviderByChain/getWaasWalletProviderByChain.d.ts +1 -1
  251. package/dist/modules/waas/getWaasWalletProviderByChain/getWaasWalletProviderByChain.d.ts.map +1 -1
  252. package/dist/modules/waas/getWaasWalletProviderFromWalletAccount/getWaasWalletProviderFromWalletAccount.d.ts +1 -1
  253. package/dist/modules/waas/getWaasWalletProviderFromWalletAccount/getWaasWalletProviderFromWalletAccount.d.ts.map +1 -1
  254. package/dist/modules/waas/getWalletRecoveryState/getWalletRecoveryState.d.ts +1 -1
  255. package/dist/modules/waas/hasDelegatedAccess/hasDelegatedAccess.d.ts +1 -1
  256. package/dist/modules/waas/importWaasPrivateKey/importWaasPrivateKey.d.ts +1 -1
  257. package/dist/modules/waas/initializeWaasClientsForEagerRecovery/initializeWaasClientsForEagerRecovery.d.ts +1 -1
  258. package/dist/modules/waas/isDynamicWaasEnabled/isDynamicWaasEnabled.d.ts +1 -1
  259. package/dist/modules/waas/isPasswordRequiredForWaasWallets/isPasswordRequiredForWaasWallets.d.ts +1 -1
  260. package/dist/modules/waas/isWaasWalletAccount/isWaasWalletAccount.d.ts +1 -1
  261. package/dist/modules/waas/isWaasWalletProvider/isWaasWalletProvider.d.ts +1 -1
  262. package/dist/modules/waas/isWaasWalletProvider/isWaasWalletProvider.d.ts.map +1 -1
  263. package/dist/modules/waas/isWalletCreationRequirement/isWalletCreationRequirement.d.ts +1 -1
  264. package/dist/modules/waas/normalizeWalletRequirements/normalizeWalletRequirements.d.ts +1 -1
  265. package/dist/modules/waas/preconnectWaasIframe/preconnectWaasIframe.d.ts +1 -1
  266. package/dist/modules/waas/refreshWaasWalletAccountShares/refreshWaasWalletAccountShares.d.ts +1 -1
  267. package/dist/modules/waas/revokeWaasDelegation/revokeWaasDelegation.d.ts +1 -1
  268. package/dist/modules/waas/setWaasWalletAccountPassword/setWaasWalletAccountPassword.d.ts +1 -1
  269. package/dist/modules/waas/shouldAutoCreateWalletForChain/shouldAutoCreateWalletForChain.d.ts +1 -1
  270. package/dist/modules/waas/unlockWallet/unlockWallet.d.ts +1 -1
  271. package/dist/modules/waas/updateWaasPassword/updateWaasPassword.d.ts +1 -1
  272. package/dist/modules/walletBackup/googleDrive/findMissingGoogleDriveBackupScopes/findMissingGoogleDriveBackupScopes.d.ts +1 -1
  273. package/dist/modules/walletBackup/googleDrive/hasAllGoogleDriveBackupScopes/hasAllGoogleDriveBackupScopes.d.ts +1 -1
  274. package/dist/modules/walletBackup/googleDrive/isInsufficientGoogleDriveScopesError/isInsufficientGoogleDriveScopesError.d.ts +1 -1
  275. package/dist/modules/walletBackup/googleDrive/utils/fetchGoogleDriveOauthAccess/fetchGoogleDriveOauthAccess.d.ts +1 -1
  276. package/dist/modules/walletBackup/googleDrive/utils/findGoogleOauthAccountId/findGoogleOauthAccountId.d.ts +1 -1
  277. package/dist/modules/walletOptionsCatalogue/buildInAppBrowserOptions/buildInAppBrowserOptions.d.ts +1 -1
  278. package/dist/modules/walletOptionsCatalogue/buildInAppBrowserOptions/getInAppBrowserUrl/getInAppBrowserUrl.d.ts +1 -1
  279. package/dist/modules/walletOptionsCatalogue/buildInstallationUrls/buildInstallationUrls.d.ts +1 -1
  280. package/dist/modules/walletOptionsCatalogue/buildInstallationUrlsByWalletOptionKey/buildInstallationUrlsByWalletOptionKey.d.ts +1 -1
  281. package/dist/modules/walletOptionsCatalogue/buildMetaMaskSdkUriOptions/buildMetaMaskSdkUriOptions.d.ts +1 -1
  282. package/dist/modules/walletOptionsCatalogue/buildWalletConnectOptions/buildWalletConnectOptions.d.ts +1 -1
  283. package/dist/modules/walletOptionsCatalogue/buildWalletOption/buildWalletOption.d.ts +1 -1
  284. package/dist/modules/walletOptionsCatalogue/buildWithWalletProviderOptions/buildWithWalletProviderOptions.d.ts +1 -1
  285. package/dist/modules/walletOptionsCatalogue/classifyWithWalletProviderSource/classifyWithWalletProviderSource.d.ts +1 -1
  286. package/dist/modules/walletOptionsCatalogue/compareByRelevance/compareByRelevance.d.ts +1 -1
  287. package/dist/modules/walletOptionsCatalogue/findWalletOptionKeyForProviderKey/findByNameMatch/findByNameMatch.d.ts +1 -1
  288. package/dist/modules/walletOptionsCatalogue/findWalletOptionKeyForProviderKey/findWalletOptionKeyForProviderKey.d.ts +1 -1
  289. package/dist/modules/walletOptionsCatalogue/findWalletOptionKeyForProviderKey/resolveWalletOptionKey/resolveWalletOptionKey.d.ts +1 -1
  290. package/dist/modules/walletOptionsCatalogue/getConnectionOptionPriority/getConnectionOptionPriority.d.ts +1 -1
  291. package/dist/modules/walletOptionsCatalogue/getInstallationLinkForCurrentPlatform/getInstallationLinkForCurrentPlatform.d.ts +1 -1
  292. package/dist/modules/walletOptionsCatalogue/getPriorityIndex/getPriorityIndex.d.ts +1 -1
  293. package/dist/modules/walletOptionsCatalogue/getWalletOptionsCatalogue/getWalletOptionsCatalogue.d.ts +1 -1
  294. package/dist/modules/walletOptionsCatalogue/groupOptionsByWalletOption/groupOptionsByWalletOption.d.ts +1 -1
  295. package/dist/modules/walletOptionsCatalogue/hasAnyConnectionOption/hasAnyConnectionOption.d.ts +1 -1
  296. package/dist/modules/walletOptionsCatalogue/hasInstalledProvider/hasInstalledProvider.d.ts +1 -1
  297. package/dist/modules/walletOptionsCatalogue/normalizeWalletDisplayName/normalizeWalletDisplayName.d.ts +1 -1
  298. package/dist/modules/walletOptionsCatalogue/resolveWalletBookWalletOptionKey/resolveWalletBookWalletOptionKey.d.ts +1 -1
  299. package/dist/modules/walletOptionsCatalogue/sortConnectionOptions/sortConnectionOptions.d.ts +1 -1
  300. package/dist/modules/walletOptionsCatalogue/sortWalletOptions/sortWalletOptions.d.ts +1 -1
  301. package/dist/modules/wallets/assertWalletAccountSigningAvailability/assertWalletAccountSigningAvailability.d.ts +1 -1
  302. package/dist/modules/wallets/destroyWalletProviders/destroyWalletProviders.d.ts +1 -1
  303. package/dist/modules/wallets/disconnectWalletAccount/disconnectWalletAccount.d.ts +1 -1
  304. package/dist/modules/wallets/emitWalletAccountsChangedEvent/emitWalletAccountsChangedEvent.d.ts +1 -1
  305. package/dist/modules/wallets/getAvailableWalletProvidersData/getAvailableWalletProvidersData.d.ts +1 -1
  306. package/dist/modules/wallets/getConnectedAddresses/getConnectedAddresses.d.ts +1 -1
  307. package/dist/modules/wallets/getOwnerWalletAccountForSmartWalletAccount/getOwnerWalletAccountForSmartWalletAccount.d.ts +1 -1
  308. package/dist/modules/wallets/getOwnerWalletAccountForSmartWalletAccount/getOwnerWalletAccountForSmartWalletAccount.d.ts.map +1 -1
  309. package/dist/modules/wallets/getWalletAccountAddressByType/getWalletAccountAddressByType.d.ts +1 -1
  310. package/dist/modules/wallets/getWalletAccountAddressByType/getWalletAccountAddressByType.d.ts.map +1 -1
  311. package/dist/modules/wallets/getWalletAccounts/getWalletAccounts.d.ts +1 -1
  312. package/dist/modules/wallets/getWalletAccounts/getWalletAccountsFromState/getWalletAccountsFromState.d.ts +1 -1
  313. package/dist/modules/wallets/getWalletAccounts/getWalletAccountsFromState/getWalletAccountsFromState.d.ts.map +1 -1
  314. package/dist/modules/wallets/getWalletProviderByKey/getWalletProviderByKey.d.ts +1 -1
  315. package/dist/modules/wallets/getWalletProviderByKey/getWalletProviderByKey.d.ts.map +1 -1
  316. package/dist/modules/wallets/getWalletProviderDataByKey/getWalletProviderDataByKey.d.ts +1 -1
  317. package/dist/modules/wallets/getWalletProviders/getWalletProviders.d.ts +1 -1
  318. package/dist/modules/wallets/hardwareWallet/canConnectWithHardwareWallet/canConnectWithHardwareWallet.d.ts +1 -1
  319. package/dist/modules/wallets/hardwareWallet/formatSignatureForHardwareWallet/formatSignatureForHardwareWallet.d.ts +1 -1
  320. package/dist/modules/wallets/hardwareWallet/isHardwareWalletAccount/isHardwareWalletAccount.d.ts +1 -1
  321. package/dist/modules/wallets/hasWalletProviderConnectMethod/hasWalletProviderConnectMethod.d.ts +1 -1
  322. package/dist/modules/wallets/isAnyWalletAccountConnected/isAnyWalletAccountConnected.d.ts +1 -1
  323. package/dist/modules/wallets/isWalletAccountVerified/isWalletAccountVerified.d.ts +1 -1
  324. package/dist/modules/wallets/networks/createBaseNetworkProvider/createBaseNetworkProvider.d.ts +1 -1
  325. package/dist/modules/wallets/networks/createBaseNetworkProvider/createBaseNetworkProvider.d.ts.map +1 -1
  326. package/dist/modules/wallets/networks/getActiveNetworkData/getActiveNetworkData.d.ts +1 -1
  327. package/dist/modules/wallets/networks/getActiveNetworkId/getActiveNetworkId.d.ts +1 -1
  328. package/dist/modules/wallets/networks/getBalance/getBalance.d.ts +1 -1
  329. package/dist/modules/wallets/networks/getBalanceForAddress/getBalanceForAddress.d.ts +1 -1
  330. package/dist/modules/wallets/networks/getNativeBalance/getNativeBalance.d.ts +1 -1
  331. package/dist/modules/wallets/networks/getNetworkDataForNetworkId/getNetworkDataForNetworkId.d.ts +1 -1
  332. package/dist/modules/wallets/networks/getNetworkDataForNetworkId/getNetworkDataForNetworkId.d.ts.map +1 -1
  333. package/dist/modules/wallets/networks/getNetworkProviderFromNetworkId/getNetworkProviderFromNetworkId.d.ts +1 -1
  334. package/dist/modules/wallets/networks/getNetworkProviderFromNetworkId/getNetworkProviderFromNetworkId.d.ts.map +1 -1
  335. package/dist/modules/wallets/networks/getNetworkProviders/getNetworkProviders.d.ts +1 -1
  336. package/dist/modules/wallets/networks/getNetworksData/getNetworksData.d.ts +1 -1
  337. package/dist/modules/wallets/networks/getSdkChainFromApiChainName/getSdkChainFromApiChainName.d.ts +1 -1
  338. package/dist/modules/wallets/networks/getTransactionHistory/getTransactionHistory.d.ts +1 -1
  339. package/dist/modules/wallets/networks/isProgrammaticNetworkSwitchAvailable/isProgrammaticNetworkSwitchAvailable.d.ts +1 -1
  340. package/dist/modules/wallets/networks/lastKnownNetworkRegistry/createLastKnownNetworkRegistry/createLastKnownNetworkRegistry.d.ts +1 -1
  341. package/dist/modules/wallets/networks/networkProviderBuilderRegistry/createNetworkProviderBuilderRegistry/createNetworkProviderBuilderRegistry.d.ts +1 -1
  342. package/dist/modules/wallets/networks/networkProviderBuilderRegistry/createNetworkProviderBuilderRegistry/createNetworkProviderBuilderRegistry.d.ts.map +1 -1
  343. package/dist/modules/wallets/primaryWalletAccount/getPrimaryWalletAccount/getPrimaryWalletAccount.d.ts +1 -1
  344. package/dist/modules/wallets/reconcileWalletAccountsAgainstClient/reconcileWalletAccountsAgainstClient.d.ts +1 -1
  345. package/dist/modules/wallets/unverifiedWalletAccounts/removeUnverifiedWalletAccount/removeUnverifiedWalletAccount.d.ts +1 -1
  346. package/dist/modules/wallets/unverifiedWalletAccounts/setUnverifiedWalletAccounts/setUnverifiedWalletAccounts.d.ts +1 -1
  347. package/dist/modules/wallets/userHasEmbeddedWalletForChain/userHasEmbeddedWalletForChain.d.ts +1 -1
  348. package/dist/modules/wallets/userHasEmbeddedWalletForChain/userHasEmbeddedWalletForChain.d.ts.map +1 -1
  349. package/dist/modules/wallets/userHasExternalWallet/userHasExternalWallet.d.ts +1 -1
  350. package/dist/modules/wallets/userHasExternalWallet/userHasExternalWallet.d.ts.map +1 -1
  351. package/dist/modules/wallets/utils/convertUnverifiedWalletAccountToWalletAccount/convertUnverifiedWalletAccountToWalletAccount.d.ts +1 -1
  352. package/dist/modules/wallets/utils/convertUnverifiedWalletAccountToWalletAccount/convertUnverifiedWalletAccountToWalletAccount.d.ts.map +1 -1
  353. package/dist/modules/wallets/utils/convertVerifiedCredentialToWalletAccount/convertVerifiedCredentialToWalletAccount.d.ts +1 -1
  354. package/dist/modules/wallets/utils/convertVerifiedCredentialToWalletAccount/convertVerifiedCredentialToWalletAccount.d.ts.map +1 -1
  355. package/dist/modules/wallets/utils/formatSignInMessage/formatSignInMessage.d.ts +1 -1
  356. package/dist/modules/wallets/utils/formatWalletAccountId/formatWalletAccountId.d.ts +1 -1
  357. package/dist/modules/wallets/utils/formatWalletAccountId/formatWalletAccountId.d.ts.map +1 -1
  358. package/dist/modules/wallets/utils/formatWalletProviderGroupKey/formatWalletProviderGroupKey.d.ts +1 -1
  359. package/dist/modules/wallets/utils/formatWalletProviderGroupKey/formatWalletProviderGroupKey.d.ts.map +1 -1
  360. package/dist/modules/wallets/utils/formatWalletProviderKey/formatWalletProviderKey.d.ts +1 -1
  361. package/dist/modules/wallets/utils/getAddressesWithTypesFromConnectionResult/getAddressesWithTypesFromConnectionResult.d.ts +1 -1
  362. package/dist/modules/wallets/utils/getAddressesWithTypesFromConnectionResult/getAddressesWithTypesFromConnectionResult.d.ts.map +1 -1
  363. package/dist/modules/wallets/utils/getAllProvidersFromWindow/getAllProvidersFromWindow.d.ts +1 -1
  364. package/dist/modules/wallets/utils/getAvailableWalletProvidersFromWalletAccounts/getAvailableWalletProvidersFromWalletAccounts.d.ts +1 -1
  365. package/dist/modules/wallets/utils/getAvailableWalletProvidersFromWalletAccounts/getAvailableWalletProvidersFromWalletAccounts.d.ts.map +1 -1
  366. package/dist/modules/wallets/utils/getChainIdForAccountVerification/getChainIdForAccountVerification.d.ts +1 -1
  367. package/dist/modules/wallets/utils/getChainIdForAccountVerification/getChainIdForAccountVerification.d.ts.map +1 -1
  368. package/dist/modules/wallets/utils/getInjectedProviderFromWindow/getInjectedProviderFromWindow.d.ts +1 -1
  369. package/dist/modules/wallets/utils/getInjectedProviderFromWindow/getInjectedProviderFromWindow.d.ts.map +1 -1
  370. package/dist/modules/wallets/utils/getSignInMessage/createSignInMessageStatement/createSignInMessageStatement.d.ts +1 -1
  371. package/dist/modules/wallets/utils/getSignInMessage/createSignInMessageStatement/createSignInMessageStatement.d.ts.map +1 -1
  372. package/dist/modules/wallets/utils/getSignInMessage/getSignInMessage.d.ts +1 -1
  373. package/dist/modules/wallets/utils/getSignInMessage/getSignInMessage.d.ts.map +1 -1
  374. package/dist/modules/wallets/utils/getVerifiedCredentialForWalletAccount/getVerifiedCredentialForWalletAccount.d.ts +1 -1
  375. package/dist/modules/wallets/utils/getVerifiedCredentialForWalletAccount/getVerifiedCredentialForWalletAccount.d.ts.map +1 -1
  376. package/dist/modules/wallets/utils/getWalletAccountFromAddress/getWalletAccountFromAddress.d.ts +1 -1
  377. package/dist/modules/wallets/utils/getWalletProviderFromWalletAccount/getWalletProviderFromWalletAccount.d.ts +1 -1
  378. package/dist/modules/wallets/utils/getWalletProviderFromWalletAccount/getWalletProviderFromWalletAccount.d.ts.map +1 -1
  379. package/dist/modules/wallets/utils/isSameAddress/isSameAddress.d.ts +1 -1
  380. package/dist/modules/wallets/utils/isSameAddress/isSameAddress.d.ts.map +1 -1
  381. package/dist/modules/wallets/utils/normalizeAddress/normalizeAddress.d.ts +1 -1
  382. package/dist/modules/wallets/utils/normalizeAddress/normalizeAddress.d.ts.map +1 -1
  383. package/dist/modules/wallets/utils/normalizeWalletNameWithChain/normalizeWalletNameWithChain.d.ts +1 -1
  384. package/dist/modules/wallets/utils/stripChainSuffix/stripChainSuffix.d.ts +1 -1
  385. package/dist/modules/wallets/verifyMessageSignatureOwnership/verifyMessageSignatureOwnership.d.ts +1 -1
  386. package/dist/modules/wallets/verifyWalletAccountForSignInOrTransfer/verifyWalletAccountForSignInOrTransfer.d.ts +1 -1
  387. package/dist/modules/wallets/verifyWalletAccountForSignInOrTransfer/verifyWalletAccountForSignInOrTransfer.d.ts.map +1 -1
  388. package/dist/modules/wallets/walletProvider/defaultImplementations/getActiveNetworkIdFromLastKnownRegistry/getActiveNetworkIdFromLastKnownRegistry.d.ts +1 -1
  389. package/dist/modules/wallets/walletProvider/defaultImplementations/getActiveNetworkIdFromLastKnownRegistry/getActiveNetworkIdFromLastKnownRegistry.d.ts.map +1 -1
  390. package/dist/modules/wallets/walletProvider/defaultImplementations/switchActiveNetworkInLastKnownRegistry/switchActiveNetworkInLastKnownRegistry.d.ts +1 -1
  391. package/dist/modules/wallets/walletProvider/defaultImplementations/switchActiveNetworkInLastKnownRegistry/switchActiveNetworkInLastKnownRegistry.d.ts.map +1 -1
  392. package/dist/modules/wallets/walletProvider/events/createWalletProviderEventEmitter/createWalletProviderEventEmitter.d.ts +2 -2
  393. package/dist/modules/wallets/walletProvider/events/offWalletProviderEvent/offWalletProviderEvent.d.ts +1 -1
  394. package/dist/modules/wallets/walletProvider/events/onWalletProviderEvent/onWalletProviderEvent.d.ts +1 -1
  395. package/dist/modules/wallets/walletProvider/extractChainFromNormalizedName/extractChainFromNormalizedName.d.ts +1 -1
  396. package/dist/modules/wallets/walletProvider/isDeeplinkWalletProvider/isDeeplinkWalletProvider.d.ts +1 -1
  397. package/dist/modules/wallets/walletProvider/splitWalletProviderKey/splitWalletProviderKey.d.ts +1 -1
  398. package/dist/modules/wallets/walletProvider/splitWalletProviderKey/splitWalletProviderKey.d.ts.map +1 -1
  399. package/dist/modules/wallets/walletProvider/walletProviderKeyMap/getWalletProviderKeyFromVerifiedCredential/getWalletProviderKeyFromVerifiedCredential.d.ts +1 -1
  400. package/dist/modules/wallets/walletProvider/walletProviderKeyMap/getWalletProviderKeyFromVerifiedCredential/getWalletProviderKeyFromVerifiedCredential.d.ts.map +1 -1
  401. package/dist/modules/wallets/walletProvider/walletProviderKeyMap/updateWalletProviderKeysForVerifiedCredentials/updateWalletProviderKeysForVerifiedCredentials.d.ts +1 -1
  402. package/dist/modules/wallets/walletProvider/walletProviderKeyMap/updateWalletProviderKeysForVerifiedCredentials/updateWalletProviderKeysForVerifiedCredentials.d.ts.map +1 -1
  403. package/dist/modules/wallets/walletProviderRegistry/createWalletProviderRegistry/createWalletProviderRegistry.d.ts +1 -1
  404. package/dist/{refreshAuth-BWQWl4uA.esm.js → refreshAuth-BTPctQtq.esm.js} +3 -3
  405. package/dist/{refreshAuth-BWQWl4uA.esm.js.map → refreshAuth-BTPctQtq.esm.js.map} +1 -1
  406. package/dist/{refreshAuth-tjEnkc58.cjs → refreshAuth-ByIVzawo.cjs} +3 -3
  407. package/dist/{refreshAuth-tjEnkc58.cjs.map → refreshAuth-ByIVzawo.cjs.map} +1 -1
  408. package/dist/{refreshAuth-D8UjWFLB.native.esm.js → refreshAuth-C3issn5b.native.esm.js} +3 -3
  409. package/dist/{refreshAuth-D8UjWFLB.native.esm.js.map → refreshAuth-C3issn5b.native.esm.js.map} +1 -1
  410. package/dist/services/asyncTrack/createAsyncTrack.d.ts +1 -1
  411. package/dist/services/crossTabBroadcast/createCrossTabBroadcast/createCrossTabBroadcast.d.ts +1 -1
  412. package/dist/services/eventEmitter/createEventEmitter.d.ts +1 -1
  413. package/dist/services/eventEmitter/createEventEmitter.d.ts.map +1 -1
  414. package/dist/services/fetch/createWebFetch.d.ts +1 -1
  415. package/dist/services/instrumentation/connectLoggerToInstrumentation/connectLoggerToInstrumentation.d.ts +1 -1
  416. package/dist/services/instrumentation/createInstrumentation/createInstrumentation.d.ts +1 -1
  417. package/dist/services/instrumentation/instrumentFunction/extractParams/extractParams.d.ts +1 -1
  418. package/dist/services/instrumentation/instrumentFunction/instrumentFunction.d.ts +1 -1
  419. package/dist/services/instrumentation/instrumentFunction/scrubResolvedValue/scrubResolvedValue.d.ts +1 -1
  420. package/dist/services/instrumentation/scrubParameters/scrubParameters.d.ts +1 -1
  421. package/dist/services/instrumentation/scrubParameters/scrubParameters.d.ts.map +1 -1
  422. package/dist/services/instrumentation/transports/createDynamicTransport/createDynamicTransport.d.ts +1 -1
  423. package/dist/services/keychain/createKeychainService/createKeychainService.d.ts +1 -1
  424. package/dist/services/keychain/createKeychainService/createKeychainService.d.ts.map +1 -1
  425. package/dist/services/keychain/createKeychainService/utils/deleteIndexedDBItem.d.ts +1 -1
  426. package/dist/services/keychain/createKeychainService/utils/deleteIndexedDBItem.d.ts.map +1 -1
  427. package/dist/services/keychain/createKeychainService/utils/getIndexedDBItem.d.ts +1 -1
  428. package/dist/services/keychain/createKeychainService/utils/getIndexedDBItem.d.ts.map +1 -1
  429. package/dist/services/keychain/createKeychainService/utils/openDatabase.d.ts +1 -1
  430. package/dist/services/keychain/createKeychainService/utils/openDatabase.d.ts.map +1 -1
  431. package/dist/services/keychain/createKeychainService/utils/setIndexedDBItem.d.ts +1 -1
  432. package/dist/services/keychain/createKeychainService/utils/setIndexedDBItem.d.ts.map +1 -1
  433. package/dist/services/keychain/createKeychainService/utils/withDatabase/withDatabase.d.ts +1 -1
  434. package/dist/services/logger/createLogger/createLogger.d.ts +2 -2
  435. package/dist/services/nativeManifest/getReactNativeManifest/getReactNativeManifest.d.ts +1 -1
  436. package/dist/services/navigate/createNavigationHandler/createNavigationHandler.d.ts +1 -1
  437. package/dist/services/openDeeplink/createWebDeeplinkOpener/createWebDeeplinkOpener.d.ts +1 -1
  438. package/dist/services/passkey/createPasskeyService/createPasskeyService.d.ts +1 -1
  439. package/dist/services/realtime/createRealtimeChannelSchema/createRealtimeChannelSchema.d.ts +1 -1
  440. package/dist/services/realtime/createRealtimeService/createRealtimeService.d.ts +1 -1
  441. package/dist/services/runtimeServices/createRuntimeServiceAccessKey/createRuntimeServiceAccessKey.d.ts +1 -1
  442. package/dist/services/runtimeServices/createRuntimeServices/createRuntimeServices.d.ts +1 -1
  443. package/dist/services/storage/createLocalStorageAdapter/createLocalStorageAdapter.d.ts +1 -1
  444. package/dist/services/storage/createStorage/createStorage.d.ts +1 -1
  445. package/dist/services/storage/createStorage/formatForStorage/isValidDateISOString/isValidDateISOString.d.ts +1 -1
  446. package/dist/services/storage/createStorage/formatForStorage/storageFormat.d.ts +2 -2
  447. package/dist/services/storage/createStorage/formatForStorage/storageFormat.d.ts.map +1 -1
  448. package/dist/services/storage/createStorageKeySchema/createStorageKeySchema.d.ts +1 -1
  449. package/dist/services/storage/createStorageKeySchema/createStorageKeySchema.d.ts.map +1 -1
  450. package/dist/tsconfig.lib.tsbuildinfo +1 -1
  451. package/dist/utils/appendConnectionUriToDeeplink/appendConnectionUriToDeeplink.d.ts +1 -1
  452. package/dist/utils/base64UrlDecode/base64UrlDecode.d.ts +1 -1
  453. package/dist/utils/base64urlFromBytes/base64urlFromBytes.d.ts +1 -1
  454. package/dist/utils/bufferToBase64/bufferToBase64.d.ts +1 -1
  455. package/dist/utils/bufferToBase64/bufferToBase64.d.ts.map +1 -1
  456. package/dist/utils/bufferToHex/bufferToHex.d.ts +1 -1
  457. package/dist/utils/bytesFromBase64url/bytesFromBase64url.d.ts +1 -1
  458. package/dist/utils/compressRawPublicKey/compressRawPublicKey.d.ts +1 -1
  459. package/dist/utils/debouncedMutex/createDebouncedMutex/createDebouncedMutex.d.ts +1 -1
  460. package/dist/utils/debouncedMutex/createDebouncedMutex/createDebouncedMutex.d.ts.map +1 -1
  461. package/dist/utils/deferredPromise/createDeferredPromise.d.ts +1 -1
  462. package/dist/utils/deferredPromise/createDeferredPromise.d.ts.map +1 -1
  463. package/dist/utils/derToP1363/derToP1363.d.ts +1 -1
  464. package/dist/utils/digestSHA256/digestSHA256.d.ts +1 -1
  465. package/dist/utils/digestSHA256/digestSHA256.d.ts.map +1 -1
  466. package/dist/utils/encodeBase64Url/encodeBase64Url.d.ts +1 -1
  467. package/dist/utils/filterDuplicates/filterDuplicates.d.ts +1 -1
  468. package/dist/utils/getAppMetadata/getAppMetadata.d.ts +1 -1
  469. package/dist/utils/getBuffer/getBuffer.d.ts +1 -1
  470. package/dist/utils/getBuffer/getBuffer.d.ts.map +1 -1
  471. package/dist/utils/getChainFromVerifiedCredentialChain/getChainFromVerifiedCredentialChain.d.ts +1 -1
  472. package/dist/utils/getChainFromVerifiedCredentialChain/getChainFromVerifiedCredentialChain.d.ts.map +1 -1
  473. package/dist/utils/getChainFromWalletBookIdentifier/getChainFromWalletBookIdentifier.d.ts +1 -1
  474. package/dist/utils/getKeychainIndexedDBName/getKeychainIndexedDBName.d.ts +1 -1
  475. package/dist/utils/getNativeLinkScheme/getNativeLinkScheme.d.ts +1 -1
  476. package/dist/utils/getNonce/fetchAndStoreNonces/fetchAndStoreNonces.d.ts +1 -1
  477. package/dist/utils/getNonce/getNonce.d.ts +1 -1
  478. package/dist/utils/getNonce/prefetchNoncesIfNeeded/prefetchNoncesIfNeeded.d.ts +1 -1
  479. package/dist/utils/getNonce/prefetchNoncesIfNeeded/prefetchNoncesIfNeeded.d.ts.map +1 -1
  480. package/dist/utils/getOperatingSystem/getOperatingSystem.d.ts +1 -1
  481. package/dist/utils/getPlatform/getPlatform.d.ts +1 -1
  482. package/dist/utils/getUserAgent/getUserAgent.d.ts +1 -1
  483. package/dist/utils/isEqualShallow/isEqualShallow.d.ts +1 -1
  484. package/dist/utils/isError/isError.d.ts +1 -1
  485. package/dist/utils/isErrorWithCode/isErrorWithCode.d.ts +1 -1
  486. package/dist/utils/isMobile/isMobile.d.ts +16 -16
  487. package/dist/utils/isMobile/isMobile.d.ts.map +1 -1
  488. package/dist/utils/isServerSideRendering/isServerSideRendering.d.ts +1 -1
  489. package/dist/utils/observable/createObservableState/createObservableState.d.ts +1 -1
  490. package/dist/utils/observable/subscribeWithSelector/subscribeWithSelector.d.ts +1 -1
  491. package/dist/utils/p256Keygen/p256Keygen.d.ts +1 -1
  492. package/dist/utils/p256Keygen/p256Keygen.d.ts.map +1 -1
  493. package/dist/utils/p256Sign/p256Sign.d.ts +1 -1
  494. package/dist/utils/p256Sign/p256Sign.d.ts.map +1 -1
  495. package/dist/utils/parseAmountToSmallestUnit/parseAmountToSmallestUnit.d.ts +1 -1
  496. package/dist/utils/parseUserAgent/parseUserAgent.d.ts +1 -1
  497. package/dist/utils/parseUserAgent/parseUserAgent.d.ts.map +1 -1
  498. package/dist/utils/randomString/randomString.d.ts +1 -1
  499. package/dist/utils/randomString/randomString.d.ts.map +1 -1
  500. package/dist/utils/retryOnFail/retryOnFail.d.ts +1 -1
  501. package/dist/utils/retryOnFail/retryOnFail.d.ts.map +1 -1
  502. package/dist/utils/setCookie/setCookie.d.ts +1 -1
  503. package/dist/waas.cjs +27 -27
  504. package/dist/waas.cjs.map +1 -1
  505. package/dist/waas.esm.js +26 -26
  506. package/dist/waas.esm.js.map +1 -1
  507. package/dist/waas.native.esm.js +26 -26
  508. package/dist/waas.native.esm.js.map +1 -1
  509. package/dist/waasCore.cjs +17 -12
  510. package/dist/waasCore.cjs.map +1 -1
  511. package/dist/waasCore.esm.js +16 -11
  512. package/dist/waasCore.esm.js.map +1 -1
  513. package/dist/waasCore.native.esm.js +19 -14
  514. package/dist/waasCore.native.esm.js.map +1 -1
  515. package/package.json +2 -2
  516. package/dist/InvalidParamError-CKUis748.native.esm.js.map +0 -1
  517. package/dist/InvalidParamError-I6NfUdQL.esm.js.map +0 -1
  518. package/dist/InvalidParamError-d0WFn5Ai.cjs.map +0 -1
  519. package/dist/getNetworkProviderFromNetworkId-CfW0tOnr.cjs.map +0 -1
  520. package/dist/getNetworkProviderFromNetworkId-D6ABmeNQ.esm.js.map +0 -1
  521. package/dist/getNetworkProviderFromNetworkId-DpiVLfs_.native.esm.js.map +0 -1
  522. package/dist/getSignedSessionId-Bc-sYE2A.cjs.map +0 -1
  523. package/dist/getSignedSessionId-C6LJdiSK.native.esm.js.map +0 -1
  524. package/dist/getSignedSessionId-IEoo2Kv9.esm.js.map +0 -1
  525. package/dist/getWaasWalletProviderFromWalletAccount-CSmVAhr2.cjs.map +0 -1
  526. package/dist/getWaasWalletProviderFromWalletAccount-D1wxsNEI.native.esm.js.map +0 -1
  527. package/dist/getWaasWalletProviderFromWalletAccount-DojjjSIP.esm.js.map +0 -1
  528. package/dist/getWalletProviderByKey-B821GpaI.cjs.map +0 -1
  529. package/dist/getWalletProviderByKey-DsTEubkT.esm.js.map +0 -1
  530. package/dist/getWalletProviderByKey-RTW-S68o.native.esm.js.map +0 -1
  531. package/dist/isMfaRequiredForAction-C1-1spV9.esm.js.map +0 -1
  532. package/dist/isMfaRequiredForAction-DL013-fR.cjs.map +0 -1
  533. package/dist/preconnectWaasIframe-BnyTG4Wy.native.esm.js +0 -31
  534. package/dist/preconnectWaasIframe-BnyTG4Wy.native.esm.js.map +0 -1
  535. package/dist/preconnectWaasIframe-DWYWeLor.cjs +0 -37
  536. package/dist/preconnectWaasIframe-DWYWeLor.cjs.map +0 -1
  537. package/dist/preconnectWaasIframe-Dn3RrrHd.esm.js +0 -31
  538. package/dist/preconnectWaasIframe-Dn3RrrHd.esm.js.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getWalletProviderByKey-BMzoL_69.esm.js","names":["newState: Partial<DynamicCoreState>","walletProvider"],"sources":["../src/modules/wallets/emitWalletAccountsChangedEvent/emitWalletAccountsChangedEvent.ts","../src/modules/auth/updateAuthFromVerifyResponse/checkAndRaiseWalletAccountsChangedEvent/checkAndRaiseWalletAccountsChangedEvent.ts","../src/modules/wallets/getWalletProviders/getWalletProviders.ts","../src/modules/waas/findWaasWalletProviderByChain/findWaasWalletProviderByChain.ts","../src/modules/waas/isWaasWalletAccount/isWaasWalletAccount.ts","../src/modules/waas/initializeWaasClientsForEagerRecovery/initializeWaasClientsForEagerRecovery.ts","../src/modules/auth/decodeJwt/decodeJwt.ts","../src/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/normalizeScopes/normalizeScopes.ts","../src/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/parseElevatedAccessToken/parseElevatedAccessToken.ts","../src/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/upsertElevatedAccessToken/upsertElevatedAccessToken.ts","../src/modules/auth/updateAuthFromVerifyResponse/updateAuthFromVerifyResponse.ts","../src/modules/wallets/utils/getVerifiedCredentialForWalletAccount/getVerifiedCredentialForWalletAccount.ts","../src/modules/wallets/getWalletProviderByKey/getWalletProviderByKey.ts"],"sourcesContent":["import type { DynamicClient } from '../../../client/types';\nimport { emitEvent } from '../../clientEvents';\nimport { getWalletAccounts } from '../getWalletAccounts';\n\n/**\n * Emits the `walletAccountsChanged` event.\n * @notInstrumented\n */\nexport const emitWalletAccountsChangedEvent = (client: DynamicClient): void => {\n const walletAccounts = getWalletAccounts(client);\n\n emitEvent(\n {\n args: { walletAccounts },\n event: 'walletAccountsChanged',\n },\n client\n );\n};\n","import { getCore } from '../../../../client/core/getCore';\nimport type { DynamicClient } from '../../../../client/types';\nimport { emitWalletAccountsChangedEvent } from '../../../wallets/emitWalletAccountsChangedEvent';\nimport { getWalletAccountsFromState } from '../../../wallets/getWalletAccounts/getWalletAccountsFromState';\n\ntype CheckAndRaiseWalletAccountsChangedEventParams = {\n previousState: Readonly<DynamicCoreState>;\n};\n\n/** @notInstrumented */\nexport const checkAndRaiseWalletAccountsChangedEvent = (\n { previousState }: CheckAndRaiseWalletAccountsChangedEventParams,\n client: DynamicClient\n) => {\n const core = getCore(client);\n\n const walletAccountsHashBefore = getWalletAccountsHash(previousState, client);\n\n const walletAccountsHashAfter = getWalletAccountsHash(\n core.state.get(),\n client\n );\n\n if (walletAccountsHashBefore !== walletAccountsHashAfter) {\n emitWalletAccountsChangedEvent(client);\n }\n};\n\n \n \nconst getWalletAccountsHash = (\n state: Readonly<DynamicCoreState>,\n client: DynamicClient\n) =>\n getWalletAccountsFromState(state, client)\n .map((walletAccount) => JSON.stringify(walletAccount))\n .sort()\n .join('-');\n","import type { DynamicClient } from '../../../client/types';\nimport { getWalletProviderRegistry } from '../walletProviderRegistry';\n\n/**\n * Get all available wallet providers to interact with internally.\n * @notInstrumented\n */\nexport const getWalletProviders = (client: DynamicClient) => {\n const walletProviderRegistry = getWalletProviderRegistry(client);\n\n return walletProviderRegistry.listProviders();\n};\n","import { WalletProviderEnum } from '@dynamic-labs/sdk-api-core';\n\nimport type { DynamicClient } from '../../../client/types/DynamicClient';\nimport type { Chain } from '../../chain';\nimport { getWalletProviders } from '../../wallets/getWalletProviders';\nimport { formatWalletProviderKey } from '../../wallets/utils/formatWalletProviderKey';\nimport { DYNAMIC_WAAS_METADATA } from '../constants';\nimport { isWaasWalletProvider } from '../isWaasWalletProvider';\nimport type { WaasWalletProvider } from '../waas.types';\n\ntype FindWaasWalletProviderByChainParams = {\n chain: Chain;\n};\n\n/** @notInstrumented */\nexport const findWaasWalletProviderByChain = (\n { chain }: FindWaasWalletProviderByChainParams,\n client: DynamicClient\n): WaasWalletProvider | null => {\n const providers = getWalletProviders(client);\n\n const waasProviderKey = formatWalletProviderKey({\n chain,\n displayName: DYNAMIC_WAAS_METADATA.displayName,\n walletProviderType: WalletProviderEnum.EmbeddedWallet,\n });\n\n const waasProvider = providers.find(\n (provider) => provider.key === waasProviderKey && provider.chain === chain\n );\n\n if (!waasProvider || !isWaasWalletProvider(waasProvider)) {\n return null;\n }\n\n return waasProvider;\n};\n","import type { WalletAccount } from '../../wallets/walletAccount';\nimport { DYNAMIC_WAAS_METADATA } from '../constants';\n\ntype IsWaasWalletAccountParams = {\n walletAccount: WalletAccount;\n};\n\n/**\n * This function determines whether the provided wallet account is a Dynamic\n * WaaS wallet account.\n *\n * @param params.walletAccount - The wallet account to check.\n * @returns True if the wallet account is a WaaS wallet account, false otherwise.\n * @notInstrumented\n */\nexport const isWaasWalletAccount = ({\n walletAccount,\n}: IsWaasWalletAccountParams): boolean => {\n return walletAccount.walletProviderKey.includes(\n DYNAMIC_WAAS_METADATA.normalizedWalletName\n );\n};\n","import { getCore } from '../../../client/core/getCore';\nimport type { DynamicClient } from '../../../client/types';\nimport { isUserMissingMfaAuth } from '../../mfa/isUserMissingMfaAuth';\nimport { getWalletAccounts } from '../../wallets/getWalletAccounts';\nimport { findWaasWalletProviderByChain } from '../findWaasWalletProviderByChain';\nimport { isWaasWalletAccount } from '../isWaasWalletAccount';\n\n/**\n * On login, boots the WaaS client once per chain so the SDK eagerly recovers\n * key shares itself (the `eagerlyRecoverKeyShares` capability) instead of the\n * host looping per wallet. Booting calls `initialize()`, which sends the auth\n * token the iframe needs to self-recover.\n *\n * @notInstrumented\n */\nexport const initializeWaasClientsForEagerRecovery = async (\n client: DynamicClient\n): Promise<void> => {\n /**\n * Booting triggers recovery, which fails if the user is missing the MFA auth.\n * This early return avoids attempting a call we know will fail and just adds\n * noise to the logs.\n */\n if (isUserMissingMfaAuth(client)) {\n return;\n }\n\n const waasChains = new Set(\n getWalletAccounts(client)\n .filter((walletAccount) => isWaasWalletAccount({ walletAccount }))\n .map((walletAccount) => walletAccount.chain)\n );\n\n await Promise.all(\n [...waasChains].map(async (chain) => {\n const provider = findWaasWalletProviderByChain({ chain }, client);\n\n /**\n * The environment might not have the embedded wallet extensions installed.\n * In that case there is no provider for the chain and nothing to boot.\n */\n if (!provider) return;\n\n try {\n await provider.getWaasClient();\n } catch (error) {\n getCore(client).logger.warn(\n '[initializeWaasClientsForEagerRecovery] failed to boot waas client',\n error\n );\n }\n })\n );\n};\n","import { InvalidParamError } from '../../../errors/InvalidParamError';\n\nexport type JwtPayload = {\n [key: string]: unknown;\n exp: number;\n iat: number;\n scope: string;\n singleUse?: boolean;\n sub: string;\n};\n\n/**\n * Decodes a JWT token and returns the full payload.\n *\n * This function extracts and returns the complete JWT payload including scopes,\n * expiration time, and other claims.\n *\n * @param jwt - The JWT token string.\n * @returns The decoded JWT payload object.\n * @throws InvalidParamError if the token is invalid or cannot be decoded.\n *\n * @example\n * ```typescript\n * const payload = decodeJwt(jwt);\n * // Returns: { scopes: ['wallet:export'], exp: 1234567890, ... }\n * ```\n * @notInstrumented\n */\n// eslint-disable-next-line custom-rules/require-single-object-param\nexport const decodeJwt = (jwt: string): JwtPayload => {\n try {\n // JWT format: header.payload.signature\n const parts = jwt.split('.');\n if (parts.length !== 3) {\n throw new InvalidParamError('Invalid JWT format');\n }\n\n // Decode the payload (second part)\n // Base64URL decode: replace URL-safe characters and decode\n const base64Payload = parts[1].replaceAll('-', '+').replaceAll('_', '/');\n // Add padding if needed\n const paddedPayload =\n base64Payload + '='.repeat((4 - (base64Payload.length % 4)) % 4);\n const decodedPayload = atob(paddedPayload);\n const claims = JSON.parse(decodedPayload) as JwtPayload;\n\n return claims;\n } catch (error) {\n if (error instanceof InvalidParamError) {\n throw error;\n }\n throw new InvalidParamError(\n `Failed to decode JWT: ${\n error instanceof Error ? error.message : String(error)\n }`\n );\n }\n};\n","/**\n * Normalizes scopes by deduplicating and sorting them.\n * This creates a canonical representation for comparison.\n *\n * @param scopes - Array of scope strings (may contain duplicates)\n * @returns Normalized, sorted array of unique scopes\n * @notInstrumented\n */\n// eslint-disable-next-line custom-rules/require-single-object-param\nexport const normalizeScopes = (scopes: string[]): string[] => {\n return [...new Set(scopes)].sort((a, b) => a.localeCompare(b));\n};\n","import { decodeJwt } from '../../../decodeJwt';\nimport type { ParsedElevatedAccessToken } from '../elevatedAccessTokens.types';\nimport { normalizeScopes } from '../normalizeScopes';\n\nexport type ParseElevatedAccessTokenOptions = {\n /** JWT string containing the elevated access token. */\n token: string;\n};\n\n/**\n * Validates and parses an elevated access token from a JWT string.\n * Extracts scopes, expiration, and validates the token structure.\n *\n * Policy decisions:\n * - Tokens without scopes are rejected (returns null)\n * - Tokens with empty scopes array are rejected (returns null)\n * - Tokens without exp field are rejected (returns null)\n * - Expired tokens are rejected (returns null)\n *\n * @returns Parsed token data or null if token is invalid/expired\n * @notInstrumented\n */\nexport const parseElevatedAccessToken = ({\n token,\n}: ParseElevatedAccessTokenOptions): ParsedElevatedAccessToken | null => {\n const payload = decodeJwt(token);\n const rawScopeClaim = payload?.scope;\n const processedScopes = rawScopeClaim?.split(' ') ?? [];\n const filteredScopes = processedScopes.filter((s) => s.length > 0);\n const singleUse = payload.singleUse ?? false;\n\n // Reject tokens without scopes or with empty scopes\n if (!filteredScopes || filteredScopes.length === 0) {\n return null;\n }\n\n // Reject tokens without exp field\n if (!payload.exp) {\n return null;\n }\n\n // Convert exp (seconds) to Date (milliseconds)\n const expiresAt = new Date(payload.exp * 1000);\n\n // Reject expired tokens\n if (expiresAt <= new Date()) {\n return null;\n }\n\n return {\n expiresAt,\n normalizedScopes: normalizeScopes(filteredScopes),\n scopes: filteredScopes,\n singleUse,\n token,\n };\n};\n","import type {\n ElevatedAccessToken,\n ParsedElevatedAccessToken,\n} from '../elevatedAccessTokens.types';\nimport { normalizeScopes } from '../normalizeScopes';\n\n/**\n * Upserts an elevated access token into the current tokens array.\n *\n * Policy: Only one token per normalized scope-set is allowed.\n * If a token with the same normalized scopes exists, it is replaced.\n * This ensures we don't accumulate multiple tokens for the same scope combination.\n *\n * @param currentTokens - Current array of elevated access tokens\n * @param newToken - New token to upsert\n * @returns Updated array of tokens with the new token upserted\n * @notInstrumented\n */\nexport const upsertElevatedAccessToken = ({\n currentTokens,\n newToken,\n}: {\n currentTokens: ElevatedAccessToken[];\n newToken: ParsedElevatedAccessToken;\n}): ElevatedAccessToken[] => {\n const newScopeKey = normalizeScopes(newToken.scopes).join(' ');\n\n // Remove any existing token with the same normalized scopes\n const filteredTokens = currentTokens.filter((existingToken) => {\n const existingScopeKey = normalizeScopes(existingToken.scopes).join(' ');\n return existingScopeKey !== newScopeKey;\n });\n\n // Add the new token\n return [\n ...filteredTokens,\n {\n expiresAt: newToken.expiresAt,\n scopes: newToken.scopes,\n singleUse: newToken.singleUse,\n token: newToken.token,\n },\n ];\n};\n","import type { VerifyResponse } from '@dynamic-labs/sdk-api-core';\n\nimport { getCore } from '../../../client/core/getCore';\nimport type { DynamicCoreState } from '../../../client/core/types';\nimport type { DynamicClient } from '../../../client/types';\nimport { setCookie } from '../../../utils/setCookie';\nimport { isCookieEnabled } from '../../projectSettings/isCookieEnabled';\nimport { initializeWaasClientsForEagerRecovery } from '../../waas/initializeWaasClientsForEagerRecovery';\nimport { DYNAMIC_AUTH_COOKIE_NAME } from '../consts';\nimport { checkAndRaiseWalletAccountsChangedEvent } from './checkAndRaiseWalletAccountsChangedEvent';\nimport { parseElevatedAccessToken } from './elevatedAccessTokens/parseElevatedAccessToken';\nimport { upsertElevatedAccessToken } from './elevatedAccessTokens/upsertElevatedAccessToken';\n\ntype UpdateAuthFromVerifyResponseParams = {\n response: VerifyResponse;\n};\n\n/** @notInstrumented */\nexport const updateAuthFromVerifyResponse = (\n { response }: UpdateAuthFromVerifyResponseParams,\n client: DynamicClient\n) => {\n const core = getCore(client);\n\n const previousState = { ...core.state.get() };\n\n const { user, minifiedJwt, jwt, expiresAt, mfaToken, elevatedAccessToken } =\n response;\n\n // Expires at is in seconds, so we need to convert it to milliseconds\n const sessionExpiresAt = new Date(expiresAt * 1000);\n\n const newState: Partial<DynamicCoreState> = {\n legacyToken: jwt ?? null,\n sessionExpiresAt: sessionExpiresAt,\n token: minifiedJwt ?? null,\n user,\n };\n\n // only override the mfaToken if a new one is provided in the response\n if (mfaToken) {\n newState.mfaToken = mfaToken;\n }\n\n // Add elevated access token to the array if a new one is provided in the response\n // Policy: Only one token per normalized scope-set is allowed (old tokens are replaced)\n // Always preserve existing tokens to ensure they're synced to storage\n const currentTokens = core.state.get().elevatedAccessTokens || [];\n newState.elevatedAccessTokens = currentTokens;\n \n if (elevatedAccessToken) {\n const parsedToken = parseElevatedAccessToken({\n token: elevatedAccessToken,\n });\n if (parsedToken) {\n newState.elevatedAccessTokens = upsertElevatedAccessToken({\n currentTokens,\n newToken: parsedToken,\n });\n }\n }\n\n core.state.set(newState);\n\n /**\n * For customers using a sandbox environment with cookies enabled, we need to set the cookie\n * programmatically because Redcoast won't set the cookie via headers. We set the cookie programmatically\n * so customers can access the cookie from document.cookie consistently between sandbox and live environments.\n */\n if (minifiedJwt && isCookieEnabled(client)) {\n const expireDate = sessionExpiresAt.toUTCString();\n\n setCookie(\n `${DYNAMIC_AUTH_COOKIE_NAME}=${minifiedJwt}; expires=${expireDate}; path=/; SameSite=Lax`\n );\n }\n\n checkAndRaiseWalletAccountsChangedEvent({ previousState }, client);\n\n // if the user is logging in, boot the waas client(s) so the SDK eagerly\n // recovers key shares for all wallet accounts\n const isUserLoggingIn = !previousState.user && Boolean(newState.user);\n if (isUserLoggingIn) {\n void initializeWaasClientsForEagerRecovery(client);\n }\n};\n","import type { DynamicClient } from '../../../../client/types/DynamicClient';\nimport type { WalletAccount } from '../../walletAccount';\n\ntype GetVerifiedCredentialForWalletAccountParams = {\n walletAccount: WalletAccount;\n};\n\n/** @notInstrumented */\nexport const getVerifiedCredentialForWalletAccount = (\n { walletAccount }: GetVerifiedCredentialForWalletAccountParams,\n client: DynamicClient\n) => {\n return client.user?.verifiedCredentials.find(\n (vc) => vc.id === walletAccount.verifiedCredentialId\n );\n};\n","import type { DynamicClient } from '../../../client/types';\nimport { NoWalletProviderFoundError } from '../../../errors/NoWalletProviderFoundError';\nimport { getWalletProviders } from '../getWalletProviders';\n\ntype GetWalletProviderByKeyParams = {\n walletProviderKey: string;\n};\n\n/** @notInstrumented */\nexport const getWalletProviderByKey = (\n { walletProviderKey }: GetWalletProviderByKeyParams,\n client: DynamicClient\n) => {\n const walletProviders = getWalletProviders(client);\n\n const walletProvider = walletProviders.find(\n (walletProvider) => walletProvider.key === walletProviderKey\n );\n\n if (!walletProvider) {\n throw new NoWalletProviderFoundError({ walletProviderKey });\n }\n\n return walletProvider;\n};\n"],"mappings":"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"}
@@ -1,11 +1,11 @@
1
- const require_isMfaRequiredForAction = require('./isMfaRequiredForAction-DL013-fR.cjs');
2
- const require_InvalidParamError = require('./InvalidParamError-d0WFn5Ai.cjs');
1
+ const require_isMfaRequiredForAction = require('./isMfaRequiredForAction-CgWBU6kM.cjs');
2
+ const require_InvalidParamError = require('./InvalidParamError-C7c-OLz1.cjs');
3
3
  let _dynamic_labs_sdk_api_core = require("@dynamic-labs/sdk-api-core");
4
4
 
5
5
  //#region src/modules/wallets/emitWalletAccountsChangedEvent/emitWalletAccountsChangedEvent.ts
6
6
  /**
7
7
  * Emits the `walletAccountsChanged` event.
8
- * @not-instrumented
8
+ * @notInstrumented
9
9
  */
10
10
  const emitWalletAccountsChangedEvent = (client) => {
11
11
  require_InvalidParamError.emitEvent({
@@ -16,36 +16,18 @@ const emitWalletAccountsChangedEvent = (client) => {
16
16
 
17
17
  //#endregion
18
18
  //#region src/modules/auth/updateAuthFromVerifyResponse/checkAndRaiseWalletAccountsChangedEvent/checkAndRaiseWalletAccountsChangedEvent.ts
19
- /** @not-instrumented */
19
+ /** @notInstrumented */
20
20
  const checkAndRaiseWalletAccountsChangedEvent = ({ previousState }, client) => {
21
21
  const core = require_InvalidParamError.getCore(client);
22
22
  if (getWalletAccountsHash(previousState, client) !== getWalletAccountsHash(core.state.get(), client)) emitWalletAccountsChangedEvent(client);
23
23
  };
24
24
  const getWalletAccountsHash = (state, client) => require_InvalidParamError.getWalletAccountsFromState(state, client).map((walletAccount) => JSON.stringify(walletAccount)).sort().join("-");
25
25
 
26
- //#endregion
27
- //#region src/modules/mfa/isUserMissingMfaAuth/isUserMissingMfaAuth.ts
28
- /**
29
- * Checks if the user requires additional MFA authentication.
30
- *
31
- * This function determines if the current user session requires
32
- * additional multi-factor authentication to access certain features.
33
- *
34
- * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
35
- * @returns True if the user needs additional MFA authentication, false otherwise.
36
- * @not-instrumented
37
- */
38
- const isUserMissingMfaAuth = (client = require_InvalidParamError.getDefaultClient()) => {
39
- const user = client.user;
40
- require_InvalidParamError.assertDefined(user, "User not logged in");
41
- return Boolean(user.scope?.includes("requiresAdditionalAuth"));
42
- };
43
-
44
26
  //#endregion
45
27
  //#region src/modules/wallets/getWalletProviders/getWalletProviders.ts
46
28
  /**
47
29
  * Get all available wallet providers to interact with internally.
48
- * @not-instrumented
30
+ * @notInstrumented
49
31
  */
50
32
  const getWalletProviders = (client) => {
51
33
  return require_InvalidParamError.getWalletProviderRegistry(client).listProviders();
@@ -53,7 +35,7 @@ const getWalletProviders = (client) => {
53
35
 
54
36
  //#endregion
55
37
  //#region src/modules/waas/findWaasWalletProviderByChain/findWaasWalletProviderByChain.ts
56
- /** @not-instrumented */
38
+ /** @notInstrumented */
57
39
  const findWaasWalletProviderByChain = ({ chain }, client) => {
58
40
  const providers = getWalletProviders(client);
59
41
  const waasProviderKey = require_InvalidParamError.formatWalletProviderKey({
@@ -74,7 +56,7 @@ const findWaasWalletProviderByChain = ({ chain }, client) => {
74
56
  *
75
57
  * @param params.walletAccount - The wallet account to check.
76
58
  * @returns True if the wallet account is a WaaS wallet account, false otherwise.
77
- * @not-instrumented
59
+ * @notInstrumented
78
60
  */
79
61
  const isWaasWalletAccount = ({ walletAccount }) => {
80
62
  return walletAccount.walletProviderKey.includes(require_InvalidParamError.DYNAMIC_WAAS_METADATA.normalizedWalletName);
@@ -88,7 +70,7 @@ const isWaasWalletAccount = ({ walletAccount }) => {
88
70
  * host looping per wallet. Booting calls `initialize()`, which sends the auth
89
71
  * token the iframe needs to self-recover.
90
72
  *
91
- * @not-instrumented
73
+ * @notInstrumented
92
74
  */
93
75
  const initializeWaasClientsForEagerRecovery = async (client) => {
94
76
  /**
@@ -96,7 +78,7 @@ const initializeWaasClientsForEagerRecovery = async (client) => {
96
78
  * This early return avoids attempting a call we know will fail and just adds
97
79
  * noise to the logs.
98
80
  */
99
- if (isUserMissingMfaAuth(client)) return;
81
+ if (require_InvalidParamError.isUserMissingMfaAuth(client)) return;
100
82
  const waasChains = new Set(require_InvalidParamError.getWalletAccounts(client).filter((walletAccount) => isWaasWalletAccount({ walletAccount })).map((walletAccount) => walletAccount.chain));
101
83
  await Promise.all([...waasChains].map(async (chain) => {
102
84
  const provider = findWaasWalletProviderByChain({ chain }, client);
@@ -130,7 +112,7 @@ const initializeWaasClientsForEagerRecovery = async (client) => {
130
112
  * const payload = decodeJwt(jwt);
131
113
  * // Returns: { scopes: ['wallet:export'], exp: 1234567890, ... }
132
114
  * ```
133
- * @not-instrumented
115
+ * @notInstrumented
134
116
  */
135
117
  const decodeJwt = (jwt) => {
136
118
  try {
@@ -154,7 +136,7 @@ const decodeJwt = (jwt) => {
154
136
  *
155
137
  * @param scopes - Array of scope strings (may contain duplicates)
156
138
  * @returns Normalized, sorted array of unique scopes
157
- * @not-instrumented
139
+ * @notInstrumented
158
140
  */
159
141
  const normalizeScopes = (scopes) => {
160
142
  return [...new Set(scopes)].sort((a, b) => a.localeCompare(b));
@@ -173,7 +155,7 @@ const normalizeScopes = (scopes) => {
173
155
  * - Expired tokens are rejected (returns null)
174
156
  *
175
157
  * @returns Parsed token data or null if token is invalid/expired
176
- * @not-instrumented
158
+ * @notInstrumented
177
159
  */
178
160
  const parseElevatedAccessToken = ({ token }) => {
179
161
  const payload = decodeJwt(token);
@@ -204,7 +186,7 @@ const parseElevatedAccessToken = ({ token }) => {
204
186
  * @param currentTokens - Current array of elevated access tokens
205
187
  * @param newToken - New token to upsert
206
188
  * @returns Updated array of tokens with the new token upserted
207
- * @not-instrumented
189
+ * @notInstrumented
208
190
  */
209
191
  const upsertElevatedAccessToken = ({ currentTokens, newToken }) => {
210
192
  const newScopeKey = normalizeScopes(newToken.scopes).join(" ");
@@ -220,7 +202,7 @@ const upsertElevatedAccessToken = ({ currentTokens, newToken }) => {
220
202
 
221
203
  //#endregion
222
204
  //#region src/modules/auth/updateAuthFromVerifyResponse/updateAuthFromVerifyResponse.ts
223
- /** @not-instrumented */
205
+ /** @notInstrumented */
224
206
  const updateAuthFromVerifyResponse = ({ response }, client) => {
225
207
  const core = require_InvalidParamError.getCore(client);
226
208
  const previousState = { ...core.state.get() };
@@ -255,14 +237,14 @@ const updateAuthFromVerifyResponse = ({ response }, client) => {
255
237
 
256
238
  //#endregion
257
239
  //#region src/modules/wallets/utils/getVerifiedCredentialForWalletAccount/getVerifiedCredentialForWalletAccount.ts
258
- /** @not-instrumented */
240
+ /** @notInstrumented */
259
241
  const getVerifiedCredentialForWalletAccount = ({ walletAccount }, client) => {
260
242
  return client.user?.verifiedCredentials.find((vc) => vc.id === walletAccount.verifiedCredentialId);
261
243
  };
262
244
 
263
245
  //#endregion
264
246
  //#region src/modules/wallets/getWalletProviderByKey/getWalletProviderByKey.ts
265
- /** @not-instrumented */
247
+ /** @notInstrumented */
266
248
  const getWalletProviderByKey = ({ walletProviderKey }, client) => {
267
249
  const walletProvider = getWalletProviders(client).find((walletProvider$1) => walletProvider$1.key === walletProviderKey);
268
250
  if (!walletProvider) throw new require_InvalidParamError.NoWalletProviderFoundError({ walletProviderKey });
@@ -312,12 +294,6 @@ Object.defineProperty(exports, 'initializeWaasClientsForEagerRecovery', {
312
294
  return initializeWaasClientsForEagerRecovery;
313
295
  }
314
296
  });
315
- Object.defineProperty(exports, 'isUserMissingMfaAuth', {
316
- enumerable: true,
317
- get: function () {
318
- return isUserMissingMfaAuth;
319
- }
320
- });
321
297
  Object.defineProperty(exports, 'isWaasWalletAccount', {
322
298
  enumerable: true,
323
299
  get: function () {
@@ -342,4 +318,4 @@ Object.defineProperty(exports, 'upsertElevatedAccessToken', {
342
318
  return upsertElevatedAccessToken;
343
319
  }
344
320
  });
345
- //# sourceMappingURL=getWalletProviderByKey-B821GpaI.cjs.map
321
+ //# sourceMappingURL=getWalletProviderByKey-DCKYAida.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getWalletProviderByKey-DCKYAida.cjs","names":["getWalletAccounts","getCore","getWalletAccountsFromState","getWalletProviderRegistry","formatWalletProviderKey","DYNAMIC_WAAS_METADATA","WalletProviderEnum","isWaasWalletProvider","DYNAMIC_WAAS_METADATA","isUserMissingMfaAuth","getWalletAccounts","InvalidParamError","getCore","newState: Partial<DynamicCoreState>","isCookieEnabled","DYNAMIC_AUTH_COOKIE_NAME","walletProvider","NoWalletProviderFoundError"],"sources":["../src/modules/wallets/emitWalletAccountsChangedEvent/emitWalletAccountsChangedEvent.ts","../src/modules/auth/updateAuthFromVerifyResponse/checkAndRaiseWalletAccountsChangedEvent/checkAndRaiseWalletAccountsChangedEvent.ts","../src/modules/wallets/getWalletProviders/getWalletProviders.ts","../src/modules/waas/findWaasWalletProviderByChain/findWaasWalletProviderByChain.ts","../src/modules/waas/isWaasWalletAccount/isWaasWalletAccount.ts","../src/modules/waas/initializeWaasClientsForEagerRecovery/initializeWaasClientsForEagerRecovery.ts","../src/modules/auth/decodeJwt/decodeJwt.ts","../src/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/normalizeScopes/normalizeScopes.ts","../src/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/parseElevatedAccessToken/parseElevatedAccessToken.ts","../src/modules/auth/updateAuthFromVerifyResponse/elevatedAccessTokens/upsertElevatedAccessToken/upsertElevatedAccessToken.ts","../src/modules/auth/updateAuthFromVerifyResponse/updateAuthFromVerifyResponse.ts","../src/modules/wallets/utils/getVerifiedCredentialForWalletAccount/getVerifiedCredentialForWalletAccount.ts","../src/modules/wallets/getWalletProviderByKey/getWalletProviderByKey.ts"],"sourcesContent":["import type { DynamicClient } from '../../../client/types';\nimport { emitEvent } from '../../clientEvents';\nimport { getWalletAccounts } from '../getWalletAccounts';\n\n/**\n * Emits the `walletAccountsChanged` event.\n * @notInstrumented\n */\nexport const emitWalletAccountsChangedEvent = (client: DynamicClient): void => {\n const walletAccounts = getWalletAccounts(client);\n\n emitEvent(\n {\n args: { walletAccounts },\n event: 'walletAccountsChanged',\n },\n client\n );\n};\n","import { getCore } from '../../../../client/core/getCore';\nimport type { DynamicClient } from '../../../../client/types';\nimport { emitWalletAccountsChangedEvent } from '../../../wallets/emitWalletAccountsChangedEvent';\nimport { getWalletAccountsFromState } from '../../../wallets/getWalletAccounts/getWalletAccountsFromState';\n\ntype CheckAndRaiseWalletAccountsChangedEventParams = {\n previousState: Readonly<DynamicCoreState>;\n};\n\n/** @notInstrumented */\nexport const checkAndRaiseWalletAccountsChangedEvent = (\n { previousState }: CheckAndRaiseWalletAccountsChangedEventParams,\n client: DynamicClient\n) => {\n const core = getCore(client);\n\n const walletAccountsHashBefore = getWalletAccountsHash(previousState, client);\n\n const walletAccountsHashAfter = getWalletAccountsHash(\n core.state.get(),\n client\n );\n\n if (walletAccountsHashBefore !== walletAccountsHashAfter) {\n emitWalletAccountsChangedEvent(client);\n }\n};\n\n \n \nconst getWalletAccountsHash = (\n state: Readonly<DynamicCoreState>,\n client: DynamicClient\n) =>\n getWalletAccountsFromState(state, client)\n .map((walletAccount) => JSON.stringify(walletAccount))\n .sort()\n .join('-');\n","import type { DynamicClient } from '../../../client/types';\nimport { getWalletProviderRegistry } from '../walletProviderRegistry';\n\n/**\n * Get all available wallet providers to interact with internally.\n * @notInstrumented\n */\nexport const getWalletProviders = (client: DynamicClient) => {\n const walletProviderRegistry = getWalletProviderRegistry(client);\n\n return walletProviderRegistry.listProviders();\n};\n","import { WalletProviderEnum } from '@dynamic-labs/sdk-api-core';\n\nimport type { DynamicClient } from '../../../client/types/DynamicClient';\nimport type { Chain } from '../../chain';\nimport { getWalletProviders } from '../../wallets/getWalletProviders';\nimport { formatWalletProviderKey } from '../../wallets/utils/formatWalletProviderKey';\nimport { DYNAMIC_WAAS_METADATA } from '../constants';\nimport { isWaasWalletProvider } from '../isWaasWalletProvider';\nimport type { WaasWalletProvider } from '../waas.types';\n\ntype FindWaasWalletProviderByChainParams = {\n chain: Chain;\n};\n\n/** @notInstrumented */\nexport const findWaasWalletProviderByChain = (\n { chain }: FindWaasWalletProviderByChainParams,\n client: DynamicClient\n): WaasWalletProvider | null => {\n const providers = getWalletProviders(client);\n\n const waasProviderKey = formatWalletProviderKey({\n chain,\n displayName: DYNAMIC_WAAS_METADATA.displayName,\n walletProviderType: WalletProviderEnum.EmbeddedWallet,\n });\n\n const waasProvider = providers.find(\n (provider) => provider.key === waasProviderKey && provider.chain === chain\n );\n\n if (!waasProvider || !isWaasWalletProvider(waasProvider)) {\n return null;\n }\n\n return waasProvider;\n};\n","import type { WalletAccount } from '../../wallets/walletAccount';\nimport { DYNAMIC_WAAS_METADATA } from '../constants';\n\ntype IsWaasWalletAccountParams = {\n walletAccount: WalletAccount;\n};\n\n/**\n * This function determines whether the provided wallet account is a Dynamic\n * WaaS wallet account.\n *\n * @param params.walletAccount - The wallet account to check.\n * @returns True if the wallet account is a WaaS wallet account, false otherwise.\n * @notInstrumented\n */\nexport const isWaasWalletAccount = ({\n walletAccount,\n}: IsWaasWalletAccountParams): boolean => {\n return walletAccount.walletProviderKey.includes(\n DYNAMIC_WAAS_METADATA.normalizedWalletName\n );\n};\n","import { getCore } from '../../../client/core/getCore';\nimport type { DynamicClient } from '../../../client/types';\nimport { isUserMissingMfaAuth } from '../../mfa/isUserMissingMfaAuth';\nimport { getWalletAccounts } from '../../wallets/getWalletAccounts';\nimport { findWaasWalletProviderByChain } from '../findWaasWalletProviderByChain';\nimport { isWaasWalletAccount } from '../isWaasWalletAccount';\n\n/**\n * On login, boots the WaaS client once per chain so the SDK eagerly recovers\n * key shares itself (the `eagerlyRecoverKeyShares` capability) instead of the\n * host looping per wallet. Booting calls `initialize()`, which sends the auth\n * token the iframe needs to self-recover.\n *\n * @notInstrumented\n */\nexport const initializeWaasClientsForEagerRecovery = async (\n client: DynamicClient\n): Promise<void> => {\n /**\n * Booting triggers recovery, which fails if the user is missing the MFA auth.\n * This early return avoids attempting a call we know will fail and just adds\n * noise to the logs.\n */\n if (isUserMissingMfaAuth(client)) {\n return;\n }\n\n const waasChains = new Set(\n getWalletAccounts(client)\n .filter((walletAccount) => isWaasWalletAccount({ walletAccount }))\n .map((walletAccount) => walletAccount.chain)\n );\n\n await Promise.all(\n [...waasChains].map(async (chain) => {\n const provider = findWaasWalletProviderByChain({ chain }, client);\n\n /**\n * The environment might not have the embedded wallet extensions installed.\n * In that case there is no provider for the chain and nothing to boot.\n */\n if (!provider) return;\n\n try {\n await provider.getWaasClient();\n } catch (error) {\n getCore(client).logger.warn(\n '[initializeWaasClientsForEagerRecovery] failed to boot waas client',\n error\n );\n }\n })\n );\n};\n","import { InvalidParamError } from '../../../errors/InvalidParamError';\n\nexport type JwtPayload = {\n [key: string]: unknown;\n exp: number;\n iat: number;\n scope: string;\n singleUse?: boolean;\n sub: string;\n};\n\n/**\n * Decodes a JWT token and returns the full payload.\n *\n * This function extracts and returns the complete JWT payload including scopes,\n * expiration time, and other claims.\n *\n * @param jwt - The JWT token string.\n * @returns The decoded JWT payload object.\n * @throws InvalidParamError if the token is invalid or cannot be decoded.\n *\n * @example\n * ```typescript\n * const payload = decodeJwt(jwt);\n * // Returns: { scopes: ['wallet:export'], exp: 1234567890, ... }\n * ```\n * @notInstrumented\n */\n// eslint-disable-next-line custom-rules/require-single-object-param\nexport const decodeJwt = (jwt: string): JwtPayload => {\n try {\n // JWT format: header.payload.signature\n const parts = jwt.split('.');\n if (parts.length !== 3) {\n throw new InvalidParamError('Invalid JWT format');\n }\n\n // Decode the payload (second part)\n // Base64URL decode: replace URL-safe characters and decode\n const base64Payload = parts[1].replaceAll('-', '+').replaceAll('_', '/');\n // Add padding if needed\n const paddedPayload =\n base64Payload + '='.repeat((4 - (base64Payload.length % 4)) % 4);\n const decodedPayload = atob(paddedPayload);\n const claims = JSON.parse(decodedPayload) as JwtPayload;\n\n return claims;\n } catch (error) {\n if (error instanceof InvalidParamError) {\n throw error;\n }\n throw new InvalidParamError(\n `Failed to decode JWT: ${\n error instanceof Error ? error.message : String(error)\n }`\n );\n }\n};\n","/**\n * Normalizes scopes by deduplicating and sorting them.\n * This creates a canonical representation for comparison.\n *\n * @param scopes - Array of scope strings (may contain duplicates)\n * @returns Normalized, sorted array of unique scopes\n * @notInstrumented\n */\n// eslint-disable-next-line custom-rules/require-single-object-param\nexport const normalizeScopes = (scopes: string[]): string[] => {\n return [...new Set(scopes)].sort((a, b) => a.localeCompare(b));\n};\n","import { decodeJwt } from '../../../decodeJwt';\nimport type { ParsedElevatedAccessToken } from '../elevatedAccessTokens.types';\nimport { normalizeScopes } from '../normalizeScopes';\n\nexport type ParseElevatedAccessTokenOptions = {\n /** JWT string containing the elevated access token. */\n token: string;\n};\n\n/**\n * Validates and parses an elevated access token from a JWT string.\n * Extracts scopes, expiration, and validates the token structure.\n *\n * Policy decisions:\n * - Tokens without scopes are rejected (returns null)\n * - Tokens with empty scopes array are rejected (returns null)\n * - Tokens without exp field are rejected (returns null)\n * - Expired tokens are rejected (returns null)\n *\n * @returns Parsed token data or null if token is invalid/expired\n * @notInstrumented\n */\nexport const parseElevatedAccessToken = ({\n token,\n}: ParseElevatedAccessTokenOptions): ParsedElevatedAccessToken | null => {\n const payload = decodeJwt(token);\n const rawScopeClaim = payload?.scope;\n const processedScopes = rawScopeClaim?.split(' ') ?? [];\n const filteredScopes = processedScopes.filter((s) => s.length > 0);\n const singleUse = payload.singleUse ?? false;\n\n // Reject tokens without scopes or with empty scopes\n if (!filteredScopes || filteredScopes.length === 0) {\n return null;\n }\n\n // Reject tokens without exp field\n if (!payload.exp) {\n return null;\n }\n\n // Convert exp (seconds) to Date (milliseconds)\n const expiresAt = new Date(payload.exp * 1000);\n\n // Reject expired tokens\n if (expiresAt <= new Date()) {\n return null;\n }\n\n return {\n expiresAt,\n normalizedScopes: normalizeScopes(filteredScopes),\n scopes: filteredScopes,\n singleUse,\n token,\n };\n};\n","import type {\n ElevatedAccessToken,\n ParsedElevatedAccessToken,\n} from '../elevatedAccessTokens.types';\nimport { normalizeScopes } from '../normalizeScopes';\n\n/**\n * Upserts an elevated access token into the current tokens array.\n *\n * Policy: Only one token per normalized scope-set is allowed.\n * If a token with the same normalized scopes exists, it is replaced.\n * This ensures we don't accumulate multiple tokens for the same scope combination.\n *\n * @param currentTokens - Current array of elevated access tokens\n * @param newToken - New token to upsert\n * @returns Updated array of tokens with the new token upserted\n * @notInstrumented\n */\nexport const upsertElevatedAccessToken = ({\n currentTokens,\n newToken,\n}: {\n currentTokens: ElevatedAccessToken[];\n newToken: ParsedElevatedAccessToken;\n}): ElevatedAccessToken[] => {\n const newScopeKey = normalizeScopes(newToken.scopes).join(' ');\n\n // Remove any existing token with the same normalized scopes\n const filteredTokens = currentTokens.filter((existingToken) => {\n const existingScopeKey = normalizeScopes(existingToken.scopes).join(' ');\n return existingScopeKey !== newScopeKey;\n });\n\n // Add the new token\n return [\n ...filteredTokens,\n {\n expiresAt: newToken.expiresAt,\n scopes: newToken.scopes,\n singleUse: newToken.singleUse,\n token: newToken.token,\n },\n ];\n};\n","import type { VerifyResponse } from '@dynamic-labs/sdk-api-core';\n\nimport { getCore } from '../../../client/core/getCore';\nimport type { DynamicCoreState } from '../../../client/core/types';\nimport type { DynamicClient } from '../../../client/types';\nimport { setCookie } from '../../../utils/setCookie';\nimport { isCookieEnabled } from '../../projectSettings/isCookieEnabled';\nimport { initializeWaasClientsForEagerRecovery } from '../../waas/initializeWaasClientsForEagerRecovery';\nimport { DYNAMIC_AUTH_COOKIE_NAME } from '../consts';\nimport { checkAndRaiseWalletAccountsChangedEvent } from './checkAndRaiseWalletAccountsChangedEvent';\nimport { parseElevatedAccessToken } from './elevatedAccessTokens/parseElevatedAccessToken';\nimport { upsertElevatedAccessToken } from './elevatedAccessTokens/upsertElevatedAccessToken';\n\ntype UpdateAuthFromVerifyResponseParams = {\n response: VerifyResponse;\n};\n\n/** @notInstrumented */\nexport const updateAuthFromVerifyResponse = (\n { response }: UpdateAuthFromVerifyResponseParams,\n client: DynamicClient\n) => {\n const core = getCore(client);\n\n const previousState = { ...core.state.get() };\n\n const { user, minifiedJwt, jwt, expiresAt, mfaToken, elevatedAccessToken } =\n response;\n\n // Expires at is in seconds, so we need to convert it to milliseconds\n const sessionExpiresAt = new Date(expiresAt * 1000);\n\n const newState: Partial<DynamicCoreState> = {\n legacyToken: jwt ?? null,\n sessionExpiresAt: sessionExpiresAt,\n token: minifiedJwt ?? null,\n user,\n };\n\n // only override the mfaToken if a new one is provided in the response\n if (mfaToken) {\n newState.mfaToken = mfaToken;\n }\n\n // Add elevated access token to the array if a new one is provided in the response\n // Policy: Only one token per normalized scope-set is allowed (old tokens are replaced)\n // Always preserve existing tokens to ensure they're synced to storage\n const currentTokens = core.state.get().elevatedAccessTokens || [];\n newState.elevatedAccessTokens = currentTokens;\n \n if (elevatedAccessToken) {\n const parsedToken = parseElevatedAccessToken({\n token: elevatedAccessToken,\n });\n if (parsedToken) {\n newState.elevatedAccessTokens = upsertElevatedAccessToken({\n currentTokens,\n newToken: parsedToken,\n });\n }\n }\n\n core.state.set(newState);\n\n /**\n * For customers using a sandbox environment with cookies enabled, we need to set the cookie\n * programmatically because Redcoast won't set the cookie via headers. We set the cookie programmatically\n * so customers can access the cookie from document.cookie consistently between sandbox and live environments.\n */\n if (minifiedJwt && isCookieEnabled(client)) {\n const expireDate = sessionExpiresAt.toUTCString();\n\n setCookie(\n `${DYNAMIC_AUTH_COOKIE_NAME}=${minifiedJwt}; expires=${expireDate}; path=/; SameSite=Lax`\n );\n }\n\n checkAndRaiseWalletAccountsChangedEvent({ previousState }, client);\n\n // if the user is logging in, boot the waas client(s) so the SDK eagerly\n // recovers key shares for all wallet accounts\n const isUserLoggingIn = !previousState.user && Boolean(newState.user);\n if (isUserLoggingIn) {\n void initializeWaasClientsForEagerRecovery(client);\n }\n};\n","import type { DynamicClient } from '../../../../client/types/DynamicClient';\nimport type { WalletAccount } from '../../walletAccount';\n\ntype GetVerifiedCredentialForWalletAccountParams = {\n walletAccount: WalletAccount;\n};\n\n/** @notInstrumented */\nexport const getVerifiedCredentialForWalletAccount = (\n { walletAccount }: GetVerifiedCredentialForWalletAccountParams,\n client: DynamicClient\n) => {\n return client.user?.verifiedCredentials.find(\n (vc) => vc.id === walletAccount.verifiedCredentialId\n );\n};\n","import type { DynamicClient } from '../../../client/types';\nimport { NoWalletProviderFoundError } from '../../../errors/NoWalletProviderFoundError';\nimport { getWalletProviders } from '../getWalletProviders';\n\ntype GetWalletProviderByKeyParams = {\n walletProviderKey: string;\n};\n\n/** @notInstrumented */\nexport const getWalletProviderByKey = (\n { walletProviderKey }: GetWalletProviderByKeyParams,\n client: DynamicClient\n) => {\n const walletProviders = getWalletProviders(client);\n\n const walletProvider = walletProviders.find(\n (walletProvider) => walletProvider.key === walletProviderKey\n );\n\n if (!walletProvider) {\n throw new NoWalletProviderFoundError({ walletProviderKey });\n }\n\n return walletProvider;\n};\n"],"mappings":"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"}
@@ -1,10 +1,10 @@
1
- import { J as getDefaultClient, N as isCookieEnabled, P as assertDefined, Q as getCore, Z as BaseError, a as DYNAMIC_WAAS_METADATA, f as NoWalletProviderFoundError, h as emitEvent, n as isWaasWalletProvider, p as getChainFromVerifiedCredentialChain, t as InvalidParamError, u as getWalletProviderRegistry } from "./InvalidParamError-CKUis748.native.esm.js";
1
+ import { $ as getCore, F as assertDefined, P as isCookieEnabled, Q as BaseError, Y as getDefaultClient, a as DYNAMIC_WAAS_METADATA, d as getWalletProviderRegistry, g as emitEvent, m as getChainFromVerifiedCredentialChain, n as isWaasWalletProvider, o as isUserMissingMfaAuth, p as NoWalletProviderFoundError, t as InvalidParamError } from "./InvalidParamError-CGiSxym5.native.esm.js";
2
2
  import { JwtVerifiedCredentialFormatEnum, WalletProviderEnum } from "@dynamic-labs/sdk-api-core";
3
3
 
4
4
  //#region src/utils/setCookie/setCookie.ts
5
5
  /**
6
6
  * Sefelly sets the cookie in the browser.
7
- * @not-instrumented
7
+ * @notInstrumented
8
8
  */
9
9
  const setCookie = (cookie) => {
10
10
  document.cookie = cookie;
@@ -26,7 +26,7 @@ var InvalidWalletProviderKeyError = class extends BaseError {
26
26
 
27
27
  //#endregion
28
28
  //#region src/modules/wallets/walletProvider/splitWalletProviderKey/splitWalletProviderKey.ts
29
- /** @not-instrumented */
29
+ /** @notInstrumented */
30
30
  const splitWalletProviderKey = (walletProviderKey) => {
31
31
  const [normalizedWalletNameWithChain, walletProviderType, suffix, ...rest] = walletProviderKey.split(":");
32
32
  if (!normalizedWalletNameWithChain || !Object.values(WalletProviderEnum).includes(walletProviderType) || rest.length > 0) throw new InvalidWalletProviderKeyError(walletProviderKey);
@@ -39,7 +39,7 @@ const splitWalletProviderKey = (walletProviderKey) => {
39
39
 
40
40
  //#endregion
41
41
  //#region src/modules/wallets/utils/normalizeAddress/normalizeAddress.ts
42
- /** @not-instrumented */
42
+ /** @notInstrumented */
43
43
  const normalizeAddress = ({ address, chain }) => {
44
44
  let normalizedAddress = address;
45
45
  if (normalizedAddress?.startsWith("0x")) normalizedAddress = normalizedAddress.slice(2);
@@ -49,7 +49,7 @@ const normalizeAddress = ({ address, chain }) => {
49
49
 
50
50
  //#endregion
51
51
  //#region src/modules/wallets/utils/formatWalletAccountId/formatWalletAccountId.ts
52
- /** @not-instrumented */
52
+ /** @notInstrumented */
53
53
  const formatWalletAccountId = ({ address, chain, walletProviderKey }) => {
54
54
  const { normalizedWalletNameWithChain } = splitWalletProviderKey(walletProviderKey);
55
55
  return `${normalizedWalletNameWithChain}:${normalizeAddress({
@@ -60,7 +60,7 @@ const formatWalletAccountId = ({ address, chain, walletProviderKey }) => {
60
60
 
61
61
  //#endregion
62
62
  //#region src/modules/wallets/utils/convertUnverifiedWalletAccountToWalletAccount/convertUnverifiedWalletAccountToWalletAccount.ts
63
- /** @not-instrumented */
63
+ /** @notInstrumented */
64
64
  const convertUnverifiedWalletAccountToWalletAccount = ({ unverifiedWalletAccount }) => ({
65
65
  address: unverifiedWalletAccount.address,
66
66
  addressesWithTypes: unverifiedWalletAccount.addressesWithTypes,
@@ -80,7 +80,7 @@ const convertUnverifiedWalletAccountToWalletAccount = ({ unverifiedWalletAccount
80
80
  /**
81
81
  * Format the raw wallet name and chain to get the value we can use for
82
82
  * verified credentials' `walletName` field.
83
- * @not-instrumented
83
+ * @notInstrumented
84
84
  */
85
85
  const normalizeWalletNameWithChain = ({ displayName, chain }) => {
86
86
  const sanitizedWalletName = displayName.replace(/[^a-zA-Z0-9]/g, "").toLowerCase();
@@ -100,7 +100,7 @@ const normalizeWalletNameWithChain = ({ displayName, chain }) => {
100
100
  * IMPORTANT: Do NOT add a suffix unless absolutely necessary, as it will cause the wallet account
101
101
  * to not be able to find its wallet provider when connecting to a new device (it won't be possible
102
102
  * to determine the full key just from the Verified Credential data).
103
- * @not-instrumented
103
+ * @notInstrumented
104
104
  */
105
105
  const formatWalletProviderKey = ({ suffix, chain, displayName, walletProviderType }) => {
106
106
  return `${normalizeWalletNameWithChain({
@@ -111,7 +111,7 @@ const formatWalletProviderKey = ({ suffix, chain, displayName, walletProviderTyp
111
111
 
112
112
  //#endregion
113
113
  //#region src/modules/wallets/walletProvider/walletProviderKeyMap/getWalletProviderKeyFromVerifiedCredential/getWalletProviderKeyFromVerifiedCredential.ts
114
- /** @not-instrumented */
114
+ /** @notInstrumented */
115
115
  const getWalletProviderKeyFromVerifiedCredential = ({ verifiedCredential }, client) => {
116
116
  const { walletProviderKeyMap } = getCore(client).state.get();
117
117
  const storedWalletProviderKey = walletProviderKeyMap[verifiedCredential.id];
@@ -137,7 +137,7 @@ const getWalletProviderKeyFromVerifiedCredential = ({ verifiedCredential }, clie
137
137
 
138
138
  //#endregion
139
139
  //#region src/modules/wallets/utils/convertVerifiedCredentialToWalletAccount/convertVerifiedCredentialToWalletAccount.ts
140
- /** @not-instrumented */
140
+ /** @notInstrumented */
141
141
  const convertVerifiedCredentialToWalletAccount = ({ verifiedCredential }, client) => {
142
142
  assertDefined(verifiedCredential.address, "Missing address in verified credential");
143
143
  assertDefined(verifiedCredential.chain, "Missing chain in verified credential");
@@ -162,7 +162,7 @@ const convertVerifiedCredentialToWalletAccount = ({ verifiedCredential }, client
162
162
 
163
163
  //#endregion
164
164
  //#region src/modules/wallets/getWalletAccounts/getWalletAccountsFromState/getWalletAccountsFromState.ts
165
- /** @not-instrumented */
165
+ /** @notInstrumented */
166
166
  const getWalletAccountsFromState = ({ unverifiedWalletAccounts, user }, client) => {
167
167
  const walletAccountsMap = /* @__PURE__ */ new Map();
168
168
  /**
@@ -174,8 +174,20 @@ const getWalletAccountsFromState = ({ unverifiedWalletAccounts, user }, client)
174
174
  walletAccountsMap.set(walletAccount.id, walletAccount);
175
175
  });
176
176
  (user?.verifiedCredentials ?? []).filter((verified) => verified.format === JwtVerifiedCredentialFormatEnum.Blockchain).forEach((verifiedWalletAccount) => {
177
- const walletAccount = convertVerifiedCredentialToWalletAccount({ verifiedCredential: verifiedWalletAccount }, client);
178
- walletAccountsMap.set(walletAccount.id, walletAccount);
177
+ try {
178
+ const walletAccount = convertVerifiedCredentialToWalletAccount({ verifiedCredential: verifiedWalletAccount }, client);
179
+ walletAccountsMap.set(walletAccount.id, walletAccount);
180
+ } catch (error) {
181
+ /**
182
+ * A verified credential can be missing the data required to resolve its
183
+ * wallet provider (e.g. a legacy credential without a walletName). Skip
184
+ * it instead of throwing so a single unconvertible credential does not
185
+ * abort the whole mapping — which, during client initialization, would
186
+ * otherwise fail init and leave the app stuck loading. The wallet stays
187
+ * absent until the user reconnects it.
188
+ */
189
+ getCore(client).logger.debug(`Skipping verified credential ${verifiedWalletAccount.id}: unable to convert to wallet account`, error);
190
+ }
179
191
  });
180
192
  return Array.from(walletAccountsMap.values());
181
193
  };
@@ -192,7 +204,7 @@ const getWalletAccountsFromState = ({ unverifiedWalletAccounts, user }, client)
192
204
  *
193
205
  * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
194
206
  * @returns An array of wallet accounts associated with the session.
195
- * @not-instrumented
207
+ * @notInstrumented
196
208
  * @hook Exposed as a hook so consumers get the reactive list of wallet accounts.
197
209
  */
198
210
  const getWalletAccounts = (client = getDefaultClient()) => {
@@ -211,7 +223,7 @@ const DYNAMIC_AUTH_COOKIE_NAME = "DYNAMIC_JWT_TOKEN";
211
223
  //#region src/modules/wallets/emitWalletAccountsChangedEvent/emitWalletAccountsChangedEvent.ts
212
224
  /**
213
225
  * Emits the `walletAccountsChanged` event.
214
- * @not-instrumented
226
+ * @notInstrumented
215
227
  */
216
228
  const emitWalletAccountsChangedEvent = (client) => {
217
229
  emitEvent({
@@ -222,36 +234,18 @@ const emitWalletAccountsChangedEvent = (client) => {
222
234
 
223
235
  //#endregion
224
236
  //#region src/modules/auth/updateAuthFromVerifyResponse/checkAndRaiseWalletAccountsChangedEvent/checkAndRaiseWalletAccountsChangedEvent.ts
225
- /** @not-instrumented */
237
+ /** @notInstrumented */
226
238
  const checkAndRaiseWalletAccountsChangedEvent = ({ previousState }, client) => {
227
239
  const core = getCore(client);
228
240
  if (getWalletAccountsHash(previousState, client) !== getWalletAccountsHash(core.state.get(), client)) emitWalletAccountsChangedEvent(client);
229
241
  };
230
242
  const getWalletAccountsHash = (state, client) => getWalletAccountsFromState(state, client).map((walletAccount) => JSON.stringify(walletAccount)).sort().join("-");
231
243
 
232
- //#endregion
233
- //#region src/modules/mfa/isUserMissingMfaAuth/isUserMissingMfaAuth.ts
234
- /**
235
- * Checks if the user requires additional MFA authentication.
236
- *
237
- * This function determines if the current user session requires
238
- * additional multi-factor authentication to access certain features.
239
- *
240
- * @param [client] - The Dynamic client instance. Only required when using multiple Dynamic clients.
241
- * @returns True if the user needs additional MFA authentication, false otherwise.
242
- * @not-instrumented
243
- */
244
- const isUserMissingMfaAuth = (client = getDefaultClient()) => {
245
- const user = client.user;
246
- assertDefined(user, "User not logged in");
247
- return Boolean(user.scope?.includes("requiresAdditionalAuth"));
248
- };
249
-
250
244
  //#endregion
251
245
  //#region src/modules/wallets/getWalletProviders/getWalletProviders.ts
252
246
  /**
253
247
  * Get all available wallet providers to interact with internally.
254
- * @not-instrumented
248
+ * @notInstrumented
255
249
  */
256
250
  const getWalletProviders = (client) => {
257
251
  return getWalletProviderRegistry(client).listProviders();
@@ -259,7 +253,7 @@ const getWalletProviders = (client) => {
259
253
 
260
254
  //#endregion
261
255
  //#region src/modules/waas/findWaasWalletProviderByChain/findWaasWalletProviderByChain.ts
262
- /** @not-instrumented */
256
+ /** @notInstrumented */
263
257
  const findWaasWalletProviderByChain = ({ chain }, client) => {
264
258
  const providers = getWalletProviders(client);
265
259
  const waasProviderKey = formatWalletProviderKey({
@@ -280,7 +274,7 @@ const findWaasWalletProviderByChain = ({ chain }, client) => {
280
274
  *
281
275
  * @param params.walletAccount - The wallet account to check.
282
276
  * @returns True if the wallet account is a WaaS wallet account, false otherwise.
283
- * @not-instrumented
277
+ * @notInstrumented
284
278
  */
285
279
  const isWaasWalletAccount = ({ walletAccount }) => {
286
280
  return walletAccount.walletProviderKey.includes(DYNAMIC_WAAS_METADATA.normalizedWalletName);
@@ -294,7 +288,7 @@ const isWaasWalletAccount = ({ walletAccount }) => {
294
288
  * host looping per wallet. Booting calls `initialize()`, which sends the auth
295
289
  * token the iframe needs to self-recover.
296
290
  *
297
- * @not-instrumented
291
+ * @notInstrumented
298
292
  */
299
293
  const initializeWaasClientsForEagerRecovery = async (client) => {
300
294
  /**
@@ -336,7 +330,7 @@ const initializeWaasClientsForEagerRecovery = async (client) => {
336
330
  * const payload = decodeJwt(jwt);
337
331
  * // Returns: { scopes: ['wallet:export'], exp: 1234567890, ... }
338
332
  * ```
339
- * @not-instrumented
333
+ * @notInstrumented
340
334
  */
341
335
  const decodeJwt = (jwt) => {
342
336
  try {
@@ -360,7 +354,7 @@ const decodeJwt = (jwt) => {
360
354
  *
361
355
  * @param scopes - Array of scope strings (may contain duplicates)
362
356
  * @returns Normalized, sorted array of unique scopes
363
- * @not-instrumented
357
+ * @notInstrumented
364
358
  */
365
359
  const normalizeScopes = (scopes) => {
366
360
  return [...new Set(scopes)].sort((a, b) => a.localeCompare(b));
@@ -379,7 +373,7 @@ const normalizeScopes = (scopes) => {
379
373
  * - Expired tokens are rejected (returns null)
380
374
  *
381
375
  * @returns Parsed token data or null if token is invalid/expired
382
- * @not-instrumented
376
+ * @notInstrumented
383
377
  */
384
378
  const parseElevatedAccessToken = ({ token }) => {
385
379
  const payload = decodeJwt(token);
@@ -410,7 +404,7 @@ const parseElevatedAccessToken = ({ token }) => {
410
404
  * @param currentTokens - Current array of elevated access tokens
411
405
  * @param newToken - New token to upsert
412
406
  * @returns Updated array of tokens with the new token upserted
413
- * @not-instrumented
407
+ * @notInstrumented
414
408
  */
415
409
  const upsertElevatedAccessToken = ({ currentTokens, newToken }) => {
416
410
  const newScopeKey = normalizeScopes(newToken.scopes).join(" ");
@@ -426,7 +420,7 @@ const upsertElevatedAccessToken = ({ currentTokens, newToken }) => {
426
420
 
427
421
  //#endregion
428
422
  //#region src/modules/auth/updateAuthFromVerifyResponse/updateAuthFromVerifyResponse.ts
429
- /** @not-instrumented */
423
+ /** @notInstrumented */
430
424
  const updateAuthFromVerifyResponse = ({ response }, client) => {
431
425
  const core = getCore(client);
432
426
  const previousState = { ...core.state.get() };
@@ -461,14 +455,14 @@ const updateAuthFromVerifyResponse = ({ response }, client) => {
461
455
 
462
456
  //#endregion
463
457
  //#region src/modules/wallets/utils/getVerifiedCredentialForWalletAccount/getVerifiedCredentialForWalletAccount.ts
464
- /** @not-instrumented */
458
+ /** @notInstrumented */
465
459
  const getVerifiedCredentialForWalletAccount = ({ walletAccount }, client) => {
466
460
  return client.user?.verifiedCredentials.find((vc) => vc.id === walletAccount.verifiedCredentialId);
467
461
  };
468
462
 
469
463
  //#endregion
470
464
  //#region src/modules/wallets/getWalletProviderByKey/getWalletProviderByKey.ts
471
- /** @not-instrumented */
465
+ /** @notInstrumented */
472
466
  const getWalletProviderByKey = ({ walletProviderKey }, client) => {
473
467
  const walletProvider = getWalletProviders(client).find((walletProvider$1) => walletProvider$1.key === walletProviderKey);
474
468
  if (!walletProvider) throw new NoWalletProviderFoundError({ walletProviderKey });
@@ -476,5 +470,5 @@ const getWalletProviderByKey = ({ walletProviderKey }, client) => {
476
470
  };
477
471
 
478
472
  //#endregion
479
- export { formatWalletAccountId as _, parseElevatedAccessToken as a, InvalidWalletProviderKeyError as b, findWaasWalletProviderByChain as c, checkAndRaiseWalletAccountsChangedEvent as d, emitWalletAccountsChangedEvent as f, normalizeWalletNameWithChain as g, formatWalletProviderKey as h, upsertElevatedAccessToken as i, getWalletProviders as l, getWalletAccounts as m, getVerifiedCredentialForWalletAccount as n, initializeWaasClientsForEagerRecovery as o, DYNAMIC_AUTH_COOKIE_NAME as p, updateAuthFromVerifyResponse as r, isWaasWalletAccount as s, getWalletProviderByKey as t, isUserMissingMfaAuth as u, normalizeAddress as v, setCookie as x, splitWalletProviderKey as y };
480
- //# sourceMappingURL=getWalletProviderByKey-RTW-S68o.native.esm.js.map
473
+ export { normalizeAddress as _, parseElevatedAccessToken as a, setCookie as b, findWaasWalletProviderByChain as c, emitWalletAccountsChangedEvent as d, DYNAMIC_AUTH_COOKIE_NAME as f, formatWalletAccountId as g, normalizeWalletNameWithChain as h, upsertElevatedAccessToken as i, getWalletProviders as l, formatWalletProviderKey as m, getVerifiedCredentialForWalletAccount as n, initializeWaasClientsForEagerRecovery as o, getWalletAccounts as p, updateAuthFromVerifyResponse as r, isWaasWalletAccount as s, getWalletProviderByKey as t, checkAndRaiseWalletAccountsChangedEvent as u, splitWalletProviderKey as v, InvalidWalletProviderKeyError as y };
474
+ //# sourceMappingURL=getWalletProviderByKey-DDDxBsdv.native.esm.js.map