@initia/initia.js 1.0.21 → 2.0.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +231 -163
- package/dist/abi-helpers-DdwdqhMQ.mjs +51 -0
- package/dist/abi-helpers-DdwdqhMQ.mjs.map +1 -0
- package/dist/address-DwAkzgJk.mjs +156 -0
- package/dist/address-DwAkzgJk.mjs.map +1 -0
- package/dist/address-profile-DjdaEBxo.d.mts +112 -0
- package/dist/address-profile-DlAFvgdg.mjs +241 -0
- package/dist/address-profile-DlAFvgdg.mjs.map +1 -0
- package/dist/amino-CMQN7Frn.mjs +220 -0
- package/dist/amino-CMQN7Frn.mjs.map +1 -0
- package/dist/amino_pb-Bi6YDY_U.mjs +88 -0
- package/dist/amino_pb-Bi6YDY_U.mjs.map +1 -0
- package/dist/amount-B0J9TTNF.mjs +90 -0
- package/dist/amount-B0J9TTNF.mjs.map +1 -0
- package/dist/any-DElm7qF7.mjs +19 -0
- package/dist/any-DElm7qF7.mjs.map +1 -0
- package/dist/auth_pb-DN4URGLh.mjs +26 -0
- package/dist/auth_pb-DN4URGLh.mjs.map +1 -0
- package/dist/auth_pb-DfXfdvrY.mjs +16 -0
- package/dist/auth_pb-DfXfdvrY.mjs.map +1 -0
- package/dist/base-provider-CLnd7kte.d.mts +68 -0
- package/dist/base-provider-LNp6K7Mt.mjs +96 -0
- package/dist/base-provider-LNp6K7Mt.mjs.map +1 -0
- package/dist/bcs-DiRcL4n9.mjs +533 -0
- package/dist/bcs-DiRcL4n9.mjs.map +1 -0
- package/dist/bridge-DL-q-7P7.mjs +1222 -0
- package/dist/bridge-DL-q-7P7.mjs.map +1 -0
- package/dist/bridge-cQoOjppA.d.mts +606 -0
- package/dist/broadcast-De8MdmYa.mjs +974 -0
- package/dist/broadcast-De8MdmYa.mjs.map +1 -0
- package/dist/chain-utils-C61cU5nd.mjs +139 -0
- package/dist/chain-utils-C61cU5nd.mjs.map +1 -0
- package/dist/codegen/cli.d.mts +1 -0
- package/dist/codegen/cli.mjs +274 -0
- package/dist/codegen/cli.mjs.map +1 -0
- package/dist/coin-DPWbtAFA.mjs +543 -0
- package/dist/coin-DPWbtAFA.mjs.map +1 -0
- package/dist/coin_pb--WuIu4sX.mjs +25 -0
- package/dist/coin_pb--WuIu4sX.mjs.map +1 -0
- package/dist/composite-provider-DbxNrdny.mjs +203 -0
- package/dist/composite-provider-DbxNrdny.mjs.map +1 -0
- package/dist/constants-W6V0E-3W.mjs +42 -0
- package/dist/constants-W6V0E-3W.mjs.map +1 -0
- package/dist/contract-Dpvu4wLO.mjs +657 -0
- package/dist/contract-Dpvu4wLO.mjs.map +1 -0
- package/dist/cosmos-Bqh8qNfP.mjs +540 -0
- package/dist/cosmos-Bqh8qNfP.mjs.map +1 -0
- package/dist/cosmos-registry-provider-DCrEEhJ-.d.mts +123 -0
- package/dist/cw20-BTpdgMXC.mjs +63 -0
- package/dist/cw20-BTpdgMXC.mjs.map +1 -0
- package/dist/decode-CXGawqIZ.mjs +29 -0
- package/dist/decode-CXGawqIZ.mjs.map +1 -0
- package/dist/entry.bridge.browser.d.mts +21 -0
- package/dist/entry.bridge.browser.mjs +25 -0
- package/dist/entry.bridge.browser.mjs.map +1 -0
- package/dist/entry.bridge.node.d.mts +21 -0
- package/dist/entry.bridge.node.mjs +25 -0
- package/dist/entry.bridge.node.mjs.map +1 -0
- package/dist/entry.browser.d.mts +49 -0
- package/dist/entry.browser.mjs +46 -0
- package/dist/entry.browser.mjs.map +1 -0
- package/dist/entry.chain.initia.browser.d.mts +8 -0
- package/dist/entry.chain.initia.browser.mjs +17 -0
- package/dist/entry.chain.initia.browser.mjs.map +1 -0
- package/dist/entry.chain.initia.node.d.mts +8 -0
- package/dist/entry.chain.initia.node.mjs +17 -0
- package/dist/entry.chain.initia.node.mjs.map +1 -0
- package/dist/entry.chain.minievm.browser.d.mts +8 -0
- package/dist/entry.chain.minievm.browser.mjs +17 -0
- package/dist/entry.chain.minievm.browser.mjs.map +1 -0
- package/dist/entry.chain.minievm.node.d.mts +8 -0
- package/dist/entry.chain.minievm.node.mjs +17 -0
- package/dist/entry.chain.minievm.node.mjs.map +1 -0
- package/dist/entry.chain.minimove.browser.d.mts +8 -0
- package/dist/entry.chain.minimove.browser.mjs +17 -0
- package/dist/entry.chain.minimove.browser.mjs.map +1 -0
- package/dist/entry.chain.minimove.node.d.mts +8 -0
- package/dist/entry.chain.minimove.node.mjs +17 -0
- package/dist/entry.chain.minimove.node.mjs.map +1 -0
- package/dist/entry.chain.miniwasm.browser.d.mts +8 -0
- package/dist/entry.chain.miniwasm.browser.mjs +17 -0
- package/dist/entry.chain.miniwasm.browser.mjs.map +1 -0
- package/dist/entry.chain.miniwasm.node.d.mts +8 -0
- package/dist/entry.chain.miniwasm.node.mjs +17 -0
- package/dist/entry.chain.miniwasm.node.mjs.map +1 -0
- package/dist/entry.client.browser.d.mts +3 -0
- package/dist/entry.client.browser.mjs +6 -0
- package/dist/entry.client.node-clFi8rmF.d.mts +1 -0
- package/dist/entry.client.node.d.mts +3 -0
- package/dist/entry.client.node.mjs +6 -0
- package/dist/entry.codegen.d.mts +251 -0
- package/dist/entry.codegen.mjs +2 -0
- package/dist/entry.cosmos.d.mts +2 -0
- package/dist/entry.cosmos.mjs +355 -0
- package/dist/entry.cosmos.mjs.map +1 -0
- package/dist/entry.events.d.mts +338 -0
- package/dist/entry.events.mjs +383 -0
- package/dist/entry.events.mjs.map +1 -0
- package/dist/entry.evm.d.mts +544 -0
- package/dist/entry.evm.mjs +761 -0
- package/dist/entry.evm.mjs.map +1 -0
- package/dist/entry.modules.d.mts +2 -0
- package/dist/entry.modules.mjs +7 -0
- package/dist/entry.move.d.mts +523 -0
- package/dist/entry.move.mjs +7 -0
- package/dist/entry.msgs.d.mts +2 -0
- package/dist/entry.msgs.mjs +3 -0
- package/dist/entry.node.d.mts +118 -0
- package/dist/entry.node.mjs +278 -0
- package/dist/entry.node.mjs.map +1 -0
- package/dist/entry.provider.d.mts +355 -0
- package/dist/entry.provider.mjs +416 -0
- package/dist/entry.provider.mjs.map +1 -0
- package/dist/entry.signer.d.mts +2 -0
- package/dist/entry.signer.mjs +674 -0
- package/dist/entry.signer.mjs.map +1 -0
- package/dist/entry.tx.d.mts +2 -0
- package/dist/entry.tx.mjs +6 -0
- package/dist/entry.usernames.d.mts +42 -0
- package/dist/entry.usernames.mjs +2 -0
- package/dist/entry.util.d.mts +103 -0
- package/dist/entry.util.mjs +70 -0
- package/dist/entry.util.mjs.map +1 -0
- package/dist/entry.vip.d.mts +1917 -0
- package/dist/entry.vip.mjs +3793 -0
- package/dist/entry.vip.mjs.map +1 -0
- package/dist/entry.wasm.d.mts +447 -0
- package/dist/entry.wasm.mjs +600 -0
- package/dist/entry.wasm.mjs.map +1 -0
- package/dist/erc20-CDs3j7vt.mjs +168 -0
- package/dist/erc20-CDs3j7vt.mjs.map +1 -0
- package/dist/errors-CN1MFOLv.mjs +253 -0
- package/dist/errors-CN1MFOLv.mjs.map +1 -0
- package/dist/evm-rpc-BxpgXIAF.mjs +338 -0
- package/dist/evm-rpc-BxpgXIAF.mjs.map +1 -0
- package/dist/fetch-Bq_aay6V.mjs +55 -0
- package/dist/fetch-Bq_aay6V.mjs.map +1 -0
- package/dist/fungible-asset-aHBTYpoT.mjs +64 -0
- package/dist/fungible-asset-aHBTYpoT.mjs.map +1 -0
- package/dist/get-tx-0P40z_A4.mjs +99 -0
- package/dist/get-tx-0P40z_A4.mjs.map +1 -0
- package/dist/grpc-client-DGyZjGcT.mjs +254 -0
- package/dist/grpc-client-DGyZjGcT.mjs.map +1 -0
- package/dist/hash-D40mxOlF.mjs +14 -0
- package/dist/hash-D40mxOlF.mjs.map +1 -0
- package/dist/hash-Doo89wm3.d.mts +31 -0
- package/dist/headers-CMO7ia_D.mjs +83 -0
- package/dist/headers-CMO7ia_D.mjs.map +1 -0
- package/dist/http-client-BrdVurTg.mjs +40 -0
- package/dist/http-client-BrdVurTg.mjs.map +1 -0
- package/dist/initia-B8l_x6sT.mjs +426 -0
- package/dist/initia-B8l_x6sT.mjs.map +1 -0
- package/dist/initia-Cj4bZ1dR.mjs +26 -0
- package/dist/initia-Cj4bZ1dR.mjs.map +1 -0
- package/dist/json-CGak0DqP.mjs +41 -0
- package/dist/json-CGak0DqP.mjs.map +1 -0
- package/dist/minievm-BAnGHa00.mjs +39 -0
- package/dist/minievm-BAnGHa00.mjs.map +1 -0
- package/dist/minievm-DZ8AhnD8.mjs +61 -0
- package/dist/minievm-DZ8AhnD8.mjs.map +1 -0
- package/dist/minimove-B8U85g-_.mjs +23 -0
- package/dist/minimove-B8U85g-_.mjs.map +1 -0
- package/dist/minimove-BBXTyhIv.mjs +24 -0
- package/dist/minimove-BBXTyhIv.mjs.map +1 -0
- package/dist/miniwasm-CB0XfStg.mjs +50 -0
- package/dist/miniwasm-CB0XfStg.mjs.map +1 -0
- package/dist/miniwasm-QdyYzmQ1.mjs +139 -0
- package/dist/miniwasm-QdyYzmQ1.mjs.map +1 -0
- package/dist/move-BaCv0oRX.mjs +64 -0
- package/dist/move-BaCv0oRX.mjs.map +1 -0
- package/dist/msg_pb-DxYxctLM.mjs +11 -0
- package/dist/msg_pb-DxYxctLM.mjs.map +1 -0
- package/dist/pagination_pb-DlkDYAcN.mjs +18 -0
- package/dist/pagination_pb-DlkDYAcN.mjs.map +1 -0
- package/dist/public-key-DV-uGaUC.mjs +550 -0
- package/dist/public-key-DV-uGaUC.mjs.map +1 -0
- package/dist/query_pb-cZ3szo3y.mjs +20 -0
- package/dist/query_pb-cZ3szo3y.mjs.map +1 -0
- package/dist/registry-provider-NzblVZQr.mjs +368 -0
- package/dist/registry-provider-NzblVZQr.mjs.map +1 -0
- package/dist/resolve-DdtY7KDz.mjs +50 -0
- package/dist/resolve-DdtY7KDz.mjs.map +1 -0
- package/dist/rolldown-runtime-wcPFST8Q.mjs +13 -0
- package/dist/service-BaMjxPNo.mjs +412 -0
- package/dist/service-BaMjxPNo.mjs.map +1 -0
- package/dist/service-CVFxsMp_.d.mts +151 -0
- package/dist/service_pb-Be-O-2-c.mjs +121 -0
- package/dist/service_pb-Be-O-2-c.mjs.map +1 -0
- package/dist/sign-DqagxLcg.mjs +212 -0
- package/dist/sign-DqagxLcg.mjs.map +1 -0
- package/dist/transport-common-BsPYcFQl.mjs +182 -0
- package/dist/transport-common-BsPYcFQl.mjs.map +1 -0
- package/dist/transport.browser-CCUWv3ta.mjs +31 -0
- package/dist/transport.browser-CCUWv3ta.mjs.map +1 -0
- package/dist/transport.node-DXcJtCnx.mjs +33 -0
- package/dist/transport.node-DXcJtCnx.mjs.map +1 -0
- package/dist/tx_pb-BJzY8SXE.mjs +38 -0
- package/dist/tx_pb-BJzY8SXE.mjs.map +1 -0
- package/dist/tx_pb-BVCXH992.mjs +39 -0
- package/dist/tx_pb-BVCXH992.mjs.map +1 -0
- package/dist/tx_pb-CnFNMLIq.mjs +107 -0
- package/dist/tx_pb-CnFNMLIq.mjs.map +1 -0
- package/dist/tx_pb-DYspoJTt.mjs +50 -0
- package/dist/tx_pb-DYspoJTt.mjs.map +1 -0
- package/dist/tx_pb-u3CoQYge.mjs +79 -0
- package/dist/tx_pb-u3CoQYge.mjs.map +1 -0
- package/dist/typed-context-Cg0If0M9.mjs +118 -0
- package/dist/typed-context-Cg0If0M9.mjs.map +1 -0
- package/dist/types-CLfdsa48.mjs +41 -0
- package/dist/types-CLfdsa48.mjs.map +1 -0
- package/dist/types-CSS5rfW1.mjs +303 -0
- package/dist/types-CSS5rfW1.mjs.map +1 -0
- package/dist/types-DGrP9Ro_.d.mts +39609 -0
- package/dist/types_pb-CrjtO9sB.mjs +21 -0
- package/dist/types_pb-CrjtO9sB.mjs.map +1 -0
- package/dist/types_pb-K7pKBvcg.mjs +1433 -0
- package/dist/types_pb-K7pKBvcg.mjs.map +1 -0
- package/dist/utils-B2carKSi.mjs +2 -0
- package/dist/waiting-BigHYRNN.mjs +1081 -0
- package/dist/waiting-BigHYRNN.mjs.map +1 -0
- package/dist/wasm-DdunGtLM.mjs +396 -0
- package/dist/wasm-DdunGtLM.mjs.map +1 -0
- package/package.json +195 -66
- package/dist/client/WebSocketClient.d.ts +0 -30
- package/dist/client/index.d.ts +0 -5
- package/dist/client/rest/APIRequester.d.ts +0 -27
- package/dist/client/rest/RESTClient.d.ts +0 -48
- package/dist/client/rest/Wallet.d.ts +0 -26
- package/dist/client/rest/api/AuctionAPI.d.ts +0 -6
- package/dist/client/rest/api/AuthAPI.d.ts +0 -8
- package/dist/client/rest/api/AuthzAPI.d.ts +0 -8
- package/dist/client/rest/api/BankAPI.d.ts +0 -10
- package/dist/client/rest/api/BaseAPI.d.ts +0 -5
- package/dist/client/rest/api/DistributionAPI.d.ts +0 -35
- package/dist/client/rest/api/EvidenceAPI.d.ts +0 -7
- package/dist/client/rest/api/EvmAPI.d.ts +0 -45
- package/dist/client/rest/api/FeeGrantAPI.d.ts +0 -22
- package/dist/client/rest/api/ForwardingAPI.d.ts +0 -20
- package/dist/client/rest/api/GovAPI.d.ts +0 -12
- package/dist/client/rest/api/GroupAPI.d.ts +0 -19
- package/dist/client/rest/api/IbcAPI.d.ts +0 -48
- package/dist/client/rest/api/IbcHooksAPI.d.ts +0 -8
- package/dist/client/rest/api/IbcNftAPI.d.ts +0 -11
- package/dist/client/rest/api/IbcPermAPI.d.ts +0 -12
- package/dist/client/rest/api/IbcTransferAPI.d.ts +0 -10
- package/dist/client/rest/api/InterTxAPI.d.ts +0 -6
- package/dist/client/rest/api/MarketmapAPI.d.ts +0 -18
- package/dist/client/rest/api/MoveAPI.d.ts +0 -62
- package/dist/client/rest/api/MstakingAPI.d.ts +0 -28
- package/dist/client/rest/api/OpchildAPI.d.ts +0 -23
- package/dist/client/rest/api/OphostAPI.d.ts +0 -34
- package/dist/client/rest/api/OracleAPI.d.ts +0 -22
- package/dist/client/rest/api/RewardAPI.d.ts +0 -8
- package/dist/client/rest/api/SlashingAPI.d.ts +0 -8
- package/dist/client/rest/api/TendermintAPI.d.ts +0 -16
- package/dist/client/rest/api/TokenfactoryAPI.d.ts +0 -12
- package/dist/client/rest/api/TxAPI.d.ts +0 -190
- package/dist/client/rest/api/UpgradeAPI.d.ts +0 -18
- package/dist/client/rest/api/WasmAPI.d.ts +0 -78
- package/dist/client/rest/api/index.d.ts +0 -30
- package/dist/core/Block.d.ts +0 -55
- package/dist/core/Coin.d.ts +0 -42
- package/dist/core/Coins.d.ts +0 -45
- package/dist/core/Denom.d.ts +0 -1
- package/dist/core/Duration.d.ts +0 -19
- package/dist/core/Msg.d.ts +0 -45
- package/dist/core/PublicKey.d.ts +0 -122
- package/dist/core/auction/AuctionParams.d.ts +0 -41
- package/dist/core/auction/index.d.ts +0 -2
- package/dist/core/auction/msgs/MsgAuctionBid.d.ts +0 -36
- package/dist/core/auction/msgs/MsgUpdateAuctionParams.d.ts +0 -33
- package/dist/core/auction/msgs/index.d.ts +0 -10
- package/dist/core/auth/Account.d.ts +0 -12
- package/dist/core/auth/AuthParams.d.ts +0 -37
- package/dist/core/auth/BaseAccount.d.ts +0 -45
- package/dist/core/auth/ModuleAccount.d.ts +0 -39
- package/dist/core/auth/index.d.ts +0 -5
- package/dist/core/auth/msgs/MsgUpdateAuthParams.d.ts +0 -33
- package/dist/core/auth/msgs/index.d.ts +0 -8
- package/dist/core/authz/authorizations/Authorization.d.ts +0 -42
- package/dist/core/authz/authorizations/CallAuthorization.d.ts +0 -28
- package/dist/core/authz/authorizations/ExecuteAuthorization.d.ts +0 -54
- package/dist/core/authz/authorizations/GenericAuthorization.d.ts +0 -28
- package/dist/core/authz/authorizations/PublishAuthorization.d.ts +0 -28
- package/dist/core/authz/authorizations/SendAuthorization.d.ts +0 -33
- package/dist/core/authz/authorizations/StakeAuthorization.d.ts +0 -60
- package/dist/core/authz/authorizations/index.d.ts +0 -7
- package/dist/core/authz/index.d.ts +0 -2
- package/dist/core/authz/msgs/MsgExecAuthorized.d.ts +0 -33
- package/dist/core/authz/msgs/MsgGrantAuthorization.d.ts +0 -36
- package/dist/core/authz/msgs/MsgRevokeAuthorization.d.ts +0 -35
- package/dist/core/authz/msgs/index.d.ts +0 -12
- package/dist/core/bank/BankParams.d.ts +0 -29
- package/dist/core/bank/DenomMetadata.d.ts +0 -43
- package/dist/core/bank/DenomUnit.d.ts +0 -28
- package/dist/core/bank/SendEnabled.d.ts +0 -25
- package/dist/core/bank/index.d.ts +0 -5
- package/dist/core/bank/msgs/MsgMultiSend.d.ts +0 -78
- package/dist/core/bank/msgs/MsgSend.d.ts +0 -36
- package/dist/core/bank/msgs/MsgSetDenomMetadata.d.ts +0 -33
- package/dist/core/bank/msgs/MsgSetSendEnabled.d.ts +0 -37
- package/dist/core/bank/msgs/MsgUpdateBankParams.d.ts +0 -33
- package/dist/core/bank/msgs/index.d.ts +0 -16
- package/dist/core/bech32.d.ts +0 -27
- package/dist/core/celestia/Blob.d.ts +0 -24
- package/dist/core/celestia/BlobTx.d.ts +0 -25
- package/dist/core/celestia/index.d.ts +0 -3
- package/dist/core/celestia/msgs/MsgPayForBlobs.d.ts +0 -31
- package/dist/core/celestia/msgs/index.d.ts +0 -7
- package/dist/core/consensus/ABCIParams.d.ts +0 -21
- package/dist/core/consensus/BlockParams.d.ts +0 -24
- package/dist/core/consensus/EvidenceParams.d.ts +0 -28
- package/dist/core/consensus/ValidatorParams.d.ts +0 -21
- package/dist/core/consensus/index.d.ts +0 -5
- package/dist/core/consensus/msgs/MsgUpdateConsensusParams.d.ts +0 -45
- package/dist/core/consensus/msgs/index.d.ts +0 -8
- package/dist/core/crisis/index.d.ts +0 -1
- package/dist/core/crisis/msgs/MsgUpdateCrisisParams.d.ts +0 -33
- package/dist/core/crisis/msgs/MsgVerifyInvariant.d.ts +0 -35
- package/dist/core/crisis/msgs/index.d.ts +0 -10
- package/dist/core/distribution/DistributionParams.d.ts +0 -32
- package/dist/core/distribution/RewardWeight.d.ts +0 -25
- package/dist/core/distribution/index.d.ts +0 -3
- package/dist/core/distribution/msgs/MsgCommunityPoolSpend.d.ts +0 -36
- package/dist/core/distribution/msgs/MsgDepositValidatorRewardsPool.d.ts +0 -40
- package/dist/core/distribution/msgs/MsgFundCommunityPool.d.ts +0 -33
- package/dist/core/distribution/msgs/MsgSetWithdrawAddress.d.ts +0 -32
- package/dist/core/distribution/msgs/MsgUpdateDistrParams.d.ts +0 -33
- package/dist/core/distribution/msgs/MsgWithdrawDelegatorReward.d.ts +0 -32
- package/dist/core/distribution/msgs/MsgWithdrawValidatorCommission.d.ts +0 -29
- package/dist/core/distribution/msgs/index.d.ts +0 -20
- package/dist/core/evidence/Equivocation.d.ts +0 -38
- package/dist/core/evidence/Evidence.d.ts +0 -11
- package/dist/core/evidence/index.d.ts +0 -3
- package/dist/core/evidence/msgs/MsgSubmitEvidence.d.ts +0 -33
- package/dist/core/evidence/msgs/index.d.ts +0 -8
- package/dist/core/evm/AccessTuple.d.ts +0 -25
- package/dist/core/evm/EvmParams.d.ts +0 -43
- package/dist/core/evm/GasEnforcement.d.ts +0 -27
- package/dist/core/evm/SetCodeAuthorization.d.ts +0 -30
- package/dist/core/evm/index.d.ts +0 -5
- package/dist/core/evm/msgs/MsgCall.d.ts +0 -46
- package/dist/core/evm/msgs/MsgCreate.d.ts +0 -39
- package/dist/core/evm/msgs/MsgCreate2.d.ts +0 -42
- package/dist/core/evm/msgs/MsgUpdateEvmParams.d.ts +0 -33
- package/dist/core/evm/msgs/index.d.ts +0 -14
- package/dist/core/feegrant/allowances/AllowedMsgAllowance.d.ts +0 -33
- package/dist/core/feegrant/allowances/BasicAllowance.d.ts +0 -32
- package/dist/core/feegrant/allowances/PeriodicAllowance.d.ts +0 -43
- package/dist/core/feegrant/allowances/index.d.ts +0 -16
- package/dist/core/feegrant/index.d.ts +0 -2
- package/dist/core/feegrant/msgs/MsgGrantAllowance.d.ts +0 -36
- package/dist/core/feegrant/msgs/MsgRevokeAllowance.d.ts +0 -32
- package/dist/core/feegrant/msgs/index.d.ts +0 -10
- package/dist/core/forwarding/index.d.ts +0 -1
- package/dist/core/forwarding/msgs/MsgClearForwardingAccount.d.ts +0 -32
- package/dist/core/forwarding/msgs/MsgRegisterForwardingAccount.d.ts +0 -38
- package/dist/core/forwarding/msgs/MsgSetAllowedDenoms.d.ts +0 -32
- package/dist/core/forwarding/msgs/MsgSetMemo.d.ts +0 -44
- package/dist/core/forwarding/msgs/index.d.ts +0 -14
- package/dist/core/gov/Deposit.d.ts +0 -29
- package/dist/core/gov/GovParams.d.ts +0 -85
- package/dist/core/gov/TallyResult.d.ts +0 -36
- package/dist/core/gov/Vesting.d.ts +0 -28
- package/dist/core/gov/Vote.d.ts +0 -55
- package/dist/core/gov/index.d.ts +0 -6
- package/dist/core/gov/msgs/MsgActivateEmergencyProposal.d.ts +0 -32
- package/dist/core/gov/msgs/MsgAddEmergencySubmitters.d.ts +0 -32
- package/dist/core/gov/msgs/MsgCancelProposal.d.ts +0 -32
- package/dist/core/gov/msgs/MsgDeposit.d.ts +0 -36
- package/dist/core/gov/msgs/MsgDepositLegacy.d.ts +0 -36
- package/dist/core/gov/msgs/MsgRemoveEmergencySubmitters.d.ts +0 -32
- package/dist/core/gov/msgs/MsgSubmitProposal.d.ts +0 -49
- package/dist/core/gov/msgs/MsgSubmitProposalLegacy.d.ts +0 -37
- package/dist/core/gov/msgs/MsgUpdateGovParams.d.ts +0 -33
- package/dist/core/gov/msgs/MsgVote.d.ts +0 -41
- package/dist/core/gov/msgs/MsgVoteLegacy.d.ts +0 -38
- package/dist/core/gov/msgs/MsgVoteWeighted.d.ts +0 -39
- package/dist/core/gov/msgs/MsgVoteWeightedLegacy.d.ts +0 -36
- package/dist/core/gov/msgs/index.d.ts +0 -32
- package/dist/core/gov/proposals/Content.d.ts +0 -12
- package/dist/core/gov/proposals/Proposal.d.ts +0 -79
- package/dist/core/gov/proposals/TextProposal.d.ts +0 -31
- package/dist/core/gov/proposals/index.d.ts +0 -3
- package/dist/core/group/GroupInfo.d.ts +0 -37
- package/dist/core/group/GroupMember.d.ts +0 -78
- package/dist/core/group/GroupPolicyInfo.d.ts +0 -41
- package/dist/core/group/GroupProposal.d.ts +0 -82
- package/dist/core/group/GroupVote.d.ts +0 -36
- package/dist/core/group/index.d.ts +0 -7
- package/dist/core/group/msgs/MsgCreateGroup.d.ts +0 -36
- package/dist/core/group/msgs/MsgCreateGroupPolicy.d.ts +0 -39
- package/dist/core/group/msgs/MsgCreateGroupWithPolicy.d.ts +0 -46
- package/dist/core/group/msgs/MsgGroupExec.d.ts +0 -32
- package/dist/core/group/msgs/MsgGroupVote.d.ts +0 -46
- package/dist/core/group/msgs/MsgLeaveGroup.d.ts +0 -32
- package/dist/core/group/msgs/MsgSubmitGroupProposal.d.ts +0 -50
- package/dist/core/group/msgs/MsgUpdateGroupAdmin.d.ts +0 -35
- package/dist/core/group/msgs/MsgUpdateGroupDecisionPolicy.d.ts +0 -36
- package/dist/core/group/msgs/MsgUpdateGroupMembers.d.ts +0 -36
- package/dist/core/group/msgs/MsgUpdateGroupMetadata.d.ts +0 -35
- package/dist/core/group/msgs/MsgUpdateGroupPolicyAdmin.d.ts +0 -35
- package/dist/core/group/msgs/MsgUpdateGroupPolicyMetadata.d.ts +0 -35
- package/dist/core/group/msgs/MsgWithdrawProposal.d.ts +0 -32
- package/dist/core/group/msgs/index.d.ts +0 -32
- package/dist/core/group/policies/DecisionPolicyWindows.d.ts +0 -25
- package/dist/core/group/policies/PercentageDecisionPolicy.d.ts +0 -32
- package/dist/core/group/policies/ThresholdDecisionPolicy.d.ts +0 -32
- package/dist/core/group/policies/index.d.ts +0 -15
- package/dist/core/ibc/applications/fee/IbcFee.d.ts +0 -28
- package/dist/core/ibc/applications/fee/IdentifiedPacketFee.d.ts +0 -26
- package/dist/core/ibc/applications/fee/Metadata.d.ts +0 -24
- package/dist/core/ibc/applications/fee/PacketFee.d.ts +0 -29
- package/dist/core/ibc/applications/fee/index.d.ts +0 -5
- package/dist/core/ibc/applications/fee/msgs/MsgPayPacketFee.d.ts +0 -31
- package/dist/core/ibc/applications/fee/msgs/MsgPayPacketFeeAsync.d.ts +0 -26
- package/dist/core/ibc/applications/fee/msgs/MsgRegisterCounterpartyPayee.d.ts +0 -28
- package/dist/core/ibc/applications/fee/msgs/MsgRegisterPayee.d.ts +0 -28
- package/dist/core/ibc/applications/fee/msgs/index.d.ts +0 -13
- package/dist/core/ibc/applications/index.d.ts +0 -4
- package/dist/core/ibc/applications/interchain-account/Account.d.ts +0 -25
- package/dist/core/ibc/applications/interchain-account/Metadata.d.ts +0 -36
- package/dist/core/ibc/applications/interchain-account/controller/Params.d.ts +0 -21
- package/dist/core/ibc/applications/interchain-account/host/Params.d.ts +0 -24
- package/dist/core/ibc/applications/interchain-account/index.d.ts +0 -4
- package/dist/core/ibc/applications/nft-transfer/IbcNftParams.d.ts +0 -28
- package/dist/core/ibc/applications/nft-transfer/NftClassTrace.d.ts +0 -24
- package/dist/core/ibc/applications/nft-transfer/NonFungibleTokenPacketData.d.ts +0 -45
- package/dist/core/ibc/applications/nft-transfer/index.d.ts +0 -4
- package/dist/core/ibc/applications/nft-transfer/msgs/MsgNftTransfer.d.ts +0 -54
- package/dist/core/ibc/applications/nft-transfer/msgs/MsgUpdateIbcNftParams.d.ts +0 -33
- package/dist/core/ibc/applications/nft-transfer/msgs/index.d.ts +0 -10
- package/dist/core/ibc/applications/perm/index.d.ts +0 -1
- package/dist/core/ibc/applications/perm/msgs/MsgUpdateIbcPermAdmin.d.ts +0 -38
- package/dist/core/ibc/applications/perm/msgs/MsgUpdatePermissionedRelayers.d.ts +0 -38
- package/dist/core/ibc/applications/perm/msgs/index.d.ts +0 -10
- package/dist/core/ibc/applications/transfer/DenomTrace.d.ts +0 -24
- package/dist/core/ibc/applications/transfer/FungibleTokenPacketData.d.ts +0 -33
- package/dist/core/ibc/applications/transfer/IbcTransferParams.d.ts +0 -24
- package/dist/core/ibc/applications/transfer/authorizations/Allocation.d.ts +0 -34
- package/dist/core/ibc/applications/transfer/authorizations/TransferAuthorization.d.ts +0 -23
- package/dist/core/ibc/applications/transfer/authorizations/index.d.ts +0 -2
- package/dist/core/ibc/applications/transfer/index.d.ts +0 -5
- package/dist/core/ibc/applications/transfer/msgs/MsgTransfer.d.ts +0 -52
- package/dist/core/ibc/applications/transfer/msgs/MsgUpdateIbcTransferParams.d.ts +0 -26
- package/dist/core/ibc/applications/transfer/msgs/index.d.ts +0 -10
- package/dist/core/ibc/core/channel/Channel.d.ts +0 -39
- package/dist/core/ibc/core/channel/ChannelCounterparty.d.ts +0 -24
- package/dist/core/ibc/core/channel/ChannelOrder.d.ts +0 -3
- package/dist/core/ibc/core/channel/ChannelState.d.ts +0 -3
- package/dist/core/ibc/core/channel/ErrorReceipt.d.ts +0 -20
- package/dist/core/ibc/core/channel/IbcChannelParams.d.ts +0 -22
- package/dist/core/ibc/core/channel/IdentifiedChannel.d.ts +0 -45
- package/dist/core/ibc/core/channel/Packet.d.ts +0 -43
- package/dist/core/ibc/core/channel/PacketId.d.ts +0 -27
- package/dist/core/ibc/core/channel/Timeout.d.ts +0 -25
- package/dist/core/ibc/core/channel/Upgrade.d.ts +0 -24
- package/dist/core/ibc/core/channel/UpgradeFields.d.ts +0 -23
- package/dist/core/ibc/core/channel/index.d.ts +0 -13
- package/dist/core/ibc/core/channel/msgs/MsgChannelCloseConfirm.d.ts +0 -32
- package/dist/core/ibc/core/channel/msgs/MsgChannelCloseInit.d.ts +0 -27
- package/dist/core/ibc/core/channel/msgs/MsgChannelOpenAck.d.ts +0 -36
- package/dist/core/ibc/core/channel/msgs/MsgChannelOpenConfirm.d.ts +0 -32
- package/dist/core/ibc/core/channel/msgs/MsgChannelOpenInit.d.ts +0 -28
- package/dist/core/ibc/core/channel/msgs/MsgChannelOpenTry.d.ts +0 -36
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeAck.d.ts +0 -37
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeCancel.d.ts +0 -35
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeConfirm.d.ts +0 -40
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeInit.d.ts +0 -30
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeOpen.d.ts +0 -37
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeTimeout.d.ts +0 -35
- package/dist/core/ibc/core/channel/msgs/MsgChannelUpgradeTry.d.ts +0 -41
- package/dist/core/ibc/core/channel/msgs/MsgRecvAcknowledgement.d.ts +0 -32
- package/dist/core/ibc/core/channel/msgs/MsgRecvPacket.d.ts +0 -30
- package/dist/core/ibc/core/channel/msgs/MsgTimeout.d.ts +0 -32
- package/dist/core/ibc/core/channel/msgs/MsgTimeoutClose.d.ts +0 -34
- package/dist/core/ibc/core/channel/msgs/MsgUpdateIbcChannelParams.d.ts +0 -26
- package/dist/core/ibc/core/channel/msgs/index.d.ts +0 -41
- package/dist/core/ibc/core/client/ClientConsensusStates.d.ts +0 -25
- package/dist/core/ibc/core/client/ConsensusStateWithHeight.d.ts +0 -25
- package/dist/core/ibc/core/client/Height.d.ts +0 -24
- package/dist/core/ibc/core/client/IbcClientParams.d.ts +0 -21
- package/dist/core/ibc/core/client/IdentifiedClient.d.ts +0 -24
- package/dist/core/ibc/core/client/index.d.ts +0 -6
- package/dist/core/ibc/core/client/msgs/MsgCreateClient.d.ts +0 -27
- package/dist/core/ibc/core/client/msgs/MsgIBCSoftwareUpgrade.d.ts +0 -28
- package/dist/core/ibc/core/client/msgs/MsgRecoverClient.d.ts +0 -27
- package/dist/core/ibc/core/client/msgs/MsgSubmitMisbehaviour.d.ts +0 -27
- package/dist/core/ibc/core/client/msgs/MsgUpdateClient.d.ts +0 -27
- package/dist/core/ibc/core/client/msgs/MsgUpdateIbcClientParams.d.ts +0 -26
- package/dist/core/ibc/core/client/msgs/MsgUpgradeClient.d.ts +0 -33
- package/dist/core/ibc/core/client/msgs/index.d.ts +0 -19
- package/dist/core/ibc/core/client/msgs/tendermint/crypto.d.ts +0 -43
- package/dist/core/ibc/core/client/msgs/tendermint/types.d.ts +0 -187
- package/dist/core/ibc/core/client/msgs/tendermint/version.d.ts +0 -38
- package/dist/core/ibc/core/commitment/MerklePrefix.d.ts +0 -21
- package/dist/core/ibc/core/commitment/MerkleRoot.d.ts +0 -21
- package/dist/core/ibc/core/commitment/index.d.ts +0 -2
- package/dist/core/ibc/core/connection/ConnectionCounterparty.d.ts +0 -28
- package/dist/core/ibc/core/connection/ConnectionState.d.ts +0 -3
- package/dist/core/ibc/core/connection/IbcConnectionParams.d.ts +0 -21
- package/dist/core/ibc/core/connection/IbcVersion.d.ts +0 -24
- package/dist/core/ibc/core/connection/IdentifiedConnection.d.ts +0 -39
- package/dist/core/ibc/core/connection/index.d.ts +0 -5
- package/dist/core/ibc/core/connection/msgs/MsgConnectionOpenAck.d.ts +0 -42
- package/dist/core/ibc/core/connection/msgs/MsgConnectionOpenConfirm.d.ts +0 -30
- package/dist/core/ibc/core/connection/msgs/MsgConnectionOpenInit.d.ts +0 -33
- package/dist/core/ibc/core/connection/msgs/MsgConnectionOpenTry.d.ts +0 -46
- package/dist/core/ibc/core/connection/msgs/MsgUpdateIbcConnectionParams.d.ts +0 -26
- package/dist/core/ibc/core/connection/msgs/index.d.ts +0 -15
- package/dist/core/ibc/core/index.d.ts +0 -4
- package/dist/core/ibc/index.d.ts +0 -2
- package/dist/core/ibc/lightclient/index.d.ts +0 -1
- package/dist/core/ibc/lightclient/tendermint/Header.d.ts +0 -29
- package/dist/core/ibchooks/ACL.d.ts +0 -25
- package/dist/core/ibchooks/IbcHooksParams.d.ts +0 -25
- package/dist/core/ibchooks/index.d.ts +0 -3
- package/dist/core/ibchooks/msgs/MsgUpdateACL.d.ts +0 -35
- package/dist/core/ibchooks/msgs/MsgUpdateIbcHooksParams.d.ts +0 -33
- package/dist/core/ibchooks/msgs/index.d.ts +0 -10
- package/dist/core/index.d.ts +0 -40
- package/dist/core/intertx/index.d.ts +0 -1
- package/dist/core/intertx/msgs/MsgRegisterAccount.d.ts +0 -39
- package/dist/core/intertx/msgs/MsgSubmitTx.d.ts +0 -36
- package/dist/core/intertx/msgs/index.d.ts +0 -10
- package/dist/core/marketmap/Market.d.ts +0 -26
- package/dist/core/marketmap/MarketmapParams.d.ts +0 -25
- package/dist/core/marketmap/ProviderConfig.d.ts +0 -34
- package/dist/core/marketmap/Ticker.d.ts +0 -34
- package/dist/core/marketmap/index.d.ts +0 -5
- package/dist/core/marketmap/msgs/MsgCreateMarkets.d.ts +0 -33
- package/dist/core/marketmap/msgs/MsgRemoveMarketAuthorities.d.ts +0 -32
- package/dist/core/marketmap/msgs/MsgRemoveMarkets.d.ts +0 -32
- package/dist/core/marketmap/msgs/MsgUpdateMarketmapParams.d.ts +0 -33
- package/dist/core/marketmap/msgs/MsgUpdateMarkets.d.ts +0 -33
- package/dist/core/marketmap/msgs/MsgUpsertMarkets.d.ts +0 -33
- package/dist/core/marketmap/msgs/index.d.ts +0 -18
- package/dist/core/move/Module.d.ts +0 -36
- package/dist/core/move/MoveParams.d.ts +0 -37
- package/dist/core/move/index.d.ts +0 -3
- package/dist/core/move/msgs/MsgDelist.d.ts +0 -32
- package/dist/core/move/msgs/MsgExecute.d.ts +0 -44
- package/dist/core/move/msgs/MsgExecuteJSON.d.ts +0 -44
- package/dist/core/move/msgs/MsgGovExecute.d.ts +0 -47
- package/dist/core/move/msgs/MsgGovExecuteJSON.d.ts +0 -47
- package/dist/core/move/msgs/MsgGovPublish.d.ts +0 -41
- package/dist/core/move/msgs/MsgGovScript.d.ts +0 -41
- package/dist/core/move/msgs/MsgGovScriptJSON.d.ts +0 -41
- package/dist/core/move/msgs/MsgPublish.d.ts +0 -38
- package/dist/core/move/msgs/MsgScript.d.ts +0 -38
- package/dist/core/move/msgs/MsgScriptJSON.d.ts +0 -38
- package/dist/core/move/msgs/MsgUpdateMoveParams.d.ts +0 -33
- package/dist/core/move/msgs/MsgWhitelist.d.ts +0 -35
- package/dist/core/move/msgs/index.d.ts +0 -32
- package/dist/core/mstaking/Delegation.d.ts +0 -36
- package/dist/core/mstaking/MstakingParams.d.ts +0 -44
- package/dist/core/mstaking/Redelegation.d.ts +0 -71
- package/dist/core/mstaking/UnbondingDelegation.d.ts +0 -57
- package/dist/core/mstaking/Validator.d.ts +0 -137
- package/dist/core/mstaking/index.d.ts +0 -6
- package/dist/core/mstaking/msgs/MsgBeginRedelegate.d.ts +0 -39
- package/dist/core/mstaking/msgs/MsgCancelUnbondingDelegation.d.ts +0 -39
- package/dist/core/mstaking/msgs/MsgCreateValidator.d.ts +0 -44
- package/dist/core/mstaking/msgs/MsgDelegate.d.ts +0 -36
- package/dist/core/mstaking/msgs/MsgEditValidator.d.ts +0 -37
- package/dist/core/mstaking/msgs/MsgUndelegate.d.ts +0 -36
- package/dist/core/mstaking/msgs/MsgUpdateMstakingParams.d.ts +0 -33
- package/dist/core/mstaking/msgs/index.d.ts +0 -20
- package/dist/core/num.d.ts +0 -2
- package/dist/core/opchild/BridgeInfo.d.ts +0 -34
- package/dist/core/opchild/L2MigrationInfo.d.ts +0 -27
- package/dist/core/opchild/OpValidator.d.ts +0 -32
- package/dist/core/opchild/OpchildParams.d.ts +0 -45
- package/dist/core/opchild/index.d.ts +0 -5
- package/dist/core/opchild/msgs/MsgAddAttestor.d.ts +0 -39
- package/dist/core/opchild/msgs/MsgAddBridgeExecutor.d.ts +0 -32
- package/dist/core/opchild/msgs/MsgAddFeeWhitelistAddresses.d.ts +0 -32
- package/dist/core/opchild/msgs/MsgExecuteMessages.d.ts +0 -33
- package/dist/core/opchild/msgs/MsgFinalizeTokenDeposit.d.ts +0 -52
- package/dist/core/opchild/msgs/MsgInitiateTokenWithdrawal.d.ts +0 -36
- package/dist/core/opchild/msgs/MsgMigrateToken.d.ts +0 -33
- package/dist/core/opchild/msgs/MsgRegisterL2MigrationInfo.d.ts +0 -33
- package/dist/core/opchild/msgs/MsgRemoveAttestor.d.ts +0 -32
- package/dist/core/opchild/msgs/MsgRemoveBridgeExecutor.d.ts +0 -32
- package/dist/core/opchild/msgs/MsgRemoveFeeWhitelistAddresses.d.ts +0 -32
- package/dist/core/opchild/msgs/MsgSetBridgeInfo.d.ts +0 -33
- package/dist/core/opchild/msgs/MsgSpendFeePool.d.ts +0 -36
- package/dist/core/opchild/msgs/MsgUpdateMinGasPrices.d.ts +0 -33
- package/dist/core/opchild/msgs/MsgUpdateOpchildAdmin.d.ts +0 -32
- package/dist/core/opchild/msgs/MsgUpdateOpchildParams.d.ts +0 -33
- package/dist/core/opchild/msgs/MsgUpdateOracle.d.ts +0 -35
- package/dist/core/opchild/msgs/MsgUpdateSequencer.d.ts +0 -39
- package/dist/core/opchild/msgs/index.d.ts +0 -42
- package/dist/core/ophost/BatchInfo.d.ts +0 -25
- package/dist/core/ophost/BatchInfoWithOutput.d.ts +0 -26
- package/dist/core/ophost/BridgeConfig.d.ts +0 -51
- package/dist/core/ophost/L1MigrationInfo.d.ts +0 -30
- package/dist/core/ophost/OphostParams.d.ts +0 -26
- package/dist/core/ophost/Output.d.ts +0 -30
- package/dist/core/ophost/index.d.ts +0 -7
- package/dist/core/ophost/msgs/MsgCreateBridge.d.ts +0 -33
- package/dist/core/ophost/msgs/MsgDeleteOutput.d.ts +0 -35
- package/dist/core/ophost/msgs/MsgDisableBridge.d.ts +0 -32
- package/dist/core/ophost/msgs/MsgFinalizeTokenWithdrawal.d.ts +0 -60
- package/dist/core/ophost/msgs/MsgInitiateTokenDeposit.d.ts +0 -42
- package/dist/core/ophost/msgs/MsgProposeOutput.d.ts +0 -41
- package/dist/core/ophost/msgs/MsgRecordBatch.d.ts +0 -35
- package/dist/core/ophost/msgs/MsgRegisterL1MigrationInfo.d.ts +0 -33
- package/dist/core/ophost/msgs/MsgUpdateBatchInfo.d.ts +0 -36
- package/dist/core/ophost/msgs/MsgUpdateChallenger.d.ts +0 -35
- package/dist/core/ophost/msgs/MsgUpdateFinalizationPeriod.d.ts +0 -36
- package/dist/core/ophost/msgs/MsgUpdateMetadata.d.ts +0 -35
- package/dist/core/ophost/msgs/MsgUpdateOphostParams.d.ts +0 -33
- package/dist/core/ophost/msgs/MsgUpdateOracleConfig.d.ts +0 -35
- package/dist/core/ophost/msgs/MsgUpdateProposer.d.ts +0 -35
- package/dist/core/ophost/msgs/index.d.ts +0 -36
- package/dist/core/oracle/CurrencyPair.d.ts +0 -25
- package/dist/core/oracle/QuotePrice.d.ts +0 -27
- package/dist/core/oracle/index.d.ts +0 -3
- package/dist/core/oracle/msgs/MsgAddCurrencyPairs.d.ts +0 -33
- package/dist/core/oracle/msgs/MsgRemoveCurrencyPairs.d.ts +0 -32
- package/dist/core/oracle/msgs/index.d.ts +0 -10
- package/dist/core/params/ParamChange.d.ts +0 -42
- package/dist/core/params/index.d.ts +0 -2
- package/dist/core/params/proposals/ParameterChangeProposal.d.ts +0 -35
- package/dist/core/params/proposals/index.d.ts +0 -1
- package/dist/core/reward/RewardParams.d.ts +0 -38
- package/dist/core/reward/index.d.ts +0 -2
- package/dist/core/reward/msgs/MsgFundCommunityPoolReward.d.ts +0 -33
- package/dist/core/reward/msgs/MsgUpdateRewardParams.d.ts +0 -33
- package/dist/core/reward/msgs/index.d.ts +0 -10
- package/dist/core/slashing/SlashingParams.d.ts +0 -38
- package/dist/core/slashing/ValidatorSigningInfo.d.ts +0 -37
- package/dist/core/slashing/index.d.ts +0 -3
- package/dist/core/slashing/msgs/MsgUnjail.d.ts +0 -29
- package/dist/core/slashing/msgs/MsgUpdateSlashingParams.d.ts +0 -33
- package/dist/core/slashing/msgs/index.d.ts +0 -10
- package/dist/core/tokenfactory/TokenfactoryParams.d.ts +0 -25
- package/dist/core/tokenfactory/index.d.ts +0 -2
- package/dist/core/tokenfactory/msgs/MsgBurn.d.ts +0 -33
- package/dist/core/tokenfactory/msgs/MsgChangeAdmin.d.ts +0 -35
- package/dist/core/tokenfactory/msgs/MsgCreateDenom.d.ts +0 -32
- package/dist/core/tokenfactory/msgs/MsgMint.d.ts +0 -36
- package/dist/core/tokenfactory/msgs/MsgSetBeforeSendHook.d.ts +0 -35
- package/dist/core/tokenfactory/msgs/MsgSetDenomMetadataWasm.d.ts +0 -33
- package/dist/core/tokenfactory/msgs/MsgUpdateTokenfactoryParams.d.ts +0 -33
- package/dist/core/tokenfactory/msgs/index.d.ts +0 -20
- package/dist/core/tx/CompactBitArray.d.ts +0 -22
- package/dist/core/tx/Fee.d.ts +0 -31
- package/dist/core/tx/MultiSignature.d.ts +0 -13
- package/dist/core/tx/SignDoc.d.ts +0 -36
- package/dist/core/tx/SignMode.d.ts +0 -3
- package/dist/core/tx/SignatureV2.d.ts +0 -66
- package/dist/core/tx/Tx.d.ts +0 -146
- package/dist/core/tx/TxInfo.d.ts +0 -74
- package/dist/core/tx/index.d.ts +0 -7
- package/dist/core/upgrade/Plan.d.ts +0 -27
- package/dist/core/upgrade/index.d.ts +0 -2
- package/dist/core/upgrade/msgs/MsgCancelUpgrade.d.ts +0 -29
- package/dist/core/upgrade/msgs/MsgSoftwareUpgrade.d.ts +0 -33
- package/dist/core/upgrade/msgs/index.d.ts +0 -10
- package/dist/core/wasm/AbsoluteTxPosition.d.ts +0 -24
- package/dist/core/wasm/AccessConfig.d.ts +0 -27
- package/dist/core/wasm/WasmParams.d.ts +0 -32
- package/dist/core/wasm/authorizations/AcceptedMessageKeysFilter.d.ts +0 -28
- package/dist/core/wasm/authorizations/AcceptedMessagesFilter.d.ts +0 -28
- package/dist/core/wasm/authorizations/AllowAllMessagesFilter.d.ts +0 -24
- package/dist/core/wasm/authorizations/CodeGrant.d.ts +0 -25
- package/dist/core/wasm/authorizations/CombinedLimit.d.ts +0 -32
- package/dist/core/wasm/authorizations/ContractExecutionAuthorization.d.ts +0 -29
- package/dist/core/wasm/authorizations/ContractFilter.d.ts +0 -13
- package/dist/core/wasm/authorizations/ContractGrant.d.ts +0 -30
- package/dist/core/wasm/authorizations/ContractLimit.d.ts +0 -13
- package/dist/core/wasm/authorizations/ContractMigrationAuthorization.d.ts +0 -29
- package/dist/core/wasm/authorizations/MaxCallsLimit.d.ts +0 -28
- package/dist/core/wasm/authorizations/MaxFundsLimit.d.ts +0 -29
- package/dist/core/wasm/authorizations/StoreCodeAuthorization.d.ts +0 -29
- package/dist/core/wasm/authorizations/index.d.ts +0 -11
- package/dist/core/wasm/index.d.ts +0 -5
- package/dist/core/wasm/msgs/MsgAddCodeUploadParamsAddresses.d.ts +0 -32
- package/dist/core/wasm/msgs/MsgClearAdmin.d.ts +0 -32
- package/dist/core/wasm/msgs/MsgExecuteContract.d.ts +0 -39
- package/dist/core/wasm/msgs/MsgInstantiateContract.d.ts +0 -45
- package/dist/core/wasm/msgs/MsgInstantiateContractV2.d.ts +0 -51
- package/dist/core/wasm/msgs/MsgMigrateContract.d.ts +0 -38
- package/dist/core/wasm/msgs/MsgPinCodes.d.ts +0 -32
- package/dist/core/wasm/msgs/MsgRemoveCodeUploadParamsAddresses.d.ts +0 -32
- package/dist/core/wasm/msgs/MsgStoreAndInstantiateContract.d.ts +0 -61
- package/dist/core/wasm/msgs/MsgStoreAndMigrateContract.d.ts +0 -42
- package/dist/core/wasm/msgs/MsgStoreCode.d.ts +0 -36
- package/dist/core/wasm/msgs/MsgSudoContract.d.ts +0 -35
- package/dist/core/wasm/msgs/MsgUnpinCodes.d.ts +0 -32
- package/dist/core/wasm/msgs/MsgUpdateAdmin.d.ts +0 -35
- package/dist/core/wasm/msgs/MsgUpdateContractLabel.d.ts +0 -35
- package/dist/core/wasm/msgs/MsgUpdateInstantiateConfig.d.ts +0 -36
- package/dist/core/wasm/msgs/MsgUpdateMaxWasmSize.d.ts +0 -32
- package/dist/core/wasm/msgs/MsgUpdateWasmParams.d.ts +0 -33
- package/dist/core/wasm/msgs/index.d.ts +0 -42
- package/dist/core/wasmextension/AccessConfigExt.d.ts +0 -28
- package/dist/core/wasmextension/index.d.ts +0 -2
- package/dist/core/wasmextension/msgs/MsgStoreCodeAdmin.d.ts +0 -39
- package/dist/core/wasmextension/msgs/index.d.ts +0 -8
- package/dist/index.cjs +0 -6
- package/dist/index.d.ts +0 -4
- package/dist/index.mjs +0 -103590
- package/dist/key/Key.d.ts +0 -20
- package/dist/key/MnemonicKey.d.ts +0 -14
- package/dist/key/RawKey.d.ts +0 -9
- package/dist/key/index.d.ts +0 -3
- package/dist/util/bcs.d.ts +0 -44
- package/dist/util/hash.d.ts +0 -4
- package/dist/util/index.d.ts +0 -3
- package/dist/util/json.d.ts +0 -9
|
@@ -0,0 +1,761 @@
|
|
|
1
|
+
import { o as ContractError } from "./errors-CN1MFOLv.mjs";
|
|
2
|
+
import { t as Message$1 } from "./types-CSS5rfW1.mjs";
|
|
3
|
+
import { n as keccak256 } from "./hash-D40mxOlF.mjs";
|
|
4
|
+
import { n as createEvmRpcClient, t as EvmRpcClient } from "./evm-rpc-BxpgXIAF.mjs";
|
|
5
|
+
import { c as tryDecodeBech32, o as isValidEvmAddress, t as AccAddress } from "./address-DwAkzgJk.mjs";
|
|
6
|
+
import { n as MsgCallSchema } from "./tx_pb-BVCXH992.mjs";
|
|
7
|
+
import { t as createErc20Token } from "./erc20-CDs3j7vt.mjs";
|
|
8
|
+
import { n as evmAbi } from "./abi-helpers-DdwdqhMQ.mjs";
|
|
9
|
+
import { n as parseUnits, t as formatUnits } from "./utils-B2carKSi.mjs";
|
|
10
|
+
import { create } from "@bufbuild/protobuf";
|
|
11
|
+
import { secp256k1 } from "@noble/curves/secp256k1.js";
|
|
12
|
+
import { bytesToHex, hexToBytes } from "@noble/hashes/utils.js";
|
|
13
|
+
import { decodeAbiParameters, decodeErrorResult, decodeErrorResult as decodeErrorResult$1, decodeEventLog, decodeEventLog as decodeEventLog$1, decodeFunctionResult, decodeFunctionResult as decodeFunctionResult$1, encodeAbiParameters, encodeAbiParameters as encodeAbiParameters$1, encodeDeployData, encodeErrorResult, encodeEventTopics, encodeEventTopics as encodeEventTopics$1, encodeFunctionData, encodeFunctionData as encodeFunctionData$1, encodeFunctionResult, parseAbi, parseEventLogs, serializeTransaction } from "viem";
|
|
14
|
+
//#region src/tx/evm.ts
|
|
15
|
+
/**
|
|
16
|
+
* EVM Transaction utilities.
|
|
17
|
+
*
|
|
18
|
+
* Provides functions for building, signing, and sending EVM transactions
|
|
19
|
+
* using the SDK's existing cryptographic primitives and EvmRpcClient.
|
|
20
|
+
*
|
|
21
|
+
* Bundle-optimized: uses viem only for `serializeTransaction` (EIP-1559 serialization),
|
|
22
|
+
* avoids viem's WalletClient/PublicClient/privateKeyToAccount to prevent
|
|
23
|
+
* double-bundling of secp256k1 and pulling in unused action modules.
|
|
24
|
+
*/
|
|
25
|
+
/**
|
|
26
|
+
* Derive EVM address from an uncompressed secp256k1 public key.
|
|
27
|
+
* address = keccak256(pubkey[1:])[12:32]
|
|
28
|
+
*/
|
|
29
|
+
function publicKeyToEvmAddress(uncompressedPubKey) {
|
|
30
|
+
return `0x${bytesToHex(keccak256(uncompressedPubKey.slice(1)).slice(12))}`;
|
|
31
|
+
}
|
|
32
|
+
function resolveRpc(rpc) {
|
|
33
|
+
return typeof rpc === "string" ? new EvmRpcClient(rpc) : rpc;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Send a raw EVM transaction and return the transaction hash.
|
|
37
|
+
*
|
|
38
|
+
* Handles nonce retrieval, gas estimation, EIP-1559 serialization, and signing
|
|
39
|
+
* via the provided EvmTxSigner or raw private key.
|
|
40
|
+
*
|
|
41
|
+
* @example Using signer (preferred)
|
|
42
|
+
* ```typescript
|
|
43
|
+
* const key = new MnemonicKey({ mnemonic: '...' })
|
|
44
|
+
* const txHash = await sendEvmTx({
|
|
45
|
+
* rpc: 'https://1rpc.io/sepolia',
|
|
46
|
+
* signer: key,
|
|
47
|
+
* to: '0x...',
|
|
48
|
+
* data: '0x...',
|
|
49
|
+
* value: 1000000000000000n, // 0.001 ETH
|
|
50
|
+
* })
|
|
51
|
+
* ```
|
|
52
|
+
*
|
|
53
|
+
* @example Using privateKey (legacy)
|
|
54
|
+
* ```typescript
|
|
55
|
+
* const txHash = await sendEvmTx({
|
|
56
|
+
* rpc: 'https://1rpc.io/sepolia',
|
|
57
|
+
* privateKey: key.getPrivateKeyHex(),
|
|
58
|
+
* to: '0x...',
|
|
59
|
+
* data: '0x...',
|
|
60
|
+
* })
|
|
61
|
+
* ```
|
|
62
|
+
*/
|
|
63
|
+
async function sendEvmTx(options) {
|
|
64
|
+
const rpc = resolveRpc(options.rpc);
|
|
65
|
+
let from;
|
|
66
|
+
let signHash;
|
|
67
|
+
if (options.signer && options.privateKey) throw new Error("Cannot specify both signer and privateKey. Use one or the other.");
|
|
68
|
+
if (options.signer) {
|
|
69
|
+
const signer = options.signer;
|
|
70
|
+
if (!/^0x[0-9a-fA-F]{40}$/.test(signer.evmAddress)) throw new Error(`Invalid EVM address from signer: "${signer.evmAddress}". Expected 0x-prefixed 40-character hex string.`);
|
|
71
|
+
from = signer.evmAddress;
|
|
72
|
+
signHash = async (hash) => {
|
|
73
|
+
const sig = await signer.signEvmHash(hash);
|
|
74
|
+
return {
|
|
75
|
+
r: `0x${bytesToHex(sig.r)}`,
|
|
76
|
+
s: `0x${bytesToHex(sig.s)}`,
|
|
77
|
+
yParity: sig.yParity
|
|
78
|
+
};
|
|
79
|
+
};
|
|
80
|
+
} else if (options.privateKey) {
|
|
81
|
+
const privateKeyBytes = hexToBytes(options.privateKey.slice(2));
|
|
82
|
+
from = publicKeyToEvmAddress(secp256k1.getPublicKey(privateKeyBytes, false));
|
|
83
|
+
signHash = (hash) => {
|
|
84
|
+
const sigBytes = secp256k1.sign(hash, privateKeyBytes, {
|
|
85
|
+
prehash: false,
|
|
86
|
+
format: "recovered"
|
|
87
|
+
});
|
|
88
|
+
return Promise.resolve({
|
|
89
|
+
r: `0x${bytesToHex(sigBytes.slice(1, 33))}`,
|
|
90
|
+
s: `0x${bytesToHex(sigBytes.slice(33, 65))}`,
|
|
91
|
+
yParity: sigBytes[0]
|
|
92
|
+
});
|
|
93
|
+
};
|
|
94
|
+
} else throw new Error("Either signer or privateKey must be provided");
|
|
95
|
+
const [nonce, chainId, gasPrice] = await Promise.all([
|
|
96
|
+
rpc.getTransactionCount(from),
|
|
97
|
+
rpc.getChainId(),
|
|
98
|
+
rpc.getGasPrice()
|
|
99
|
+
]);
|
|
100
|
+
const gas = options.gasLimit ?? await rpc.estimateGas({
|
|
101
|
+
from,
|
|
102
|
+
to: options.to,
|
|
103
|
+
data: options.data,
|
|
104
|
+
value: options.value ? `0x${options.value.toString(16)}` : void 0
|
|
105
|
+
});
|
|
106
|
+
const maxFeePerGas = options.maxFeePerGas ?? gasPrice * 2n;
|
|
107
|
+
const maxPriorityFeePerGas = options.maxPriorityFeePerGas ?? gasPrice / 10n;
|
|
108
|
+
const txParams = {
|
|
109
|
+
type: "eip1559",
|
|
110
|
+
chainId: Number(chainId),
|
|
111
|
+
nonce: Number(nonce),
|
|
112
|
+
to: options.to,
|
|
113
|
+
data: options.data,
|
|
114
|
+
value: options.value ?? 0n,
|
|
115
|
+
maxFeePerGas,
|
|
116
|
+
maxPriorityFeePerGas,
|
|
117
|
+
gas
|
|
118
|
+
};
|
|
119
|
+
const txHash = keccak256(hexToBytes(serializeTransaction(txParams).slice(2)));
|
|
120
|
+
const { r, s, yParity } = await signHash(txHash);
|
|
121
|
+
const signedTx = serializeTransaction(txParams, {
|
|
122
|
+
r,
|
|
123
|
+
s,
|
|
124
|
+
yParity
|
|
125
|
+
});
|
|
126
|
+
return rpc.sendRawTransaction(signedTx);
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* Send an EVM transaction and wait for the receipt.
|
|
130
|
+
*
|
|
131
|
+
* Polls `eth_getTransactionReceipt` until the transaction is confirmed
|
|
132
|
+
* or the timeout is reached.
|
|
133
|
+
*
|
|
134
|
+
* @example
|
|
135
|
+
* ```typescript
|
|
136
|
+
* const result = await sendEvmTxAndWait({
|
|
137
|
+
* rpc: 'https://1rpc.io/sepolia',
|
|
138
|
+
* signer: key,
|
|
139
|
+
* to: '0x...',
|
|
140
|
+
* data: '0x...',
|
|
141
|
+
* })
|
|
142
|
+
* console.log(result.status) // 'success' or 'reverted'
|
|
143
|
+
* ```
|
|
144
|
+
*/
|
|
145
|
+
async function sendEvmTxAndWait(options, pollIntervalMs = 2e3, timeoutMs = 12e4) {
|
|
146
|
+
const txHash = await sendEvmTx(options);
|
|
147
|
+
const rpc = resolveRpc(options.rpc);
|
|
148
|
+
const deadline = Date.now() + timeoutMs;
|
|
149
|
+
while (Date.now() < deadline) {
|
|
150
|
+
const receipt = await rpc.getTransactionReceipt(txHash);
|
|
151
|
+
if (receipt) return {
|
|
152
|
+
txHash,
|
|
153
|
+
status: receipt.status === "0x1" ? "success" : "reverted",
|
|
154
|
+
blockNumber: BigInt(receipt.blockNumber),
|
|
155
|
+
gasUsed: BigInt(receipt.gasUsed)
|
|
156
|
+
};
|
|
157
|
+
await new Promise((r) => setTimeout(r, pollIntervalMs));
|
|
158
|
+
}
|
|
159
|
+
throw new Error(`Timeout waiting for EVM tx receipt: ${txHash}`);
|
|
160
|
+
}
|
|
161
|
+
//#endregion
|
|
162
|
+
//#region src/contracts/evm/contract.ts
|
|
163
|
+
const ZERO_ADDRESS_BECH32 = "init1qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqa4qvvl";
|
|
164
|
+
const ZERO_ADDRESS_HEX = "0x0000000000000000000000000000000000000000";
|
|
165
|
+
/**
|
|
166
|
+
* Validates that an address is in a valid format (EVM hex or bech32).
|
|
167
|
+
* @throws Error if address format is invalid
|
|
168
|
+
*/
|
|
169
|
+
function validateContractAddress(address) {
|
|
170
|
+
if (address.startsWith("0x")) {
|
|
171
|
+
if (!isValidEvmAddress(address)) throw new Error(`Invalid EVM address format: ${address}. Expected 0x followed by 40 hex characters.`);
|
|
172
|
+
return;
|
|
173
|
+
}
|
|
174
|
+
if (!tryDecodeBech32(address)) throw new Error(`Invalid contract address: ${address}. Expected EVM hex (0x...) or bech32 format.`);
|
|
175
|
+
}
|
|
176
|
+
/**
|
|
177
|
+
* Converts a bech32 string to hex if it's not already hex.
|
|
178
|
+
* Returns the value unchanged if conversion fails or unnecessary.
|
|
179
|
+
*/
|
|
180
|
+
function maybeToHex(val) {
|
|
181
|
+
if (typeof val === "string" && !val.startsWith("0x")) try {
|
|
182
|
+
return AccAddress.toHex(val);
|
|
183
|
+
} catch {}
|
|
184
|
+
return val;
|
|
185
|
+
}
|
|
186
|
+
/**
|
|
187
|
+
* Recursively converts bech32 addresses to hex based on ABI parameter type.
|
|
188
|
+
* Handles address, address[], tuple (with components), and tuple[].
|
|
189
|
+
*/
|
|
190
|
+
function convertEvmArg(arg, param) {
|
|
191
|
+
const { type } = param;
|
|
192
|
+
if (type === "address") return maybeToHex(arg);
|
|
193
|
+
if (type === "address[]" && Array.isArray(arg)) return arg.map((el) => maybeToHex(el));
|
|
194
|
+
if (type === "tuple" && param.components && arg && typeof arg === "object") {
|
|
195
|
+
const obj = { ...arg };
|
|
196
|
+
for (const comp of param.components) if (comp.name && comp.name in obj) obj[comp.name] = convertEvmArg(obj[comp.name], comp);
|
|
197
|
+
return obj;
|
|
198
|
+
}
|
|
199
|
+
if (type === "tuple[]" && param.components && Array.isArray(arg)) {
|
|
200
|
+
const tupleParam = {
|
|
201
|
+
...param,
|
|
202
|
+
type: "tuple"
|
|
203
|
+
};
|
|
204
|
+
return arg.map((el) => convertEvmArg(el, tupleParam));
|
|
205
|
+
}
|
|
206
|
+
return arg;
|
|
207
|
+
}
|
|
208
|
+
/**
|
|
209
|
+
* Converts bech32 addresses in function args to hex, guided by ABI types.
|
|
210
|
+
*/
|
|
211
|
+
function convertEvmArgs(contractAbi, functionName, args) {
|
|
212
|
+
const fn = contractAbi.find((item) => item.type === "function" && item.name === functionName);
|
|
213
|
+
if (!fn || fn.type !== "function") return args;
|
|
214
|
+
return args.map((arg, i) => {
|
|
215
|
+
const input = fn.inputs[i];
|
|
216
|
+
if (!input) return arg;
|
|
217
|
+
return convertEvmArg(arg, input);
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
function createEvmContract(context, address, abi, options) {
|
|
221
|
+
validateContractAddress(address);
|
|
222
|
+
const contextTransport = context.evmTransport;
|
|
223
|
+
if (options?.transport === "jsonrpc" || contextTransport === "jsonrpc") return createEvmContractJsonRpc(context, address, abi, options ?? { transport: "jsonrpc" });
|
|
224
|
+
return createEvmContractGrpc(context, address, abi);
|
|
225
|
+
}
|
|
226
|
+
/**
|
|
227
|
+
* Extract WriteOptions from the end of args if present.
|
|
228
|
+
* Compares args count against the ABI-declared input count to detect the trailing options object.
|
|
229
|
+
*/
|
|
230
|
+
function extractWriteOptions(abi, functionName, args) {
|
|
231
|
+
const abiItem = abi.find((item) => item.type === "function" && item.name === functionName);
|
|
232
|
+
const expectedArgCount = abiItem && abiItem.type === "function" ? abiItem.inputs.length : 0;
|
|
233
|
+
if (args.length > expectedArgCount) {
|
|
234
|
+
const lastArg = args[args.length - 1];
|
|
235
|
+
if (lastArg && typeof lastArg === "object" && "value" in lastArg) {
|
|
236
|
+
const opts = lastArg;
|
|
237
|
+
return {
|
|
238
|
+
fnArgs: args.slice(0, -1),
|
|
239
|
+
value: opts.value !== void 0 ? opts.value.toString() : "0"
|
|
240
|
+
};
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
return {
|
|
244
|
+
fnArgs: args,
|
|
245
|
+
value: "0"
|
|
246
|
+
};
|
|
247
|
+
}
|
|
248
|
+
/**
|
|
249
|
+
* Ensure a hex string has a 0x prefix.
|
|
250
|
+
*/
|
|
251
|
+
function ensureHexPrefix(hex) {
|
|
252
|
+
return hex.startsWith("0x") ? hex : `0x${hex}`;
|
|
253
|
+
}
|
|
254
|
+
/**
|
|
255
|
+
* Build shared token utility methods (parseUnits, formatUnits, getTokenInfo).
|
|
256
|
+
*/
|
|
257
|
+
function buildTokenUtils(read) {
|
|
258
|
+
let cachedDecimals;
|
|
259
|
+
async function getDecimals() {
|
|
260
|
+
if (cachedDecimals !== void 0) return cachedDecimals;
|
|
261
|
+
cachedDecimals = await read.decimals();
|
|
262
|
+
return cachedDecimals;
|
|
263
|
+
}
|
|
264
|
+
return {
|
|
265
|
+
async parseUnits(value) {
|
|
266
|
+
return parseUnits(value, await getDecimals());
|
|
267
|
+
},
|
|
268
|
+
async formatUnits(value) {
|
|
269
|
+
return formatUnits(value, await getDecimals());
|
|
270
|
+
},
|
|
271
|
+
async getTokenInfo() {
|
|
272
|
+
const erc20 = read;
|
|
273
|
+
const [name, symbol, decimals, totalSupply] = await Promise.all([
|
|
274
|
+
erc20.name(),
|
|
275
|
+
erc20.symbol(),
|
|
276
|
+
erc20.decimals(),
|
|
277
|
+
erc20.totalSupply().catch(() => void 0)
|
|
278
|
+
]);
|
|
279
|
+
cachedDecimals = decimals;
|
|
280
|
+
return {
|
|
281
|
+
name,
|
|
282
|
+
symbol,
|
|
283
|
+
decimals,
|
|
284
|
+
totalSupply
|
|
285
|
+
};
|
|
286
|
+
}
|
|
287
|
+
};
|
|
288
|
+
}
|
|
289
|
+
/**
|
|
290
|
+
* Convert contract address to 0x hex format for JSON-RPC.
|
|
291
|
+
* If already 0x-prefixed, returns as-is. If bech32, converts to hex.
|
|
292
|
+
*/
|
|
293
|
+
function toHexAddress(address) {
|
|
294
|
+
if (address.startsWith("0x")) return address;
|
|
295
|
+
return AccAddress.toHex(address);
|
|
296
|
+
}
|
|
297
|
+
function createEvmContractGrpc(context, address, abi) {
|
|
298
|
+
const evmClient = context.client.evm;
|
|
299
|
+
async function callContract(input) {
|
|
300
|
+
const response = await evmClient.call({
|
|
301
|
+
sender: ZERO_ADDRESS_BECH32,
|
|
302
|
+
contractAddr: address,
|
|
303
|
+
input,
|
|
304
|
+
value: "0",
|
|
305
|
+
accessList: []
|
|
306
|
+
});
|
|
307
|
+
if (response.error) throw new ContractError("evm", 0, response.error);
|
|
308
|
+
return response.response;
|
|
309
|
+
}
|
|
310
|
+
const read = new Proxy({}, { get(_, functionName) {
|
|
311
|
+
return async (...args) => {
|
|
312
|
+
return decodeFunctionResult$1({
|
|
313
|
+
abi,
|
|
314
|
+
functionName,
|
|
315
|
+
data: ensureHexPrefix(await callContract(encodeFunctionData$1({
|
|
316
|
+
abi,
|
|
317
|
+
functionName,
|
|
318
|
+
args: convertEvmArgs(abi, functionName, args)
|
|
319
|
+
})))
|
|
320
|
+
});
|
|
321
|
+
};
|
|
322
|
+
} });
|
|
323
|
+
return {
|
|
324
|
+
address,
|
|
325
|
+
abi,
|
|
326
|
+
read,
|
|
327
|
+
write: new Proxy({}, { get(_, functionName) {
|
|
328
|
+
return (sender, ...args) => {
|
|
329
|
+
const { fnArgs, value } = extractWriteOptions(abi, functionName, args);
|
|
330
|
+
return new Message$1(MsgCallSchema, {
|
|
331
|
+
sender,
|
|
332
|
+
contractAddr: address,
|
|
333
|
+
input: encodeFunctionData$1({
|
|
334
|
+
abi,
|
|
335
|
+
functionName,
|
|
336
|
+
args: convertEvmArgs(abi, functionName, fnArgs)
|
|
337
|
+
}),
|
|
338
|
+
value,
|
|
339
|
+
accessList: []
|
|
340
|
+
});
|
|
341
|
+
};
|
|
342
|
+
} }),
|
|
343
|
+
estimateGas: new Proxy({}, { get(_, functionName) {
|
|
344
|
+
return async (sender, ...args) => {
|
|
345
|
+
const { fnArgs, value } = extractWriteOptions(abi, functionName, args);
|
|
346
|
+
const input = encodeFunctionData$1({
|
|
347
|
+
abi,
|
|
348
|
+
functionName,
|
|
349
|
+
args: convertEvmArgs(abi, functionName, fnArgs)
|
|
350
|
+
});
|
|
351
|
+
const response = await evmClient.call({
|
|
352
|
+
sender,
|
|
353
|
+
contractAddr: address,
|
|
354
|
+
input,
|
|
355
|
+
value,
|
|
356
|
+
accessList: []
|
|
357
|
+
});
|
|
358
|
+
if (response.error) throw new ContractError("evm", 0, response.error);
|
|
359
|
+
return response.usedGas;
|
|
360
|
+
};
|
|
361
|
+
} }),
|
|
362
|
+
...buildTokenUtils(read)
|
|
363
|
+
};
|
|
364
|
+
}
|
|
365
|
+
/**
|
|
366
|
+
* Resolve EvmRpcClient from context at runtime.
|
|
367
|
+
* ChainContext<'minievm'> provides `evmRpc` via getter.
|
|
368
|
+
*/
|
|
369
|
+
function resolveEvmRpc(context) {
|
|
370
|
+
const rpc = context.evmRpc;
|
|
371
|
+
if (!rpc) throw new Error("JSON-RPC transport requires evmRpc on context.\nUse a ChainContext<'minievm'> which provides evmRpc, or pass a context with evmRpc.");
|
|
372
|
+
return rpc;
|
|
373
|
+
}
|
|
374
|
+
/**
|
|
375
|
+
* Resolve private key from options or context.signer at runtime.
|
|
376
|
+
*/
|
|
377
|
+
function resolvePrivateKey(context, options) {
|
|
378
|
+
if (options.privateKey) return options.privateKey;
|
|
379
|
+
const signer = context.signer;
|
|
380
|
+
if (signer && typeof signer === "object" && "getPrivateKeyHex" in signer) return signer.getPrivateKeyHex();
|
|
381
|
+
throw new Error("Private key required for JSON-RPC write.\nProvide privateKey in options or use a context with a Key signer.");
|
|
382
|
+
}
|
|
383
|
+
function createEvmContractJsonRpc(context, address, abi, options) {
|
|
384
|
+
const rpc = resolveEvmRpc(context);
|
|
385
|
+
const hexAddress = toHexAddress(address);
|
|
386
|
+
const read = new Proxy({}, { get(_, functionName) {
|
|
387
|
+
return async (...args) => {
|
|
388
|
+
const input = encodeFunctionData$1({
|
|
389
|
+
abi,
|
|
390
|
+
functionName,
|
|
391
|
+
args: convertEvmArgs(abi, functionName, args)
|
|
392
|
+
});
|
|
393
|
+
return decodeFunctionResult$1({
|
|
394
|
+
abi,
|
|
395
|
+
functionName,
|
|
396
|
+
data: ensureHexPrefix(await rpc.ethCall({
|
|
397
|
+
to: hexAddress,
|
|
398
|
+
data: input
|
|
399
|
+
}))
|
|
400
|
+
});
|
|
401
|
+
};
|
|
402
|
+
} });
|
|
403
|
+
const estimateGas = new Proxy({}, { get(_, functionName) {
|
|
404
|
+
return async (...args) => {
|
|
405
|
+
const { fnArgs, value } = extractWriteOptions(abi, functionName, args);
|
|
406
|
+
const input = encodeFunctionData$1({
|
|
407
|
+
abi,
|
|
408
|
+
functionName,
|
|
409
|
+
args: convertEvmArgs(abi, functionName, fnArgs)
|
|
410
|
+
});
|
|
411
|
+
let from = ZERO_ADDRESS_HEX;
|
|
412
|
+
try {
|
|
413
|
+
const pk = resolvePrivateKey(context, options);
|
|
414
|
+
const { secp256k1 } = await import("@noble/curves/secp256k1.js");
|
|
415
|
+
const { hexToBytes, bytesToHex } = await import("@noble/hashes/utils.js");
|
|
416
|
+
const { keccak256 } = await import("./hash-D40mxOlF.mjs").then((n) => n.t);
|
|
417
|
+
from = `0x${bytesToHex(keccak256(secp256k1.getPublicKey(hexToBytes(pk.slice(2)), false).slice(1)).slice(12))}`;
|
|
418
|
+
} catch {}
|
|
419
|
+
return rpc.estimateGas({
|
|
420
|
+
from,
|
|
421
|
+
to: hexAddress,
|
|
422
|
+
data: input,
|
|
423
|
+
value: value !== "0" ? `0x${BigInt(value).toString(16)}` : void 0
|
|
424
|
+
});
|
|
425
|
+
};
|
|
426
|
+
} });
|
|
427
|
+
return {
|
|
428
|
+
address,
|
|
429
|
+
abi,
|
|
430
|
+
read,
|
|
431
|
+
write: new Proxy({}, { get(_, functionName) {
|
|
432
|
+
return async (...args) => {
|
|
433
|
+
const { fnArgs, value } = extractWriteOptions(abi, functionName, args);
|
|
434
|
+
return sendEvmTx({
|
|
435
|
+
rpc,
|
|
436
|
+
privateKey: resolvePrivateKey(context, options),
|
|
437
|
+
to: hexAddress,
|
|
438
|
+
data: encodeFunctionData$1({
|
|
439
|
+
abi,
|
|
440
|
+
functionName,
|
|
441
|
+
args: convertEvmArgs(abi, functionName, fnArgs)
|
|
442
|
+
}),
|
|
443
|
+
value: value !== "0" ? BigInt(value) : void 0
|
|
444
|
+
});
|
|
445
|
+
};
|
|
446
|
+
} }),
|
|
447
|
+
estimateGas,
|
|
448
|
+
...buildTokenUtils(read)
|
|
449
|
+
};
|
|
450
|
+
}
|
|
451
|
+
/**
|
|
452
|
+
* Deploys an EVM contract.
|
|
453
|
+
*
|
|
454
|
+
* Note: This creates a MsgCreate message. Use with signAndBroadcast().
|
|
455
|
+
*
|
|
456
|
+
* @param sender - Deployer address
|
|
457
|
+
* @param options - Deployment options (abi, bytecode, args, value)
|
|
458
|
+
* @returns MsgCreate message for signing
|
|
459
|
+
*
|
|
460
|
+
* @example
|
|
461
|
+
* ```typescript
|
|
462
|
+
* const deployMsg = createDeployEvmContractMsg(ctx.address, {
|
|
463
|
+
* abi: myContractAbi,
|
|
464
|
+
* bytecode: '0x6080...',
|
|
465
|
+
* args: [arg1, arg2],
|
|
466
|
+
* })
|
|
467
|
+
*
|
|
468
|
+
* const result = await ctx.signAndBroadcast([deployMsg])
|
|
469
|
+
* ```
|
|
470
|
+
*/
|
|
471
|
+
function createDeployEvmContractMsg(sender, options) {
|
|
472
|
+
const { abi, bytecode, args, value } = options;
|
|
473
|
+
const hexBytecode = bytecode.startsWith("0x") ? bytecode : `0x${bytecode}`;
|
|
474
|
+
const constructor = abi.find((item) => item.type === "constructor");
|
|
475
|
+
let convertedArgs = args;
|
|
476
|
+
if (convertedArgs && constructor && constructor.type === "constructor") convertedArgs = convertedArgs.map((arg, i) => {
|
|
477
|
+
const input = constructor.inputs[i];
|
|
478
|
+
if (!input) return arg;
|
|
479
|
+
return convertEvmArg(arg, input);
|
|
480
|
+
});
|
|
481
|
+
return create(MsgCallSchema, {
|
|
482
|
+
sender,
|
|
483
|
+
contractAddr: "",
|
|
484
|
+
input: encodeDeployData({
|
|
485
|
+
abi,
|
|
486
|
+
bytecode: hexBytecode,
|
|
487
|
+
args: convertedArgs
|
|
488
|
+
}).slice(2),
|
|
489
|
+
value: value?.toString() ?? "0",
|
|
490
|
+
accessList: []
|
|
491
|
+
});
|
|
492
|
+
}
|
|
493
|
+
/**
|
|
494
|
+
* Decodes an EVM revert reason from error data.
|
|
495
|
+
*
|
|
496
|
+
* @param data - Hex encoded error data
|
|
497
|
+
* @param abi - Optional contract ABI for custom error decoding
|
|
498
|
+
* @returns Decoded error reason
|
|
499
|
+
*
|
|
500
|
+
* @example
|
|
501
|
+
* ```typescript
|
|
502
|
+
* try {
|
|
503
|
+
* await contract.read.transfer(to, amount)
|
|
504
|
+
* } catch (e) {
|
|
505
|
+
* if (e instanceof ContractError && e.data) {
|
|
506
|
+
* const reason = decodeRevertReason(e.data, contract.abi)
|
|
507
|
+
* console.log('Revert reason:', reason)
|
|
508
|
+
* }
|
|
509
|
+
* }
|
|
510
|
+
* ```
|
|
511
|
+
*/
|
|
512
|
+
function decodeRevertReason(data, abi) {
|
|
513
|
+
const hexData = data.startsWith("0x") ? data : `0x${data}`;
|
|
514
|
+
try {
|
|
515
|
+
if (abi) {
|
|
516
|
+
const decoded = decodeErrorResult$1({
|
|
517
|
+
abi,
|
|
518
|
+
data: hexData
|
|
519
|
+
});
|
|
520
|
+
return `${decoded.errorName}(${decoded.args?.join(", ") ?? ""})`;
|
|
521
|
+
}
|
|
522
|
+
} catch {}
|
|
523
|
+
if (hexData.startsWith("0x08c379a0")) try {
|
|
524
|
+
const decoded = decodeErrorResult$1({
|
|
525
|
+
abi: [{
|
|
526
|
+
type: "error",
|
|
527
|
+
name: "Error",
|
|
528
|
+
inputs: [{
|
|
529
|
+
type: "string",
|
|
530
|
+
name: "message"
|
|
531
|
+
}]
|
|
532
|
+
}],
|
|
533
|
+
data: hexData
|
|
534
|
+
});
|
|
535
|
+
return String(decoded.args?.[0]);
|
|
536
|
+
} catch {}
|
|
537
|
+
if (hexData.startsWith("0x4e487b71")) try {
|
|
538
|
+
const panicCode = decodeErrorResult$1({
|
|
539
|
+
abi: [{
|
|
540
|
+
type: "error",
|
|
541
|
+
name: "Panic",
|
|
542
|
+
inputs: [{
|
|
543
|
+
type: "uint256",
|
|
544
|
+
name: "code"
|
|
545
|
+
}]
|
|
546
|
+
}],
|
|
547
|
+
data: hexData
|
|
548
|
+
}).args?.[0];
|
|
549
|
+
return `Panic(${panicCode}): ${getPanicReason(panicCode)}`;
|
|
550
|
+
} catch {}
|
|
551
|
+
return `Unknown error: ${hexData}`;
|
|
552
|
+
}
|
|
553
|
+
/**
|
|
554
|
+
* Gets human-readable panic reason.
|
|
555
|
+
*/
|
|
556
|
+
function getPanicReason(code) {
|
|
557
|
+
return {
|
|
558
|
+
"0": "Generic compiler panic",
|
|
559
|
+
"1": "Assert failed",
|
|
560
|
+
"17": "Arithmetic overflow/underflow",
|
|
561
|
+
"18": "Division by zero",
|
|
562
|
+
"33": "Invalid enum value",
|
|
563
|
+
"34": "Invalid storage access",
|
|
564
|
+
"49": "Pop on empty array",
|
|
565
|
+
"50": "Array index out of bounds",
|
|
566
|
+
"65": "Out of memory",
|
|
567
|
+
"81": "Call to zero-initialized function"
|
|
568
|
+
}[code.toString()] ?? "Unknown panic code";
|
|
569
|
+
}
|
|
570
|
+
//#endregion
|
|
571
|
+
//#region src/contracts/evm/abi.ts
|
|
572
|
+
/**
|
|
573
|
+
* EVM ABI Encoding/Decoding Utilities
|
|
574
|
+
*
|
|
575
|
+
* Standalone utilities for ABI operations without creating contract instances.
|
|
576
|
+
* Re-exports viem functions for consistent API.
|
|
577
|
+
*/
|
|
578
|
+
/**
|
|
579
|
+
* Encodes an EVM function call from a human-readable signature string.
|
|
580
|
+
* Accepts bech32 addresses in args — automatically converts to hex for address params.
|
|
581
|
+
*
|
|
582
|
+
* @param signature - Human-readable function signature (e.g., "function transfer(address to, uint256 amount)")
|
|
583
|
+
* @param args - Function arguments (bech32 addresses accepted for address params)
|
|
584
|
+
* @returns ABI-encoded calldata with function selector
|
|
585
|
+
*
|
|
586
|
+
* @example
|
|
587
|
+
* ```typescript
|
|
588
|
+
* // With 'function' keyword
|
|
589
|
+
* const calldata = encodeEvmCall(
|
|
590
|
+
* 'function transfer(address to, uint256 amount)',
|
|
591
|
+
* ['init1qwer...', 100n]
|
|
592
|
+
* )
|
|
593
|
+
*
|
|
594
|
+
* // Without 'function' keyword (also accepted)
|
|
595
|
+
* const calldata = encodeEvmCall(
|
|
596
|
+
* 'transfer(address,uint256)',
|
|
597
|
+
* ['init1qwer...', 100n]
|
|
598
|
+
* )
|
|
599
|
+
*
|
|
600
|
+
* const msg = createExecuteMsg(sender, contractAddr, calldata)
|
|
601
|
+
* ```
|
|
602
|
+
*/
|
|
603
|
+
function encodeEvmCall(signature, args) {
|
|
604
|
+
const abi = parseAbi([signature.startsWith("function ") ? signature : `function ${signature}`]);
|
|
605
|
+
const fn = abi[0];
|
|
606
|
+
if (!fn || fn.type !== "function") throw new Error(`Invalid function signature: ${signature}`);
|
|
607
|
+
const convertedArgs = convertEvmArgs(abi, fn.name, args);
|
|
608
|
+
return encodeFunctionData$1({
|
|
609
|
+
abi,
|
|
610
|
+
functionName: fn.name,
|
|
611
|
+
args: convertedArgs
|
|
612
|
+
});
|
|
613
|
+
}
|
|
614
|
+
/**
|
|
615
|
+
* Encodes ABI parameters from type strings with bech32 address auto-conversion.
|
|
616
|
+
*
|
|
617
|
+
* @param types - Parameter type strings (e.g., ["address", "uint256"])
|
|
618
|
+
* @param values - Parameter values (bech32 addresses accepted for address params)
|
|
619
|
+
* @returns ABI-encoded parameters (no function selector)
|
|
620
|
+
*
|
|
621
|
+
* @example
|
|
622
|
+
* ```typescript
|
|
623
|
+
* const encoded = encodeEvmParameters(
|
|
624
|
+
* ['address', 'uint256'],
|
|
625
|
+
* ['init1qwer...', 100n]
|
|
626
|
+
* )
|
|
627
|
+
* ```
|
|
628
|
+
*/
|
|
629
|
+
function encodeEvmParameters(types, values) {
|
|
630
|
+
const convertedArgs = convertEvmArgs(parseAbi([`function _encode(${types.join(",")})`]), "_encode", values);
|
|
631
|
+
return encodeAbiParameters$1(types.map((type) => ({ type })), convertedArgs);
|
|
632
|
+
}
|
|
633
|
+
//#endregion
|
|
634
|
+
//#region src/contracts/evm/events.ts
|
|
635
|
+
/**
|
|
636
|
+
* Decode a single EVM log using the provided ABI.
|
|
637
|
+
*
|
|
638
|
+
* @param abi - Contract ABI containing event definitions
|
|
639
|
+
* @param log - EVM log to decode
|
|
640
|
+
* @returns Decoded event data with ABI-inferred eventName and args
|
|
641
|
+
* @throws If log cannot be decoded with the provided ABI
|
|
642
|
+
*
|
|
643
|
+
* @example
|
|
644
|
+
* ```typescript
|
|
645
|
+
* import { decodeEvmLog } from 'initia.js'
|
|
646
|
+
*
|
|
647
|
+
* const log = await rpcClient.getLogs({ address: contractAddress })
|
|
648
|
+
* const decoded = decodeEvmLog(erc20Abi, log[0])
|
|
649
|
+
* if (decoded.eventName === 'Transfer') {
|
|
650
|
+
* console.log(decoded.args.from, decoded.args.to, decoded.args.value)
|
|
651
|
+
* }
|
|
652
|
+
* ```
|
|
653
|
+
*/
|
|
654
|
+
function decodeEvmLog(abi, log) {
|
|
655
|
+
const topics = log.topics;
|
|
656
|
+
const data = log.data;
|
|
657
|
+
const decoded = decodeEventLog$1({
|
|
658
|
+
abi,
|
|
659
|
+
data,
|
|
660
|
+
topics,
|
|
661
|
+
strict: false
|
|
662
|
+
});
|
|
663
|
+
return {
|
|
664
|
+
log,
|
|
665
|
+
eventName: decoded.eventName,
|
|
666
|
+
args: decoded.args,
|
|
667
|
+
blockNumber: BigInt(log.blockNumber),
|
|
668
|
+
transactionIndex: parseInt(log.transactionIndex, 16),
|
|
669
|
+
logIndex: parseInt(log.logIndex, 16)
|
|
670
|
+
};
|
|
671
|
+
}
|
|
672
|
+
/**
|
|
673
|
+
* Decode multiple EVM logs using the provided ABI.
|
|
674
|
+
*
|
|
675
|
+
* @param abi - Contract ABI containing event definitions
|
|
676
|
+
* @param logs - Array of EVM logs to decode
|
|
677
|
+
* @param options - Decode options
|
|
678
|
+
* @returns Array of decoded events with ABI-inferred types
|
|
679
|
+
*
|
|
680
|
+
* @example
|
|
681
|
+
* ```typescript
|
|
682
|
+
* import { createEvmRpcClient, decodeEvmLogs } from 'initia.js'
|
|
683
|
+
*
|
|
684
|
+
* const rpc = createEvmRpcClient(evmRpcEndpoint)
|
|
685
|
+
* const logs = await rpc.getLogs({
|
|
686
|
+
* address: contractAddress,
|
|
687
|
+
* fromBlock: 1000000,
|
|
688
|
+
* toBlock: 'latest',
|
|
689
|
+
* })
|
|
690
|
+
*
|
|
691
|
+
* const decoded = decodeEvmLogs(erc20Abi, logs)
|
|
692
|
+
* for (const event of decoded) {
|
|
693
|
+
* if (event.eventName === 'Transfer') {
|
|
694
|
+
* console.log(event.args.from, event.args.to, event.args.value)
|
|
695
|
+
* }
|
|
696
|
+
* }
|
|
697
|
+
* ```
|
|
698
|
+
*/
|
|
699
|
+
function decodeEvmLogs(abi, logs, options = {}) {
|
|
700
|
+
const { skipInvalid = true } = options;
|
|
701
|
+
const decoded = [];
|
|
702
|
+
for (const log of logs) try {
|
|
703
|
+
decoded.push(decodeEvmLog(abi, log));
|
|
704
|
+
} catch (error) {
|
|
705
|
+
if (!skipInvalid) throw error;
|
|
706
|
+
}
|
|
707
|
+
return decoded;
|
|
708
|
+
}
|
|
709
|
+
/**
|
|
710
|
+
* Filter and decode logs by event name.
|
|
711
|
+
*
|
|
712
|
+
* @param abi - Contract ABI containing event definitions
|
|
713
|
+
* @param logs - Array of EVM logs to filter and decode
|
|
714
|
+
* @param eventName - Event name to filter by (narrowed to ABI event names)
|
|
715
|
+
* @returns Array of decoded events narrowed to the specified event type
|
|
716
|
+
*
|
|
717
|
+
* @example
|
|
718
|
+
* ```typescript
|
|
719
|
+
* import { filterEvmLogsByEvent } from 'initia.js'
|
|
720
|
+
*
|
|
721
|
+
* const transfers = filterEvmLogsByEvent(erc20Abi, logs, 'Transfer')
|
|
722
|
+
* for (const transfer of transfers) {
|
|
723
|
+
* // args is typed: { from: `0x${string}`, to: `0x${string}`, value: bigint }
|
|
724
|
+
* console.log(`Transfer from ${transfer.args.from} to ${transfer.args.to}: ${transfer.args.value}`)
|
|
725
|
+
* }
|
|
726
|
+
* ```
|
|
727
|
+
*/
|
|
728
|
+
function filterEvmLogsByEvent(abi, logs, eventName) {
|
|
729
|
+
return decodeEvmLogs(abi, logs, { skipInvalid: true }).filter((d) => d.eventName === eventName);
|
|
730
|
+
}
|
|
731
|
+
/**
|
|
732
|
+
* Get event signature (topic0) for an event by name.
|
|
733
|
+
*
|
|
734
|
+
* @param abi - Contract ABI containing event definitions
|
|
735
|
+
* @param eventName - Event name (narrowed to ABI event names)
|
|
736
|
+
* @returns Event signature hash (topic0) or undefined if not found
|
|
737
|
+
*
|
|
738
|
+
* @example
|
|
739
|
+
* ```typescript
|
|
740
|
+
* import { getEventSignature } from 'initia.js'
|
|
741
|
+
*
|
|
742
|
+
* const topic = getEventSignature(erc20Abi, 'Transfer')
|
|
743
|
+
* // 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
|
|
744
|
+
* ```
|
|
745
|
+
*/
|
|
746
|
+
function getEventSignature(abi, eventName) {
|
|
747
|
+
const event = abi.find((item) => item.type === "event" && item.name === eventName);
|
|
748
|
+
if (!event) return;
|
|
749
|
+
try {
|
|
750
|
+
return encodeEventTopics$1({
|
|
751
|
+
abi: [event],
|
|
752
|
+
eventName: event.name
|
|
753
|
+
})[0];
|
|
754
|
+
} catch {
|
|
755
|
+
return;
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
//#endregion
|
|
759
|
+
export { EvmRpcClient, createDeployEvmContractMsg, createErc20Token, createEvmContract, createEvmRpcClient, decodeAbiParameters, decodeErrorResult, decodeEventLog, decodeEvmLog, decodeEvmLogs, decodeFunctionResult, decodeRevertReason, encodeAbiParameters, encodeErrorResult, encodeEventTopics, encodeEvmCall, encodeEvmParameters, encodeFunctionData, encodeFunctionResult, evmAbi, filterEvmLogsByEvent, getEventSignature, parseEventLogs, sendEvmTx, sendEvmTxAndWait };
|
|
760
|
+
|
|
761
|
+
//# sourceMappingURL=entry.evm.mjs.map
|