@gurge/sdk 0.3.150 → 0.3.151
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +43 -29
- package/common/src/API/API.cjs +1 -1
- package/common/src/API/API.d.ts +21 -46
- package/common/src/API/API.mjs +96 -121
- package/common/src/API/admin-calls.cjs +1 -1
- package/common/src/API/admin-calls.d.ts +1 -1
- package/common/src/API/admin-calls.mjs +3 -1
- package/common/src/API/callLifiAPI.cjs +1 -1
- package/common/src/API/callLifiAPI.d.ts +4 -0
- package/common/src/API/callLifiAPI.mjs +7 -2
- package/common/src/API/callNearIntentsAPI.cjs +1 -1
- package/common/src/API/callNearIntentsAPI.mjs +2 -2
- package/common/src/API/callRelayer.cjs +1 -1
- package/common/src/API/callRelayer.d.ts +36 -1
- package/common/src/API/callRelayer.mjs +7 -1
- package/common/src/API/dashboardAccountMemberCalls.cjs +1 -1
- package/common/src/API/dashboardAccountMemberCalls.d.ts +15 -0
- package/common/src/API/dashboardAccountMemberCalls.mjs +5 -2
- package/common/src/API/dashboardPayoutCalls.cjs +1 -1
- package/common/src/API/dashboardPayoutCalls.d.ts +2 -1
- package/common/src/API/dashboardPayoutCalls.mjs +4 -1
- package/common/src/API/dashboardTransactionCalls.cjs +1 -1
- package/common/src/API/dashboardTransactionCalls.d.ts +4 -1
- package/common/src/API/dashboardTransactionCalls.mjs +2 -2
- package/common/src/API/enclaveRecipientInfoCalls.d.ts +0 -2
- package/common/src/API/enclaveSignatureCalls.cjs +1 -1
- package/common/src/API/enclaveSignatureCalls.d.ts +2 -1
- package/common/src/API/enclaveSignatureCalls.mjs +5 -8
- package/common/src/API/enclaveUtxoCalls.cjs +1 -1
- package/common/src/API/enclaveUtxoCalls.d.ts +40 -27
- package/common/src/API/enclaveUtxoCalls.mjs +16 -17
- package/common/src/API/evm-rpc-fallback.cjs +1 -0
- package/common/src/API/evm-rpc-fallback.d.ts +1 -0
- package/common/src/API/evm-rpc-fallback.mjs +17 -0
- package/common/src/API/evm-token-assets.d.ts +8 -0
- package/common/src/API/getOdosPriceForToken.cjs +1 -0
- package/common/src/API/getOdosPriceForToken.d.ts +1 -0
- package/common/src/API/getOdosPriceForToken.mjs +14 -0
- package/common/src/API/getWebsiteURL.d.ts +1 -3
- package/common/src/API/index.cjs +1 -1
- package/common/src/API/index.d.ts +2 -3
- package/common/src/API/index.mjs +4 -5
- package/common/src/API/payoutNotificationStateCalls.cjs +1 -0
- package/common/src/API/payoutNotificationStateCalls.d.ts +10 -0
- package/common/src/API/payoutNotificationStateCalls.mjs +10 -0
- package/common/src/API/privateSendRecipientInfoCalls.cjs +1 -1
- package/common/src/API/privateSendRecipientInfoCalls.d.ts +3 -6
- package/common/src/API/privateSendRecipientInfoCalls.mjs +12 -6
- package/common/src/API/proxyAccountsCalls.cjs +1 -1
- package/common/src/API/proxyAccountsCalls.d.ts +2 -3
- package/common/src/API/proxyAccountsCalls.mjs +11 -10
- package/common/src/API/rewardsUserCalls.cjs +1 -1
- package/common/src/API/rewardsUserCalls.d.ts +1 -40
- package/common/src/API/rewardsUserCalls.mjs +2 -10
- package/common/src/API/route-config.cjs +1 -0
- package/common/src/API/route-config.d.ts +1 -0
- package/common/src/API/route-config.mjs +26 -0
- package/common/src/API/scheduled-transactions-calls.cjs +1 -1
- package/common/src/API/scheduled-transactions-calls.d.ts +2 -5
- package/common/src/API/scheduled-transactions-calls.mjs +2 -6
- package/common/src/API/solana-nft-assets.d.ts +1 -0
- package/common/src/API/solana-priority-fee.cjs +1 -0
- package/common/src/API/solana-priority-fee.d.ts +3 -0
- package/common/src/API/solana-priority-fee.mjs +20 -0
- package/common/src/API/solana-rpc-fallback.cjs +1 -0
- package/common/src/API/solana-rpc-fallback.d.ts +1 -0
- package/common/src/API/solana-rpc-fallback.mjs +13 -0
- package/common/src/API/temporaryWalletCalls.cjs +1 -1
- package/common/src/API/temporaryWalletCalls.d.ts +3 -5
- package/common/src/API/temporaryWalletCalls.mjs +8 -9
- package/common/src/API/tenderly.api.cjs +1 -1
- package/common/src/API/tenderly.api.d.ts +5 -10
- package/common/src/API/tenderly.api.mjs +1 -1
- package/common/src/API/weeklyAnalyticCalls.cjs +1 -1
- package/common/src/API/weeklyAnalyticCalls.d.ts +1 -11
- package/common/src/API/weeklyAnalyticCalls.mjs +2 -5
- package/common/src/constants/addresses.constants.cjs +1 -1
- package/common/src/constants/addresses.constants.d.ts +4 -46
- package/common/src/constants/addresses.constants.mjs +19 -60
- package/common/src/constants/balance.constants.cjs +1 -0
- package/common/src/constants/balance.constants.d.ts +3 -0
- package/common/src/constants/balance.constants.mjs +4 -0
- package/common/src/constants/bridging.constants.cjs +1 -1
- package/common/src/constants/bridging.constants.d.ts +10 -0
- package/common/src/constants/bridging.constants.mjs +2 -1
- package/common/src/constants/chains.constants.cjs +1 -1
- package/common/src/constants/chains.constants.d.ts +21 -19
- package/common/src/constants/chains.constants.mjs +175 -198
- package/common/src/constants/coingecko.constants.cjs +1 -1
- package/common/src/constants/coingecko.constants.d.ts +3 -1
- package/common/src/constants/coingecko.constants.mjs +1 -1
- package/common/src/constants/contracts.constants.cjs +1 -1
- package/common/src/constants/contracts.constants.d.ts +1 -109
- package/common/src/constants/contracts.constants.mjs +16 -34
- package/common/src/constants/deploy-data/deploy-data-arbMainnet.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-arbMainnet.json.mjs +8 -9
- package/common/src/constants/deploy-data/deploy-data-arcTestnet.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-arcTestnet.json.mjs +7 -6
- package/common/src/constants/deploy-data/deploy-data-base.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-base.json.mjs +8 -9
- package/common/src/constants/deploy-data/deploy-data-bnbMainnet.json.cjs +1 -0
- package/common/src/constants/deploy-data/deploy-data-bnbMainnet.json.mjs +12 -0
- package/common/src/constants/deploy-data/deploy-data-ethMainnet.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-ethMainnet.json.mjs +8 -9
- package/common/src/constants/deploy-data/deploy-data-localhost.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-localhost.json.mjs +0 -3
- package/common/src/constants/deploy-data/deploy-data-optimism.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-optimism.json.mjs +8 -9
- package/common/src/constants/deploy-data/deploy-data-optimismTest.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-optimismTest.json.mjs +5 -9
- package/common/src/constants/deploy-data/deploy-data-polygon.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-polygon.json.mjs +8 -9
- package/common/src/constants/deploy-data/deploy-data-sepoliaTestnet.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-sepoliaTestnet.json.mjs +0 -1
- package/common/src/constants/deploy-data/deploy-data-solana.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-solana.json.mjs +2 -2
- package/common/src/constants/deploy-data/deploy-data-tempo.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-tempo.json.mjs +7 -7
- package/common/src/constants/deploy-data/deploy-data-tronMainnet.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-tronMainnet.json.mjs +2 -4
- package/common/src/constants/deploy-data/deploy-data-tronNile.json.cjs +1 -1
- package/common/src/constants/deploy-data/deploy-data-tronNile.json.mjs +2 -4
- package/common/src/constants/deploy-data/index.cjs +1 -1
- package/common/src/constants/deploy-data/index.d.ts +2 -1
- package/common/src/constants/deploy-data/index.mjs +16 -15
- package/common/src/constants/deploy-data/shared-deploy-data-evm.json.cjs +1 -1
- package/common/src/constants/deploy-data/shared-deploy-data-evm.json.mjs +36 -45
- package/common/src/constants/deploy-data/shared-deploy-data-solana.json.cjs +1 -1
- package/common/src/constants/deploy-data/shared-deploy-data-solana.json.mjs +1 -1
- package/common/src/constants/deploy-data/shared-deploy-data-tron.json.cjs +1 -1
- package/common/src/constants/deploy-data/shared-deploy-data-tron.json.mjs +2 -46
- package/common/src/constants/enclaveAuth.constants.d.ts +5 -0
- package/common/src/constants/events.constants.cjs +1 -1
- package/common/src/constants/events.constants.mjs +1 -15
- package/common/src/constants/fees.constants.cjs +1 -1
- package/common/src/constants/fees.constants.mjs +2 -2
- package/common/src/constants/index.cjs +1 -1
- package/common/src/constants/index.d.ts +1 -3
- package/common/src/constants/index.mjs +1 -1
- package/common/src/constants/lifi.constants.cjs +1 -1
- package/common/src/constants/lifi.constants.mjs +6 -3
- package/common/src/constants/mediaUrls.constants.d.ts +0 -1
- package/common/src/constants/okx.constants.d.ts +1 -0
- package/common/src/constants/pay.constants.d.ts +1 -0
- package/common/src/constants/protocol.constants.cjs +2 -1
- package/common/src/constants/protocol.constants.d.ts +22 -12
- package/common/src/constants/protocol.constants.mjs +3 -15
- package/common/src/constants/server.constants.cjs +1 -1
- package/common/src/constants/server.constants.d.ts +14 -36
- package/common/src/constants/server.constants.mjs +19 -49
- package/common/src/constants/tokens.constants.cjs +1 -1
- package/common/src/constants/tokens.constants.d.ts +1 -0
- package/common/src/constants/tokens.constants.mjs +4 -1
- package/common/src/constants/tx-confirmation.constants.cjs +1 -1
- package/common/src/constants/tx-confirmation.constants.d.ts +1 -0
- package/common/src/constants/tx-confirmation.constants.mjs +2 -2
- package/common/src/crypto/ecdh-sealed-keys.cjs +1 -1
- package/common/src/crypto/ecdh-sealed-keys.mjs +17 -2
- package/common/src/crypto/index.cjs +1 -1
- package/common/src/crypto/index.d.ts +0 -1
- package/common/src/crypto/index.mjs +1 -2
- package/common/src/data-structures/ApprovalDBs/EventsPublicApprovalsDB.d.ts +1 -2
- package/common/src/data-structures/Hinkal/Hinkal.cjs +1 -1
- package/common/src/data-structures/Hinkal/Hinkal.d.ts +18 -23
- package/common/src/data-structures/Hinkal/Hinkal.mjs +142 -174
- package/common/src/data-structures/Hinkal/IHinkal.d.ts +18 -24
- package/common/src/data-structures/Hinkal/handleAutoDepositBack.cjs +1 -1
- package/common/src/data-structures/Hinkal/handleAutoDepositBack.d.ts +1 -1
- package/common/src/data-structures/Hinkal/handleAutoDepositBack.mjs +36 -35
- package/common/src/data-structures/Hinkal/hinkalActionReceive.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalActionReceive.mjs +13 -11
- package/common/src/data-structures/Hinkal/hinkalBridgePrivateToPrivate.cjs +1 -0
- package/common/src/data-structures/Hinkal/hinkalBridgePrivateToPrivate.d.ts +6 -0
- package/common/src/data-structures/Hinkal/hinkalBridgePrivateToPrivate.mjs +100 -0
- package/common/src/data-structures/Hinkal/hinkalClaimUtxo.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalClaimUtxo.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalClaimUtxo.mjs +40 -50
- package/common/src/data-structures/Hinkal/hinkalDeposit.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalDeposit.d.ts +1 -0
- package/common/src/data-structures/Hinkal/hinkalDeposit.mjs +50 -119
- package/common/src/data-structures/Hinkal/hinkalDepositAndBridge.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalDepositAndBridge.d.ts +2 -2
- package/common/src/data-structures/Hinkal/hinkalDepositAndBridge.mjs +113 -109
- package/common/src/data-structures/Hinkal/hinkalDepositAndWithdraw.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalDepositAndWithdraw.d.ts +3 -2
- package/common/src/data-structures/Hinkal/hinkalDepositAndWithdraw.mjs +98 -64
- package/common/src/data-structures/Hinkal/hinkalDepositOnChainUtxos.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalDepositOnChainUtxos.d.ts +20 -7
- package/common/src/data-structures/Hinkal/hinkalDepositOnChainUtxos.mjs +50 -48
- package/common/src/data-structures/Hinkal/hinkalNearDepositAndBridge.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalNearDepositAndBridge.mjs +8 -3
- package/common/src/data-structures/Hinkal/hinkalPalEvmDeposit.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalPalTronDepositPrepare.d.ts +2 -2
- package/common/src/data-structures/Hinkal/hinkalPrivateWallet.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalPrivateWallet.mjs +50 -38
- package/common/src/data-structures/Hinkal/hinkalProoflessDeposit.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalProoflessDeposit.d.ts +2 -3
- package/common/src/data-structures/Hinkal/hinkalProoflessDeposit.mjs +52 -117
- package/common/src/data-structures/Hinkal/hinkalProoflessDeposit.utils.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalProoflessDeposit.utils.d.ts +3 -0
- package/common/src/data-structures/Hinkal/hinkalProoflessDeposit.utils.mjs +26 -32
- package/common/src/data-structures/Hinkal/hinkalProxySend.cjs +1 -0
- package/common/src/data-structures/Hinkal/hinkalProxySend.d.ts +6 -0
- package/common/src/data-structures/Hinkal/hinkalProxySend.mjs +16 -0
- package/common/src/data-structures/Hinkal/hinkalProxySwap.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalProxySwap.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalProxySwap.mjs +13 -12
- package/common/src/data-structures/Hinkal/hinkalProxyToPrivate.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalProxyToPrivate.mjs +19 -17
- package/common/src/data-structures/Hinkal/hinkalSolanaClaimUtxo.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaClaimUtxo.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaClaimUtxo.mjs +50 -79
- package/common/src/data-structures/Hinkal/hinkalSolanaDeposit.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaDeposit.d.ts +2 -2
- package/common/src/data-structures/Hinkal/hinkalSolanaDeposit.mjs +47 -51
- package/common/src/data-structures/Hinkal/hinkalSolanaDepositAndWithdraw.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaDepositAndWithdraw.d.ts +8 -4
- package/common/src/data-structures/Hinkal/hinkalSolanaDepositAndWithdraw.mjs +115 -133
- package/common/src/data-structures/Hinkal/hinkalSolanaProoflessDeposit.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaProoflessDeposit.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaProoflessDeposit.mjs +16 -12
- package/common/src/data-structures/Hinkal/hinkalSolanaProxySend.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaProxySend.mjs +1 -3
- package/common/src/data-structures/Hinkal/hinkalSolanaProxyShield.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaProxyShield.d.ts +24 -2
- package/common/src/data-structures/Hinkal/hinkalSolanaProxyShield.mjs +82 -56
- package/common/src/data-structures/Hinkal/hinkalSolanaProxySwap.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaProxySwap.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaProxySwap.mjs +11 -13
- package/common/src/data-structures/Hinkal/hinkalSolanaSponsoredShield.cjs +1 -0
- package/common/src/data-structures/Hinkal/hinkalSolanaSponsoredShield.d.ts +8 -0
- package/common/src/data-structures/Hinkal/hinkalSolanaSponsoredShield.mjs +32 -0
- package/common/src/data-structures/Hinkal/hinkalSolanaSwap.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaSwap.mjs +58 -79
- package/common/src/data-structures/Hinkal/hinkalSolanaTransact.cjs +1 -0
- package/common/src/data-structures/Hinkal/hinkalSolanaTransact.d.ts +3 -0
- package/common/src/data-structures/Hinkal/hinkalSolanaTransact.mjs +119 -0
- package/common/src/data-structures/Hinkal/hinkalSolanaTransfer.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaTransfer.d.ts +2 -30
- package/common/src/data-structures/Hinkal/hinkalSolanaTransfer.mjs +46 -77
- package/common/src/data-structures/Hinkal/hinkalSolanaWithdraw.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaWithdraw.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalSolanaWithdraw.mjs +46 -57
- package/common/src/data-structures/Hinkal/hinkalSwap.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalSwap.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalSwap.mjs +32 -32
- package/common/src/data-structures/Hinkal/hinkalTransact.cjs +1 -0
- package/common/src/data-structures/Hinkal/hinkalTransact.d.ts +3 -0
- package/common/src/data-structures/Hinkal/hinkalTransact.mjs +106 -0
- package/common/src/data-structures/Hinkal/hinkalTransfer.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalTransfer.mjs +39 -44
- package/common/src/data-structures/Hinkal/hinkalWithdraw.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalWithdraw.d.ts +1 -1
- package/common/src/data-structures/Hinkal/hinkalWithdraw.mjs +38 -49
- package/common/src/data-structures/Hinkal/hinkalWithdrawStuckUtxos.cjs +1 -1
- package/common/src/data-structures/Hinkal/hinkalWithdrawStuckUtxos.mjs +160 -102
- package/common/src/data-structures/Hinkal/index.d.ts +2 -1
- package/common/src/data-structures/Hinkal/prepareTronDepositToSelf.d.ts +27 -0
- package/common/src/data-structures/Hinkal/resetMerkleTrees.cjs +1 -1
- package/common/src/data-structures/Hinkal/resetMerkleTrees.mjs +7 -6
- package/common/src/data-structures/IndexedDB/activity-db.cjs +1 -1
- package/common/src/data-structures/IndexedDB/activity-db.mjs +34 -34
- package/common/src/data-structures/IndexedDB/contact-db.cjs +1 -1
- package/common/src/data-structures/IndexedDB/contact-db.d.ts +0 -1
- package/common/src/data-structures/IndexedDB/contact-db.mjs +14 -28
- package/common/src/data-structures/IndexedDB/index.cjs +1 -1
- package/common/src/data-structures/IndexedDB/index.d.ts +1 -0
- package/common/src/data-structures/IndexedDB/index.mjs +1 -0
- package/common/src/data-structures/IndexedDB/key-val-store.cjs +1 -1
- package/common/src/data-structures/IndexedDB/key-val-store.d.ts +2 -0
- package/common/src/data-structures/IndexedDB/key-val-store.mjs +14 -0
- package/common/src/data-structures/IndexedDB/pay-activity-db.cjs +1 -1
- package/common/src/data-structures/IndexedDB/pay-activity-db.mjs +43 -1
- package/common/src/data-structures/IndexedDB/private-balances-db.cjs +1 -1
- package/common/src/data-structures/IndexedDB/private-balances-db.d.ts +1 -0
- package/common/src/data-structures/IndexedDB/private-balances-db.mjs +3 -0
- package/common/src/data-structures/IndexedDB/scheduled-transactions-db.cjs +1 -0
- package/common/src/data-structures/IndexedDB/scheduled-transactions-db.d.ts +11 -0
- package/common/src/data-structures/IndexedDB/scheduled-transactions-db.mjs +34 -0
- package/common/src/data-structures/IndexedDB/signatures-db.cjs +1 -1
- package/common/src/data-structures/IndexedDB/signatures-db.mjs +11 -11
- package/common/src/data-structures/MultiThreadedUtxoUtils/MultiThreadedUtxoUtils.cjs +1 -1
- package/common/src/data-structures/MultiThreadedUtxoUtils/MultiThreadedUtxoUtils.d.ts +1 -0
- package/common/src/data-structures/MultiThreadedUtxoUtils/MultiThreadedUtxoUtils.mjs +29 -26
- package/common/src/data-structures/TokenDBs/AlchemyPublicTokensDB.d.ts +0 -1
- package/common/src/data-structures/TokenDBs/PrivateTokensDB.cjs +1 -1
- package/common/src/data-structures/TokenDBs/PrivateTokensDB.mjs +17 -18
- package/common/src/data-structures/TokenDBs/TronPublicTokensDB.d.ts +1 -0
- package/common/src/data-structures/WalletManager/WalletManager.d.ts +1 -0
- package/common/src/data-structures/cacheDevices/BaseCacheDevice.cjs +1 -1
- package/common/src/data-structures/cacheDevices/BaseCacheDevice.d.ts +1 -0
- package/common/src/data-structures/cacheDevices/BaseCacheDevice.mjs +3 -0
- package/common/src/data-structures/cacheDevices/FileCacheDevice.cjs +1 -1
- package/common/src/data-structures/cacheDevices/FileCacheDevice.d.ts +3 -0
- package/common/src/data-structures/cacheDevices/FileCacheDevice.mjs +12 -3
- package/common/src/data-structures/crypto-keys/decodeUTXO.cjs +1 -1
- package/common/src/data-structures/crypto-keys/decodeUTXO.d.ts +9 -9
- package/common/src/data-structures/crypto-keys/decodeUTXO.mjs +11 -71
- package/common/src/data-structures/crypto-keys/encryptDecryptUtxo.cjs +1 -1
- package/common/src/data-structures/crypto-keys/encryptDecryptUtxo.d.ts +2 -3
- package/common/src/data-structures/crypto-keys/encryptDecryptUtxo.mjs +39 -23
- package/common/src/data-structures/crypto-keys/keys.cjs +1 -1
- package/common/src/data-structures/crypto-keys/keys.d.ts +13 -27
- package/common/src/data-structures/crypto-keys/keys.mjs +64 -79
- package/common/src/data-structures/event-service/evm/BlockchainEventEmitter.cjs +1 -1
- package/common/src/data-structures/event-service/evm/BlockchainEventEmitter.d.ts +3 -2
- package/common/src/data-structures/event-service/evm/BlockchainEventEmitter.mjs +46 -38
- package/common/src/data-structures/event-service/evm/ClientBlockchainEventEmitter.cjs +1 -1
- package/common/src/data-structures/event-service/evm/ClientBlockchainEventEmitter.d.ts +1 -1
- package/common/src/data-structures/event-service/evm/ClientBlockchainEventEmitter.mjs +2 -2
- package/common/src/data-structures/event-service/solana/AbstractSolanaCommitmentsSnapshotService.cjs +1 -1
- package/common/src/data-structures/event-service/solana/AbstractSolanaCommitmentsSnapshotService.mjs +27 -23
- package/common/src/data-structures/merkle-tree/MerkleTree.cjs +1 -1
- package/common/src/data-structures/merkle-tree/MerkleTree.d.ts +11 -0
- package/common/src/data-structures/merkle-tree/MerkleTree.mjs +12 -1
- package/common/src/data-structures/private-balances/HinkalPrivateBalanceController.cjs +1 -1
- package/common/src/data-structures/private-balances/HinkalPrivateBalanceController.d.ts +4 -0
- package/common/src/data-structures/private-balances/HinkalPrivateBalanceController.mjs +100 -86
- package/common/src/data-structures/provider-adapter/IProviderAdapter.d.ts +1 -5
- package/common/src/data-structures/token-price-fetcher/TokenChecker.cjs +1 -1
- package/common/src/data-structures/token-price-fetcher/TokenChecker.d.ts +1 -0
- package/common/src/data-structures/token-price-fetcher/TokenChecker.mjs +5 -3
- package/common/src/data-structures/utxo/Utxo.cjs +1 -1
- package/common/src/data-structures/utxo/Utxo.d.ts +1 -4
- package/common/src/data-structures/utxo/Utxo.mjs +7 -17
- package/common/src/error-handling/error-codes.constants.cjs +2 -2
- package/common/src/error-handling/error-codes.constants.d.ts +14 -14
- package/common/src/error-handling/error-codes.constants.mjs +30 -32
- package/common/src/error-handling/get-error.message.cjs +1 -1
- package/common/src/error-handling/get-error.message.mjs +28 -18
- package/common/src/error-handling/index.cjs +1 -1
- package/common/src/error-handling/index.d.ts +1 -0
- package/common/src/error-handling/index.mjs +1 -0
- package/common/src/externalABIs/index.cjs +1 -1
- package/common/src/externalABIs/index.d.ts +1 -113
- package/common/src/externalABIs/index.mjs +2 -6
- package/common/src/functions/auto-deposit-back-helpers/get-gas-token-records.cjs +1 -1
- package/common/src/functions/auto-deposit-back-helpers/get-gas-token-records.mjs +7 -6
- package/common/src/functions/auto-deposit-back-helpers/select-gas-token.cjs +1 -1
- package/common/src/functions/auto-deposit-back-helpers/select-gas-token.mjs +8 -8
- package/common/src/functions/index.cjs +1 -1
- package/common/src/functions/index.d.ts +0 -1
- package/common/src/functions/index.mjs +21 -20
- package/common/src/functions/pre-transaction/buildCommitmentValidationData.cjs +1 -1
- package/common/src/functions/pre-transaction/buildCommitmentValidationData.mjs +36 -38
- package/common/src/functions/pre-transaction/calculateSolanaNullifierCount.cjs +1 -1
- package/common/src/functions/pre-transaction/calculateSolanaNullifierCount.mjs +38 -5
- package/common/src/functions/pre-transaction/ensureAmountChanges.cjs +1 -1
- package/common/src/functions/pre-transaction/ensureAmountChanges.mjs +3 -10
- package/common/src/functions/pre-transaction/getExternalSwapAddress.cjs +1 -1
- package/common/src/functions/pre-transaction/getExternalSwapAddress.mjs +2 -18
- package/common/src/functions/pre-transaction/getSolanaCalldataHash.cjs +1 -1
- package/common/src/functions/pre-transaction/getSolanaCalldataHash.d.ts +1 -1
- package/common/src/functions/pre-transaction/getSolanaCalldataHash.mjs +11 -10
- package/common/src/functions/pre-transaction/getVolatileTransferAmount.cjs +1 -1
- package/common/src/functions/pre-transaction/getVolatileTransferAmount.mjs +1 -1
- package/common/src/functions/pre-transaction/index.cjs +1 -1
- package/common/src/functions/pre-transaction/index.d.ts +2 -2
- package/common/src/functions/pre-transaction/index.mjs +2 -3
- package/common/src/functions/pre-transaction/merge-with-fee-structure-emporium.cjs +1 -1
- package/common/src/functions/pre-transaction/merge-with-fee-structure-emporium.mjs +2 -2
- package/common/src/functions/pre-transaction/outputUtxoProcessing.cjs +1 -1
- package/common/src/functions/pre-transaction/outputUtxoProcessing.d.ts +2 -1
- package/common/src/functions/pre-transaction/outputUtxoProcessing.mjs +19 -18
- package/common/src/functions/pre-transaction/sendV0Transaction.cjs +2 -2
- package/common/src/functions/pre-transaction/sendV0Transaction.d.ts +5 -2
- package/common/src/functions/pre-transaction/sendV0Transaction.mjs +4 -4
- package/common/src/functions/pre-transaction/solana-public-signals.d.ts +1 -0
- package/common/src/functions/pre-transaction/solana.cjs +1 -1
- package/common/src/functions/pre-transaction/solana.d.ts +13 -0
- package/common/src/functions/pre-transaction/solana.mjs +46 -21
- package/common/src/functions/pre-transaction/solanaTransfer.utils.cjs +1 -1
- package/common/src/functions/pre-transaction/solanaTransfer.utils.mjs +16 -15
- package/common/src/functions/pre-transaction/speculativeUtxo.cjs +1 -0
- package/common/src/functions/pre-transaction/speculativeUtxo.d.ts +9 -0
- package/common/src/functions/pre-transaction/speculativeUtxo.mjs +19 -0
- package/common/src/functions/pre-transaction/store-proof.cjs +1 -1
- package/common/src/functions/pre-transaction/store-proof.d.ts +1 -1
- package/common/src/functions/pre-transaction/store-proof.mjs +1 -0
- package/common/src/functions/private-wallet/emporium.helpers.cjs +1 -1
- package/common/src/functions/private-wallet/emporium.helpers.d.ts +9 -3
- package/common/src/functions/private-wallet/emporium.helpers.mjs +116 -72
- package/common/src/functions/private-wallet/emporium.swap.helpers.cjs +1 -1
- package/common/src/functions/private-wallet/emporium.swap.helpers.d.ts +0 -1
- package/common/src/functions/private-wallet/emporium.swap.helpers.mjs +38 -80
- package/common/src/functions/private-wallet/index.cjs +1 -1
- package/common/src/functions/private-wallet/index.d.ts +0 -1
- package/common/src/functions/private-wallet/index.mjs +0 -1
- package/common/src/functions/snarkjs/common.snarkjs.cjs +1 -1
- package/common/src/functions/snarkjs/common.snarkjs.d.ts +4 -4
- package/common/src/functions/snarkjs/common.snarkjs.mjs +104 -65
- package/common/src/functions/snarkjs/constant.cjs +1 -1
- package/common/src/functions/snarkjs/constant.d.ts +231 -144
- package/common/src/functions/snarkjs/constant.mjs +231 -145
- package/common/src/functions/snarkjs/constructGeneralZkProof.cjs +1 -1
- package/common/src/functions/snarkjs/constructGeneralZkProof.d.ts +1 -1
- package/common/src/functions/snarkjs/constructGeneralZkProof.mjs +85 -69
- package/common/src/functions/snarkjs/constructSignatureFromMnemonicProofInput.cjs +1 -0
- package/common/src/functions/snarkjs/constructSignatureFromMnemonicProofInput.d.ts +7 -0
- package/common/src/functions/snarkjs/constructSignatureFromMnemonicProofInput.mjs +2 -0
- package/common/src/functions/snarkjs/constructSolanaZkProof.cjs +1 -1
- package/common/src/functions/snarkjs/constructSolanaZkProof.d.ts +4 -1
- package/common/src/functions/snarkjs/constructSolanaZkProof.mjs +62 -61
- package/common/src/functions/snarkjs/constructTxEnclave.cjs +1 -0
- package/common/src/functions/snarkjs/constructTxEnclave.d.ts +34 -0
- package/common/src/functions/snarkjs/constructTxEnclave.mjs +95 -0
- package/common/src/functions/snarkjs/constructTxEnclaveVerify.cjs +1 -0
- package/common/src/functions/snarkjs/constructTxEnclaveVerify.d.ts +5 -0
- package/common/src/functions/snarkjs/constructTxEnclaveVerify.mjs +295 -0
- package/common/src/functions/snarkjs/fetchMerkleTreeSiblings.d.ts +1 -3
- package/common/src/functions/snarkjs/fetchOnChainRootHashes.cjs +1 -1
- package/common/src/functions/snarkjs/fetchOnChainRootHashes.d.ts +1 -0
- package/common/src/functions/snarkjs/fetchOnChainRootHashes.mjs +16 -18
- package/common/src/functions/snarkjs/fetchTronInsertionSiblings.cjs +1 -0
- package/common/src/functions/snarkjs/fetchTronInsertionSiblings.d.ts +7 -0
- package/common/src/functions/snarkjs/fetchTronInsertionSiblings.mjs +13 -0
- package/common/src/functions/snarkjs/generateCircomData.cjs +1 -1
- package/common/src/functions/snarkjs/generateCircomData.d.ts +1 -1
- package/common/src/functions/snarkjs/generateCircomData.mjs +41 -31
- package/common/src/functions/snarkjs/generateMainAndCommitmentZkProof.cjs +1 -1
- package/common/src/functions/snarkjs/generateMainAndCommitmentZkProof.d.ts +1 -1
- package/common/src/functions/snarkjs/generateMainAndCommitmentZkProof.mjs +7 -7
- package/common/src/functions/snarkjs/generateSignatureFromMnemonicProof.cjs +1 -0
- package/common/src/functions/snarkjs/generateSignatureFromMnemonicProof.d.ts +2 -0
- package/common/src/functions/snarkjs/generateSignatureFromMnemonicProof.mjs +3 -0
- package/common/src/functions/snarkjs/generateZkProof.cjs +1 -1
- package/common/src/functions/snarkjs/generateZkProof.d.ts +1 -1
- package/common/src/functions/snarkjs/generateZkProof.mjs +9 -16
- package/common/src/functions/snarkjs/getMerkleTreeSiblingsAndRootHashes.cjs +1 -1
- package/common/src/functions/snarkjs/getMerkleTreeSiblingsAndRootHashes.d.ts +4 -2
- package/common/src/functions/snarkjs/getMerkleTreeSiblingsAndRootHashes.mjs +19 -13
- package/common/src/functions/snarkjs/getZKFiles.cjs +1 -1
- package/common/src/functions/snarkjs/getZKFiles.mjs +9 -3
- package/common/src/functions/snarkjs/index.cjs +1 -1
- package/common/src/functions/snarkjs/index.d.ts +2 -0
- package/common/src/functions/snarkjs/index.mjs +2 -0
- package/common/src/functions/snarkjs/signedMessageHash.cjs +1 -1
- package/common/src/functions/snarkjs/signedMessageHash.d.ts +16 -0
- package/common/src/functions/snarkjs/signedMessageHash.mjs +36 -7
- package/common/src/functions/snarkjs/verifySignedEnclaveResponse.cjs +1 -0
- package/common/src/functions/snarkjs/verifySignedEnclaveResponse.d.ts +1 -0
- package/common/src/functions/snarkjs/verifySignedEnclaveResponse.mjs +11 -0
- package/common/src/functions/utils/addresses.cjs +1 -1
- package/common/src/functions/utils/addresses.d.ts +2 -1
- package/common/src/functions/utils/addresses.mjs +30 -21
- package/common/src/functions/utils/bridge-arrival.utils.cjs +1 -0
- package/common/src/functions/utils/bridge-arrival.utils.d.ts +1 -0
- package/common/src/functions/utils/bridge-arrival.utils.mjs +16 -0
- package/common/src/functions/utils/bridge-claimable-utxo.utils.cjs +1 -0
- package/common/src/functions/utils/bridge-claimable-utxo.utils.d.ts +19 -0
- package/common/src/functions/utils/bridge-claimable-utxo.utils.mjs +24 -0
- package/common/src/functions/utils/bridge-claimable.utils.cjs +1 -0
- package/common/src/functions/utils/bridge-claimable.utils.d.ts +15 -0
- package/common/src/functions/utils/bridge-claimable.utils.mjs +3 -0
- package/common/src/functions/utils/bridge-flow.utils.cjs +1 -0
- package/common/src/functions/utils/bridge-flow.utils.d.ts +4 -0
- package/common/src/functions/utils/bridge-flow.utils.mjs +2 -0
- package/common/src/functions/utils/buildClaimableDepositPlan.d.ts +3 -2
- package/common/src/functions/utils/convertEmporiumOpToCallInfo.cjs +1 -1
- package/common/src/functions/utils/convertEmporiumOpToCallInfo.mjs +5 -10
- package/common/src/functions/utils/convertIntegrationProviderToExternalActionId.cjs +1 -1
- package/common/src/functions/utils/convertIntegrationProviderToExternalActionId.mjs +1 -1
- package/common/src/functions/utils/create-provider.cjs +1 -1
- package/common/src/functions/utils/create-provider.d.ts +9 -2
- package/common/src/functions/utils/create-provider.mjs +45 -9
- package/common/src/functions/utils/deposit-claimable.utils.cjs +1 -1
- package/common/src/functions/utils/deposit-claimable.utils.d.ts +2 -5
- package/common/src/functions/utils/deposit-claimable.utils.mjs +3 -6
- package/common/src/functions/utils/enclave-recipient-info-storage.cjs +1 -1
- package/common/src/functions/utils/enclave-recipient-info-storage.d.ts +4 -1
- package/common/src/functions/utils/enclave-recipient-info-storage.mjs +1 -0
- package/common/src/functions/utils/enclave-signature-storage.cjs +1 -1
- package/common/src/functions/utils/enclave-signature-storage.d.ts +1 -1
- package/common/src/functions/utils/enclave-signature-storage.mjs +3 -3
- package/common/src/functions/utils/enclave-utxo-storage.cjs +1 -1
- package/common/src/functions/utils/enclave-utxo-storage.d.ts +6 -7
- package/common/src/functions/utils/enclave-utxo-storage.mjs +16 -2
- package/common/src/functions/utils/enclaveSessionSigning.cjs +1 -0
- package/common/src/functions/utils/enclaveSessionSigning.d.ts +16 -0
- package/common/src/functions/utils/enclaveSessionSigning.mjs +2 -0
- package/common/src/functions/utils/encodeTokenWithId.cjs +1 -1
- package/common/src/functions/utils/encodeTokenWithId.d.ts +1 -2
- package/common/src/functions/utils/encodeTokenWithId.mjs +2 -5
- package/common/src/functions/utils/encryptInputForEnclave.cjs +1 -1
- package/common/src/functions/utils/encryptInputForEnclave.d.ts +8 -0
- package/common/src/functions/utils/encryptInputForEnclave.mjs +43 -23
- package/common/src/functions/utils/erc20tokenFunctions.cjs +1 -1
- package/common/src/functions/utils/erc20tokenFunctions.mjs +2 -15
- package/common/src/functions/utils/fees.utils.cjs +1 -1
- package/common/src/functions/utils/fees.utils.d.ts +3 -0
- package/common/src/functions/utils/fees.utils.mjs +42 -29
- package/common/src/functions/utils/formatter.d.ts +2 -0
- package/common/src/functions/utils/getDataFromTransaction.d.ts +4 -3
- package/common/src/functions/utils/getRecipientInfoFromUserKeys.cjs +1 -1
- package/common/src/functions/utils/getRecipientInfoFromUserKeys.mjs +2 -3
- package/common/src/functions/utils/getUtxosFromReceipt.utils.cjs +1 -1
- package/common/src/functions/utils/getUtxosFromReceipt.utils.d.ts +1 -1
- package/common/src/functions/utils/getUtxosFromReceipt.utils.mjs +2 -26
- package/common/src/functions/utils/getUtxosFromReceiptSolana.cjs +1 -1
- package/common/src/functions/utils/getUtxosFromReceiptSolana.mjs +7 -24
- package/common/src/functions/utils/index.cjs +1 -1
- package/common/src/functions/utils/index.d.ts +17 -3
- package/common/src/functions/utils/index.mjs +27 -13
- package/common/src/functions/utils/ipfs.d.ts +2 -3
- package/common/src/functions/utils/legacyKeys.cjs +1 -0
- package/common/src/functions/utils/legacyKeys.d.ts +10 -0
- package/common/src/functions/utils/legacyKeys.mjs +8 -0
- package/common/src/functions/utils/lifi.utils.d.ts +3 -0
- package/common/src/functions/utils/mnemonics.cjs +1 -1
- package/common/src/functions/utils/mnemonics.mjs +4 -6
- package/common/src/functions/utils/nearIntents.utils.cjs +1 -1
- package/common/src/functions/utils/nearIntents.utils.mjs +27 -13
- package/common/src/functions/utils/networks.utils.d.ts +1 -0
- package/common/src/functions/utils/prepareHinkal.cjs +1 -1
- package/common/src/functions/utils/prepareHinkal.d.ts +1 -3
- package/common/src/functions/utils/prepareHinkal.mjs +2 -1
- package/common/src/functions/utils/process.utils.cjs +1 -1
- package/common/src/functions/utils/process.utils.d.ts +0 -1
- package/common/src/functions/utils/process.utils.mjs +2 -11
- package/common/src/functions/utils/proxyAvatar.utils.cjs +1 -0
- package/common/src/functions/utils/proxyAvatar.utils.mjs +3 -0
- package/common/src/functions/utils/publicBalance.utils.cjs +1 -1
- package/common/src/functions/utils/publicBalance.utils.d.ts +0 -1
- package/common/src/functions/utils/publicBalance.utils.mjs +37 -23
- package/common/src/functions/utils/recovery-balance.utils.cjs +1 -0
- package/common/src/functions/utils/recovery-balance.utils.d.ts +2 -0
- package/common/src/functions/utils/recovery-balance.utils.mjs +1 -0
- package/common/src/functions/utils/resolve-domain-address.cjs +1 -0
- package/common/src/functions/utils/resolve-domain-address.d.ts +4 -0
- package/common/src/functions/utils/resolve-domain-address.mjs +3 -0
- package/common/src/functions/utils/serialize-utxos.utils.cjs +1 -1
- package/common/src/functions/utils/serialize-utxos.utils.mjs +6 -4
- package/common/src/functions/utils/solana-program.utils.cjs +1 -0
- package/common/src/functions/utils/solana-program.utils.d.ts +3 -0
- package/common/src/functions/utils/solana-program.utils.mjs +17 -0
- package/common/src/functions/utils/solana-sponsored.utils.cjs +1 -0
- package/common/src/functions/utils/solana-sponsored.utils.d.ts +22 -0
- package/common/src/functions/utils/solana-sponsored.utils.mjs +30 -0
- package/common/src/functions/utils/solanaMint.utils.cjs +1 -1
- package/common/src/functions/utils/solanaMint.utils.d.ts +7 -0
- package/common/src/functions/utils/solanaMint.utils.mjs +18 -8
- package/common/src/functions/utils/sponsored-shield.utils.cjs +1 -0
- package/common/src/functions/utils/sponsored-shield.utils.d.ts +3 -0
- package/common/src/functions/utils/sponsored-shield.utils.mjs +3 -0
- package/common/src/functions/utils/temp-wallet.utils.cjs +1 -0
- package/common/src/functions/utils/temp-wallet.utils.d.ts +8 -0
- package/common/src/functions/utils/temp-wallet.utils.mjs +43 -0
- package/common/src/functions/utils/temporary-wallet-recovery.utils.cjs +1 -0
- package/common/src/functions/utils/temporary-wallet-recovery.utils.d.ts +7 -0
- package/common/src/functions/utils/temporary-wallet-recovery.utils.mjs +10 -0
- package/common/src/functions/utils/transfer-claimable.utils.cjs +1 -1
- package/common/src/functions/utils/transfer-claimable.utils.d.ts +1 -2
- package/common/src/functions/utils/transfer-claimable.utils.mjs +1 -4
- package/common/src/functions/utils/tron.utils.cjs +1 -1
- package/common/src/functions/utils/tron.utils.d.ts +5 -14
- package/common/src/functions/utils/tron.utils.mjs +89 -152
- package/common/src/functions/utils/tronSimulation.utils.cjs +1 -1
- package/common/src/functions/utils/tronSimulation.utils.mjs +4 -6
- package/common/src/functions/utils/tx-confirmation.utils.cjs +1 -1
- package/common/src/functions/utils/tx-confirmation.utils.d.ts +1 -0
- package/common/src/functions/utils/tx-confirmation.utils.mjs +16 -13
- package/common/src/functions/utils/validateWalletAddress.cjs +1 -0
- package/common/src/functions/utils/validateWalletAddress.d.ts +1 -0
- package/common/src/functions/utils/validateWalletAddress.mjs +2 -0
- package/common/src/functions/utils/voidWallets.utils.cjs +1 -0
- package/common/src/functions/utils/voidWallets.utils.d.ts +4 -0
- package/common/src/functions/utils/voidWallets.utils.mjs +1 -0
- package/common/src/functions/utils/waasStamp.cjs +1 -0
- package/common/src/functions/utils/waasStamp.d.ts +5 -0
- package/common/src/functions/utils/waasStamp.mjs +2 -0
- package/common/src/functions/web3/connectors.utils.d.ts +1 -0
- package/common/src/functions/web3/etherFunctions.d.ts +1 -0
- package/common/src/functions/web3/events/getInputUtxoAndBalance.cjs +1 -1
- package/common/src/functions/web3/events/getInputUtxoAndBalance.d.ts +5 -12
- package/common/src/functions/web3/events/getInputUtxoAndBalance.mjs +50 -61
- package/common/src/functions/web3/events/getInputUtxosEnclave.cjs +1 -1
- package/common/src/functions/web3/events/getInputUtxosEnclave.d.ts +4 -3
- package/common/src/functions/web3/events/getInputUtxosEnclave.mjs +42 -35
- package/common/src/functions/web3/events/getShieldedBalance.cjs +1 -1
- package/common/src/functions/web3/events/getShieldedBalance.d.ts +4 -4
- package/common/src/functions/web3/events/getShieldedBalance.mjs +109 -93
- package/common/src/functions/web3/fetchSolanaMerkleTreeRootHash.cjs +1 -1
- package/common/src/functions/web3/fetchSolanaMerkleTreeRootHash.mjs +9 -6
- package/common/src/functions/web3/functionCalls/approveToken.cjs +1 -1
- package/common/src/functions/web3/functionCalls/approveToken.d.ts +1 -1
- package/common/src/functions/web3/functionCalls/approveToken.mjs +21 -107
- package/common/src/functions/web3/functionCalls/constructBatchCall.cjs +1 -1
- package/common/src/functions/web3/functionCalls/constructBatchCall.d.ts +2 -2
- package/common/src/functions/web3/functionCalls/constructBatchCall.mjs +23 -18
- package/common/src/functions/web3/functionCalls/submitProof.cjs +1 -0
- package/common/src/functions/web3/functionCalls/submitProof.d.ts +5 -0
- package/common/src/functions/web3/functionCalls/submitProof.mjs +26 -0
- package/common/src/functions/web3/functionCalls/transactCallDirectTron.cjs +1 -1
- package/common/src/functions/web3/functionCalls/transactCallDirectTron.d.ts +7 -3
- package/common/src/functions/web3/functionCalls/transactCallDirectTron.mjs +81 -53
- package/common/src/functions/web3/functionCalls/transactCallRelayer.cjs +1 -1
- package/common/src/functions/web3/functionCalls/transactCallRelayer.d.ts +8 -13
- package/common/src/functions/web3/functionCalls/transactCallRelayer.mjs +12 -8
- package/common/src/functions/web3/getPublicAddressBalance.cjs +1 -1
- package/common/src/functions/web3/getPublicAddressBalance.d.ts +1 -2
- package/common/src/functions/web3/getPublicAddressBalance.mjs +6 -5
- package/common/src/functions/web3/getTokenHolder.cjs +1 -1
- package/common/src/functions/web3/getTokenHolder.mjs +3 -2
- package/common/src/functions/web3/index.cjs +1 -1
- package/common/src/functions/web3/index.d.ts +1 -4
- package/common/src/functions/web3/index.mjs +1 -4
- package/common/src/functions/web3/lifiAPI.cjs +1 -1
- package/common/src/functions/web3/lifiAPI.mjs +38 -7
- package/common/src/providers/EthersProviderAdapter.cjs +1 -1
- package/common/src/providers/EthersProviderAdapter.d.ts +0 -1
- package/common/src/providers/EthersProviderAdapter.mjs +0 -3
- package/common/src/providers/SolanaProviderAdapter.cjs +1 -1
- package/common/src/providers/SolanaProviderAdapter.d.ts +1 -5
- package/common/src/providers/SolanaProviderAdapter.mjs +4 -11
- package/common/src/providers/TronProviderAdapter.cjs +1 -1
- package/common/src/providers/TronProviderAdapter.d.ts +0 -1
- package/common/src/providers/TronProviderAdapter.mjs +7 -4
- package/common/src/providers/WagmiProviderAdapter.cjs +1 -1
- package/common/src/providers/WagmiProviderAdapter.d.ts +0 -1
- package/common/src/providers/WagmiProviderAdapter.mjs +32 -39
- package/common/src/types/API.types.d.ts +0 -4
- package/common/src/types/WeeklyAnalytics.types.d.ts +1 -26
- package/common/src/types/activities.types.cjs +1 -1
- package/common/src/types/activities.types.d.ts +0 -9
- package/common/src/types/activities.types.mjs +1 -1
- package/common/src/types/admin.types.cjs +1 -1
- package/common/src/types/admin.types.d.ts +4 -1
- package/common/src/types/admin.types.mjs +1 -1
- package/common/src/types/bridging-tx.types.d.ts +26 -3
- package/common/src/types/cache.types.cjs +1 -1
- package/common/src/types/cache.types.d.ts +4 -3
- package/common/src/types/cache.types.mjs +1 -1
- package/common/src/types/circom-data.types.cjs +1 -1
- package/common/src/types/circom-data.types.d.ts +32 -27
- package/common/src/types/circom-data.types.mjs +1 -1
- package/common/src/types/commitments.types.d.ts +2 -0
- package/common/src/types/dashboard-account.d.ts +15 -0
- package/common/src/types/dashboard-payout.types.d.ts +1 -0
- package/common/src/types/dashboard-transaction.types.d.ts +3 -0
- package/common/src/types/enclaveApi.types.d.ts +77 -0
- package/common/src/types/ethereum-network.types.cjs +1 -1
- package/common/src/types/ethereum-network.types.d.ts +13 -29
- package/common/src/types/ethereum-network.types.mjs +1 -1
- package/common/src/types/events.types.d.ts +1 -0
- package/common/src/types/external-action.types.cjs +1 -1
- package/common/src/types/external-action.types.d.ts +4 -7
- package/common/src/types/external-action.types.mjs +1 -1
- package/common/src/types/hinkal.types.cjs +1 -1
- package/common/src/types/hinkal.types.d.ts +12 -29
- package/common/src/types/hinkal.types.mjs +12 -20
- package/common/src/types/index.cjs +1 -1
- package/common/src/types/index.d.ts +6 -5
- package/common/src/types/index.mjs +3 -2
- package/common/src/types/near-intents.types.d.ts +2 -0
- package/common/src/types/new-rewards.type.d.ts +0 -70
- package/common/src/types/offscreen.types.cjs +1 -1
- package/common/src/types/offscreen.types.d.ts +0 -1
- package/common/src/types/offscreen.types.mjs +1 -1
- package/common/src/types/pay-activities.types.d.ts +24 -4
- package/common/src/types/payout-notification.types.d.ts +11 -0
- package/common/src/types/proxy-progress.types.d.ts +5 -0
- package/common/src/types/remote-proof.types.d.ts +5 -6
- package/common/src/types/remote-tx-build.types.d.ts +298 -0
- package/common/src/types/scheduled-transactions.types.d.ts +25 -12
- package/common/src/types/snark.types.d.ts +1 -3
- package/common/src/types/solana-transact.types.cjs +1 -0
- package/common/src/types/solana-transact.types.d.ts +35 -0
- package/common/src/types/solana-transact.types.mjs +6 -0
- package/common/src/types/solana.types.cjs +1 -0
- package/common/src/types/solana.types.d.ts +12 -3
- package/common/src/types/solana.types.mjs +6 -0
- package/common/src/types/temp-wallet.types.d.ts +9 -0
- package/common/src/types/tenderly.api.types.d.ts +70 -0
- package/common/src/types/token.types.cjs +1 -1
- package/common/src/types/token.types.d.ts +10 -0
- package/common/src/types/token.types.mjs +2 -2
- package/common/src/types/transact.types.cjs +1 -0
- package/common/src/types/transact.types.d.ts +53 -0
- package/common/src/types/transact.types.mjs +6 -0
- package/common/src/types/transaction.types.d.ts +0 -1
- package/common/src/types/transactions.types.d.ts +0 -1
- package/common/src/webworker/logError-ScFy7p5w.js +2 -0
- package/common/src/webworker/package.json +26 -25
- package/common/src/webworker/snarkjsWorker/snarkjsWorkerLauncher.ts?worker&url.cjs +1 -1
- package/common/src/webworker/snarkjsWorker/snarkjsWorkerLauncher.ts?worker&url.mjs +1 -1
- package/common/src/webworker/snarkjsWorkerNode.cjs +1 -1
- package/common/src/webworker/utxoWorker/utxoWorker.types.d.ts +4 -2
- package/common/src/webworker/utxoWorker/utxoWorkerLauncher.ts?worker&url.cjs +1 -1
- package/common/src/webworker/utxoWorker/utxoWorkerLauncher.ts?worker&url.mjs +1 -1
- package/common/src/webworker/utxoWorkerNode.cjs +1 -1
- package/common/src/webworker/viteWorkerURL.constant.cjs +3 -3
- package/common/src/webworker/viteWorkerURL.constant.mjs +3 -3
- package/common/src/webworker/workerProxy-B_eSl85g.js +1 -0
- package/common/src/webworker/zkProofWorker/zkProofWorkerLauncher.ts?worker&url.cjs +1 -1
- package/common/src/webworker/zkProofWorker/zkProofWorkerLauncher.ts?worker&url.mjs +1 -1
- package/common/src/webworker/zkProofWorkerNode.cjs +1 -1
- package/index.cjs +1 -1
- package/index.mjs +1 -1
- package/internal/swapApi.cjs +1 -1
- package/internal/swapApi.d.ts +3 -3
- package/internal/swapApi.mjs +22 -25
- package/package.json +26 -25
- package/providers/prepareEthersHinkal.cjs +1 -1
- package/providers/prepareEthersHinkal.d.ts +1 -0
- package/providers/prepareEthersHinkal.mjs +2 -2
- package/providers/prepareSolanaHinkal.cjs +1 -1
- package/providers/prepareSolanaHinkal.d.ts +1 -0
- package/providers/prepareSolanaHinkal.mjs +2 -2
- package/providers/prepareTronHinkal.cjs +1 -1
- package/providers/prepareTronHinkal.d.ts +1 -0
- package/providers/prepareTronHinkal.mjs +2 -2
- package/providers/prepareWagmiHinkal.cjs +1 -1
- package/providers/prepareWagmiHinkal.d.ts +1 -0
- package/providers/prepareWagmiHinkal.mjs +2 -2
- package/services/Hinkal.cjs +1 -1
- package/services/Hinkal.d.ts +16 -10
- package/services/Hinkal.mjs +29 -17
- package/types/IHinkal.d.ts +16 -10
- package/types/swap.types.d.ts +3 -20
- package/common/src/API/accessCodeCalls.cjs +0 -1
- package/common/src/API/accessCodeCalls.d.ts +0 -23
- package/common/src/API/accessCodeCalls.mjs +0 -13
- package/common/src/API/brotherhoodCalls.cjs +0 -1
- package/common/src/API/brotherhoodCalls.d.ts +0 -82
- package/common/src/API/brotherhoodCalls.mjs +0 -17
- package/common/src/API/callOdosAPI.cjs +0 -1
- package/common/src/API/callOdosAPI.d.ts +0 -63
- package/common/src/API/callOdosAPI.mjs +0 -18
- package/common/src/API/callOneInchAPI.cjs +0 -1
- package/common/src/API/callOneInchAPI.d.ts +0 -18
- package/common/src/API/callOneInchAPI.mjs +0 -13
- package/common/src/API/deposit-and-withdraw-status-calls.cjs +0 -1
- package/common/src/API/deposit-and-withdraw-status-calls.d.ts +0 -21
- package/common/src/API/deposit-and-withdraw-status-calls.mjs +0 -13
- package/common/src/API/generate-trading-points.cjs +0 -1
- package/common/src/API/generate-trading-points.d.ts +0 -27
- package/common/src/API/generate-trading-points.mjs +0 -23
- package/common/src/API/getAnyRecipientInfo.d.ts +0 -1
- package/common/src/API/leaderboardCalls.cjs +0 -1
- package/common/src/API/leaderboardCalls.d.ts +0 -14
- package/common/src/API/leaderboardCalls.mjs +0 -8
- package/common/src/API/referralsCalls.cjs +0 -1
- package/common/src/API/referralsCalls.d.ts +0 -22
- package/common/src/API/referralsCalls.mjs +0 -11
- package/common/src/API/send-telegram-callback.cjs +0 -1
- package/common/src/API/send-telegram-callback.d.ts +0 -7
- package/common/src/API/send-telegram-callback.mjs +0 -11
- package/common/src/constants/mystery-boxes.constants.d.ts +0 -0
- package/common/src/constants/price-impact.constants.d.ts +0 -2
- package/common/src/constants/rewards.constants.d.ts +0 -15
- package/common/src/constants/tasks.constants.cjs +0 -1
- package/common/src/constants/tasks.constants.d.ts +0 -9
- package/common/src/constants/tasks.constants.mjs +0 -124
- package/common/src/crypto/ecdh-dual-path.cjs +0 -1
- package/common/src/crypto/ecdh-dual-path.d.ts +0 -13
- package/common/src/crypto/ecdh-dual-path.mjs +0 -6
- package/common/src/data-structures/Hinkal/hinkalMultiSend.cjs +0 -1
- package/common/src/data-structures/Hinkal/hinkalMultiSend.d.ts +0 -3
- package/common/src/data-structures/Hinkal/hinkalMultiSend.mjs +0 -12
- package/common/src/data-structures/Hinkal/hinkalProoflessDepositViaWrapper.cjs +0 -1
- package/common/src/data-structures/Hinkal/hinkalProoflessDepositViaWrapper.d.ts +0 -6
- package/common/src/data-structures/Hinkal/hinkalProoflessDepositViaWrapper.mjs +0 -128
- package/common/src/data-structures/Hinkal/prepareDepositOnChainUtxosZkProof.cjs +0 -1
- package/common/src/data-structures/Hinkal/prepareDepositOnChainUtxosZkProof.d.ts +0 -22
- package/common/src/data-structures/Hinkal/prepareDepositOnChainUtxosZkProof.mjs +0 -34
- package/common/src/data-structures/TokenDBs/AlchemyPublicTokensDB.cjs +0 -1
- package/common/src/data-structures/TokenDBs/AlchemyPublicTokensDB.mjs +0 -172
- package/common/src/data-structures/TokenDBs/ArcPublicTokensDB.cjs +0 -1
- package/common/src/data-structures/TokenDBs/ArcPublicTokensDB.mjs +0 -94
- package/common/src/data-structures/TokenDBs/EventsPublicTokensDB.cjs +0 -1
- package/common/src/data-structures/TokenDBs/EventsPublicTokensDB.mjs +0 -134
- package/common/src/data-structures/TokenDBs/PublicTokensDB.cjs +0 -1
- package/common/src/data-structures/TokenDBs/PublicTokensDB.mjs +0 -32
- package/common/src/data-structures/TokenDBs/TempoPublicTokensDB.cjs +0 -1
- package/common/src/data-structures/TokenDBs/TempoPublicTokensDB.mjs +0 -41
- package/common/src/data-structures/TokenDBs/TronPublicTokensDB.cjs +0 -1
- package/common/src/data-structures/TokenDBs/TronPublicTokensDB.mjs +0 -47
- package/common/src/data-structures/TokenDBs/index.cjs +0 -1
- package/common/src/data-structures/TokenDBs/index.mjs +0 -6
- package/common/src/externalABIs/IQuoterV2.json.cjs +0 -1
- package/common/src/externalABIs/IQuoterV2.json.mjs +0 -203
- package/common/src/externalABIs/ISwapRouter.json.cjs +0 -1
- package/common/src/externalABIs/ISwapRouter.json.mjs +0 -537
- package/common/src/externalABIs/IUniswapV3Factory.json.cjs +0 -1
- package/common/src/externalABIs/IUniswapV3Factory.json.mjs +0 -188
- package/common/src/externalABIs/IUniswapV3Pool.json.cjs +0 -1
- package/common/src/externalABIs/IUniswapV3Pool.json.mjs +0 -938
- package/common/src/externalABIs/UniswapV2PoolAbi.json.cjs +0 -1
- package/common/src/externalABIs/UniswapV2PoolAbi.json.mjs +0 -78
- package/common/src/functions/pre-transaction/interaction-to-action.cjs +0 -1
- package/common/src/functions/pre-transaction/interaction-to-action.d.ts +0 -2
- package/common/src/functions/pre-transaction/interaction-to-action.mjs +0 -1
- package/common/src/functions/pre-transaction/recipientUtxoProcessing.cjs +0 -1
- package/common/src/functions/pre-transaction/recipientUtxoProcessing.d.ts +0 -3
- package/common/src/functions/pre-transaction/recipientUtxoProcessing.mjs +0 -32
- package/common/src/functions/pre-transaction/waitForDepositedUtxosInMerkleTree.cjs +0 -1
- package/common/src/functions/pre-transaction/waitForDepositedUtxosInMerkleTree.mjs +0 -29
- package/common/src/functions/private-wallet/opProducer.cjs +0 -1
- package/common/src/functions/private-wallet/opProducer.d.ts +0 -5
- package/common/src/functions/private-wallet/opProducer.mjs +0 -3
- package/common/src/functions/snarkjs/generateZkProofEnclave.cjs +0 -1
- package/common/src/functions/snarkjs/generateZkProofEnclave.d.ts +0 -5
- package/common/src/functions/snarkjs/generateZkProofEnclave.mjs +0 -27
- package/common/src/functions/utils/bit.operations.cjs +0 -1
- package/common/src/functions/utils/bit.operations.d.ts +0 -3
- package/common/src/functions/utils/bit.operations.mjs +0 -4
- package/common/src/functions/utils/get-signature-header.cjs +0 -1
- package/common/src/functions/utils/get-signature-header.d.ts +0 -5
- package/common/src/functions/utils/get-signature-header.mjs +0 -4
- package/common/src/functions/utils/ipfs.cjs +0 -1
- package/common/src/functions/utils/ipfs.mjs +0 -1
- package/common/src/functions/utils/reloadPage.cjs +0 -1
- package/common/src/functions/utils/reloadPage.mjs +0 -4
- package/common/src/functions/web3/getSolanaPriorityFee.cjs +0 -1
- package/common/src/functions/web3/getSolanaPriorityFee.d.ts +0 -3
- package/common/src/functions/web3/getSolanaPriorityFee.mjs +0 -26
- package/common/src/functions/web3/odosAPI.cjs +0 -1
- package/common/src/functions/web3/odosAPI.d.ts +0 -5
- package/common/src/functions/web3/odosAPI.mjs +0 -35
- package/common/src/functions/web3/oneInchAPI.cjs +0 -1
- package/common/src/functions/web3/oneInchAPI.d.ts +0 -5
- package/common/src/functions/web3/oneInchAPI.mjs +0 -34
- package/common/src/functions/web3/uniswapAPI.cjs +0 -1
- package/common/src/functions/web3/uniswapAPI.d.ts +0 -16
- package/common/src/functions/web3/uniswapAPI.mjs +0 -60
- package/common/src/types/brotherhood-user.types.d.ts +0 -11
- package/common/src/types/crypto.types.d.ts +0 -8
- package/common/src/types/generatePoints.d.ts +0 -14
- package/common/src/types/new-rewards.type.cjs +0 -1
- package/common/src/types/new-rewards.type.mjs +0 -10
- package/common/src/types/referral.types.d.ts +0 -12
- package/common/src/types/rewards.types.d.ts +0 -34
- package/common/src/types/scheduled-transactions.types.cjs +0 -1
- package/common/src/types/scheduled-transactions.types.mjs +0 -6
- package/common/src/types/token-with-id.types.d.ts +0 -4
- package/common/src/webworker/logError-CZYZ3oyV.js +0 -2
- package/common/src/webworker/workerProxy-DPeuP2Mg.js +0 -1
|
@@ -1,13 +1,9 @@
|
|
|
1
1
|
//#region libs/shared/common/src/error-handling/error-codes.constants.ts
|
|
2
2
|
var e = {
|
|
3
|
-
CANNOT_CERTIFY_FOR_PAST_WEEK: "Certification for the past week is not available",
|
|
4
|
-
CYCLICAL_REFERRALS_FORBIDDEN: "Cyclical referrals are forbidden",
|
|
5
|
-
USER_IS_UNRANKED: "Please certify transactions to see rank"
|
|
6
|
-
}, t = {
|
|
7
3
|
WC_NO_MATCHING_KEY: "creating the transaction failed\nversion",
|
|
8
4
|
CONNECTION_PROBLEM: "Failed to connect wallet. Please try again.",
|
|
9
5
|
REQUEST_PENDING: "request of type 'wallet_requestpermissions' already pending for origin"
|
|
10
|
-
},
|
|
6
|
+
}, t = {
|
|
11
7
|
INSUFFICIENT_FUNDS: "Insufficient funds",
|
|
12
8
|
INSUFFICIENT_FUNDS_WITHDRAW: "Not enough funds to withdraw",
|
|
13
9
|
INSUFFICIENT_FUNDS_TRANSFER: "Not enough funds to transfer",
|
|
@@ -15,20 +11,20 @@ var e = {
|
|
|
15
11
|
INSUFFICIENT_FUNDS_GAS: "Insufficient funds for gas * price",
|
|
16
12
|
INSUFFICIENT_TRON_BALANCE_FOR_FEE: "Insufficient TRX balance to cover transfer amount and transaction fee reserve",
|
|
17
13
|
INSUFFICIENT_SOL_BALANCE: "Insufficient SOL balance"
|
|
18
|
-
},
|
|
14
|
+
}, n = {
|
|
19
15
|
GAS_PRICE_EXCEEDS_AUTOSHIELD_LIMIT: "Skipped shielding due to gas fee exceeding your limit.",
|
|
20
16
|
AUTO_SHIELD_INSUFFICIENT_GAS: "Auto-Shield skipped due to insufficient gas."
|
|
21
|
-
},
|
|
17
|
+
}, r = {
|
|
22
18
|
...e,
|
|
23
19
|
...t,
|
|
24
20
|
...n,
|
|
25
|
-
...r,
|
|
26
21
|
SOME_ERROR: "Some error has occurred. Please try again in a few minutes. If the issue persists, please report it in Discord",
|
|
27
22
|
TOO_HIGH_AMOUNT: "ApproxParamsInvalid",
|
|
28
23
|
NOT_ENOUGH_TOKENS: "Transfer amount exceeds balance",
|
|
29
24
|
TRANSACTION_NOT_CONFIRMED: "The transaction was not confirmed by the network. Please, try again",
|
|
30
25
|
RPC_PROVIDER_LIMIT_ERROR: "Non-200 status code: '429'",
|
|
31
26
|
RELAYER_NOT_AVAILABLE: "All relayers are busy, please try in a few seconds",
|
|
27
|
+
NO_STUCK_BALANCE_TO_WITHDRAW: "No stuck balance found to withdraw",
|
|
32
28
|
TRANSACTION_TIMEOUT: "Your transaction got stale. Please, try in a few seconds",
|
|
33
29
|
CONNECT_ERROR: "Connection error",
|
|
34
30
|
CONNECT_ERROR2: "DOMException: Failed",
|
|
@@ -40,6 +36,7 @@ var e = {
|
|
|
40
36
|
USER_REJECTED_RPC: "User has rejected",
|
|
41
37
|
SIMULATION_FAILED: "Simulation failed:",
|
|
42
38
|
USER_DENIED_TRANSACTION_SIGNATURE: "User denied transaction signature.",
|
|
39
|
+
USER_DENIED_REQUEST_SIGNATURE: "User denied request signature.",
|
|
43
40
|
SIGNING_FAILED: "The signing failed. Please, try again",
|
|
44
41
|
SIGNATURE_UNSUPPORTED_CHAINS: "Details: Unsupported chains",
|
|
45
42
|
SIGNATURE_UNSUPPORTED_CHAINS2: "User disapproved requested chains",
|
|
@@ -80,14 +77,12 @@ var e = {
|
|
|
80
77
|
SWAP_RELAYER_MIN: "Relayer minimum fee is not satisfied",
|
|
81
78
|
LOW_LEVEL_CALL: "low-level delegate call failed",
|
|
82
79
|
INTEGRAL_CURVE_ZERO: "previous integral cannot be zero",
|
|
83
|
-
ODOS_FETCH: "Odos API Fetch Error",
|
|
84
80
|
YOU_CANCELED_REQUEST: "You canceled the request",
|
|
85
81
|
YOU_CANCELED_TRANSACTION_REQUEST: "You cancelled the transaction request.",
|
|
86
82
|
SLIPPAGE_LIMIT: "Slippage Limit Exceeded",
|
|
87
83
|
SLIPPAGE_LIMIT_1: "Slippage screwed you",
|
|
88
84
|
QUOTE_EXPIRED: "Quote has expired",
|
|
89
85
|
REVERT_NO_STRING: "Transaction reverted without a reason string",
|
|
90
|
-
UNISWAP_NOT_ENOUGH_LIQUIDITY: "Not Enough Liquidity",
|
|
91
86
|
CONNECTION_FAILED: "Failed to connect",
|
|
92
87
|
FAILED_TO_SWITCH_NETWORKS: "Please switch networks in your wallet settings",
|
|
93
88
|
INVALID_FROM: "Invalid from token",
|
|
@@ -104,17 +99,11 @@ var e = {
|
|
|
104
99
|
LEDGER_BLIDN_SIGNING_NOT_ALLOWED: "Ledger device: UNKNOWN_ERROR (0x6a8c)",
|
|
105
100
|
LEDGER_IS_NOT_AVAILABLE: "Ledger device: UNKNOWN_ERROR",
|
|
106
101
|
LEDGER_ACCESS_DENIED: "Access denied to use Ledger device.",
|
|
107
|
-
ODOS_SWAP_FAILED: "Odos swap call failed",
|
|
108
|
-
ONEINCH_SWAP_FAILED: "One inch swap failed",
|
|
109
102
|
GAS_ESTIMATION_ERROR: "Failed Gas Estimates Response",
|
|
110
103
|
GAS_ESTIMATE_INCORRECT_PARAMETERS: "Incorrect Parameters for Gas Estimate",
|
|
111
104
|
CONNECTIVITY_ERROR: "Request failed with status code 500",
|
|
112
105
|
TRANSACTION_FAILED: "Transaction Failed: Revert",
|
|
113
106
|
NO_SWAP_QUOTES: "No swap quotes available",
|
|
114
|
-
NO_UNISWAP_PRICE: "Cannot get Uniswap Price",
|
|
115
|
-
NO_ODOS_PRICE: "Cannot get Odos Price",
|
|
116
|
-
NO_ONEINCH_PRICE: "Cannot get OneInch Price",
|
|
117
|
-
NO_LIFI_PRICE: "Cannot get LiFi Price",
|
|
118
107
|
FEES_OVER_TRANSACTION_VALUE: "Fees are over transaction value. Please, increase the amount",
|
|
119
108
|
GAS_STATION_NOT_AVAILABLE: "Gas Station Not Available",
|
|
120
109
|
INBALANCE_IN_TOKEN: "Inbalance in token detected",
|
|
@@ -151,11 +140,16 @@ var e = {
|
|
|
151
140
|
RELAY_FEE_OVER_WITHDRAW_AMOUNT: "Relay Fee is over withdraw amount",
|
|
152
141
|
TRON_CONFIRMATION_DECLINED: "Confirmation declined by user",
|
|
153
142
|
BLACKLISTED_INPUT_COMMITMENT_ADDRESS: "One of the source addresses is restricted from private transactions",
|
|
154
|
-
ACCOUNT_RESOURCE_INSUFFICIENT_ERROR: "Account resource insufficient error"
|
|
155
|
-
|
|
143
|
+
ACCOUNT_RESOURCE_INSUFFICIENT_ERROR: "Account resource insufficient error",
|
|
144
|
+
TRON_ROOT_HASH_STALE: "Hinkal Root Hash Is Stale For Insertion",
|
|
145
|
+
TRON_TX_IN_FLIGHT: "Another Hinkal transaction is in progress",
|
|
146
|
+
SOLANA_CONFIRMATION_TIMEOUT: "Transaction was not confirmed in",
|
|
147
|
+
BRIDGE_ARRIVAL_TIMEOUT: "Bridge did not land on destination temp wallet"
|
|
148
|
+
}, i = "Not enough memory. Please, close some tabs/applications to free up memory and try again", a = "Your transaction didn’t go through due to price slippage. Try increasing your slippage tolerance", o = {
|
|
156
149
|
USER_REJECTED_TRANSACTION: "You cancelled the transaction",
|
|
157
150
|
SOME_ERROR: "Some error has occurred. Please try again in a few minutes. If the issue persists, please report it in Discord",
|
|
158
151
|
TOO_HIGH_AMOUNT: "The amount you provided is too high, please adjust the amount",
|
|
152
|
+
NOT_ENOUGH_TOKENS: "Transfer amount exceeds balance. Try lowering amount or add funds and retry.",
|
|
159
153
|
WC_NO_MATCHING_KEY: "Wallet Connect error. Please, try again",
|
|
160
154
|
RPC_PROVIDER_LIMIT_ERROR: "Rate Limit: please, use different rpc provider in your wallet",
|
|
161
155
|
INSUFFICIENT_FUNDS_GAS: "Your balance is too low to cover the transaction fees. Please add funds to proceed",
|
|
@@ -178,9 +172,7 @@ var e = {
|
|
|
178
172
|
USER_REJECTED_SIGN2: "You canceled the request",
|
|
179
173
|
USER_REJECTED_RPC: "You canceled the request",
|
|
180
174
|
USER_DENIED_TRANSACTION_SIGNATURE: "You canceled the request",
|
|
181
|
-
|
|
182
|
-
ODOS_SWAP_FAILED: "Your Odos Swap transaction didn’t go through. Please try again",
|
|
183
|
-
ONEINCH_SWAP_FAILED: "Your 1inch Swap transaction didn’t go through. Please try again",
|
|
175
|
+
USER_DENIED_REQUEST_SIGNATURE: "You canceled the request",
|
|
184
176
|
CONNECT_ERROR2: "Oops, there are connectivity issues. Please check your internet connection and try again",
|
|
185
177
|
WALLET_CONNECT_MATCHING_KEYS: "An internal WalletConnect error occurred. Please try reconnecting",
|
|
186
178
|
SIGNATURE_UNSUPPORTED_CHAINS: "The transaction couldn’t be signed: this network is not supported",
|
|
@@ -198,10 +190,10 @@ var e = {
|
|
|
198
190
|
LEDGER_BLIDN_SIGNING_NOT_ALLOWED: "Your ledger is not allowed to sign transactions. Please allow blind signing",
|
|
199
191
|
LEDGER_IS_NOT_AVAILABLE: "Access denied to use Ledger device.",
|
|
200
192
|
LEDGER_ACCESS_DENIED: "Access denied to use Ledger device.",
|
|
201
|
-
INBALANCE_IN_TOKEN:
|
|
202
|
-
OKX_MIN_RETURN_NOT_REACHED:
|
|
203
|
-
SOLANA_RECEIVED_LOWER_THAN_EXPECTED:
|
|
204
|
-
MIN_RETURNED_NOT_REACHED:
|
|
193
|
+
INBALANCE_IN_TOKEN: a,
|
|
194
|
+
OKX_MIN_RETURN_NOT_REACHED: a,
|
|
195
|
+
SOLANA_RECEIVED_LOWER_THAN_EXPECTED: a,
|
|
196
|
+
MIN_RETURNED_NOT_REACHED: a,
|
|
205
197
|
BALANCE_EQUATION_FAILED: "There's an issue with the balance calculation. Please adjust your transaction parameters",
|
|
206
198
|
SLIPPAGE_LIMIT_1: "Your transaction didn’t go through due to price slippage. Adjust slippage settings and retry",
|
|
207
199
|
CANNOT_ESTIMATE_GAS: "Unable to estimate the gas required. Please set the gas limit manually",
|
|
@@ -209,9 +201,9 @@ var e = {
|
|
|
209
201
|
GAS_STATION_NOT_AVAILABLE: "The Gas Station service is currently unavailable. Please submit a ticket on Hinkal discord server",
|
|
210
202
|
TIMESTAMP_STALE: "This transaction is outdated. Please initiate a new transaction",
|
|
211
203
|
ALREADY_SUBSCRIBED: "This email is already subscribed to the Hinkal newsletter",
|
|
212
|
-
OUT_OF_MEMORY:
|
|
213
|
-
OUT_OF_MEMORY2:
|
|
214
|
-
OUT_OF_MEMORY3:
|
|
204
|
+
OUT_OF_MEMORY: i,
|
|
205
|
+
OUT_OF_MEMORY2: i,
|
|
206
|
+
OUT_OF_MEMORY3: i,
|
|
215
207
|
INVALID_RECOVERY_PHRASE: "Invalid recovery phrase",
|
|
216
208
|
PHRASES_DONT_MATCH: "Phrases do not match. You can go back and verify your recovery phrase.",
|
|
217
209
|
PASSWORDS_DONT_MATCH: "Passwords do not match",
|
|
@@ -231,11 +223,17 @@ var e = {
|
|
|
231
223
|
INVALID_RELAYER_FEE: "The transaction fee changed while submitting. Please try again.",
|
|
232
224
|
REQUEST_PENDING: "A request is already pending in your wallet. Please confirm to connect.",
|
|
233
225
|
BLACKLISTED_INPUT_COMMITMENT_ADDRESS: "The funds you’re trying to use have been flagged as sanctioned.",
|
|
234
|
-
NO_SWAP_QUOTES: "No swap route available for this token pair on the selected network at the moment. Please try again later or adjust the swap parameters."
|
|
235
|
-
|
|
226
|
+
NO_SWAP_QUOTES: "No swap route available for this token pair on the selected network at the moment. Please try again later or adjust the swap parameters.",
|
|
227
|
+
TRON_ROOT_HASH_STALE: "Another transaction was processed just before yours. Please try again",
|
|
228
|
+
TRON_TX_IN_FLIGHT: "Another transaction is currently being processed. Please try again in a few seconds",
|
|
229
|
+
NO_LIFI_PRICE: "Li-Fi provider couldn't fetch the price. please, retry in a few seconds.",
|
|
230
|
+
SOLANA_CONFIRMATION_TIMEOUT: "Network didn't confirm your transfer in time. It may still be confirmed - please, check Solscan before retrying.",
|
|
231
|
+
BRIDGE_ARRIVAL_TIMEOUT: "The bridge is taking longer than usual. Your funds left the source chain and are not lost - once they arrive, claim them from Recovery Funds."
|
|
232
|
+
}, s = {
|
|
236
233
|
UTXO_LIMITATIONS: "Your transaction exceeds the UTXO limit",
|
|
237
234
|
INSUFFICIENT_BALANCE_FOR_FEES: "Fees are high right now and would consume a large portion of your balance. Consider reducing the amount or retrying later.",
|
|
238
|
-
HIGH_FEE_WARNING: "Total fees exceed your available balance. Consider adding funds or retry later when fees decrease."
|
|
235
|
+
HIGH_FEE_WARNING: "Total fees exceed your available balance. Consider adding funds or retry later when fees decrease.",
|
|
236
|
+
INSUFFICIENT_FUNDS_FOR_RECOVERY_FEES: "Insufficient funds to cover recovery fees"
|
|
239
237
|
};
|
|
240
238
|
//#endregion
|
|
241
|
-
export {
|
|
239
|
+
export { s as DIRECTLY_SHOW_MESSAGE_ERROR_CODES, o as UserFriendlyErrorCodes, n as gasErrorCodes, t as insufficientResourcesErrorCodes, r as transactionErrorCodes };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require(`./error-codes.constants.cjs`),t=require(`./customErrors/ErrorWithAmount.cjs`),n=require(`./customErrors/FeeOverTransactionValueError.cjs`),r=require(`./types.cjs`),i=require(`./customErrors/customErrors.helpers.cjs`);require(`./customErrors/index.cjs`);const a=require(`../types/transaction.types.cjs`);require(`../types/index.cjs`);const o=require(`./isInsufficientFundsError.cjs`);var s=e=>{
|
|
1
|
+
const e=require(`./error-codes.constants.cjs`),t=require(`./customErrors/ErrorWithAmount.cjs`),n=require(`./customErrors/FeeOverTransactionValueError.cjs`),r=require(`./types.cjs`),i=require(`./customErrors/customErrors.helpers.cjs`);require(`./customErrors/index.cjs`);const a=require(`../types/transaction.types.cjs`);require(`../types/index.cjs`);const o=require(`./isInsufficientFundsError.cjs`);var s=(e,t)=>{let n=t.reduce((e,t)=>{if(!(typeof e!=`object`||!e||!(t in e)))return e[t]},e);return typeof n==`string`&&n?n:void 0},c=e=>{if(typeof e==`object`&&e){let t=s(e,[`response`,`data`,`message`])??s(e,[`response`,`data`,`detail`])??s(e,[`data`,`message`])??s(e,[`data`,`detail`]);if(t)return t;if(`message`in e&&typeof e.message==`string`&&e.message)return e.message;if(`error`in e&&typeof e.error==`string`&&e.error)return e.error}if(e instanceof Error)return e.message;if(typeof e==`string`)return e},l=t=>{switch(t){case r.ErrorCategory.DEPOSIT:return`Deposit failed`;case r.ErrorCategory.SWAP:return`Swap failed`;case r.ErrorCategory.BRIDGE:return`Bridge failed`;case r.ErrorCategory.WITHDRAW:return`Send failed`;case r.ErrorCategory.Fund:return`Unshield failed`;case r.ErrorCategory.Receive:return`Shield failed`;case r.ErrorCategory.DappTransaction:return`DApp transaction failed`;case r.ErrorCategory.Approve:return`Approval failed`;default:return e.transactionErrorCodes.UNKNOWN}},u=(r,a)=>{if(r instanceof n.FeeOverTransactionValueError)return i.getGenericFeeOverTransactionValueErrorMessage(r,a);if(r instanceof t.ErrorWithAmount)return r.message;let s=c(r);if(s&&o.isInsufficientFundsError(s))return e.insufficientResourcesErrorCodes.INSUFFICIENT_FUNDS;if(s){let t=s.toLowerCase(),n=Object.keys(e.transactionErrorCodes).find(n=>t===e.transactionErrorCodes[n].toLowerCase());if(n&&n in e.UserFriendlyErrorCodes)return e.UserFriendlyErrorCodes[n];let r=Object.entries(e.transactionErrorCodes).find(([e,n])=>t.includes(n.toLowerCase()));if(r)return e.UserFriendlyErrorCodes[r[0]]??r[1];if(Object.values(e.DIRECTLY_SHOW_MESSAGE_ERROR_CODES).find(e=>t.includes(e.toLowerCase())))return s}return a?l(a):e.transactionErrorCodes.UNKNOWN},d=(e,t)=>{let n;switch(t){case a.TransactionRequestType.Send:case a.TransactionRequestType.ProxySend:n=r.ErrorCategory.WITHDRAW;break;case a.TransactionRequestType.SwapTokens:case a.TransactionRequestType.ProxySwapTokens:n=r.ErrorCategory.SWAP;break;case a.TransactionRequestType.ReceiveFromShieldedAccount:n=r.ErrorCategory.Receive;break;case a.TransactionRequestType.Fund:n=r.ErrorCategory.Fund;break;case a.TransactionRequestType.PrivateTransactionFromProxy:n=r.ErrorCategory.DappTransaction;break;default:n=void 0;break}return u(e,n)};exports.extractMessage=c,exports.getErrorMessage=u,exports.getErrorMessageFromTransactionRequest=d;
|
|
@@ -8,16 +8,29 @@ import { TransactionRequestType as c } from "../types/transaction.types.mjs";
|
|
|
8
8
|
import "../types/index.mjs";
|
|
9
9
|
import { isInsufficientFundsError as l } from "./isInsufficientFundsError.mjs";
|
|
10
10
|
//#region libs/shared/common/src/error-handling/get-error.message.ts
|
|
11
|
-
var u = (e) => {
|
|
11
|
+
var u = (e, t) => {
|
|
12
|
+
let n = t.reduce((e, t) => {
|
|
13
|
+
if (!(typeof e != "object" || !e || !(t in e))) return e[t];
|
|
14
|
+
}, e);
|
|
15
|
+
return typeof n == "string" && n ? n : void 0;
|
|
16
|
+
}, d = (e) => {
|
|
12
17
|
if (typeof e == "object" && e) {
|
|
13
|
-
|
|
14
|
-
|
|
18
|
+
let t = u(e, [
|
|
19
|
+
"response",
|
|
20
|
+
"data",
|
|
21
|
+
"message"
|
|
22
|
+
]) ?? u(e, [
|
|
23
|
+
"response",
|
|
24
|
+
"data",
|
|
25
|
+
"detail"
|
|
26
|
+
]) ?? u(e, ["data", "message"]) ?? u(e, ["data", "detail"]);
|
|
27
|
+
if (t) return t;
|
|
15
28
|
if ("message" in e && typeof e.message == "string" && e.message) return e.message;
|
|
16
29
|
if ("error" in e && typeof e.error == "string" && e.error) return e.error;
|
|
17
30
|
}
|
|
18
31
|
if (e instanceof Error) return e.message;
|
|
19
32
|
if (typeof e == "string") return e;
|
|
20
|
-
},
|
|
33
|
+
}, f = (e) => {
|
|
21
34
|
switch (e) {
|
|
22
35
|
case o.DEPOSIT: return "Deposit failed";
|
|
23
36
|
case o.SWAP: return "Swap failed";
|
|
@@ -29,23 +42,20 @@ var u = (e) => {
|
|
|
29
42
|
case o.Approve: return "Approval failed";
|
|
30
43
|
default: return r.UNKNOWN;
|
|
31
44
|
}
|
|
32
|
-
},
|
|
45
|
+
}, p = (o, c) => {
|
|
33
46
|
if (o instanceof a) return s(o, c);
|
|
34
|
-
if (o instanceof i)
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
if (f && l(f)) return n.INSUFFICIENT_FUNDS;
|
|
40
|
-
if (f) {
|
|
41
|
-
let n = f.toLowerCase(), i = Object.keys(r).find((e) => n === r[e].toLowerCase());
|
|
47
|
+
if (o instanceof i) return o.message;
|
|
48
|
+
let u = d(o);
|
|
49
|
+
if (u && l(u)) return n.INSUFFICIENT_FUNDS;
|
|
50
|
+
if (u) {
|
|
51
|
+
let n = u.toLowerCase(), i = Object.keys(r).find((e) => n === r[e].toLowerCase());
|
|
42
52
|
if (i && i in t) return t[i];
|
|
43
53
|
let a = Object.entries(r).find(([e, t]) => n.includes(t.toLowerCase()));
|
|
44
54
|
if (a) return t[a[0]] ?? a[1];
|
|
45
|
-
if (Object.values(e).find((e) => n.includes(e.toLowerCase()))) return
|
|
55
|
+
if (Object.values(e).find((e) => n.includes(e.toLowerCase()))) return u;
|
|
46
56
|
}
|
|
47
|
-
return c ?
|
|
48
|
-
},
|
|
57
|
+
return c ? f(c) : r.UNKNOWN;
|
|
58
|
+
}, m = (e, t) => {
|
|
49
59
|
let n;
|
|
50
60
|
switch (t) {
|
|
51
61
|
case c.Send:
|
|
@@ -69,7 +79,7 @@ var u = (e) => {
|
|
|
69
79
|
n = void 0;
|
|
70
80
|
break;
|
|
71
81
|
}
|
|
72
|
-
return
|
|
82
|
+
return p(e, n);
|
|
73
83
|
};
|
|
74
84
|
//#endregion
|
|
75
|
-
export {
|
|
85
|
+
export { d as extractMessage, p as getErrorMessage, m as getErrorMessageFromTransactionRequest };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
require(`./error-codes.constants.cjs`),require(`./customErrors/ErrorWithAmount.cjs`),require(`./customErrors/FeeOverTransactionValueError.cjs`),require(`./types.cjs`),require(`./customErrors/customErrors.helpers.cjs`),require(`./customErrors/ErrorWithTx.cjs`),require(`./customErrors/index.cjs`),require(`./logError.cjs`),require(`./logger.cjs`),require(`./get-error.message.cjs`);
|
|
1
|
+
require(`./error-codes.constants.cjs`),require(`./customErrors/ErrorWithAmount.cjs`),require(`./customErrors/FeeOverTransactionValueError.cjs`),require(`./types.cjs`),require(`./customErrors/customErrors.helpers.cjs`),require(`./customErrors/ErrorWithTx.cjs`),require(`./customErrors/index.cjs`),require(`./logError.cjs`),require(`./logger.cjs`),require(`./isInsufficientFundsError.cjs`),require(`./get-error.message.cjs`);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require(`./ERC20.json.cjs`),t=require(`./ERC721.json.cjs`),n=require(`./ERC1155.json.cjs`)
|
|
1
|
+
const e=require(`./ERC20.json.cjs`),t=require(`./ERC721.json.cjs`),n=require(`./ERC1155.json.cjs`);var r=e.default.abi,i=t.default.abi,a=n.default.abi;exports.ERC1155ABI=a,exports.ERC20ABI=r,exports.ERC721ABI=i;
|
|
@@ -104,116 +104,4 @@ declare const ERC1155ABI: ({
|
|
|
104
104
|
type: string;
|
|
105
105
|
anonymous?: undefined;
|
|
106
106
|
})[];
|
|
107
|
-
|
|
108
|
-
inputs: {
|
|
109
|
-
internalType: string;
|
|
110
|
-
name: string;
|
|
111
|
-
type: string;
|
|
112
|
-
}[];
|
|
113
|
-
name: string;
|
|
114
|
-
outputs: {
|
|
115
|
-
internalType: string;
|
|
116
|
-
name: string;
|
|
117
|
-
type: string;
|
|
118
|
-
}[];
|
|
119
|
-
stateMutability: string;
|
|
120
|
-
type: string;
|
|
121
|
-
} | {
|
|
122
|
-
inputs: {
|
|
123
|
-
components: {
|
|
124
|
-
internalType: string;
|
|
125
|
-
name: string;
|
|
126
|
-
type: string;
|
|
127
|
-
}[];
|
|
128
|
-
internalType: string;
|
|
129
|
-
name: string;
|
|
130
|
-
type: string;
|
|
131
|
-
}[];
|
|
132
|
-
name: string;
|
|
133
|
-
outputs: {
|
|
134
|
-
internalType: string;
|
|
135
|
-
name: string;
|
|
136
|
-
type: string;
|
|
137
|
-
}[];
|
|
138
|
-
stateMutability: string;
|
|
139
|
-
type: string;
|
|
140
|
-
})[];
|
|
141
|
-
declare const factoryABI: ({
|
|
142
|
-
anonymous: boolean;
|
|
143
|
-
inputs: {
|
|
144
|
-
indexed: boolean;
|
|
145
|
-
internalType: string;
|
|
146
|
-
name: string;
|
|
147
|
-
type: string;
|
|
148
|
-
}[];
|
|
149
|
-
name: string;
|
|
150
|
-
type: string;
|
|
151
|
-
outputs?: undefined;
|
|
152
|
-
stateMutability?: undefined;
|
|
153
|
-
} | {
|
|
154
|
-
inputs: {
|
|
155
|
-
internalType: string;
|
|
156
|
-
name: string;
|
|
157
|
-
type: string;
|
|
158
|
-
}[];
|
|
159
|
-
name: string;
|
|
160
|
-
outputs: {
|
|
161
|
-
internalType: string;
|
|
162
|
-
name: string;
|
|
163
|
-
type: string;
|
|
164
|
-
}[];
|
|
165
|
-
stateMutability: string;
|
|
166
|
-
type: string;
|
|
167
|
-
anonymous?: undefined;
|
|
168
|
-
})[];
|
|
169
|
-
declare const ISwapRouterABI: ({
|
|
170
|
-
inputs: {
|
|
171
|
-
internalType: string;
|
|
172
|
-
name: string;
|
|
173
|
-
type: string;
|
|
174
|
-
}[];
|
|
175
|
-
stateMutability: string;
|
|
176
|
-
type: string;
|
|
177
|
-
name?: undefined;
|
|
178
|
-
outputs?: undefined;
|
|
179
|
-
} | {
|
|
180
|
-
inputs: {
|
|
181
|
-
components: {
|
|
182
|
-
internalType: string;
|
|
183
|
-
name: string;
|
|
184
|
-
type: string;
|
|
185
|
-
}[];
|
|
186
|
-
internalType: string;
|
|
187
|
-
name: string;
|
|
188
|
-
type: string;
|
|
189
|
-
}[];
|
|
190
|
-
name: string;
|
|
191
|
-
outputs: {
|
|
192
|
-
internalType: string;
|
|
193
|
-
name: string;
|
|
194
|
-
type: string;
|
|
195
|
-
}[];
|
|
196
|
-
stateMutability: string;
|
|
197
|
-
type: string;
|
|
198
|
-
} | {
|
|
199
|
-
inputs: {
|
|
200
|
-
internalType: string;
|
|
201
|
-
name: string;
|
|
202
|
-
type: string;
|
|
203
|
-
}[];
|
|
204
|
-
name: string;
|
|
205
|
-
outputs: {
|
|
206
|
-
internalType: string;
|
|
207
|
-
name: string;
|
|
208
|
-
type: string;
|
|
209
|
-
}[];
|
|
210
|
-
stateMutability: string;
|
|
211
|
-
type: string;
|
|
212
|
-
} | {
|
|
213
|
-
stateMutability: string;
|
|
214
|
-
type: string;
|
|
215
|
-
inputs?: undefined;
|
|
216
|
-
name?: undefined;
|
|
217
|
-
outputs?: undefined;
|
|
218
|
-
})[];
|
|
219
|
-
export { quoterV2ABI, factoryABI, AmTokenABI, ERC20ABI, ERC721ABI, USDCABI, daiABI, USDRABI, USDR3CRVABI, USDTABI, WETHABI, BUSDABI, sanctionsListABI, optimismGasPriceOracleAbi, NodeInterfaceABI, ISwapRouterABI, ERC1155ABI, };
|
|
107
|
+
export { AmTokenABI, ERC20ABI, ERC721ABI, USDCABI, daiABI, USDRABI, USDR3CRVABI, USDTABI, WETHABI, BUSDABI, sanctionsListABI, optimismGasPriceOracleAbi, NodeInterfaceABI, ERC1155ABI, };
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import e from "./ERC20.json.mjs";
|
|
2
2
|
import t from "./ERC721.json.mjs";
|
|
3
3
|
import n from "./ERC1155.json.mjs";
|
|
4
|
-
import r from "./IQuoterV2.json.mjs";
|
|
5
|
-
import i from "./IUniswapV3Factory.json.mjs";
|
|
6
|
-
import a from "./ISwapRouter.json.mjs";
|
|
7
4
|
//#region libs/shared/common/src/externalABIs/index.ts
|
|
8
|
-
var
|
|
9
|
-
r.abi, i.abi, a.abi;
|
|
5
|
+
var r = e.abi, i = t.abi, a = n.abi;
|
|
10
6
|
//#endregion
|
|
11
|
-
export {
|
|
7
|
+
export { a as ERC1155ABI, r as ERC20ABI, i as ERC721ABI };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require(`../web3/etherFunctions.cjs`),t=require(`../../error-handling/logger.cjs`),n=require(`../utils/publicBalance.utils.cjs`);require(`../utils/index.cjs`),require(`../web3/index.cjs`);var
|
|
1
|
+
const e=require(`../web3/etherFunctions.cjs`),t=require(`../../error-handling/logger.cjs`),n=require(`../web3/events/getShieldedBalance.cjs`),r=require(`../utils/publicBalance.utils.cjs`);require(`../utils/index.cjs`),require(`../web3/index.cjs`);var i=async(i,a,o,s,c,l)=>{try{let t=await o.getEthereumAddressByChain(a),u=(await n.getShieldedBalances(o,new Map([[a,t]]),o.userKeys.getShieldedPrivateKey(),o.userKeys.getShieldedPublicKey())).get(a)??[];return await Promise.all(i.map(async t=>{let n=t.erc20TokenAddress.toLowerCase(),i=u.find(e=>e.token.erc20TokenAddress.toLowerCase()===n)?.balance??0n,a=(await r.getPublicBalance(c,s,t))?.balance??0n,o=l.get(n)??0,d=parseFloat(e.getAmountInToken(t,i))*o,f=parseFloat(e.getAmountInToken(t,a))*o;return{erc20Token:t,privateUsdBalance:d,publicUsdBalance:f,totalUsdBalance:d+f}}))}catch(e){return t.Logger.error(`Error getting gas token records`,e),[]}};exports.getGasTokenRecords=i;
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { getAmountInToken as e } from "../web3/etherFunctions.mjs";
|
|
2
2
|
import { Logger as t } from "../../error-handling/logger.mjs";
|
|
3
|
-
import {
|
|
3
|
+
import { getShieldedBalances as n } from "../web3/events/getShieldedBalance.mjs";
|
|
4
|
+
import { getPublicBalance as r } from "../utils/publicBalance.utils.mjs";
|
|
4
5
|
import "../utils/index.mjs";
|
|
5
6
|
import "../web3/index.mjs";
|
|
6
7
|
//#region libs/shared/common/src/functions/auto-deposit-back-helpers/get-gas-token-records.ts
|
|
7
|
-
var
|
|
8
|
+
var i = async (i, a, o, s, c, l) => {
|
|
8
9
|
try {
|
|
9
|
-
let t = await
|
|
10
|
-
return await Promise.all(
|
|
11
|
-
let
|
|
10
|
+
let t = await o.getEthereumAddressByChain(a), u = (await n(o, new Map([[a, t]]), o.userKeys.getShieldedPrivateKey(), o.userKeys.getShieldedPublicKey())).get(a) ?? [];
|
|
11
|
+
return await Promise.all(i.map(async (t) => {
|
|
12
|
+
let n = t.erc20TokenAddress.toLowerCase(), i = u.find((e) => e.token.erc20TokenAddress.toLowerCase() === n)?.balance ?? 0n, a = (await r(c, s, t))?.balance ?? 0n, o = l.get(n) ?? 0, d = parseFloat(e(t, i)) * o, f = parseFloat(e(t, a)) * o;
|
|
12
13
|
return {
|
|
13
14
|
erc20Token: t,
|
|
14
15
|
privateUsdBalance: d,
|
|
@@ -21,4 +22,4 @@ var r = async (r, i, a, o, s, c) => {
|
|
|
21
22
|
}
|
|
22
23
|
};
|
|
23
24
|
//#endregion
|
|
24
|
-
export {
|
|
25
|
+
export { i as getGasTokenRecords };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const e=require(`../utils/caseInsensitive.utils.cjs`),t=require(`../../error-handling/error-codes.constants.cjs`),n=require(`../../
|
|
1
|
+
const e=require(`../utils/caseInsensitive.utils.cjs`),t=require(`../../error-handling/error-codes.constants.cjs`),n=require(`../../error-handling/logger.cjs`),r=require(`../../types/external-action.types.cjs`),i=require(`../../types/offscreen.types.cjs`);require(`../../types/index.cjs`),require(`../../error-handling/index.cjs`);const a=require(`../pre-transaction/getFeeStructure.cjs`);require(`../pre-transaction/index.cjs`);const o=require(`../utils/convertEmporiumOpToCallInfo.cjs`),s=require(`../utils/postToOffscreen.cjs`);require(`../utils/index.cjs`);var c=async(c,l,u,d,f,p,m,h,g)=>{try{if(!((p.find(({erc20Token:t})=>e.caseInsensitiveEqual(t.erc20TokenAddress,c))?.totalUsdBalance??0)>=l)){let n=p.find(t=>t.totalUsdBalance<=l?!1:d.find(({erc20TokenAddress:n})=>e.caseInsensitiveEqual(n,t.erc20Token.erc20TokenAddress))?t.publicUsdBalance>l:!0);if(!n){s.postToOffscreen(i.MessagesFromOffscreen.AutoShieldTxStatus,{message:t.transactionErrorCodes.AUTO_SHIELD_INSUFFICIENT_GAS});return}c=n.erc20Token.erc20TokenAddress,m=await a.getFeeStructure(u,c,h,r.ExternalActionId.Emporium,f.map(e=>o.convertEmporiumOpToCallInfo(e,g,u)))}return{feeToken:c,feeStructure:m}}catch(e){n.Logger.error(`selectGasToken error`,{error:e});return}};exports.selectGasToken=c;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { caseInsensitiveEqual as e } from "../utils/caseInsensitive.utils.mjs";
|
|
2
2
|
import { transactionErrorCodes as t } from "../../error-handling/error-codes.constants.mjs";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { Logger as n } from "../../error-handling/logger.mjs";
|
|
4
|
+
import { ExternalActionId as r } from "../../types/external-action.types.mjs";
|
|
5
|
+
import { MessagesFromOffscreen as i } from "../../types/offscreen.types.mjs";
|
|
5
6
|
import "../../types/index.mjs";
|
|
6
|
-
import { Logger as i } from "../../error-handling/logger.mjs";
|
|
7
7
|
import "../../error-handling/index.mjs";
|
|
8
8
|
import { getFeeStructure as a } from "../pre-transaction/getFeeStructure.mjs";
|
|
9
9
|
import "../pre-transaction/index.mjs";
|
|
@@ -14,19 +14,19 @@ import "../utils/index.mjs";
|
|
|
14
14
|
var c = async (c, l, u, d, f, p, m, h, g) => {
|
|
15
15
|
try {
|
|
16
16
|
if (!((p.find(({ erc20Token: t }) => e(t.erc20TokenAddress, c))?.totalUsdBalance ?? 0) >= l)) {
|
|
17
|
-
let
|
|
18
|
-
if (!
|
|
19
|
-
s(
|
|
17
|
+
let n = p.find((t) => t.totalUsdBalance <= l ? !1 : d.find(({ erc20TokenAddress: n }) => e(n, t.erc20Token.erc20TokenAddress)) ? t.publicUsdBalance > l : !0);
|
|
18
|
+
if (!n) {
|
|
19
|
+
s(i.AutoShieldTxStatus, { message: t.AUTO_SHIELD_INSUFFICIENT_GAS });
|
|
20
20
|
return;
|
|
21
21
|
}
|
|
22
|
-
c =
|
|
22
|
+
c = n.erc20Token.erc20TokenAddress, m = await a(u, c, h, r.Emporium, f.map((e) => o(e, g, u)));
|
|
23
23
|
}
|
|
24
24
|
return {
|
|
25
25
|
feeToken: c,
|
|
26
26
|
feeStructure: m
|
|
27
27
|
};
|
|
28
28
|
} catch (e) {
|
|
29
|
-
|
|
29
|
+
n.error("selectGasToken error", { error: e });
|
|
30
30
|
return;
|
|
31
31
|
}
|
|
32
32
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
require(`./utils/abi.utils.cjs`),require(`./utils/serialize.utils.cjs`),require(`./utils/caseInsensitive.utils.cjs`),require(`./utils/amounts.utils.cjs`),require(`./web3/etherFunctions.cjs`),require(`./utils/time.utils.cjs`),require(`./utils/upToDateState.cjs`),require(`./utils/cacheFunctions.cjs`),require(`./utils/
|
|
1
|
+
require(`./utils/abi.utils.cjs`),require(`./utils/serialize.utils.cjs`),require(`./utils/caseInsensitive.utils.cjs`),require(`./utils/amounts.utils.cjs`),require(`./web3/etherFunctions.cjs`),require(`./utils/time.utils.cjs`),require(`./utils/upToDateState.cjs`),require(`./utils/cacheFunctions.cjs`),require(`./utils/encodeTokenWithId.cjs`),require(`./utils/enclaveHandshakeService.cjs`),require(`./utils/encryptInputForEnclave.cjs`),require(`./utils/solanaMint.utils.cjs`),require(`./utils/serialize-utxos.utils.cjs`),require(`./utils/customEnclaveFunctionsRegister.cjs`),require(`./utils/tron.utils.cjs`),require(`./utils/addresses.cjs`),require(`./web3/events/getInputUtxoAndBalance.cjs`),require(`./utils/legacyKeys.cjs`),require(`./utils/auth.utils.cjs`),require(`./utils/string.utils.cjs`),require(`./utils/token-check.utils.cjs`),require(`./utils/map.utils.cjs`),require(`./utils/mutexes.utils.cjs`),require(`./utils/erc20tokenFunctions.cjs`),require(`./web3/events/getShieldedBalance.cjs`),require(`./pre-transaction/outputUtxoProcessing.cjs`),require(`./utils/external-action.utils.cjs`),require(`./snarkjs/common.snarkjs.cjs`),require(`./pre-transaction/solana.cjs`),require(`./snarkjs/signedMessageHash.cjs`),require(`./pre-transaction/process-gas-estimates.cjs`),require(`./pre-transaction/getVolatileTransferAmount.cjs`),require(`./pre-transaction/constructAdminData.cjs`),require(`./utils/create-provider.cjs`),require(`./pre-transaction/calculateSolanaNullifierCount.cjs`),require(`./pre-transaction/convert-okx-instructions.cjs`),require(`./utils/process.utils.cjs`),require(`./pre-transaction/sendV0Transaction.cjs`),require(`./utils/bytes32.utils.cjs`),require(`./pre-transaction/getFeeStructure.cjs`),require(`./pre-transaction/getExternalSwapAddress.cjs`),require(`./pre-transaction/speculativeUtxo.cjs`),require(`./pre-transaction/buildCommitmentValidationData.cjs`),require(`./pre-transaction/index.cjs`),require(`./snarkjs/generateZkProof.cjs`),require(`./snarkjs/generateMainAndCommitmentZkProof.cjs`),require(`./web3/getContractMetadata.cjs`),require(`./utils/solana-program.utils.cjs`),require(`./snarkjs/fetchOnChainRootHashes.cjs`),require(`./utils/getContractAddress.cjs`),require(`./private-wallet/emporium.helpers.cjs`),require(`./snarkjs/constructGeneralZkProof.cjs`),require(`./utils/getSignerFromContract.cjs`),require(`./utils/tronSimulation.utils.cjs`),require(`./utils/resolve-sync.utils.cjs`),require(`./utils/cacheDevice.utils.cjs`),require(`./utils/involves-permit2-op.cjs`),require(`./utils/convertEmporiumOpToCallInfo.cjs`),require(`./utils/getRecipientInfoFromUserKeys.cjs`),require(`./utils/publicBalance.utils.cjs`),require(`./utils/postToOffscreen.cjs`),require(`./utils/fees.utils.cjs`),require(`./utils/proxyAvatar.utils.cjs`),require(`./utils/enclave-utxo-storage.cjs`),require(`./utils/enclave-signature-storage.cjs`),require(`./utils/tx-confirmation.utils.cjs`),require(`./utils/bridge-arrival.utils.cjs`),require(`./utils/solana-sponsored.utils.cjs`),require(`./utils/temp-wallet.utils.cjs`),require(`./utils/mnemonics.cjs`),require(`./utils/nearIntents.utils.cjs`),require(`./utils/index.cjs`),require(`./web3/lifiAPI.cjs`),require(`./web3/okxAPI.cjs`),require(`./web3/index.cjs`),require(`./snarkjs/constructSolanaZkProof.cjs`),require(`./snarkjs/index.cjs`),require(`./private-wallet/emporium.swap.helpers.cjs`),require(`./private-wallet/index.cjs`),require(`./auto-deposit-back-helpers/get-tokens-to-deposit-back.cjs`),require(`./auto-deposit-back-helpers/get-gas-token-records.cjs`),require(`./auto-deposit-back-helpers/select-gas-token.cjs`),require(`./auto-deposit-back-helpers/update-hinkal.cjs`),require(`./auto-deposit-back-helpers/index.cjs`);
|
|
@@ -6,15 +6,16 @@ import "./web3/etherFunctions.mjs";
|
|
|
6
6
|
import "./utils/time.utils.mjs";
|
|
7
7
|
import "./utils/upToDateState.mjs";
|
|
8
8
|
import "./utils/cacheFunctions.mjs";
|
|
9
|
+
import "./utils/encodeTokenWithId.mjs";
|
|
9
10
|
import "./utils/enclaveHandshakeService.mjs";
|
|
10
11
|
import "./utils/encryptInputForEnclave.mjs";
|
|
11
12
|
import "./utils/solanaMint.utils.mjs";
|
|
12
|
-
import "./utils/customEnclaveFunctionsRegister.mjs";
|
|
13
13
|
import "./utils/serialize-utxos.utils.mjs";
|
|
14
|
-
import "./utils/
|
|
14
|
+
import "./utils/customEnclaveFunctionsRegister.mjs";
|
|
15
15
|
import "./utils/tron.utils.mjs";
|
|
16
|
+
import "./utils/addresses.mjs";
|
|
16
17
|
import "./web3/events/getInputUtxoAndBalance.mjs";
|
|
17
|
-
import "./utils/
|
|
18
|
+
import "./utils/legacyKeys.mjs";
|
|
18
19
|
import "./utils/auth.utils.mjs";
|
|
19
20
|
import "./utils/string.utils.mjs";
|
|
20
21
|
import "./utils/token-check.utils.mjs";
|
|
@@ -24,7 +25,6 @@ import "./utils/erc20tokenFunctions.mjs";
|
|
|
24
25
|
import "./web3/events/getShieldedBalance.mjs";
|
|
25
26
|
import "./pre-transaction/outputUtxoProcessing.mjs";
|
|
26
27
|
import "./utils/external-action.utils.mjs";
|
|
27
|
-
import "./utils/bit.operations.mjs";
|
|
28
28
|
import "./snarkjs/common.snarkjs.mjs";
|
|
29
29
|
import "./pre-transaction/solana.mjs";
|
|
30
30
|
import "./snarkjs/signedMessageHash.mjs";
|
|
@@ -32,44 +32,45 @@ import "./pre-transaction/process-gas-estimates.mjs";
|
|
|
32
32
|
import "./pre-transaction/getVolatileTransferAmount.mjs";
|
|
33
33
|
import "./pre-transaction/constructAdminData.mjs";
|
|
34
34
|
import "./utils/create-provider.mjs";
|
|
35
|
+
import "./pre-transaction/calculateSolanaNullifierCount.mjs";
|
|
35
36
|
import "./pre-transaction/convert-okx-instructions.mjs";
|
|
36
|
-
import "./web3/getSolanaPriorityFee.mjs";
|
|
37
37
|
import "./utils/process.utils.mjs";
|
|
38
38
|
import "./pre-transaction/sendV0Transaction.mjs";
|
|
39
39
|
import "./utils/bytes32.utils.mjs";
|
|
40
|
-
import "./pre-transaction/recipientUtxoProcessing.mjs";
|
|
41
|
-
import "./pre-transaction/ensureAmountChanges.mjs";
|
|
42
40
|
import "./pre-transaction/getFeeStructure.mjs";
|
|
43
|
-
import "./pre-transaction/
|
|
41
|
+
import "./pre-transaction/getExternalSwapAddress.mjs";
|
|
42
|
+
import "./pre-transaction/speculativeUtxo.mjs";
|
|
44
43
|
import "./pre-transaction/buildCommitmentValidationData.mjs";
|
|
45
44
|
import "./pre-transaction/index.mjs";
|
|
46
45
|
import "./snarkjs/generateZkProof.mjs";
|
|
47
46
|
import "./snarkjs/generateMainAndCommitmentZkProof.mjs";
|
|
47
|
+
import "./web3/getContractMetadata.mjs";
|
|
48
|
+
import "./utils/solana-program.utils.mjs";
|
|
49
|
+
import "./snarkjs/fetchOnChainRootHashes.mjs";
|
|
50
|
+
import "./utils/getContractAddress.mjs";
|
|
51
|
+
import "./private-wallet/emporium.helpers.mjs";
|
|
52
|
+
import "./snarkjs/constructGeneralZkProof.mjs";
|
|
53
|
+
import "./utils/getSignerFromContract.mjs";
|
|
54
|
+
import "./utils/tronSimulation.utils.mjs";
|
|
48
55
|
import "./utils/resolve-sync.utils.mjs";
|
|
49
|
-
import "./utils/reloadPage.mjs";
|
|
50
56
|
import "./utils/cacheDevice.utils.mjs";
|
|
51
57
|
import "./utils/involves-permit2-op.mjs";
|
|
52
58
|
import "./utils/convertEmporiumOpToCallInfo.mjs";
|
|
53
59
|
import "./utils/getRecipientInfoFromUserKeys.mjs";
|
|
54
60
|
import "./utils/publicBalance.utils.mjs";
|
|
55
61
|
import "./utils/postToOffscreen.mjs";
|
|
56
|
-
import "./utils/getContractAddress.mjs";
|
|
57
|
-
import "./utils/getUtxosFromReceipt.utils.mjs";
|
|
58
|
-
import "./utils/getUtxosFromReceiptSolana.mjs";
|
|
59
62
|
import "./utils/fees.utils.mjs";
|
|
63
|
+
import "./utils/proxyAvatar.utils.mjs";
|
|
64
|
+
import "./utils/enclave-utxo-storage.mjs";
|
|
60
65
|
import "./utils/enclave-signature-storage.mjs";
|
|
61
66
|
import "./utils/tx-confirmation.utils.mjs";
|
|
62
|
-
import "./utils/
|
|
63
|
-
import "./utils/
|
|
67
|
+
import "./utils/bridge-arrival.utils.mjs";
|
|
68
|
+
import "./utils/solana-sponsored.utils.mjs";
|
|
69
|
+
import "./utils/temp-wallet.utils.mjs";
|
|
64
70
|
import "./utils/mnemonics.mjs";
|
|
65
71
|
import "./utils/nearIntents.utils.mjs";
|
|
66
72
|
import "./utils/index.mjs";
|
|
67
|
-
import "./
|
|
68
|
-
import "./private-wallet/emporium.helpers.mjs";
|
|
69
|
-
import "./snarkjs/constructGeneralZkProof.mjs";
|
|
70
|
-
import "./web3/uniswapAPI.mjs";
|
|
71
|
-
import "./web3/odosAPI.mjs";
|
|
72
|
-
import "./web3/oneInchAPI.mjs";
|
|
73
|
+
import "./web3/lifiAPI.mjs";
|
|
73
74
|
import "./web3/okxAPI.mjs";
|
|
74
75
|
import "./web3/index.mjs";
|
|
75
76
|
import "./snarkjs/constructSolanaZkProof.mjs";
|