@aptos-labs/ts-sdk 1.16.0-zeta.1 → 1.16.0-zeta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/common/{accountAddress-OUd5ov6z.d.ts → accountAddress-YfW6h4Ja.d.ts} +1 -1
- package/dist/common/{chunk-VLEH6QBR.js → chunk-HPZUSDYP.js} +1 -1
- package/dist/common/{chunk-VLEH6QBR.js.map → chunk-HPZUSDYP.js.map} +1 -1
- package/dist/common/cli/index.d.ts +1 -1
- package/dist/common/cli/index.js +1 -1
- package/dist/common/index.d.ts +46 -58
- package/dist/common/index.js +27 -27
- package/dist/common/index.js.map +1 -1
- package/dist/esm/account/Account.mjs +1 -1
- package/dist/esm/account/Ed25519Account.mjs +1 -1
- package/dist/esm/account/EphemeralKeyPair.mjs +1 -1
- package/dist/esm/account/KeylessAccount.d.mts +1 -14
- package/dist/esm/account/KeylessAccount.mjs +1 -1
- package/dist/esm/account/MultiKeyAccount.mjs +1 -1
- package/dist/esm/account/SingleKeyAccount.mjs +1 -1
- package/dist/esm/account/index.d.mts +1 -2
- package/dist/esm/account/index.mjs +1 -1
- package/dist/esm/api/account.mjs +1 -1
- package/dist/esm/api/ans.mjs +1 -1
- package/dist/esm/api/aptos.d.mts +0 -1
- package/dist/esm/api/aptos.mjs +1 -1
- package/dist/esm/api/aptosConfig.mjs +1 -1
- package/dist/esm/api/coin.mjs +1 -1
- package/dist/esm/api/digitalAsset.mjs +1 -1
- package/dist/esm/api/event.mjs +1 -1
- package/dist/esm/api/faucet.mjs +1 -1
- package/dist/esm/api/fungibleAsset.mjs +1 -1
- package/dist/esm/api/general.mjs +1 -1
- package/dist/esm/api/index.d.mts +0 -1
- package/dist/esm/api/index.mjs +1 -1
- package/dist/esm/api/keyless.d.mts +0 -1
- package/dist/esm/api/keyless.mjs +1 -1
- package/dist/esm/api/staking.mjs +1 -1
- package/dist/esm/api/table.mjs +1 -1
- package/dist/esm/api/transaction.mjs +1 -1
- package/dist/esm/api/transactionSubmission/build.mjs +1 -1
- package/dist/esm/api/transactionSubmission/management.mjs +1 -1
- package/dist/esm/api/transactionSubmission/sign.mjs +1 -1
- package/dist/esm/api/transactionSubmission/simulate.mjs +1 -1
- package/dist/esm/api/transactionSubmission/submit.mjs +1 -1
- package/dist/esm/api/utils.mjs +1 -1
- package/dist/esm/bcs/deserializer.mjs +1 -1
- package/dist/esm/bcs/index.mjs +1 -1
- package/dist/esm/bcs/serializable/entryFunctionBytes.mjs +1 -1
- package/dist/esm/bcs/serializable/fixedBytes.mjs +1 -1
- package/dist/esm/bcs/serializable/movePrimitives.mjs +1 -1
- package/dist/esm/bcs/serializable/moveStructs.mjs +1 -1
- package/dist/esm/bcs/serializer.mjs +1 -1
- package/dist/esm/{chunk-V6M7FGQT.mjs → chunk-27PC47S7.mjs} +2 -2
- package/dist/esm/{chunk-SNBE5YAC.mjs → chunk-2NGHKNUS.mjs} +2 -2
- package/dist/esm/{chunk-SZ6KR73C.mjs → chunk-37FFZSIM.mjs} +2 -2
- package/dist/esm/{chunk-WXLSJF4A.mjs → chunk-3IFR6T3V.mjs} +1 -1
- package/dist/esm/chunk-3IFR6T3V.mjs.map +1 -0
- package/dist/esm/chunk-3RJZNUCQ.mjs +2 -0
- package/dist/esm/{chunk-3DP4R3FI.mjs → chunk-472OGHMG.mjs} +2 -2
- package/dist/esm/chunk-4TDMJQOJ.mjs +2 -0
- package/dist/esm/chunk-4TDMJQOJ.mjs.map +1 -0
- package/dist/esm/{chunk-J577ODDM.mjs → chunk-4VPCPASN.mjs} +2 -2
- package/dist/esm/{chunk-7CJAEAQZ.mjs → chunk-5YH2YL3L.mjs} +2 -2
- package/dist/esm/{chunk-LLRWILVZ.mjs → chunk-6DFVM2W6.mjs} +2 -2
- package/dist/esm/{chunk-WJIICWOB.mjs → chunk-6FK6OA37.mjs} +2 -2
- package/dist/esm/{chunk-6MDYCC7P.mjs → chunk-6GGHUBUA.mjs} +2 -2
- package/dist/esm/{chunk-SCHMTP4N.mjs → chunk-7BW2N4IE.mjs} +2 -2
- package/dist/esm/{chunk-SSDWEOF7.mjs → chunk-7JLHN655.mjs} +2 -2
- package/dist/esm/{chunk-DSVNXD5A.mjs → chunk-7XRUPEQ4.mjs} +2 -2
- package/dist/esm/{chunk-6F3HFDL3.mjs → chunk-B76XCRLH.mjs} +2 -2
- package/dist/esm/{chunk-AVWAYKNS.mjs → chunk-BO44HPGU.mjs} +2 -2
- package/dist/esm/{chunk-WSVJNBSJ.mjs → chunk-CVCM46UN.mjs} +2 -2
- package/dist/esm/{chunk-PGP2XMDE.mjs → chunk-DPWEHSHH.mjs} +2 -2
- package/dist/esm/{chunk-J534ICWA.mjs → chunk-E4XMEVB7.mjs} +2 -2
- package/dist/esm/{chunk-NGTNMV6Q.mjs → chunk-EFMAZTIM.mjs} +2 -2
- package/dist/esm/{chunk-R4HLV32L.mjs → chunk-EQN6FVO7.mjs} +2 -2
- package/dist/esm/{chunk-WHSN42R2.mjs → chunk-F3ZVWLDH.mjs} +2 -2
- package/dist/esm/{chunk-THURV6CN.mjs → chunk-FF4L66LJ.mjs} +2 -2
- package/dist/esm/{chunk-GS5Z3HO7.mjs → chunk-FGGRPEQ3.mjs} +2 -2
- package/dist/esm/{chunk-EJ7ODMDA.mjs → chunk-FIG65OJD.mjs} +2 -2
- package/dist/esm/chunk-FLALKQIK.mjs +2 -0
- package/dist/esm/{chunk-JBTLE33X.mjs.map → chunk-FLALKQIK.mjs.map} +1 -1
- package/dist/esm/{chunk-UFMIMN7W.mjs → chunk-FUKWM4HL.mjs} +2 -2
- package/dist/esm/{chunk-MSGHGK52.mjs → chunk-GRHLQDHF.mjs} +2 -2
- package/dist/esm/{chunk-VMVSUH2K.mjs → chunk-GSCM444Z.mjs} +2 -2
- package/dist/esm/{chunk-OOYRJQPD.mjs → chunk-GTUBZWAF.mjs} +2 -2
- package/dist/esm/{chunk-SCHZ67F3.mjs → chunk-GY6LFCB2.mjs} +2 -2
- package/dist/esm/{chunk-SCHZ67F3.mjs.map → chunk-GY6LFCB2.mjs.map} +1 -1
- package/dist/esm/{chunk-NUBYALZP.mjs → chunk-H4AGIUGI.mjs} +2 -2
- package/dist/esm/{chunk-SCRIQQV3.mjs → chunk-HZOBRRQP.mjs} +2 -2
- package/dist/esm/{chunk-RAHMGSBW.mjs → chunk-I7GRECEJ.mjs} +2 -2
- package/dist/esm/{chunk-ZV5P2GSJ.mjs → chunk-IBN7ETCB.mjs} +2 -2
- package/dist/esm/{chunk-QOOHLRRJ.mjs → chunk-IGMXAPHY.mjs} +2 -2
- package/dist/esm/{chunk-HOX6Q6ZP.mjs → chunk-IPSITJFX.mjs} +2 -2
- package/dist/esm/{chunk-ZAXWW7VW.mjs → chunk-IVVWQKCF.mjs} +1 -1
- package/dist/esm/chunk-IVVWQKCF.mjs.map +1 -0
- package/dist/esm/{chunk-XQ7I34AL.mjs → chunk-IXFYYWAC.mjs} +2 -2
- package/dist/esm/{chunk-45ESRYGP.mjs → chunk-J6VDYVNB.mjs} +2 -2
- package/dist/esm/{chunk-CEGCSC3T.mjs → chunk-JKRWCFUQ.mjs} +2 -2
- package/dist/esm/{chunk-M4Q4XDVR.mjs → chunk-JOXU5RWH.mjs} +2 -2
- package/dist/esm/{chunk-3J53BCEQ.mjs → chunk-JWGG6XFS.mjs} +2 -2
- package/dist/esm/{chunk-Y24BMR2W.mjs → chunk-K2KJX32L.mjs} +2 -2
- package/dist/esm/{chunk-FUQDDIKQ.mjs → chunk-KCRCX6BL.mjs} +2 -2
- package/dist/esm/{chunk-FUQDDIKQ.mjs.map → chunk-KCRCX6BL.mjs.map} +1 -1
- package/dist/esm/{chunk-OZ3GSAFK.mjs → chunk-KGHBTSDR.mjs} +2 -2
- package/dist/esm/{chunk-5SGIYAB7.mjs → chunk-KMVSI4PC.mjs} +2 -2
- package/dist/esm/{chunk-FWTJQHJR.mjs → chunk-KNMQU2TA.mjs} +2 -2
- package/dist/esm/chunk-KNMQU2TA.mjs.map +1 -0
- package/dist/esm/{chunk-7Y6AWDBZ.mjs → chunk-KSSJ3CT5.mjs} +2 -2
- package/dist/esm/{chunk-BNA3SGG6.mjs → chunk-KUMZXNMD.mjs} +2 -2
- package/dist/esm/{chunk-3SXTTG2X.mjs → chunk-L5CPAOUM.mjs} +2 -2
- package/dist/esm/{chunk-QJIMZI32.mjs → chunk-LMEJ5K6B.mjs} +2 -2
- package/dist/esm/chunk-LYOUEPDG.mjs +2 -0
- package/dist/esm/{chunk-5VLCYHNJ.mjs.map → chunk-LYOUEPDG.mjs.map} +1 -1
- package/dist/esm/{chunk-YLQJBXUF.mjs → chunk-MEOGVBMZ.mjs} +2 -2
- package/dist/esm/{chunk-VBODXPT3.mjs → chunk-MLX6DFMR.mjs} +2 -2
- package/dist/esm/{chunk-OFC75EWS.mjs → chunk-MX5Z3EHG.mjs} +2 -2
- package/dist/esm/{chunk-4VAYXBD2.mjs → chunk-NW3WUTTD.mjs} +2 -2
- package/dist/esm/{chunk-QLE5JL4X.mjs → chunk-NW6LGHE7.mjs} +2 -2
- package/dist/esm/{chunk-NMD45OTM.mjs → chunk-OJL36Q4H.mjs} +2 -2
- package/dist/esm/{chunk-ULW5LX5H.mjs → chunk-OJUFU5TJ.mjs} +2 -2
- package/dist/esm/{chunk-EJURLI4L.mjs → chunk-PAY7N36H.mjs} +2 -2
- package/dist/esm/{chunk-ISXBJPLD.mjs → chunk-PHEA3NOJ.mjs} +2 -2
- package/dist/esm/{chunk-NH466YFP.mjs → chunk-PUP6XMAV.mjs} +2 -2
- package/dist/esm/{chunk-PG7KSUMN.mjs → chunk-PWYL5QZP.mjs} +2 -2
- package/dist/esm/{chunk-JCDZ2WXX.mjs → chunk-QHB5A5YP.mjs} +1 -1
- package/dist/esm/chunk-QHB5A5YP.mjs.map +1 -0
- package/dist/esm/{chunk-CZOUSIAD.mjs → chunk-R4KIZ2FK.mjs} +2 -2
- package/dist/esm/{chunk-AUV4VAXK.mjs → chunk-RTO3YBWQ.mjs} +2 -2
- package/dist/esm/{chunk-34WI7I3Z.mjs → chunk-RURI53PG.mjs} +2 -2
- package/dist/esm/{chunk-TU6VKYDC.mjs → chunk-RX5SPT5S.mjs} +2 -2
- package/dist/esm/{chunk-HGRU3HWY.mjs → chunk-RYRID5HT.mjs} +2 -2
- package/dist/esm/{chunk-IWKIZLFW.mjs → chunk-SBEZ64HG.mjs} +2 -2
- package/dist/esm/{chunk-RWYPGTNL.mjs → chunk-SNDFJWYM.mjs} +2 -2
- package/dist/esm/{chunk-CIPPNT3W.mjs → chunk-T4HO5JMQ.mjs} +2 -2
- package/dist/esm/chunk-T4HO5JMQ.mjs.map +1 -0
- package/dist/esm/{chunk-3YIUOKWW.mjs → chunk-T5YEMU53.mjs} +2 -2
- package/dist/esm/{chunk-MLQT5I6K.mjs → chunk-TUCCV62K.mjs} +2 -2
- package/dist/esm/{chunk-7QGIAVW4.mjs → chunk-UBON2G6Y.mjs} +2 -2
- package/dist/esm/{chunk-272NA6H5.mjs → chunk-UMLUOYFK.mjs} +1 -1
- package/dist/esm/{chunk-272NA6H5.mjs.map → chunk-UMLUOYFK.mjs.map} +1 -1
- package/dist/esm/chunk-VCAURUJ3.mjs +2 -0
- package/dist/esm/chunk-VCAURUJ3.mjs.map +1 -0
- package/dist/esm/{chunk-D76FE35G.mjs → chunk-VJ3OBIFQ.mjs} +2 -2
- package/dist/esm/{chunk-AUAL3H36.mjs → chunk-WA2NTBYY.mjs} +2 -2
- package/dist/esm/{chunk-QYEJOEWB.mjs → chunk-XGDLSWBF.mjs} +2 -2
- package/dist/esm/{chunk-PENBUSGL.mjs → chunk-XH33BXEY.mjs} +2 -2
- package/dist/esm/{chunk-WOLLRMXR.mjs → chunk-XVZBWW46.mjs} +2 -2
- package/dist/esm/{chunk-IMVC2JKU.mjs → chunk-YBXQVY7N.mjs} +2 -2
- package/dist/esm/{chunk-IMVC2JKU.mjs.map → chunk-YBXQVY7N.mjs.map} +1 -1
- package/dist/esm/{chunk-IU6REVKX.mjs → chunk-YDNOKWV3.mjs} +2 -2
- package/dist/esm/{chunk-GHHIUWPP.mjs → chunk-YRUF6N3U.mjs} +2 -2
- package/dist/esm/cli/index.mjs +1 -1
- package/dist/esm/cli/localNode.mjs +1 -1
- package/dist/esm/client/core.mjs +1 -1
- package/dist/esm/client/get.mjs +1 -1
- package/dist/esm/client/index.mjs +1 -1
- package/dist/esm/client/post.mjs +1 -1
- package/dist/esm/core/account/index.mjs +1 -1
- package/dist/esm/core/account/utils/address.mjs +1 -1
- package/dist/esm/core/account/utils/index.mjs +1 -1
- package/dist/esm/core/accountAddress.mjs +1 -1
- package/dist/esm/core/authenticationKey.mjs +1 -1
- package/dist/esm/core/crypto/cryptoHasher.mjs +1 -1
- package/dist/esm/core/crypto/ed25519.mjs +1 -1
- package/dist/esm/core/crypto/ephemeral.mjs +1 -1
- package/dist/esm/core/crypto/index.mjs +1 -1
- package/dist/esm/core/crypto/keyless.mjs +1 -1
- package/dist/esm/core/crypto/multiEd25519.mjs +1 -1
- package/dist/esm/core/crypto/multiKey.mjs +1 -1
- package/dist/esm/core/crypto/poseidon.mjs +1 -1
- package/dist/esm/core/crypto/proof.mjs +1 -1
- package/dist/esm/core/crypto/publicKey.mjs +1 -1
- package/dist/esm/core/crypto/secp256k1.mjs +1 -1
- package/dist/esm/core/crypto/signature.mjs +1 -1
- package/dist/esm/core/crypto/singleKey.mjs +1 -1
- package/dist/esm/core/index.mjs +1 -1
- package/dist/esm/index.d.mts +1 -1
- package/dist/esm/index.mjs +1 -1
- package/dist/esm/internal/account.mjs +1 -1
- package/dist/esm/internal/ans.mjs +1 -1
- package/dist/esm/internal/coin.mjs +1 -1
- package/dist/esm/internal/digitalAsset.mjs +1 -1
- package/dist/esm/internal/event.mjs +1 -1
- package/dist/esm/internal/faucet.mjs +1 -1
- package/dist/esm/internal/fungibleAsset.mjs +1 -1
- package/dist/esm/internal/general.mjs +1 -1
- package/dist/esm/internal/keyless.d.mts +0 -1
- package/dist/esm/internal/keyless.mjs +1 -1
- package/dist/esm/internal/staking.mjs +1 -1
- package/dist/esm/internal/table.mjs +1 -1
- package/dist/esm/internal/transaction.mjs +1 -1
- package/dist/esm/internal/transactionSubmission.mjs +1 -1
- package/dist/esm/internal/view.mjs +1 -1
- package/dist/esm/transactions/authenticator/account.mjs +1 -1
- package/dist/esm/transactions/authenticator/index.mjs +1 -1
- package/dist/esm/transactions/authenticator/transaction.mjs +1 -1
- package/dist/esm/transactions/index.mjs +1 -1
- package/dist/esm/transactions/instances/chainId.mjs +1 -1
- package/dist/esm/transactions/instances/identifier.mjs +1 -1
- package/dist/esm/transactions/instances/index.mjs +1 -1
- package/dist/esm/transactions/instances/moduleId.mjs +1 -1
- package/dist/esm/transactions/instances/multiAgentTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/rawTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/rotationProofChallenge.mjs +1 -1
- package/dist/esm/transactions/instances/signedTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/simpleTransaction.mjs +1 -1
- package/dist/esm/transactions/instances/transactionPayload.mjs +1 -1
- package/dist/esm/transactions/management/accountSequenceNumber.mjs +1 -1
- package/dist/esm/transactions/management/index.mjs +1 -1
- package/dist/esm/transactions/management/transactionWorker.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/helpers.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/index.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/remoteAbi.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/signingMessage.mjs +1 -1
- package/dist/esm/transactions/transactionBuilder/transactionBuilder.mjs +1 -1
- package/dist/esm/transactions/typeTag/index.mjs +1 -1
- package/dist/esm/transactions/typeTag/parser.mjs +1 -1
- package/dist/esm/utils/apiEndpoints.mjs +1 -1
- package/dist/esm/utils/helpers.mjs +1 -1
- package/dist/esm/utils/index.mjs +1 -1
- package/dist/esm/utils/normalizeBundle.mjs +1 -1
- package/dist/esm/version.d.mts +1 -1
- package/dist/esm/version.mjs +1 -1
- package/package.json +1 -2
- package/src/account/KeylessAccount.ts +8 -40
- package/src/api/keyless.ts +1 -3
- package/src/bcs/deserializer.ts +4 -4
- package/src/bcs/serializer.ts +2 -2
- package/src/client/core.ts +0 -1
- package/src/core/crypto/cryptoHasher.ts +1 -1
- package/src/core/crypto/keyless.ts +49 -53
- package/src/core/crypto/poseidon.ts +5 -3
- package/src/internal/keyless.ts +2 -0
- package/src/internal/transactionSubmission.ts +2 -2
- package/src/types/keyless.ts +22 -22
- package/src/utils/apiEndpoints.ts +1 -1
- package/src/utils/helpers.ts +0 -1
- package/src/version.ts +1 -1
- package/dist/esm/chunk-4RXGVY2H.mjs +0 -2
- package/dist/esm/chunk-4RXGVY2H.mjs.map +0 -1
- package/dist/esm/chunk-5VLCYHNJ.mjs +0 -2
- package/dist/esm/chunk-CIPPNT3W.mjs.map +0 -1
- package/dist/esm/chunk-FWTJQHJR.mjs.map +0 -1
- package/dist/esm/chunk-HQK6MF3G.mjs +0 -2
- package/dist/esm/chunk-JBTLE33X.mjs +0 -2
- package/dist/esm/chunk-JCDZ2WXX.mjs.map +0 -1
- package/dist/esm/chunk-MEOBWD6V.mjs +0 -2
- package/dist/esm/chunk-MEOBWD6V.mjs.map +0 -1
- package/dist/esm/chunk-WXLSJF4A.mjs.map +0 -1
- package/dist/esm/chunk-ZAXWW7VW.mjs.map +0 -1
- /package/dist/esm/{chunk-V6M7FGQT.mjs.map → chunk-27PC47S7.mjs.map} +0 -0
- /package/dist/esm/{chunk-SNBE5YAC.mjs.map → chunk-2NGHKNUS.mjs.map} +0 -0
- /package/dist/esm/{chunk-SZ6KR73C.mjs.map → chunk-37FFZSIM.mjs.map} +0 -0
- /package/dist/esm/{chunk-HQK6MF3G.mjs.map → chunk-3RJZNUCQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-3DP4R3FI.mjs.map → chunk-472OGHMG.mjs.map} +0 -0
- /package/dist/esm/{chunk-J577ODDM.mjs.map → chunk-4VPCPASN.mjs.map} +0 -0
- /package/dist/esm/{chunk-7CJAEAQZ.mjs.map → chunk-5YH2YL3L.mjs.map} +0 -0
- /package/dist/esm/{chunk-LLRWILVZ.mjs.map → chunk-6DFVM2W6.mjs.map} +0 -0
- /package/dist/esm/{chunk-WJIICWOB.mjs.map → chunk-6FK6OA37.mjs.map} +0 -0
- /package/dist/esm/{chunk-6MDYCC7P.mjs.map → chunk-6GGHUBUA.mjs.map} +0 -0
- /package/dist/esm/{chunk-SCHMTP4N.mjs.map → chunk-7BW2N4IE.mjs.map} +0 -0
- /package/dist/esm/{chunk-SSDWEOF7.mjs.map → chunk-7JLHN655.mjs.map} +0 -0
- /package/dist/esm/{chunk-DSVNXD5A.mjs.map → chunk-7XRUPEQ4.mjs.map} +0 -0
- /package/dist/esm/{chunk-6F3HFDL3.mjs.map → chunk-B76XCRLH.mjs.map} +0 -0
- /package/dist/esm/{chunk-AVWAYKNS.mjs.map → chunk-BO44HPGU.mjs.map} +0 -0
- /package/dist/esm/{chunk-WSVJNBSJ.mjs.map → chunk-CVCM46UN.mjs.map} +0 -0
- /package/dist/esm/{chunk-PGP2XMDE.mjs.map → chunk-DPWEHSHH.mjs.map} +0 -0
- /package/dist/esm/{chunk-J534ICWA.mjs.map → chunk-E4XMEVB7.mjs.map} +0 -0
- /package/dist/esm/{chunk-NGTNMV6Q.mjs.map → chunk-EFMAZTIM.mjs.map} +0 -0
- /package/dist/esm/{chunk-R4HLV32L.mjs.map → chunk-EQN6FVO7.mjs.map} +0 -0
- /package/dist/esm/{chunk-WHSN42R2.mjs.map → chunk-F3ZVWLDH.mjs.map} +0 -0
- /package/dist/esm/{chunk-THURV6CN.mjs.map → chunk-FF4L66LJ.mjs.map} +0 -0
- /package/dist/esm/{chunk-GS5Z3HO7.mjs.map → chunk-FGGRPEQ3.mjs.map} +0 -0
- /package/dist/esm/{chunk-EJ7ODMDA.mjs.map → chunk-FIG65OJD.mjs.map} +0 -0
- /package/dist/esm/{chunk-UFMIMN7W.mjs.map → chunk-FUKWM4HL.mjs.map} +0 -0
- /package/dist/esm/{chunk-MSGHGK52.mjs.map → chunk-GRHLQDHF.mjs.map} +0 -0
- /package/dist/esm/{chunk-VMVSUH2K.mjs.map → chunk-GSCM444Z.mjs.map} +0 -0
- /package/dist/esm/{chunk-OOYRJQPD.mjs.map → chunk-GTUBZWAF.mjs.map} +0 -0
- /package/dist/esm/{chunk-NUBYALZP.mjs.map → chunk-H4AGIUGI.mjs.map} +0 -0
- /package/dist/esm/{chunk-SCRIQQV3.mjs.map → chunk-HZOBRRQP.mjs.map} +0 -0
- /package/dist/esm/{chunk-RAHMGSBW.mjs.map → chunk-I7GRECEJ.mjs.map} +0 -0
- /package/dist/esm/{chunk-ZV5P2GSJ.mjs.map → chunk-IBN7ETCB.mjs.map} +0 -0
- /package/dist/esm/{chunk-QOOHLRRJ.mjs.map → chunk-IGMXAPHY.mjs.map} +0 -0
- /package/dist/esm/{chunk-HOX6Q6ZP.mjs.map → chunk-IPSITJFX.mjs.map} +0 -0
- /package/dist/esm/{chunk-XQ7I34AL.mjs.map → chunk-IXFYYWAC.mjs.map} +0 -0
- /package/dist/esm/{chunk-45ESRYGP.mjs.map → chunk-J6VDYVNB.mjs.map} +0 -0
- /package/dist/esm/{chunk-CEGCSC3T.mjs.map → chunk-JKRWCFUQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-M4Q4XDVR.mjs.map → chunk-JOXU5RWH.mjs.map} +0 -0
- /package/dist/esm/{chunk-3J53BCEQ.mjs.map → chunk-JWGG6XFS.mjs.map} +0 -0
- /package/dist/esm/{chunk-Y24BMR2W.mjs.map → chunk-K2KJX32L.mjs.map} +0 -0
- /package/dist/esm/{chunk-OZ3GSAFK.mjs.map → chunk-KGHBTSDR.mjs.map} +0 -0
- /package/dist/esm/{chunk-5SGIYAB7.mjs.map → chunk-KMVSI4PC.mjs.map} +0 -0
- /package/dist/esm/{chunk-7Y6AWDBZ.mjs.map → chunk-KSSJ3CT5.mjs.map} +0 -0
- /package/dist/esm/{chunk-BNA3SGG6.mjs.map → chunk-KUMZXNMD.mjs.map} +0 -0
- /package/dist/esm/{chunk-3SXTTG2X.mjs.map → chunk-L5CPAOUM.mjs.map} +0 -0
- /package/dist/esm/{chunk-QJIMZI32.mjs.map → chunk-LMEJ5K6B.mjs.map} +0 -0
- /package/dist/esm/{chunk-YLQJBXUF.mjs.map → chunk-MEOGVBMZ.mjs.map} +0 -0
- /package/dist/esm/{chunk-VBODXPT3.mjs.map → chunk-MLX6DFMR.mjs.map} +0 -0
- /package/dist/esm/{chunk-OFC75EWS.mjs.map → chunk-MX5Z3EHG.mjs.map} +0 -0
- /package/dist/esm/{chunk-4VAYXBD2.mjs.map → chunk-NW3WUTTD.mjs.map} +0 -0
- /package/dist/esm/{chunk-QLE5JL4X.mjs.map → chunk-NW6LGHE7.mjs.map} +0 -0
- /package/dist/esm/{chunk-NMD45OTM.mjs.map → chunk-OJL36Q4H.mjs.map} +0 -0
- /package/dist/esm/{chunk-ULW5LX5H.mjs.map → chunk-OJUFU5TJ.mjs.map} +0 -0
- /package/dist/esm/{chunk-EJURLI4L.mjs.map → chunk-PAY7N36H.mjs.map} +0 -0
- /package/dist/esm/{chunk-ISXBJPLD.mjs.map → chunk-PHEA3NOJ.mjs.map} +0 -0
- /package/dist/esm/{chunk-NH466YFP.mjs.map → chunk-PUP6XMAV.mjs.map} +0 -0
- /package/dist/esm/{chunk-PG7KSUMN.mjs.map → chunk-PWYL5QZP.mjs.map} +0 -0
- /package/dist/esm/{chunk-CZOUSIAD.mjs.map → chunk-R4KIZ2FK.mjs.map} +0 -0
- /package/dist/esm/{chunk-AUV4VAXK.mjs.map → chunk-RTO3YBWQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-34WI7I3Z.mjs.map → chunk-RURI53PG.mjs.map} +0 -0
- /package/dist/esm/{chunk-TU6VKYDC.mjs.map → chunk-RX5SPT5S.mjs.map} +0 -0
- /package/dist/esm/{chunk-HGRU3HWY.mjs.map → chunk-RYRID5HT.mjs.map} +0 -0
- /package/dist/esm/{chunk-IWKIZLFW.mjs.map → chunk-SBEZ64HG.mjs.map} +0 -0
- /package/dist/esm/{chunk-RWYPGTNL.mjs.map → chunk-SNDFJWYM.mjs.map} +0 -0
- /package/dist/esm/{chunk-3YIUOKWW.mjs.map → chunk-T5YEMU53.mjs.map} +0 -0
- /package/dist/esm/{chunk-MLQT5I6K.mjs.map → chunk-TUCCV62K.mjs.map} +0 -0
- /package/dist/esm/{chunk-7QGIAVW4.mjs.map → chunk-UBON2G6Y.mjs.map} +0 -0
- /package/dist/esm/{chunk-D76FE35G.mjs.map → chunk-VJ3OBIFQ.mjs.map} +0 -0
- /package/dist/esm/{chunk-AUAL3H36.mjs.map → chunk-WA2NTBYY.mjs.map} +0 -0
- /package/dist/esm/{chunk-QYEJOEWB.mjs.map → chunk-XGDLSWBF.mjs.map} +0 -0
- /package/dist/esm/{chunk-PENBUSGL.mjs.map → chunk-XH33BXEY.mjs.map} +0 -0
- /package/dist/esm/{chunk-WOLLRMXR.mjs.map → chunk-XVZBWW46.mjs.map} +0 -0
- /package/dist/esm/{chunk-IU6REVKX.mjs.map → chunk-YDNOKWV3.mjs.map} +0 -0
- /package/dist/esm/{chunk-GHHIUWPP.mjs.map → chunk-YRUF6N3U.mjs.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{e as o}from"../../chunk-
|
|
1
|
+
import{e as o}from"../../chunk-VCAURUJ3.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-I7GRECEJ.mjs";import"../../chunk-KMVSI4PC.mjs";import"../../chunk-T5YEMU53.mjs";import"../../chunk-XH33BXEY.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-JWGG6XFS.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-PWYL5QZP.mjs";import"../../chunk-NW6LGHE7.mjs";import"../../chunk-7JLHN655.mjs";import"../../chunk-4TDMJQOJ.mjs";import"../../chunk-LYOUEPDG.mjs";import"../../chunk-VJ3OBIFQ.mjs";import"../../chunk-R4KIZ2FK.mjs";import"../../chunk-KGHBTSDR.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-JKRWCFUQ.mjs";import"../../chunk-YDNOKWV3.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-YRUF6N3U.mjs";import"../../chunk-472OGHMG.mjs";import"../../chunk-FIG65OJD.mjs";import"../../chunk-MLX6DFMR.mjs";import"../../chunk-NW3WUTTD.mjs";import"../../chunk-TUCCV62K.mjs";import"../../chunk-GSCM444Z.mjs";import"../../chunk-IXFYYWAC.mjs";import"../../chunk-PHEA3NOJ.mjs";import"../../chunk-RYRID5HT.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-SNDFJWYM.mjs";import"../../chunk-E4XMEVB7.mjs";import"../../chunk-XGDLSWBF.mjs";import"../../chunk-BO44HPGU.mjs";import"../../chunk-T4HO5JMQ.mjs";import"../../chunk-37FFZSIM.mjs";import"../../chunk-L5CPAOUM.mjs";import"../../chunk-IVVWQKCF.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-XVZBWW46.mjs";import"../../chunk-WA2NTBYY.mjs";import"../../chunk-4VPCPASN.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-EFMAZTIM.mjs";import"../../chunk-F3ZVWLDH.mjs";import"../../chunk-EQN6FVO7.mjs";import"../../chunk-KUMZXNMD.mjs";import"../../chunk-KSSJ3CT5.mjs";import"../../chunk-S3EDNXZE.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-JOXU5RWH.mjs";import"../../chunk-CVCM46UN.mjs";import"../../chunk-YBXQVY7N.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-3RJZNUCQ.mjs";import"../../chunk-RKHPXZM6.mjs";import"../../chunk-QHB5A5YP.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-GRHLQDHF.mjs";import"../../chunk-7BW2N4IE.mjs";import"../../chunk-FGGRPEQ3.mjs";import"../../chunk-IBN7ETCB.mjs";import"../../chunk-Q6LFIZ3L.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-3IFR6T3V.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FLALKQIK.mjs";import"../../chunk-GY6LFCB2.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-FVA2OPG4.mjs";var a=class{constructor(n){this.config=n}transaction(n){return o({...n})}transactionAsFeePayer(n){let{signer:r,transaction:t}=n;if(!t.feePayerAddress)throw new Error(`Transaction ${t} is not a Fee Payer transaction`);return t.feePayerAddress=r.accountAddress,o({signer:r,transaction:t})}};export{a as Sign};
|
|
2
2
|
//# sourceMappingURL=sign.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-LMEJ5K6B.mjs";import"../../chunk-6EMN3BOV.mjs";import"../../chunk-VCAURUJ3.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-I7GRECEJ.mjs";import"../../chunk-KMVSI4PC.mjs";import"../../chunk-T5YEMU53.mjs";import"../../chunk-XH33BXEY.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-JWGG6XFS.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-PWYL5QZP.mjs";import"../../chunk-NW6LGHE7.mjs";import"../../chunk-7JLHN655.mjs";import"../../chunk-4TDMJQOJ.mjs";import"../../chunk-LYOUEPDG.mjs";import"../../chunk-VJ3OBIFQ.mjs";import"../../chunk-R4KIZ2FK.mjs";import"../../chunk-KGHBTSDR.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-JKRWCFUQ.mjs";import"../../chunk-YDNOKWV3.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-YRUF6N3U.mjs";import"../../chunk-472OGHMG.mjs";import"../../chunk-FIG65OJD.mjs";import"../../chunk-MLX6DFMR.mjs";import"../../chunk-NW3WUTTD.mjs";import"../../chunk-TUCCV62K.mjs";import"../../chunk-GSCM444Z.mjs";import"../../chunk-IXFYYWAC.mjs";import"../../chunk-PHEA3NOJ.mjs";import"../../chunk-RYRID5HT.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-SNDFJWYM.mjs";import"../../chunk-E4XMEVB7.mjs";import"../../chunk-XGDLSWBF.mjs";import"../../chunk-BO44HPGU.mjs";import"../../chunk-T4HO5JMQ.mjs";import"../../chunk-37FFZSIM.mjs";import"../../chunk-L5CPAOUM.mjs";import"../../chunk-IVVWQKCF.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-XVZBWW46.mjs";import"../../chunk-WA2NTBYY.mjs";import"../../chunk-4VPCPASN.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-EFMAZTIM.mjs";import"../../chunk-F3ZVWLDH.mjs";import"../../chunk-EQN6FVO7.mjs";import"../../chunk-KUMZXNMD.mjs";import"../../chunk-KSSJ3CT5.mjs";import"../../chunk-S3EDNXZE.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-JOXU5RWH.mjs";import"../../chunk-CVCM46UN.mjs";import"../../chunk-YBXQVY7N.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-3RJZNUCQ.mjs";import"../../chunk-RKHPXZM6.mjs";import"../../chunk-QHB5A5YP.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-GRHLQDHF.mjs";import"../../chunk-7BW2N4IE.mjs";import"../../chunk-FGGRPEQ3.mjs";import"../../chunk-IBN7ETCB.mjs";import"../../chunk-Q6LFIZ3L.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-3IFR6T3V.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FLALKQIK.mjs";import"../../chunk-GY6LFCB2.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Simulate};
|
|
2
2
|
//# sourceMappingURL=simulate.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-FUKWM4HL.mjs";import"../../chunk-6EMN3BOV.mjs";import"../../chunk-VCAURUJ3.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-I7GRECEJ.mjs";import"../../chunk-KMVSI4PC.mjs";import"../../chunk-T5YEMU53.mjs";import"../../chunk-XH33BXEY.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-JWGG6XFS.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-PWYL5QZP.mjs";import"../../chunk-NW6LGHE7.mjs";import"../../chunk-7JLHN655.mjs";import"../../chunk-4TDMJQOJ.mjs";import"../../chunk-LYOUEPDG.mjs";import"../../chunk-VJ3OBIFQ.mjs";import"../../chunk-R4KIZ2FK.mjs";import"../../chunk-KGHBTSDR.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-JKRWCFUQ.mjs";import"../../chunk-YDNOKWV3.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-YRUF6N3U.mjs";import"../../chunk-472OGHMG.mjs";import"../../chunk-FIG65OJD.mjs";import"../../chunk-MLX6DFMR.mjs";import"../../chunk-NW3WUTTD.mjs";import"../../chunk-TUCCV62K.mjs";import"../../chunk-GSCM444Z.mjs";import"../../chunk-IXFYYWAC.mjs";import"../../chunk-PHEA3NOJ.mjs";import"../../chunk-RYRID5HT.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-SNDFJWYM.mjs";import"../../chunk-E4XMEVB7.mjs";import"../../chunk-XGDLSWBF.mjs";import"../../chunk-BO44HPGU.mjs";import"../../chunk-T4HO5JMQ.mjs";import"../../chunk-37FFZSIM.mjs";import"../../chunk-L5CPAOUM.mjs";import"../../chunk-IVVWQKCF.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-XVZBWW46.mjs";import"../../chunk-WA2NTBYY.mjs";import"../../chunk-4VPCPASN.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-LR65XHSF.mjs";import"../../chunk-EFMAZTIM.mjs";import"../../chunk-F3ZVWLDH.mjs";import"../../chunk-EQN6FVO7.mjs";import"../../chunk-KUMZXNMD.mjs";import"../../chunk-KSSJ3CT5.mjs";import"../../chunk-S3EDNXZE.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-JOXU5RWH.mjs";import"../../chunk-CVCM46UN.mjs";import"../../chunk-YBXQVY7N.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-3RJZNUCQ.mjs";import"../../chunk-RKHPXZM6.mjs";import"../../chunk-QHB5A5YP.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-GRHLQDHF.mjs";import"../../chunk-7BW2N4IE.mjs";import"../../chunk-FGGRPEQ3.mjs";import"../../chunk-IBN7ETCB.mjs";import"../../chunk-Q6LFIZ3L.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-3IFR6T3V.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FLALKQIK.mjs";import"../../chunk-GY6LFCB2.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Submit};
|
|
2
2
|
//# sourceMappingURL=submit.mjs.map
|
package/dist/esm/api/utils.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-7XRUPEQ4.mjs";import"../chunk-KUMZXNMD.mjs";import"../chunk-KSSJ3CT5.mjs";import"../chunk-S3EDNXZE.mjs";import"../chunk-AH44UPM4.mjs";import"../chunk-N2FKVZ4D.mjs";import"../chunk-JOXU5RWH.mjs";import"../chunk-CVCM46UN.mjs";import"../chunk-YBXQVY7N.mjs";import"../chunk-GED6IT3S.mjs";import"../chunk-3RJZNUCQ.mjs";import"../chunk-RKHPXZM6.mjs";import"../chunk-QHB5A5YP.mjs";import"../chunk-FZY4PMEE.mjs";import"../chunk-GRHLQDHF.mjs";import"../chunk-7BW2N4IE.mjs";import"../chunk-FGGRPEQ3.mjs";import"../chunk-IBN7ETCB.mjs";import"../chunk-Q6LFIZ3L.mjs";import"../chunk-4WPQQPUF.mjs";import"../chunk-3IFR6T3V.mjs";import"../chunk-UMLUOYFK.mjs";import"../chunk-AOCNYMMX.mjs";import"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FLALKQIK.mjs";import"../chunk-GY6LFCB2.mjs";import"../chunk-YE5B2S5L.mjs";import"../chunk-FVA2OPG4.mjs";export{a as waitForIndexerOnVersion};
|
|
2
2
|
//# sourceMappingURL=utils.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-3IFR6T3V.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FVA2OPG4.mjs";export{a as Deserializer};
|
|
2
2
|
//# sourceMappingURL=deserializer.mjs.map
|
package/dist/esm/bcs/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../chunk-FZY4PMEE.mjs";import{a as h}from"../chunk-
|
|
1
|
+
import"../chunk-FZY4PMEE.mjs";import{a as h}from"../chunk-GRHLQDHF.mjs";import{a as g}from"../chunk-7BW2N4IE.mjs";import{a as p,b as q,c as r}from"../chunk-FGGRPEQ3.mjs";import{a as i,b as j,c as k,d as l,e as m,f as n,g as o}from"../chunk-IBN7ETCB.mjs";import"../chunk-Q6LFIZ3L.mjs";import"../chunk-4WPQQPUF.mjs";import{a}from"../chunk-3IFR6T3V.mjs";import{a as b,b as c,c as d,d as e,e as f}from"../chunk-UMLUOYFK.mjs";import"../chunk-AOCNYMMX.mjs";import"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FVA2OPG4.mjs";export{i as Bool,a as Deserializer,h as EntryFunctionBytes,g as FixedBytes,r as MoveOption,q as MoveString,p as MoveVector,b as Serializable,c as Serializer,n as U128,k as U16,o as U256,l as U32,m as U64,j as U8,d as ensureBoolean,e as outOfRangeErrorMessage,f as validateNumberInRange};
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-GRHLQDHF.mjs";import"../../chunk-7BW2N4IE.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as EntryFunctionBytes};
|
|
2
2
|
//# sourceMappingURL=entryFunctionBytes.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-7BW2N4IE.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as FixedBytes};
|
|
2
2
|
//# sourceMappingURL=fixedBytes.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b,c,d,e,f,g}from"../../chunk-
|
|
1
|
+
import{a,b,c,d,e,f,g}from"../../chunk-IBN7ETCB.mjs";import"../../chunk-Q6LFIZ3L.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Bool,f as U128,c as U16,g as U256,d as U32,e as U64,b as U8};
|
|
2
2
|
//# sourceMappingURL=movePrimitives.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b,c}from"../../chunk-
|
|
1
|
+
import{a,b,c}from"../../chunk-FGGRPEQ3.mjs";import"../../chunk-IBN7ETCB.mjs";import"../../chunk-Q6LFIZ3L.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-UMLUOYFK.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{c as MoveOption,b as MoveString,a as MoveVector};
|
|
2
2
|
//# sourceMappingURL=moveStructs.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b,c,d,e}from"../chunk-
|
|
1
|
+
import{a,b,c,d,e}from"../chunk-UMLUOYFK.mjs";import"../chunk-AOCNYMMX.mjs";import"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FVA2OPG4.mjs";export{a as Serializable,b as Serializer,c as ensureBoolean,d as outOfRangeErrorMessage,e as validateNumberInRange};
|
|
2
2
|
//# sourceMappingURL=serializer.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as h}from"./chunk-GTUBZWAF.mjs";import{a as c}from"./chunk-2NGHKNUS.mjs";import{a as l}from"./chunk-J6VDYVNB.mjs";import{a as f}from"./chunk-OJUFU5TJ.mjs";import{a as g}from"./chunk-5YH2YL3L.mjs";import{a as u}from"./chunk-KNMQU2TA.mjs";import{a as y}from"./chunk-K2KJX32L.mjs";import{a as m}from"./chunk-PAY7N36H.mjs";import{a as s}from"./chunk-MX5Z3EHG.mjs";import{a as p}from"./chunk-6DFVM2W6.mjs";import{a as d}from"./chunk-OJL36Q4H.mjs";import{a as r}from"./chunk-RX5SPT5S.mjs";import{a}from"./chunk-IGMXAPHY.mjs";var t=class{constructor(e){this.config=new d(e),this.account=new s(this.config),this.ans=new p(this.config),this.coin=new r(this.config),this.digitalAsset=new a(this.config),this.event=new c(this.config),this.faucet=new l(this.config),this.fungibleAsset=new f(this.config),this.general=new g(this.config),this.staking=new y(this.config),this.transaction=new h(this.config),this.table=new m(this.config),this.keyless=new u(this.config)}};function n(A,e,b){Object.getOwnPropertyNames(e.prototype).forEach(i=>{let o=Object.getOwnPropertyDescriptor(e.prototype,i);o&&(o.value=function(...w){return this[b][i](...w)},Object.defineProperty(A.prototype,i,o))})}n(t,s,"account");n(t,p,"ans");n(t,r,"coin");n(t,a,"digitalAsset");n(t,c,"event");n(t,l,"faucet");n(t,f,"fungibleAsset");n(t,g,"general");n(t,y,"staking");n(t,h,"transaction");n(t,m,"table");n(t,u,"keyless");export{t as a};
|
|
2
|
+
//# sourceMappingURL=chunk-27PC47S7.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as o,b as r,c as t,d as s}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as o,b as r,c as t,d as s}from"./chunk-IPSITJFX.mjs";import{a as n}from"./chunk-7XRUPEQ4.mjs";var i=class{constructor(e){this.config=e}async getModuleEventsByEventType(e){return await n({config:this.config,minimumLedgerVersion:e.minimumLedgerVersion,processorType:"events_processor"}),o({aptosConfig:this.config,...e})}async getAccountEventsByCreationNumber(e){return await n({config:this.config,minimumLedgerVersion:e.minimumLedgerVersion,processorType:"events_processor"}),r({aptosConfig:this.config,...e})}async getAccountEventsByEventType(e){return await n({config:this.config,minimumLedgerVersion:e.minimumLedgerVersion,processorType:"events_processor"}),t({aptosConfig:this.config,...e})}async getEvents(e){return await n({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"events_processor"}),s({aptosConfig:this.config,...e})}};export{i as a};
|
|
2
|
+
//# sourceMappingURL=chunk-2NGHKNUS.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as r}from"./chunk-UMLUOYFK.mjs";import{b as t}from"./chunk-AOCNYMMX.mjs";var e=class extends r{toString(){let s=this.bcsToBytes();return t.fromHexInput(s).toString()}};export{e as a};
|
|
2
|
+
//# sourceMappingURL=chunk-37FFZSIM.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import{c as r}from"./chunk-56CNRT2K.mjs";var n=class{constructor(e){this.buffer=new ArrayBuffer(e.length),new Uint8Array(this.buffer).set(e,0),this.offset=0}read(e){if(this.offset+e>this.buffer.byteLength)throw new Error("Reached to the end of buffer");let i=this.buffer.slice(this.offset,this.offset+e);return this.offset+=e,i}deserializeStr(){let e=this.deserializeBytes();return new TextDecoder().decode(e)}deserializeOptionStr(){if(this.deserializeUleb128AsU32()===1)return this.deserializeStr()}deserializeOption(e){if(this.deserializeUleb128AsU32()===1)return this.deserialize(e)}deserializeBytes(){let e=this.deserializeUleb128AsU32();return new Uint8Array(this.read(e))}deserializeFixedBytes(e){return new Uint8Array(this.read(e))}deserializeBool(){let e=new Uint8Array(this.read(1))[0];if(e!==1&&e!==0)throw new Error("Invalid boolean value");return e===1}deserializeU8(){return new DataView(this.read(1)).getUint8(0)}deserializeU16(){return new DataView(this.read(2)).getUint16(0,!0)}deserializeU32(){return new DataView(this.read(4)).getUint32(0,!0)}deserializeU64(){let e=this.deserializeU32(),i=this.deserializeU32();return BigInt(BigInt(i)<<BigInt(32)|BigInt(e))}deserializeU128(){let e=this.deserializeU64(),i=this.deserializeU64();return BigInt(i<<BigInt(64)|e)}deserializeU256(){let e=this.deserializeU128(),i=this.deserializeU128();return BigInt(i<<BigInt(128)|e)}deserializeUleb128AsU32(){let e=BigInt(0),i=0;for(;e<r;){let t=this.deserializeU8();if(e|=BigInt(t&127)<<BigInt(i),!(t&128))break;i+=7}if(e>r)throw new Error("Overflow while parsing uleb128-encoded uint32 value");return Number(e)}deserialize(e){return e.deserialize(this)}deserializeVector(e){let i=this.deserializeUleb128AsU32(),t=new Array;for(let s=0;s<i;s+=1)t.push(this.deserialize(e));return t}};export{n as a};
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
2
|
+
//# sourceMappingURL=chunk-3IFR6T3V.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/bcs/deserializer.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\n/* eslint-disable no-bitwise */\nimport { MAX_U32_NUMBER } from \"./consts\";\nimport { Uint8, Uint16, Uint32, Uint64, Uint128, Uint256 } from \"../types\";\n\n/**\n * This interface exists to define Deserializable<T> inputs for functions that\n * deserialize a byte buffer into a type T.\n * It is not intended to be implemented or extended, because Typescript has no support\n * for static methods in interfaces.\n */\nexport interface Deserializable<T> {\n deserialize(deserializer: Deserializer): T;\n}\n\nexport class Deserializer {\n private buffer: ArrayBuffer;\n\n private offset: number;\n\n constructor(data: Uint8Array) {\n // copies data to prevent outside mutation of buffer.\n this.buffer = new ArrayBuffer(data.length);\n new Uint8Array(this.buffer).set(data, 0);\n this.offset = 0;\n }\n\n private read(length: number): ArrayBuffer {\n if (this.offset + length > this.buffer.byteLength) {\n throw new Error(\"Reached to the end of buffer\");\n }\n\n const bytes = this.buffer.slice(this.offset, this.offset + length);\n this.offset += length;\n return bytes;\n }\n\n /**\n * Deserializes a string. UTF8 string is supported. Reads the string's bytes length \"l\" first,\n * and then reads \"l\" bytes of content. Decodes the byte array into a string.\n *\n * BCS layout for \"string\": string_length | string_content\n * where string_length is a u32 integer encoded as a uleb128 integer, equal to the number of bytes in string_content.\n *\n * @example\n * ```ts\n * const deserializer = new Deserializer(new Uint8Array([8, 49, 50, 51, 52, 97, 98, 99, 100]));\n * assert(deserializer.deserializeStr() === \"1234abcd\");\n * ```\n */\n deserializeStr(): string {\n const value = this.deserializeBytes();\n const textDecoder = new TextDecoder();\n return textDecoder.decode(value);\n }\n\n /**\n * Deserializes a an optional string.\n *\n * BCS layout for Optional<String>: 0 if none, else 1 | string_length | string_content\n * @example\n * ```ts\n * const deserializer = new Deserializer(new Uint8Array([0x00]));\n * assert(deserializer.deserializeOptionStr() === undefined);\n * const deserializer = new Deserializer(new Uint8Array([1, 8, 49, 50, 51, 52, 97, 98, 99, 100]));\n * assert(deserializer.deserializeOptionStr() === \"1234abcd\");\n * ```\n */\n deserializeOptionStr(): string | undefined {\n const exists = this.deserializeUleb128AsU32();\n if (exists === 1) {\n return this.deserializeStr();\n }\n return undefined;\n }\n\n /**\n * Deserializes a an optional deserializable class.\n *\n * BCS layout for Optional<T>: 0 if none, else 1 | bcs representation of class\n *\n * @example\n * const deserializer = new Deserializer(new Uint8Array([1, 2, 3]));\n * const value = deserializer.deserializeOption(MyClass); // where MyClass has a `deserialize` function\n * // value is now an instance of MyClass\n *\n * const deserializer = new Deserializer(new Uint8Array([0]));\n * const value = deserializer.deserializeOption(MyClass); // where MyClass has a `deserialize` function\n * // value is undefined\n *\n * @param cls The BCS-deserializable class to deserialize the buffered bytes into.\n *\n * @returns the deserialized value of class type T\n */\n deserializeOption<T>(cls: Deserializable<T>): T | undefined {\n const exists = this.deserializeUleb128AsU32();\n if (exists === 1) {\n return this.deserialize(cls);\n }\n return undefined;\n }\n\n /**\n * Deserializes an array of bytes.\n *\n * BCS layout for \"bytes\": bytes_length | bytes\n * where bytes_length is a u32 integer encoded as a uleb128 integer, equal to the length of the bytes array.\n */\n deserializeBytes(): Uint8Array {\n const len = this.deserializeUleb128AsU32();\n return new Uint8Array(this.read(len));\n }\n\n /**\n * Deserializes an array of bytes. The number of bytes to read is already known.\n *\n */\n deserializeFixedBytes(len: number): Uint8Array {\n return new Uint8Array(this.read(len));\n }\n\n /**\n * Deserializes a boolean value.\n *\n * BCS layout for \"boolean\": One byte. \"0x01\" for true and \"0x00\" for false.\n */\n deserializeBool(): boolean {\n const bool = new Uint8Array(this.read(1))[0];\n if (bool !== 1 && bool !== 0) {\n throw new Error(\"Invalid boolean value\");\n }\n return bool === 1;\n }\n\n /**\n * Deserializes a uint8 number.\n *\n * BCS layout for \"uint8\": One byte. Binary format in little-endian representation.\n */\n deserializeU8(): Uint8 {\n return new DataView(this.read(1)).getUint8(0);\n }\n\n /**\n * Deserializes a uint16 number.\n *\n * BCS layout for \"uint16\": Two bytes. Binary format in little-endian representation.\n * @example\n * ```ts\n * const deserializer = new Deserializer(new Uint8Array([0x34, 0x12]));\n * assert(deserializer.deserializeU16() === 4660);\n * ```\n */\n deserializeU16(): Uint16 {\n return new DataView(this.read(2)).getUint16(0, true);\n }\n\n /**\n * Deserializes a uint32 number.\n *\n * BCS layout for \"uint32\": Four bytes. Binary format in little-endian representation.\n * @example\n * ```ts\n * const deserializer = new Deserializer(new Uint8Array([0x78, 0x56, 0x34, 0x12]));\n * assert(deserializer.deserializeU32() === 305419896);\n * ```\n */\n deserializeU32(): Uint32 {\n return new DataView(this.read(4)).getUint32(0, true);\n }\n\n /**\n * Deserializes a uint64 number.\n *\n * BCS layout for \"uint64\": Eight bytes. Binary format in little-endian representation.\n * @example\n * ```ts\n * const deserializer = new Deserializer(new Uint8Array([0x00, 0xEF, 0xCD, 0xAB, 0x78, 0x56, 0x34, 0x12]));\n * assert(deserializer.deserializeU64() === 1311768467750121216);\n * ```\n */\n deserializeU64(): Uint64 {\n const low = this.deserializeU32();\n const high = this.deserializeU32();\n\n // combine the two 32-bit values and return (little endian)\n return BigInt((BigInt(high) << BigInt(32)) | BigInt(low));\n }\n\n /**\n * Deserializes a uint128 number.\n *\n * BCS layout for \"uint128\": Sixteen bytes. Binary format in little-endian representation.\n */\n deserializeU128(): Uint128 {\n const low = this.deserializeU64();\n const high = this.deserializeU64();\n\n // combine the two 64-bit values and return (little endian)\n return BigInt((high << BigInt(64)) | low);\n }\n\n /**\n * Deserializes a uint256 number.\n *\n * BCS layout for \"uint256\": Thirty-two bytes. Binary format in little-endian representation.\n */\n deserializeU256(): Uint256 {\n const low = this.deserializeU128();\n const high = this.deserializeU128();\n\n // combine the two 128-bit values and return (little endian)\n return BigInt((high << BigInt(128)) | low);\n }\n\n /**\n * Deserializes a uleb128 encoded uint32 number.\n *\n * BCS use uleb128 encoding in two cases: (1) lengths of variable-length sequences and (2) tags of enum values\n */\n deserializeUleb128AsU32(): Uint32 {\n let value: bigint = BigInt(0);\n let shift = 0;\n\n while (value < MAX_U32_NUMBER) {\n const byte = this.deserializeU8();\n value |= BigInt(byte & 0x7f) << BigInt(shift);\n\n if ((byte & 0x80) === 0) {\n break;\n }\n shift += 7;\n }\n\n if (value > MAX_U32_NUMBER) {\n throw new Error(\"Overflow while parsing uleb128-encoded uint32 value\");\n }\n\n return Number(value);\n }\n\n /**\n * Helper function that primarily exists to support alternative syntax for deserialization.\n * That is, if we have a `const deserializer: new Deserializer(...)`, instead of having to use\n * `MyClass.deserialize(deserializer)`, we can call `deserializer.deserialize(MyClass)`.\n *\n * @example const deserializer = new Deserializer(new Uint8Array([1, 2, 3]));\n * const value = deserializer.deserialize(MyClass); // where MyClass has a `deserialize` function\n * // value is now an instance of MyClass\n * // equivalent to `const value = MyClass.deserialize(deserializer)`\n * @param cls The BCS-deserializable class to deserialize the buffered bytes into.\n *\n * @returns the deserialized value of class type T\n */\n deserialize<T>(cls: Deserializable<T>): T {\n // NOTE: `deserialize` in `cls.deserialize(this)` here is a static method defined in `cls`,\n // It is separate from the `deserialize` instance method defined here in Deserializer.\n return cls.deserialize(this);\n }\n\n /**\n * Deserializes an array of BCS Deserializable values given an existing Deserializer\n * instance with a loaded byte buffer.\n *\n * @param cls The BCS-deserializable class to deserialize the buffered bytes into.\n * @example\n * // serialize a vector of addresses\n * const addresses = new Array<AccountAddress>(\n * AccountAddress.from(\"0x1\"),\n * AccountAddress.from(\"0x2\"),\n * AccountAddress.from(\"0xa\"),\n * AccountAddress.from(\"0xb\"),\n * );\n * const serializer = new Serializer();\n * serializer.serializeVector(addresses);\n * const serializedBytes = serializer.toUint8Array();\n *\n * // deserialize the bytes into an array of addresses\n * const deserializer = new Deserializer(serializedBytes);\n * const deserializedAddresses = deserializer.deserializeVector(AccountAddress);\n * // deserializedAddresses is now an array of AccountAddress instances\n * @returns an array of deserialized values of type T\n */\n deserializeVector<T>(cls: Deserializable<T>): Array<T> {\n const length = this.deserializeUleb128AsU32();\n const vector = new Array<T>();\n for (let i = 0; i < length; i += 1) {\n vector.push(this.deserialize(cls));\n }\n return vector;\n }\n}\n"],"mappings":"yCAiBO,IAAMA,EAAN,KAAmB,CAKxB,YAAYC,EAAkB,CAE5B,KAAK,OAAS,IAAI,YAAYA,EAAK,MAAM,EACzC,IAAI,WAAW,KAAK,MAAM,EAAE,IAAIA,EAAM,CAAC,EACvC,KAAK,OAAS,CAChB,CAEQ,KAAKC,EAA6B,CACxC,GAAI,KAAK,OAASA,EAAS,KAAK,OAAO,WACrC,MAAM,IAAI,MAAM,8BAA8B,EAGhD,IAAMC,EAAQ,KAAK,OAAO,MAAM,KAAK,OAAQ,KAAK,OAASD,CAAM,EACjE,YAAK,QAAUA,EACRC,CACT,CAeA,gBAAyB,CACvB,IAAMC,EAAQ,KAAK,iBAAiB,EAEpC,OADoB,IAAI,YAAY,EACjB,OAAOA,CAAK,CACjC,CAcA,sBAA2C,CAEzC,GADe,KAAK,wBAAwB,IAC7B,EACb,OAAO,KAAK,eAAe,CAG/B,CAoBA,kBAAqBC,EAAuC,CAE1D,GADe,KAAK,wBAAwB,IAC7B,EACb,OAAO,KAAK,YAAYA,CAAG,CAG/B,CAQA,kBAA+B,CAC7B,IAAMC,EAAM,KAAK,wBAAwB,EACzC,OAAO,IAAI,WAAW,KAAK,KAAKA,CAAG,CAAC,CACtC,CAMA,sBAAsBA,EAAyB,CAC7C,OAAO,IAAI,WAAW,KAAK,KAAKA,CAAG,CAAC,CACtC,CAOA,iBAA2B,CACzB,IAAMC,EAAO,IAAI,WAAW,KAAK,KAAK,CAAC,CAAC,EAAE,CAAC,EAC3C,GAAIA,IAAS,GAAKA,IAAS,EACzB,MAAM,IAAI,MAAM,uBAAuB,EAEzC,OAAOA,IAAS,CAClB,CAOA,eAAuB,CACrB,OAAO,IAAI,SAAS,KAAK,KAAK,CAAC,CAAC,EAAE,SAAS,CAAC,CAC9C,CAYA,gBAAyB,CACvB,OAAO,IAAI,SAAS,KAAK,KAAK,CAAC,CAAC,EAAE,UAAU,EAAG,EAAI,CACrD,CAYA,gBAAyB,CACvB,OAAO,IAAI,SAAS,KAAK,KAAK,CAAC,CAAC,EAAE,UAAU,EAAG,EAAI,CACrD,CAYA,gBAAyB,CACvB,IAAMC,EAAM,KAAK,eAAe,EAC1BC,EAAO,KAAK,eAAe,EAGjC,OAAO,OAAQ,OAAOA,CAAI,GAAK,OAAO,EAAE,EAAK,OAAOD,CAAG,CAAC,CAC1D,CAOA,iBAA2B,CACzB,IAAMA,EAAM,KAAK,eAAe,EAC1BC,EAAO,KAAK,eAAe,EAGjC,OAAO,OAAQA,GAAQ,OAAO,EAAE,EAAKD,CAAG,CAC1C,CAOA,iBAA2B,CACzB,IAAMA,EAAM,KAAK,gBAAgB,EAC3BC,EAAO,KAAK,gBAAgB,EAGlC,OAAO,OAAQA,GAAQ,OAAO,GAAG,EAAKD,CAAG,CAC3C,CAOA,yBAAkC,CAChC,IAAIJ,EAAgB,OAAO,CAAC,EACxBM,EAAQ,EAEZ,KAAON,EAAQO,GAAgB,CAC7B,IAAMC,EAAO,KAAK,cAAc,EAGhC,GAFAR,GAAS,OAAOQ,EAAO,GAAI,GAAK,OAAOF,CAAK,EAEvC,EAAAE,EAAO,KACV,MAEFF,GAAS,CACX,CAEA,GAAIN,EAAQO,EACV,MAAM,IAAI,MAAM,qDAAqD,EAGvE,OAAO,OAAOP,CAAK,CACrB,CAeA,YAAeC,EAA2B,CAGxC,OAAOA,EAAI,YAAY,IAAI,CAC7B,CAyBA,kBAAqBA,EAAkC,CACrD,IAAMH,EAAS,KAAK,wBAAwB,EACtCW,EAAS,IAAI,MACnB,QAASC,EAAI,EAAGA,EAAIZ,EAAQY,GAAK,EAC/BD,EAAO,KAAK,KAAK,YAAYR,CAAG,CAAC,EAEnC,OAAOQ,CACT,CACF","names":["Deserializer","data","length","bytes","value","cls","len","bool","low","high","shift","MAX_U32_NUMBER","byte","vector","i"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as m}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as m}from"./chunk-FIG65OJD.mjs";import{a as h}from"./chunk-NW3WUTTD.mjs";import{b as t}from"./chunk-F3ZVWLDH.mjs";import{a as u}from"./chunk-UMLUOYFK.mjs";var o=class i extends u{constructor(e,s,a,n,d,l,_){super();this.sender=e,this.sequence_number=s,this.payload=a,this.max_gas_amount=n,this.gas_unit_price=d,this.expiration_timestamp_secs=l,this.chain_id=_}serialize(e){this.sender.serialize(e),e.serializeU64(this.sequence_number),this.payload.serialize(e),e.serializeU64(this.max_gas_amount),e.serializeU64(this.gas_unit_price),e.serializeU64(this.expiration_timestamp_secs),this.chain_id.serialize(e)}static deserialize(e){let s=t.deserialize(e),a=e.deserializeU64(),n=m.deserialize(e),d=e.deserializeU64(),l=e.deserializeU64(),_=e.deserializeU64(),b=h.deserialize(e);return new i(s,a,n,d,l,_,b)}},c=class extends u{static deserialize(r){let e=r.deserializeUleb128AsU32();switch(e){case 0:return p.load(r);case 1:return y.load(r);default:throw new Error(`Unknown variant index for RawTransactionWithData: ${e}`)}}},p=class i extends c{constructor(e,s){super();this.raw_txn=e,this.secondary_signer_addresses=s}serialize(e){e.serializeU32AsUleb128(0),this.raw_txn.serialize(e),e.serializeVector(this.secondary_signer_addresses)}static load(e){let s=o.deserialize(e),a=e.deserializeVector(t);return new i(s,a)}},y=class i extends c{constructor(e,s,a){super();this.raw_txn=e,this.secondary_signer_addresses=s,this.fee_payer_address=a}serialize(e){e.serializeU32AsUleb128(1),this.raw_txn.serialize(e),e.serializeVector(this.secondary_signer_addresses),this.fee_payer_address.serialize(e)}static load(e){let s=o.deserialize(e),a=e.deserializeVector(t),n=t.deserialize(e);return new i(s,a,n)}};export{o as a,c as b,p as c,y as d};
|
|
2
|
+
//# sourceMappingURL=chunk-472OGHMG.mjs.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as v}from"./chunk-LYOUEPDG.mjs";import{a as x}from"./chunk-VJ3OBIFQ.mjs";import{a as E}from"./chunk-KGHBTSDR.mjs";import{d as y}from"./chunk-RYRID5HT.mjs";import{a as u,b as f}from"./chunk-XGDLSWBF.mjs";import{i as S,j as F,k as A,n as d}from"./chunk-T4HO5JMQ.mjs";import{b as K}from"./chunk-F3ZVWLDH.mjs";import{d as b}from"./chunk-QHB5A5YP.mjs";import{a as g}from"./chunk-3IFR6T3V.mjs";import{a as P}from"./chunk-UMLUOYFK.mjs";import{b as w}from"./chunk-AOCNYMMX.mjs";import{jwtDecode as H}from"jwt-decode";import Z from"eventemitter3";var ee={"https://accounts.google.com":"https://www.googleapis.com/oauth2/v3/certs"},s=class s extends P{constructor(e){super();let{address:r,ephemeralKeyPair:t,uidKey:o,uidVal:n,aud:a,pepper:c,proofOrFetcher:i,proofFetchCallback:p,jwt:l}=e;if(this.ephemeralKeyPair=t,this.publicKey=S.create(e),this.accountAddress=r?K.from(r):this.publicKey.authKey().derivedAddress(),this.uidKey=o,this.uidVal=n,this.aud=a,this.jwt=l,this.emitter=new Z,this.proofOrPromise=i,i instanceof d)this.proof=i;else{if(p===void 0)throw new Error("Must provide callback for async proof fetch");this.emitter.on("proofFetchFinish",async z=>{await p(z),this.emitter.removeAllListeners()}),this.init(i)}this.signingScheme=2;let h=w.fromHexInput(c).toUint8Array();if(h.length!==s.PEPPER_LENGTH)throw new Error(`Pepper length in bytes should be ${s.PEPPER_LENGTH}`);this.pepper=h,this.isJwtValid=!0}async init(e){try{this.proof=await e,this.emitter.emit("proofFetchFinish",{status:"Success"})}catch(r){r instanceof Error?this.emitter.emit("proofFetchFinish",{status:"Failed",error:r.toString()}):this.emitter.emit("proofFetchFinish",{status:"Failed",error:"Unknown"})}}serialize(e){if(e.serializeStr(this.jwt),e.serializeStr(this.uidKey),e.serializeFixedBytes(this.pepper),this.ephemeralKeyPair.serialize(e),this.proof===void 0)throw new Error("Connot serialize - proof undefined");this.proof.serialize(e)}static deserialize(e){let r=e.deserializeStr(),t=e.deserializeStr(),o=e.deserializeFixedBytes(31),n=x.deserialize(e),a=d.deserialize(e);return s.fromJWTAndProof({proof:a,pepper:o,uidKey:t,jwt:r,ephemeralKeyPair:n})}isExpired(){return this.ephemeralKeyPair.isExpired()}signWithAuthenticator(e){let r=new f(this.sign(e)),t=new u(this.publicKey);return new y(t,r)}signTransactionWithAuthenticator(e){let r=new f(this.signTransaction(e)),t=new u(this.publicKey);return new y(t,r)}async waitForProofFetch(){this.proofOrPromise instanceof Promise&&await this.proofOrPromise}sign(e){let{expiryDateSecs:r}=this.ephemeralKeyPair;if(this.isExpired())throw new Error("EphemeralKeyPair is expired");if(this.proof===void 0)throw new Error("Proof not defined");let t=this.ephemeralKeyPair.getPublicKey(),o=this.ephemeralKeyPair.sign(e);return new F({jwtHeader:b(this.jwt.split(".")[0]),ephemeralCertificate:new A(this.proof,0),expiryDateSecs:r,ephemeralPublicKey:t,ephemeralSignature:o})}signTransaction(e){if(this.proof===void 0)throw new Error("Proof not found");let r=E(e),o=new m(r,this.proof.proof).hash();return this.sign(o)}verifySignature(e){throw new Error("Not implemented")}static fromBytes(e){return s.deserialize(new g(e))}static fromJWTAndProof(e){let{proof:r,jwt:t,ephemeralKeyPair:o,pepper:n,proofFetchCallback:a}=e,c=e.uidKey??"sub",i=H(t),p=i.iss;if(typeof i.aud!="string")throw new Error("aud was not found or an array of values");let l=i.aud,h=i[c];return new s({proofOrFetcher:r,ephemeralKeyPair:o,iss:p,uidKey:c,uidVal:h,aud:l,pepper:n,jwt:t,proofFetchCallback:a})}};s.PEPPER_LENGTH=31;var T=s,m=class extends v{constructor(e,r){super();this.transaction=e,this.proof=r,this.domainSeparator="APTOS::TransactionAndProof"}serialize(e){e.serializeFixedBytes(this.transaction.bcsToBytes()),e.serializeOption(this.proof)}};export{ee as a,T as b,m as c};
|
|
2
|
+
//# sourceMappingURL=chunk-4TDMJQOJ.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/account/KeylessAccount.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\nimport { JwtPayload, jwtDecode } from \"jwt-decode\";\nimport EventEmitter from \"eventemitter3\";\nimport { EphemeralCertificateVariant, HexInput, SigningScheme } from \"../types\";\nimport { AccountAddress } from \"../core/accountAddress\";\nimport {\n AnyPublicKey,\n AnySignature,\n KeylessPublicKey,\n KeylessSignature,\n EphemeralCertificate,\n Signature,\n ZeroKnowledgeSig,\n ZkProof,\n} from \"../core/crypto\";\n\nimport { Account } from \"./Account\";\nimport { EphemeralKeyPair } from \"./EphemeralKeyPair\";\nimport { Hex } from \"../core/hex\";\nimport { AccountAuthenticatorSingleKey } from \"../transactions/authenticator/account\";\nimport { Deserializer, Serializable, Serializer } from \"../bcs\";\nimport { deriveTransactionType } from \"../transactions/transactionBuilder/signingMessage\";\nimport { AnyRawTransaction, AnyRawTransactionInstance } from \"../transactions/types\";\nimport { AptsoDomainSeparator, CryptoHashable } from \"../core/crypto/cryptoHasher\";\nimport { base64UrlDecode } from \"../utils/helpers\";\n\nexport const IssuerToJwkEndpoint: Record<string, string> = {\n \"https://accounts.google.com\": \"https://www.googleapis.com/oauth2/v3/certs\",\n};\n\n/**\n * Account implementation for the Keyless authentication scheme.\n *\n * Used to represent a Keyless based account and sign transactions with it.\n *\n * Use KeylessAccount.fromJWTAndProof to instantiate a KeylessAccount with a JWT, proof and EphemeralKeyPair.\n *\n * When the proof expires or the JWT becomes invalid, the KeylessAccount must be instantiated again with a new JWT,\n * EphemeralKeyPair, and corresponding proof.\n */\nexport class KeylessAccount extends Serializable implements Account {\n static readonly PEPPER_LENGTH: number = 31;\n\n /**\n * The KeylessPublicKey associated with the account\n */\n readonly publicKey: KeylessPublicKey;\n\n /**\n * The EphemeralKeyPair used to generate sign.\n */\n readonly ephemeralKeyPair: EphemeralKeyPair;\n\n /**\n * The claim on the JWT to identify a user. This is typically 'sub' or 'email'.\n */\n readonly uidKey: string;\n\n /**\n * The value of the uidKey claim on the JWT. This intended to be a stable user identifier.\n */\n readonly uidVal: string;\n\n /**\n * The value of the 'aud' claim on the JWT, also known as client ID. This is the identifier for the dApp's\n * OIDC registration with the identity provider.\n */\n readonly aud: string;\n\n /**\n * A value contains 31 bytes of entropy that preserves privacy of the account. Typically fetched from a pepper provider.\n */\n readonly pepper: Uint8Array;\n\n /**\n * Account address associated with the account\n */\n readonly accountAddress: AccountAddress;\n\n /**\n * The zero knowledge signature (if ready) which contains the proof used to validate the EphemeralKeyPair.\n */\n proof: ZeroKnowledgeSig | undefined;\n\n /**\n * The proof of the EphemeralKeyPair or a promise that provides the proof. This is used to allow for awaiting on\n * fetching the proof.\n */\n readonly proofOrPromise: ZeroKnowledgeSig | Promise<ZeroKnowledgeSig>;\n\n /**\n * Signing scheme used to sign transactions\n */\n readonly signingScheme: SigningScheme;\n\n /**\n * The JWT token used to derive the account\n */\n private jwt: string;\n\n /**\n * A value that caches the JWT's validity. A JWT becomes invalid when it's corresponding JWK is rotated from the\n * identity provider's JWK keyset.\n */\n private isJwtValid: boolean;\n\n /**\n * An event emitter used to assist in handling asycronous proof fetching.\n */\n private readonly emitter: EventEmitter<ProofFetchEvents>;\n\n constructor(args: {\n address?: AccountAddress;\n ephemeralKeyPair: EphemeralKeyPair;\n iss: string;\n uidKey: string;\n uidVal: string;\n aud: string;\n pepper: HexInput;\n proofOrFetcher: ZeroKnowledgeSig | Promise<ZeroKnowledgeSig>;\n proofFetchCallback?: ProofFetchCallback;\n jwt: string;\n }) {\n super();\n const { address, ephemeralKeyPair, uidKey, uidVal, aud, pepper, proofOrFetcher, proofFetchCallback, jwt } = args;\n this.ephemeralKeyPair = ephemeralKeyPair;\n this.publicKey = KeylessPublicKey.create(args);\n this.accountAddress = address ? AccountAddress.from(address) : this.publicKey.authKey().derivedAddress();\n this.uidKey = uidKey;\n this.uidVal = uidVal;\n this.aud = aud;\n this.jwt = jwt;\n this.emitter = new EventEmitter<ProofFetchEvents>();\n this.proofOrPromise = proofOrFetcher;\n if (proofOrFetcher instanceof ZeroKnowledgeSig) {\n this.proof = proofOrFetcher;\n } else {\n if (proofFetchCallback === undefined) {\n throw new Error(\"Must provide callback for async proof fetch\");\n }\n this.emitter.on(\"proofFetchFinish\", async (status) => {\n await proofFetchCallback(status);\n this.emitter.removeAllListeners();\n });\n this.init(proofOrFetcher);\n }\n this.signingScheme = SigningScheme.SingleKey;\n const pepperBytes = Hex.fromHexInput(pepper).toUint8Array();\n if (pepperBytes.length !== KeylessAccount.PEPPER_LENGTH) {\n throw new Error(`Pepper length in bytes should be ${KeylessAccount.PEPPER_LENGTH}`);\n }\n this.pepper = pepperBytes;\n this.isJwtValid = true;\n }\n\n /**\n * This initializes the asyncronous proof fetch\n * @return\n */\n async init(promise: Promise<ZeroKnowledgeSig>) {\n try {\n this.proof = await promise;\n this.emitter.emit(\"proofFetchFinish\", { status: \"Success\" });\n } catch (error) {\n if (error instanceof Error) {\n this.emitter.emit(\"proofFetchFinish\", { status: \"Failed\", error: error.toString() });\n } else {\n this.emitter.emit(\"proofFetchFinish\", { status: \"Failed\", error: \"Unknown\" });\n }\n }\n }\n\n serialize(serializer: Serializer): void {\n serializer.serializeStr(this.jwt);\n serializer.serializeStr(this.uidKey);\n serializer.serializeFixedBytes(this.pepper);\n this.ephemeralKeyPair.serialize(serializer);\n if (this.proof === undefined) {\n throw new Error(\"Connot serialize - proof undefined\");\n }\n this.proof.serialize(serializer);\n }\n\n static deserialize(deserializer: Deserializer): KeylessAccount {\n const jwt = deserializer.deserializeStr();\n const uidKey = deserializer.deserializeStr();\n const pepper = deserializer.deserializeFixedBytes(31);\n const ephemeralKeyPair = EphemeralKeyPair.deserialize(deserializer);\n const proof = ZeroKnowledgeSig.deserialize(deserializer);\n return KeylessAccount.fromJWTAndProof({\n proof,\n pepper,\n uidKey,\n jwt,\n ephemeralKeyPair,\n });\n }\n\n /**\n * Checks if the proof is expired. If so the account must be rederived with a new EphemeralKeyPair\n * and JWT token.\n * @return boolean\n */\n isExpired(): boolean {\n return this.ephemeralKeyPair.isExpired();\n }\n\n /**\n * Sign a message using Keyless.\n * @param message the message to sign, as binary input\n * @return the AccountAuthenticator containing the signature, together with the account's public key\n */\n signWithAuthenticator(message: HexInput): AccountAuthenticatorSingleKey {\n const signature = new AnySignature(this.sign(message));\n const publicKey = new AnyPublicKey(this.publicKey);\n return new AccountAuthenticatorSingleKey(publicKey, signature);\n }\n\n /**\n * Sign a transaction using Keyless.\n * @param transaction the raw transaction\n * @return the AccountAuthenticator containing the signature of the transaction, together with the account's public key\n */\n signTransactionWithAuthenticator(transaction: AnyRawTransaction): AccountAuthenticatorSingleKey {\n const signature = new AnySignature(this.signTransaction(transaction));\n const publicKey = new AnyPublicKey(this.publicKey);\n return new AccountAuthenticatorSingleKey(publicKey, signature);\n }\n\n /**\n * Waits for asyncronous proof fetching to finish.\n * @return\n */\n async waitForProofFetch() {\n if (this.proofOrPromise instanceof Promise) {\n await this.proofOrPromise;\n }\n }\n\n /**\n * Sign the given message using Keyless.\n * @param message in HexInput format\n * @returns Signature\n */\n sign(data: HexInput): KeylessSignature {\n const { expiryDateSecs } = this.ephemeralKeyPair;\n if (this.isExpired()) {\n throw new Error(\"EphemeralKeyPair is expired\");\n }\n if (this.proof === undefined) {\n throw new Error(\"Proof not defined\");\n }\n const ephemeralPublicKey = this.ephemeralKeyPair.getPublicKey();\n const ephemeralSignature = this.ephemeralKeyPair.sign(data);\n\n return new KeylessSignature({\n jwtHeader: base64UrlDecode(this.jwt.split(\".\")[0]),\n ephemeralCertificate: new EphemeralCertificate(this.proof, EphemeralCertificateVariant.ZkProof),\n expiryDateSecs,\n ephemeralPublicKey,\n ephemeralSignature,\n });\n }\n\n /**\n * Sign the given transaction with Keyless.\n * Signs the transaction and proof to guard against proof malleability.\n * @param transaction the transaction to be signed\n * @returns KeylessSignature\n */\n signTransaction(transaction: AnyRawTransaction): KeylessSignature {\n if (this.proof === undefined) {\n throw new Error(\"Proof not found\");\n }\n const raw = deriveTransactionType(transaction);\n const txnAndProof = new TransactionAndProof(raw, this.proof.proof);\n const signMess = txnAndProof.hash();\n return this.sign(signMess);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-unused-vars, class-methods-use-this\n verifySignature(args: { message: HexInput; signature: Signature }): boolean {\n throw new Error(\"Not implemented\");\n }\n\n static fromBytes(bytes: Uint8Array): KeylessAccount {\n return KeylessAccount.deserialize(new Deserializer(bytes));\n }\n\n static fromJWTAndProof(args: {\n proof: ZeroKnowledgeSig | Promise<ZeroKnowledgeSig>;\n jwt: string;\n ephemeralKeyPair: EphemeralKeyPair;\n pepper: HexInput;\n uidKey?: string;\n proofFetchCallback?: ProofFetchCallback;\n }): KeylessAccount {\n const { proof, jwt, ephemeralKeyPair, pepper, proofFetchCallback } = args;\n const uidKey = args.uidKey ?? \"sub\";\n\n const jwtPayload = jwtDecode<JwtPayload & { [key: string]: string }>(jwt);\n const iss = jwtPayload.iss!;\n if (typeof jwtPayload.aud !== \"string\") {\n throw new Error(\"aud was not found or an array of values\");\n }\n const aud = jwtPayload.aud!;\n const uidVal = jwtPayload[uidKey];\n return new KeylessAccount({\n proofOrFetcher: proof,\n ephemeralKeyPair,\n iss,\n uidKey,\n uidVal,\n aud,\n pepper,\n jwt,\n proofFetchCallback,\n });\n }\n}\n\n/**\n * A container class to hold a transaction and a proof. It implements CryptoHashable which is used to create\n * the signing message for Keyless transactions. We sign over the proof to ensure non-malleability.\n */\nexport class TransactionAndProof extends CryptoHashable {\n /**\n * The transaction to sign.\n */\n transaction: AnyRawTransactionInstance;\n\n /**\n * The zero knowledge proof used in signing the transaction.\n */\n proof?: ZkProof;\n\n /**\n * The domain separator prefix used when hashing.\n */\n domainSeparator: AptsoDomainSeparator;\n\n constructor(transaction: AnyRawTransactionInstance, proof?: ZkProof) {\n super();\n this.transaction = transaction;\n this.proof = proof;\n this.domainSeparator = \"APTOS::TransactionAndProof\";\n }\n\n serialize(serializer: Serializer): void {\n serializer.serializeFixedBytes(this.transaction.bcsToBytes());\n serializer.serializeOption(this.proof);\n }\n}\n\nexport type ProofFetchSuccess = {\n status: \"Success\";\n};\n\nexport type ProofFetchFailure = {\n status: \"Failed\";\n error: string;\n};\n\nexport type ProofFetchStatus = ProofFetchSuccess | ProofFetchFailure;\n\nexport type ProofFetchCallback = (status: ProofFetchStatus) => Promise<void>;\n\nexport interface ProofFetchEvents {\n proofFetchFinish: (status: ProofFetchStatus) => void;\n}\n"],"mappings":"+dAGA,OAAqB,aAAAA,MAAiB,aACtC,OAAOC,MAAkB,gBAwBlB,IAAMC,GAA8C,CACzD,8BAA+B,4CACjC,EAYaC,EAAN,MAAMA,UAAuBC,CAAgC,CAuElE,YAAYC,EAWT,CACD,MAAM,EACN,GAAM,CAAE,QAAAC,EAAS,iBAAAC,EAAkB,OAAAC,EAAQ,OAAAC,EAAQ,IAAAC,EAAK,OAAAC,EAAQ,eAAAC,EAAgB,mBAAAC,EAAoB,IAAAC,CAAI,EAAIT,EAU5G,GATA,KAAK,iBAAmBE,EACxB,KAAK,UAAYQ,EAAiB,OAAOV,CAAI,EAC7C,KAAK,eAAiBC,EAAUU,EAAe,KAAKV,CAAO,EAAI,KAAK,UAAU,QAAQ,EAAE,eAAe,EACvG,KAAK,OAASE,EACd,KAAK,OAASC,EACd,KAAK,IAAMC,EACX,KAAK,IAAMI,EACX,KAAK,QAAU,IAAIG,EACnB,KAAK,eAAiBL,EAClBA,aAA0BM,EAC5B,KAAK,MAAQN,MACR,CACL,GAAIC,IAAuB,OACzB,MAAM,IAAI,MAAM,6CAA6C,EAE/D,KAAK,QAAQ,GAAG,mBAAoB,MAAOM,GAAW,CACpD,MAAMN,EAAmBM,CAAM,EAC/B,KAAK,QAAQ,mBAAmB,CAClC,CAAC,EACD,KAAK,KAAKP,CAAc,CAC1B,CACA,KAAK,cAAgB,EACrB,IAAMQ,EAAcC,EAAI,aAAaV,CAAM,EAAE,aAAa,EAC1D,GAAIS,EAAY,SAAWjB,EAAe,cACxC,MAAM,IAAI,MAAM,oCAAoCA,EAAe,aAAa,EAAE,EAEpF,KAAK,OAASiB,EACd,KAAK,WAAa,EACpB,CAMA,MAAM,KAAKE,EAAoC,CAC7C,GAAI,CACF,KAAK,MAAQ,MAAMA,EACnB,KAAK,QAAQ,KAAK,mBAAoB,CAAE,OAAQ,SAAU,CAAC,CAC7D,OAASC,EAAO,CACVA,aAAiB,MACnB,KAAK,QAAQ,KAAK,mBAAoB,CAAE,OAAQ,SAAU,MAAOA,EAAM,SAAS,CAAE,CAAC,EAEnF,KAAK,QAAQ,KAAK,mBAAoB,CAAE,OAAQ,SAAU,MAAO,SAAU,CAAC,CAEhF,CACF,CAEA,UAAUC,EAA8B,CAKtC,GAJAA,EAAW,aAAa,KAAK,GAAG,EAChCA,EAAW,aAAa,KAAK,MAAM,EACnCA,EAAW,oBAAoB,KAAK,MAAM,EAC1C,KAAK,iBAAiB,UAAUA,CAAU,EACtC,KAAK,QAAU,OACjB,MAAM,IAAI,MAAM,oCAAoC,EAEtD,KAAK,MAAM,UAAUA,CAAU,CACjC,CAEA,OAAO,YAAYC,EAA4C,CAC7D,IAAMX,EAAMW,EAAa,eAAe,EAClCjB,EAASiB,EAAa,eAAe,EACrCd,EAASc,EAAa,sBAAsB,EAAE,EAC9ClB,EAAmBmB,EAAiB,YAAYD,CAAY,EAC5DE,EAAQT,EAAiB,YAAYO,CAAY,EACvD,OAAOtB,EAAe,gBAAgB,CACpC,MAAAwB,EACA,OAAAhB,EACA,OAAAH,EACA,IAAAM,EACA,iBAAAP,CACF,CAAC,CACH,CAOA,WAAqB,CACnB,OAAO,KAAK,iBAAiB,UAAU,CACzC,CAOA,sBAAsBqB,EAAkD,CACtE,IAAMC,EAAY,IAAIC,EAAa,KAAK,KAAKF,CAAO,CAAC,EAC/CG,EAAY,IAAIC,EAAa,KAAK,SAAS,EACjD,OAAO,IAAIC,EAA8BF,EAAWF,CAAS,CAC/D,CAOA,iCAAiCK,EAA+D,CAC9F,IAAML,EAAY,IAAIC,EAAa,KAAK,gBAAgBI,CAAW,CAAC,EAC9DH,EAAY,IAAIC,EAAa,KAAK,SAAS,EACjD,OAAO,IAAIC,EAA8BF,EAAWF,CAAS,CAC/D,CAMA,MAAM,mBAAoB,CACpB,KAAK,0BAA0B,SACjC,MAAM,KAAK,cAEf,CAOA,KAAKM,EAAkC,CACrC,GAAM,CAAE,eAAAC,CAAe,EAAI,KAAK,iBAChC,GAAI,KAAK,UAAU,EACjB,MAAM,IAAI,MAAM,6BAA6B,EAE/C,GAAI,KAAK,QAAU,OACjB,MAAM,IAAI,MAAM,mBAAmB,EAErC,IAAMC,EAAqB,KAAK,iBAAiB,aAAa,EACxDC,EAAqB,KAAK,iBAAiB,KAAKH,CAAI,EAE1D,OAAO,IAAII,EAAiB,CAC1B,UAAWC,EAAgB,KAAK,IAAI,MAAM,GAAG,EAAE,CAAC,CAAC,EACjD,qBAAsB,IAAIC,EAAqB,KAAK,OAA0C,EAC9F,eAAAL,EACA,mBAAAC,EACA,mBAAAC,CACF,CAAC,CACH,CAQA,gBAAgBJ,EAAkD,CAChE,GAAI,KAAK,QAAU,OACjB,MAAM,IAAI,MAAM,iBAAiB,EAEnC,IAAMQ,EAAMC,EAAsBT,CAAW,EAEvCU,EADc,IAAIC,EAAoBH,EAAK,KAAK,MAAM,KAAK,EACpC,KAAK,EAClC,OAAO,KAAK,KAAKE,CAAQ,CAC3B,CAGA,gBAAgBvC,EAA4D,CAC1E,MAAM,IAAI,MAAM,iBAAiB,CACnC,CAEA,OAAO,UAAUyC,EAAmC,CAClD,OAAO3C,EAAe,YAAY,IAAI4C,EAAaD,CAAK,CAAC,CAC3D,CAEA,OAAO,gBAAgBzC,EAOJ,CACjB,GAAM,CAAE,MAAAsB,EAAO,IAAAb,EAAK,iBAAAP,EAAkB,OAAAI,EAAQ,mBAAAE,CAAmB,EAAIR,EAC/DG,EAASH,EAAK,QAAU,MAExB2C,EAAaC,EAAkDnC,CAAG,EAClEoC,EAAMF,EAAW,IACvB,GAAI,OAAOA,EAAW,KAAQ,SAC5B,MAAM,IAAI,MAAM,yCAAyC,EAE3D,IAAMtC,EAAMsC,EAAW,IACjBvC,EAASuC,EAAWxC,CAAM,EAChC,OAAO,IAAIL,EAAe,CACxB,eAAgBwB,EAChB,iBAAApB,EACA,IAAA2C,EACA,OAAA1C,EACA,OAAAC,EACA,IAAAC,EACA,OAAAC,EACA,IAAAG,EACA,mBAAAD,CACF,CAAC,CACH,CACF,EAvRaV,EACK,cAAwB,GADnC,IAAMgD,EAANhD,EA6RM0C,EAAN,cAAkCO,CAAe,CAgBtD,YAAYlB,EAAwCP,EAAiB,CACnE,MAAM,EACN,KAAK,YAAcO,EACnB,KAAK,MAAQP,EACb,KAAK,gBAAkB,4BACzB,CAEA,UAAUH,EAA8B,CACtCA,EAAW,oBAAoB,KAAK,YAAY,WAAW,CAAC,EAC5DA,EAAW,gBAAgB,KAAK,KAAK,CACvC,CACF","names":["jwtDecode","EventEmitter","IssuerToJwkEndpoint","_KeylessAccount","Serializable","args","address","ephemeralKeyPair","uidKey","uidVal","aud","pepper","proofOrFetcher","proofFetchCallback","jwt","KeylessPublicKey","AccountAddress","EventEmitter","ZeroKnowledgeSig","status","pepperBytes","Hex","promise","error","serializer","deserializer","EphemeralKeyPair","proof","message","signature","AnySignature","publicKey","AnyPublicKey","AccountAuthenticatorSingleKey","transaction","data","expiryDateSecs","ephemeralPublicKey","ephemeralSignature","KeylessSignature","base64UrlDecode","EphemeralCertificate","raw","deriveTransactionType","signMess","TransactionAndProof","bytes","Deserializer","jwtPayload","jwtDecode","iss","KeylessAccount","CryptoHashable"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as r}from"./chunk-UMLUOYFK.mjs";import{b as t}from"./chunk-AOCNYMMX.mjs";var o=class extends r{toString(){let i=this.toUint8Array();return t.fromHexInput(i).toString()}};export{o as a};
|
|
2
|
+
//# sourceMappingURL=chunk-4VPCPASN.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as c}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as c}from"./chunk-FF4L66LJ.mjs";import{a as e,b as s,c as r,d as n,e as t,g as i,h as a}from"./chunk-KSSJ3CT5.mjs";var g=class{constructor(o){this.config=o}async getLedgerInfo(){return e({aptosConfig:this.config})}async getChainId(){return(await this.getLedgerInfo()).chain_id}async getBlockByVersion(o){return s({aptosConfig:this.config,...o})}async getBlockByHeight(o){return r({aptosConfig:this.config,...o})}async view(o){return c({aptosConfig:this.config,...o})}async getChainTopUserTransactions(o){return n({aptosConfig:this.config,...o})}async queryIndexer(o){return t({aptosConfig:this.config,...o})}async getIndexerLastSuccessVersion(){return i({aptosConfig:this.config})}async getProcessorStatus(o){return a({aptosConfig:this.config,processorType:o})}};export{g as a};
|
|
2
|
+
//# sourceMappingURL=chunk-5YH2YL3L.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{f as e,g as s,h as t,i as o,j as r,k as i,l as a,m,n as c,o as g,p as u,q as p,r as d}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{f as e,g as s,h as t,i as o,j as r,k as i,l as a,m,n as c,o as g,p as u,q as p,r as d}from"./chunk-PUP6XMAV.mjs";var A=class{constructor(n){this.config=n}async getOwnerAddress(n){return e({aptosConfig:this.config,...n})}async getExpiration(n){return t({aptosConfig:this.config,...n})}async getTargetAddress(n){return i({aptosConfig:this.config,...n})}async setTargetAddress(n){return a({aptosConfig:this.config,...n})}async getPrimaryName(n){return o({aptosConfig:this.config,...n})}async setPrimaryName(n){return r({aptosConfig:this.config,...n})}async registerName(n){return s({aptosConfig:this.config,...n})}async renewDomain(n){return d({aptosConfig:this.config,...n})}async getName(n){return m({aptosConfig:this.config,...n})}async getAccountNames(n){return c({aptosConfig:this.config,...n})}async getAccountDomains(n){return g({aptosConfig:this.config,...n})}async getAccountSubdomains(n){return u({aptosConfig:this.config,...n})}async getDomainSubdomains(n){return p({aptosConfig:this.config,...n})}};export{A as a};
|
|
2
|
+
//# sourceMappingURL=chunk-6DFVM2W6.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as t}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as t}from"./chunk-VCAURUJ3.mjs";var o=class{constructor(n){this.config=n}async simple(n){return t({aptosConfig:this.config,...n})}async multiAgent(n){return t({aptosConfig:this.config,...n})}};export{o as a};
|
|
2
|
+
//# sourceMappingURL=chunk-6FK6OA37.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as l}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as l}from"./chunk-SBEZ64HG.mjs";import{a as o,b as c}from"./chunk-U6Z4FNB7.mjs";import{a as h,h as d}from"./chunk-VCAURUJ3.mjs";import{g as u}from"./chunk-KUMZXNMD.mjs";import g from"eventemitter3";var m="fulfilled",f=(n=>(n.TransactionSent="transactionSent",n.TransactionSendFailed="transactionSendFailed",n.TransactionExecuted="transactionExecuted",n.TransactionExecutionFailed="transactionExecutionFailed",n.ExecutionFinish="executionFinish",n))(f||{}),p=class extends g{constructor(t,e,a=30,n=100,i=10){super();this.taskQueue=new o;this.transactionsQueue=new o;this.outstandingTransactions=new o;this.sentTransactions=[];this.executedTransactions=[];this.aptosConfig=t,this.account=e,this.started=!1,this.accountSequnceNumber=new l(t,e,a,n,i)}async submitNextTransaction(){try{for(;;){let t=await this.accountSequnceNumber.nextSequenceNumber();if(t===null)return;let e=await this.generateNextTransaction(this.account,t);if(!e)return;let a=d({aptosConfig:this.aptosConfig,transaction:e,signer:this.account});await this.outstandingTransactions.enqueue([a,t])}}catch(t){if(t instanceof c)return;throw new Error(`Submit transaction failed for ${this.account.accountAddress.toString()} with error ${t}`)}}async processTransactions(){try{for(;;){let t=[],e=[],[a,n]=await this.outstandingTransactions.dequeue();for(t.push(a),e.push(n);!this.outstandingTransactions.isEmpty();)[a,n]=await this.outstandingTransactions.dequeue(),t.push(a),e.push(n);let i=await Promise.allSettled(t);for(let s=0;s<i.length&&s<e.length;s+=1){let r=i[s];n=e[s],r.status===m?(this.sentTransactions.push([r.value.hash,n,null]),this.emit("transactionSent",{message:`transaction hash ${r.value.hash} has been committed to chain`,transactionHash:r.value.hash}),await this.checkTransaction(r,n)):(this.sentTransactions.push([r.status,n,r.reason]),this.emit("transactionSendFailed",{message:`failed to commit transaction ${this.sentTransactions.length} with error ${r.reason}`,error:r.reason}))}this.emit("executionFinish",{message:`execute ${i.length} transactions finished`})}}catch(t){if(t instanceof c)return;throw new Error(`Process execution failed for ${this.account.accountAddress.toString()} with error ${t}`)}}async checkTransaction(t,e){try{let a=[];a.push(u({aptosConfig:this.aptosConfig,transactionHash:t.value.hash}));let n=await Promise.allSettled(a);for(let i=0;i<n.length;i+=1){let s=n[i];s.status===m?(this.executedTransactions.push([s.value.hash,e,null]),this.emit("transactionExecuted",{message:`transaction hash ${s.value.hash} has been executed on chain`,transactionHash:t.value.hash})):(this.executedTransactions.push([s.status,e,s.reason]),this.emit("transactionExecutionFailed",{message:`failed to execute transaction ${this.executedTransactions.length} with error ${s.reason}`,error:s.reason}))}}catch(a){throw new Error(`Check transaction failed for ${this.account.accountAddress.toString()} with error ${a}`)}}async push(t,e){this.transactionsQueue.enqueue([t,e])}async generateNextTransaction(t,e){if(this.transactionsQueue.isEmpty())return;let[a,n]=await this.transactionsQueue.dequeue();return h({aptosConfig:this.aptosConfig,sender:t.accountAddress,data:a,options:{...n,accountSequenceNumber:e}})}async run(){try{for(;!this.taskQueue.isCancelled();)await(await this.taskQueue.dequeue())()}catch(t){throw new Error(`Unable to start transaction batching: ${t}`)}}start(){if(this.started)throw new Error("worker has already started");this.started=!0,this.taskQueue.enqueue(()=>this.submitNextTransaction()),this.taskQueue.enqueue(()=>this.processTransactions()),this.run()}stop(){if(this.taskQueue.isCancelled())throw new Error("worker has already stopped");this.started=!1,this.taskQueue.cancel()}};export{m as a,f as b,p as c};
|
|
2
|
+
//# sourceMappingURL=chunk-6GGHUBUA.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as r}from"./chunk-UMLUOYFK.mjs";import{b as i}from"./chunk-AOCNYMMX.mjs";var t=class a extends r{constructor(e){super();this.value=i.fromHexInput(e).toUint8Array()}serialize(e){e.serializeFixedBytes(this.value)}serializeForEntryFunction(e){e.serialize(this)}serializeForScriptFunction(e){e.serialize(this)}static deserialize(e,s){let o=e.deserializeFixedBytes(s);return new a(o)}};export{t as a};
|
|
2
|
+
//# sourceMappingURL=chunk-7BW2N4IE.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as l}from"./chunk-4TDMJQOJ.mjs";import{e as o}from"./chunk-RYRID5HT.mjs";import{a as g,b as c}from"./chunk-E4XMEVB7.mjs";var y=class a{constructor(i){let{multiKey:e,signers:s}=i;this.publicKey=e,this.signingScheme=3,this.accountAddress=this.publicKey.authKey().derivedAddress();let r=[];for(let t of s)r.push(this.publicKey.getIndex(t.publicKey));let n=s.map((t,u)=>[t,r[u]]);n.sort((t,u)=>t[1]-u[1]),this.signers=n.map(t=>t[0]),this.signerIndicies=n.map(t=>t[1]),this.signaturesBitmap=this.publicKey.createBitmap({bits:r})}static fromPublicKeysAndSigners(i){let{publicKeys:e,signaturesRequired:s,signers:r}=i,n=new g({publicKeys:e,signaturesRequired:s});return new a({multiKey:n,signers:r})}static isMultiKeySigner(i){return i instanceof a}signWithAuthenticator(i){return new o(this.publicKey,this.sign(i))}signTransactionWithAuthenticator(i){return new o(this.publicKey,this.signTransaction(i))}async waitForProofFetch(){let i=this.signers.filter(e=>e instanceof l);await Promise.all(i.filter(e=>e.proof instanceof Promise).map(e=>e.proof))}sign(i){let e=[];for(let s of this.signers)e.push(s.sign(i));return new c({signatures:e,bitmap:this.signaturesBitmap})}signTransaction(i){let e=[];for(let s of this.signers)e.push(s.signTransaction(i));return new c({signatures:e,bitmap:this.signaturesBitmap})}verifySignature(i){let{message:e,signature:s}=i;if(!this.signerIndicies.every((n,t)=>t===0||n>=this.signerIndicies[t-1]))return!1;for(let n=0;n<s.signatures.length;n+=1){let t=s.signatures[n];if(!this.publicKey.publicKeys[this.signerIndicies[n]].verifySignature({message:e,signature:t}))return!1}return!0}};export{y as a};
|
|
2
|
+
//# sourceMappingURL=chunk-7JLHN655.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{h as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{h as e}from"./chunk-KUMZXNMD.mjs";async function i(o){o.minimumLedgerVersion!==void 0&&await e({aptosConfig:o.config,minimumLedgerVersion:o.minimumLedgerVersion,processorType:o.processorType})}export{i as a};
|
|
2
|
+
//# sourceMappingURL=chunk-7XRUPEQ4.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{c as a}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{c as a}from"./chunk-6GGHUBUA.mjs";import e from"eventemitter3";var i=class extends e{constructor(t){super();this.config=t}start(t){let{sender:n}=t;this.account=n,this.transactionWorker=new a(this.config,n),this.transactionWorker.start(),this.registerToEvents()}push(t){let{data:n,options:o}=t;for(let r of n)this.transactionWorker.push(r,o)}registerToEvents(){this.transactionWorker.on("transactionSent",async t=>{this.emit("transactionSent",t)}),this.transactionWorker.on("transactionSendFailed",async t=>{this.emit("transactionSendFailed",t)}),this.transactionWorker.on("transactionExecuted",async t=>{this.emit("transactionExecuted",t)}),this.transactionWorker.on("transactionExecutionFailed",async t=>{this.emit("transactionExecutionFailed",t)}),this.transactionWorker.on("executionFinish",async t=>{this.emit("executionFinish",t)})}forSingleAccount(t){try{let{sender:n,data:o,options:r}=t;this.start({sender:n}),this.push({data:o,options:r})}catch(n){throw new Error(`failed to submit transactions with error: ${n}`)}}};export{i as a};
|
|
2
|
+
//# sourceMappingURL=chunk-B76XCRLH.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as d}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as d}from"./chunk-WA2NTBYY.mjs";import{a as v}from"./chunk-4VPCPASN.mjs";import{a as u}from"./chunk-TJDC5PWD.mjs";import{e as h,j as f}from"./chunk-LR65XHSF.mjs";import{a as g}from"./chunk-UMLUOYFK.mjs";import{b as s}from"./chunk-AOCNYMMX.mjs";import{sha3_256 as A}from"@noble/hashes/sha3";import{secp256k1 as o}from"@noble/curves/secp256k1";import{HDKey as U}from"@scure/bip32";var n=class n extends d{constructor(e){super();let r=s.fromHexInput(e);if(r.toUint8Array().length!==n.LENGTH)throw new Error(`PublicKey length should be ${n.LENGTH}`);this.key=r}verifySignature(e){let{message:r,signature:i}=e;if(!(i instanceof y))return!1;let l=u(r),c=s.fromHexInput(l).toUint8Array(),x=A(c),S=i.toUint8Array();return o.verify(S,x,this.key.toUint8Array(),{lowS:!0})}toUint8Array(){return this.key.toUint8Array()}serialize(e){e.serializeBytes(this.key.toUint8Array())}static deserialize(e){let r=e.deserializeBytes();return new n(r)}static isPublicKey(e){return e instanceof n}};n.LENGTH=65;var m=n,t=class t extends g{constructor(e){super();let r=s.fromHexInput(e);if(r.toUint8Array().length!==t.LENGTH)throw new Error(`PrivateKey length should be ${t.LENGTH}`);this.key=r}static generate(){let e=o.utils.randomPrivateKey();return new t(e)}static fromDerivationPath(e,r){if(!h(e))throw new Error(`Invalid derivation path ${e}`);return t.fromDerivationPathInner(e,f(r))}static fromDerivationPathInner(e,r){let{privateKey:i}=U.fromMasterSeed(r).derive(e);if(i===null)throw new Error("Invalid key");return new t(i)}sign(e){let r=u(e),i=s.fromHexInput(r),l=A(i.toUint8Array()),c=o.sign(l,this.key.toUint8Array(),{lowS:!0});return new y(c.toCompactRawBytes())}publicKey(){let e=o.getPublicKey(this.key.toUint8Array(),!1);return new m(e)}toUint8Array(){return this.key.toUint8Array()}toString(){return this.key.toString()}serialize(e){e.serializeBytes(this.toUint8Array())}static deserialize(e){let r=e.deserializeBytes();return new t(r)}static isPrivateKey(e){return e instanceof t}};t.LENGTH=32;var H=t,a=class a extends v{constructor(e){super();let r=s.fromHexInput(e);if(r.toUint8Array().length!==a.LENGTH)throw new Error(`Signature length should be ${a.LENGTH}, received ${r.toUint8Array().length}`);this.data=r}toUint8Array(){return this.data.toUint8Array()}serialize(e){e.serializeBytes(this.data.toUint8Array())}static deserialize(e){let r=e.deserializeBytes();return new a(r)}};a.LENGTH=64;var y=a;export{m as a,H as b,y as c};
|
|
2
|
+
//# sourceMappingURL=chunk-BO44HPGU.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as p}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as p}from"./chunk-YBXQVY7N.mjs";async function o(e){let{type:t,originMethod:s,path:i,body:r,acceptType:R,contentType:f,params:c,aptosConfig:n,overrides:A}=e,d=n.getRequestUrl(t);return p({url:d,method:"POST",originMethod:s,path:i,body:r,contentType:f,acceptType:R,params:c,overrides:A},n,e.type)}async function q(e){let{aptosConfig:t}=e;return o({...e,type:"Fullnode",overrides:{...t.clientConfig,...t.fullnodeConfig,...e.overrides,HEADERS:{...t.clientConfig?.HEADERS,...t.fullnodeConfig?.HEADERS}}})}async function C(e){let{aptosConfig:t}=e;return o({...e,type:"Indexer",overrides:{...t.clientConfig,...t.indexerConfig,...e.overrides,HEADERS:{...t.clientConfig?.HEADERS,...t.indexerConfig?.HEADERS}}})}async function m(e){let{aptosConfig:t}=e,s={...t,clientConfig:{...t.clientConfig}};return delete s?.clientConfig?.API_KEY,o({...e,type:"Faucet",overrides:{...s.clientConfig,...s.faucetConfig,...e.overrides,HEADERS:{...s.clientConfig?.HEADERS,...s.faucetConfig?.HEADERS}}})}async function E(e){return o({...e,type:"Pepper"})}async function a(e){return o({...e,type:"Prover"})}export{o as a,q as b,C as c,m as d,E as e,a as f};
|
|
2
|
+
//# sourceMappingURL=chunk-CVCM46UN.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as c}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as c}from"./chunk-F3ZVWLDH.mjs";import{sha3_256 as n}from"@noble/hashes/sha3";var d=(e,r)=>{let t=e.bcsToBytes(),s=typeof r=="string"?Buffer.from(r,"utf8"):r,o=new Uint8Array([...t,...s,254]);return new c(n(o))},f=(e,r)=>{let t=e.bcsToBytes(),s=typeof r=="string"?Buffer.from(r,"utf8"):r,o=new Uint8Array([...t,...s,255]);return new c(n(o))},a=(e,r,t)=>{let s=`${r}::${t}`;return d(e,s)};export{d as a,f as b,a as c};
|
|
2
|
+
//# sourceMappingURL=chunk-DPWEHSHH.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as u,b as l}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as u,b as l}from"./chunk-XGDLSWBF.mjs";import{b as g}from"./chunk-WA2NTBYY.mjs";import{a as f}from"./chunk-4VPCPASN.mjs";import{a as m}from"./chunk-EFMAZTIM.mjs";function A(y){let o=y;return o-=o>>1&1431655765,o=(o&858993459)+(o>>2&858993459),(o+(o>>4)&252645135)*16843009>>24}var p=class y extends g{constructor(e){super();let{publicKeys:r,signaturesRequired:t}=e;if(t<1)throw new Error("The number of required signatures needs to be greater than 0");if(r.length<t)throw new Error(`Provided ${r.length} public keys is smaller than the ${t} required signatures`);this.publicKeys=r.map(i=>i instanceof u?i:new u(i)),this.signaturesRequired=t}verifySignature(e){throw new Error("not implemented")}authKey(){return m.fromSchemeAndBytes({scheme:3,input:this.toUint8Array()})}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeVector(this.publicKeys),e.serializeU8(this.signaturesRequired)}static deserialize(e){let r=e.deserializeVector(u),t=e.deserializeU8();return new y({publicKeys:r,signaturesRequired:t})}createBitmap(e){let{bits:r}=e,t=128,i=new Uint8Array([0,0,0,0]),a=new Set;return r.forEach((n,c)=>{if(c+1>this.publicKeys.length)throw new Error(`Signature index ${c+1} is out of public keys range, ${this.publicKeys.length}.`);if(a.has(n))throw new Error(`Duplicate bit ${n} detected.`);a.add(n);let h=Math.floor(n/8),b=i[h];b|=t>>n%8,i[h]=b}),i}getIndex(e){let r=e instanceof u?e:new u(e),t=this.publicKeys.findIndex(i=>i.toString()===r.toString());if(t!==-1)return t;throw new Error("Public key not found in MultiKey")}},s=class s extends f{constructor(e){super();let{signatures:r,bitmap:t}=e;if(r.length>s.MAX_SIGNATURES_SUPPORTED)throw new Error(`The number of signatures cannot be greater than ${s.MAX_SIGNATURES_SUPPORTED}`);if(this.signatures=r.map(a=>a instanceof l?a:new l(a)),!(t instanceof Uint8Array))this.bitmap=s.createBitmap({bits:t});else{if(t.length!==s.BITMAP_LEN)throw new Error(`"bitmap" length should be ${s.BITMAP_LEN}`);this.bitmap=t}let i=this.bitmap.reduce((a,n)=>a+A(n),0);if(i!==this.signatures.length)throw new Error(`Expecting ${i} signatures from the bitmap, but got ${this.signatures.length}`)}static createBitmap(e){let{bits:r}=e,t=128,i=new Uint8Array([0,0,0,0]),a=new Set;return r.forEach(n=>{if(n>=s.MAX_SIGNATURES_SUPPORTED)throw new Error(`Cannot have a signature larger than ${s.MAX_SIGNATURES_SUPPORTED-1}.`);if(a.has(n))throw new Error("Duplicate bits detected.");a.add(n);let c=Math.floor(n/8),h=i[c];h|=t>>n%8,i[c]=h}),i}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeVector(this.signatures),e.serializeBytes(this.bitmap)}static deserialize(e){let r=e.deserializeVector(l),t=e.deserializeBytes();return new s({signatures:r,bitmap:t})}};s.BITMAP_LEN=4,s.MAX_SIGNATURES_SUPPORTED=s.BITMAP_LEN*8;var d=s;export{p as a,d as b};
|
|
2
|
+
//# sourceMappingURL=chunk-E4XMEVB7.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as s}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as s}from"./chunk-F3ZVWLDH.mjs";import{a as o}from"./chunk-UMLUOYFK.mjs";import{b as n}from"./chunk-AOCNYMMX.mjs";import{sha3_256 as d}from"@noble/hashes/sha3";var r=class r extends o{constructor(t){super();let{data:e}=t,i=n.fromHexInput(e);if(i.toUint8Array().length!==r.LENGTH)throw new Error(`Authentication Key length should be ${r.LENGTH}`);this.data=i}serialize(t){t.serializeFixedBytes(this.data.toUint8Array())}static deserialize(t){let e=t.deserializeFixedBytes(r.LENGTH);return new r({data:e})}toString(){return this.data.toString()}toUint8Array(){return this.data.toUint8Array()}static fromSchemeAndBytes(t){let{scheme:e,input:i}=t,u=n.fromHexInput(i).toUint8Array(),h=new Uint8Array([...u,e]),a=d.create();a.update(h);let y=a.digest();return new r({data:y})}static fromPublicKeyAndScheme(t){let{publicKey:e}=t;return e.authKey()}static fromPublicKey(t){let{publicKey:e}=t;return e.authKey()}derivedAddress(){return new s(this.data.toUint8Array())}};r.LENGTH=32;var c=r;export{c as a};
|
|
2
|
+
//# sourceMappingURL=chunk-EFMAZTIM.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{e as s}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{e as s}from"./chunk-KSSJ3CT5.mjs";import{w as i,x as m}from"./chunk-S3EDNXZE.mjs";import{b as n}from"./chunk-CVCM46UN.mjs";async function b(t){let{aptosConfig:a,handle:e,data:o,options:r}=t;return(await n({aptosConfig:a,originMethod:"getTableItem",path:`tables/${e}/item`,params:{ledger_version:r?.ledgerVersion},body:o})).data}async function f(t){let{aptosConfig:a,options:e}=t,o={query:i,variables:{where_condition:e?.where,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await s({aptosConfig:a,query:o,originMethod:"getTableItemsData"})).table_items}async function T(t){let{aptosConfig:a,options:e}=t,o={query:m,variables:{where_condition:e?.where,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await s({aptosConfig:a,query:o,originMethod:"getTableItemsMetadata"})).table_metadatas}export{b as a,f as b,T as c};
|
|
2
|
+
//# sourceMappingURL=chunk-EQN6FVO7.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a}from"./chunk-UMLUOYFK.mjs";import{a as i}from"./chunk-FBPNHF54.mjs";import{bytesToHex as o,hexToBytes as l}from"@noble/hashes/utils";var h=(s=>(s.INCORRECT_NUMBER_OF_BYTES="incorrect_number_of_bytes",s.INVALID_HEX_CHARS="invalid_hex_chars",s.TOO_SHORT="too_short",s.TOO_LONG="too_long",s.LEADING_ZERO_X_REQUIRED="leading_zero_x_required",s.LONG_FORM_REQUIRED_UNLESS_SPECIAL="long_form_required_unless_special",s.INVALID_PADDING_ZEROES="INVALID_PADDING_ZEROES",s))(h||{}),r=class r extends a{constructor(t){super();if(t.length!==r.LENGTH)throw new i("AccountAddress data should be exactly 32 bytes long","incorrect_number_of_bytes");this.data=t}isSpecial(){return this.data.slice(0,this.data.length-1).every(t=>t===0)&&this.data[this.data.length-1]<16}toString(){return`0x${this.toStringWithoutPrefix()}`}toStringWithoutPrefix(){let t=o(this.data);return this.isSpecial()&&(t=t[t.length-1]),t}toStringLong(){return`0x${this.toStringLongWithoutPrefix()}`}toStringLongWithoutPrefix(){return o(this.data)}toUint8Array(){return this.data}serialize(t){t.serializeFixedBytes(this.data)}serializeForEntryFunction(t){let e=this.bcsToBytes();t.serializeBytes(e)}serializeForScriptFunction(t){t.serializeU32AsUleb128(3),t.serialize(this)}static deserialize(t){let e=t.deserializeFixedBytes(r.LENGTH);return new r(e)}static fromStringStrict(t){if(!t.startsWith("0x"))throw new i("Hex string must start with a leading 0x.","leading_zero_x_required");let e=r.fromString(t);if(t.length!==r.LONG_STRING_LENGTH+2)if(e.isSpecial()){if(t.length!==3)throw new i(`The given hex string ${t} is a special address not in LONG form, it must be 0x0 to 0xf without padding zeroes.`,"INVALID_PADDING_ZEROES")}else throw new i(`The given hex string ${t} is not a special address, it must be represented as 0x + 64 chars.`,"long_form_required_unless_special");return e}static fromString(t){let e=t;if(t.startsWith("0x")&&(e=t.slice(2)),e.length===0)throw new i("Hex string is too short, must be 1 to 64 chars long, excluding the leading 0x.","too_short");if(e.length>64)throw new i("Hex string is too long, must be 1 to 64 chars long, excluding the leading 0x.","too_long");let n;try{n=l(e.padStart(64,"0"))}catch(d){throw new i(`Hex characters are invalid: ${d?.message}`,"invalid_hex_chars")}return new r(n)}static from(t){return t instanceof r?t:t instanceof Uint8Array?new r(t):r.fromString(t)}static fromStrict(t){return t instanceof r?t:t instanceof Uint8Array?new r(t):r.fromStringStrict(t)}static isValid(t){try{return t.strict?r.fromStrict(t.input):r.from(t.input),{valid:!0}}catch(e){return{valid:!1,invalidReason:e?.invalidReason,invalidReasonMessage:e?.message}}}equals(t){return this.data.length!==t.data.length?!1:this.data.every((e,n)=>e===t.data[n])}};r.LENGTH=32,r.LONG_STRING_LENGTH=64,r.ZERO=r.from("0x0"),r.ONE=r.from("0x1"),r.TWO=r.from("0x2"),r.THREE=r.from("0x3"),r.FOUR=r.from("0x4");var c=r;export{h as a,c as b};
|
|
2
|
+
//# sourceMappingURL=chunk-F3ZVWLDH.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{c as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{c as r}from"./chunk-I7GRECEJ.mjs";import{b as i}from"./chunk-CVCM46UN.mjs";import{b as t}from"./chunk-UMLUOYFK.mjs";async function v(a){let{aptosConfig:o,payload:n,options:s}=a,p=await r({...n,aptosConfig:o}),e=new t;p.serialize(e);let l=e.toUint8Array(),{data:d}=await i({aptosConfig:o,path:"view",originMethod:"view",contentType:"application/x.aptos.view_function+bcs",params:{ledger_version:s?.ledgerVersion},body:l});return d}export{v as a};
|
|
2
|
+
//# sourceMappingURL=chunk-FF4L66LJ.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as l,b as s,c as u,d as c,e as d,f as m,g as U}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as l,b as s,c as u,d as c,e as d,f as m,g as U}from"./chunk-IBN7ETCB.mjs";import{a as o}from"./chunk-UMLUOYFK.mjs";import{b as z}from"./chunk-AOCNYMMX.mjs";var t=class n extends o{constructor(e){super();this.values=e}serializeForEntryFunction(e){let r=this.bcsToBytes();e.serializeBytes(r)}serializeForScriptFunction(e){if(!(this.values[0]instanceof s)&&this.values[0]!==void 0)throw new Error("Script function arguments only accept u8 vectors");e.serializeU32AsUleb128(4),e.serialize(this)}static U8(e){let r;if(Array.isArray(e)&&typeof e[0]=="number")r=e;else if(typeof e=="string"){let i=z.fromHexInput(e);r=Array.from(i.toUint8Array())}else if(e instanceof Uint8Array)r=Array.from(e);else throw new Error("Invalid input type");return new n(r.map(i=>new s(i)))}static U16(e){return new n(e.map(r=>new u(r)))}static U32(e){return new n(e.map(r=>new c(r)))}static U64(e){return new n(e.map(r=>new d(r)))}static U128(e){return new n(e.map(r=>new m(r)))}static U256(e){return new n(e.map(r=>new U(r)))}static Bool(e){return new n(e.map(r=>new l(r)))}static MoveString(e){return new n(e.map(r=>new a(r)))}serialize(e){e.serializeVector(this.values)}static deserialize(e,r){let i=e.deserializeUleb128AsU32(),y=new Array;for(let w=0;w<i;w+=1)y.push(r.deserialize(e));return new n(y)}},a=class n extends o{constructor(e){super();this.value=e}serialize(e){e.serializeStr(this.value)}serializeForEntryFunction(e){let r=this.bcsToBytes();e.serializeBytes(r)}serializeForScriptFunction(e){let r=this.bcsToBytes().slice(1);t.U8(r).serializeForScriptFunction(e)}static deserialize(e){return new n(e.deserializeStr())}},f=class n extends o{constructor(e){super();typeof e<"u"&&e!==null?this.vec=new t([e]):this.vec=new t([]),[this.value]=this.vec.values}serializeForEntryFunction(e){let r=this.bcsToBytes();e.serializeBytes(r)}unwrap(){if(this.isSome())return this.vec.values[0];throw new Error("Called unwrap on a MoveOption with no value")}isSome(){return this.vec.values.length===1}serialize(e){this.vec.serialize(e)}static U8(e){return new n(e!=null?new s(e):void 0)}static U16(e){return new n(e!=null?new u(e):void 0)}static U32(e){return new n(e!=null?new c(e):void 0)}static U64(e){return new n(e!=null?new d(e):void 0)}static U128(e){return new n(e!=null?new m(e):void 0)}static U256(e){return new n(e!=null?new U(e):void 0)}static Bool(e){return new n(e!=null?new l(e):void 0)}static MoveString(e){return new n(e!=null?new a(e):void 0)}static deserialize(e,r){let i=t.deserialize(e,r);return new n(i.values[0])}};export{t as a,a as b,f as c};
|
|
2
|
+
//# sourceMappingURL=chunk-FGGRPEQ3.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as m}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as m}from"./chunk-MLX6DFMR.mjs";import{a as g}from"./chunk-TUCCV62K.mjs";import{a as p}from"./chunk-GSCM444Z.mjs";import{b as y}from"./chunk-F3ZVWLDH.mjs";import{a as S}from"./chunk-GRHLQDHF.mjs";import{a as v}from"./chunk-FGGRPEQ3.mjs";import{a as F,b as d,c as T,d as x,e as E,f as _,g as w}from"./chunk-IBN7ETCB.mjs";import{a as u}from"./chunk-UMLUOYFK.mjs";function D(r){let e=r.deserializeUleb128AsU32();switch(e){case 0:return d.deserialize(r);case 1:return E.deserialize(r);case 2:return _.deserialize(r);case 3:return y.deserialize(r);case 4:return v.deserialize(r,d);case 5:return F.deserialize(r);case 6:return T.deserialize(r);case 7:return x.deserialize(r);case 8:return w.deserialize(r);default:throw new Error(`Unknown variant index for ScriptTransactionArgument: ${e}`)}}var a=class extends u{static deserialize(e){let t=e.deserializeUleb128AsU32();switch(t){case 0:return A.load(e);case 2:return z.load(e);case 3:return h.load(e);default:throw new Error(`Unknown variant index for TransactionPayload: ${t}`)}}},A=class r extends a{constructor(t){super();this.script=t}serialize(t){t.serializeU32AsUleb128(0),this.script.serialize(t)}static load(t){let i=U.deserialize(t);return new r(i)}},z=class r extends a{constructor(t){super();this.entryFunction=t}serialize(t){t.serializeU32AsUleb128(2),this.entryFunction.serialize(t)}static load(t){let i=l.deserialize(t);return new r(i)}},h=class r extends a{constructor(t){super();this.multiSig=t}serialize(t){t.serializeU32AsUleb128(3),this.multiSig.serialize(t)}static load(t){let i=f.deserialize(t);return new r(i)}},l=class r{constructor(e,t,i,n){this.module_name=e,this.function_name=t,this.type_args=i,this.args=n}static build(e,t,i,n){return new r(g.fromStr(e),new p(t),i,n)}serialize(e){this.module_name.serialize(e),this.function_name.serialize(e),e.serializeVector(this.type_args),e.serializeU32AsUleb128(this.args.length),this.args.forEach(t=>{t.serializeForEntryFunction(e)})}static deserialize(e){let t=g.deserialize(e),i=p.deserialize(e),n=e.deserializeVector(m),o=e.deserializeUleb128AsU32(),s=new Array;for(let c=0;c<o;c+=1){let M=e.deserializeUleb128AsU32(),B=S.deserialize(e,M);s.push(B)}return new r(t,i,n,s)}},U=class r{constructor(e,t,i){this.bytecode=e,this.type_args=t,this.args=i}serialize(e){e.serializeBytes(this.bytecode),e.serializeVector(this.type_args),e.serializeU32AsUleb128(this.args.length),this.args.forEach(t=>{t.serializeForScriptFunction(e)})}static deserialize(e){let t=e.deserializeBytes(),i=e.deserializeVector(m),n=e.deserializeUleb128AsU32(),o=new Array;for(let s=0;s<n;s+=1){let c=D(e);o.push(c)}return new r(t,i,o)}},f=class r{constructor(e,t){this.multisig_address=e,this.transaction_payload=t}serialize(e){this.multisig_address.serialize(e),this.transaction_payload===void 0?e.serializeBool(!1):(e.serializeBool(!0),this.transaction_payload.serialize(e))}static deserialize(e){let t=y.deserialize(e),i=e.deserializeBool(),n;return i&&(n=b.deserialize(e)),new r(t,n)}},b=class r extends u{constructor(t){super();this.transaction_payload=t}serialize(t){t.serializeU32AsUleb128(0),this.transaction_payload.serialize(t)}static deserialize(t){return t.deserializeUleb128AsU32(),new r(l.deserialize(t))}};export{D as a,a as b,A as c,z as d,h as e,l as f,U as g,f as h,b as i};
|
|
2
|
+
//# sourceMappingURL=chunk-FIG65OJD.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/version.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\n/**\n * The current version of the SDK\n *\n * hardcoded for now, we would want to have it injected dynamically\n */\nexport const VERSION = \"1.16.0-zeta.
|
|
1
|
+
{"version":3,"sources":["../../src/version.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\n/**\n * The current version of the SDK\n *\n * hardcoded for now, we would want to have it injected dynamically\n */\nexport const VERSION = \"1.16.0-zeta.2\";\n"],"mappings":"AAQO,IAAMA,EAAU","names":["VERSION"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as i}from"./chunk-6EMN3BOV.mjs";import{g as a}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as i}from"./chunk-6EMN3BOV.mjs";import{g as a}from"./chunk-VCAURUJ3.mjs";import{a as o}from"./chunk-FVA2OPG4.mjs";var n=class{constructor(t){this.config=t}async simple(t){return a({aptosConfig:this.config,...t})}async multiAgent(t){return a({aptosConfig:this.config,...t})}};o([i],n.prototype,"simple",1),o([i],n.prototype,"multiAgent",1);export{n as a};
|
|
2
|
+
//# sourceMappingURL=chunk-FUKWM4HL.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as i}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as i}from"./chunk-7BW2N4IE.mjs";import{a as r}from"./chunk-UMLUOYFK.mjs";var t=class l extends r{constructor(e){super();this.value=new i(e)}serialize(e){e.serialize(this.value)}serializeForEntryFunction(e){e.serializeU32AsUleb128(this.value.value.length),e.serialize(this)}static deserialize(e,s){let a=i.deserialize(e,s);return new l(a.value)}};export{t as a};
|
|
2
|
+
//# sourceMappingURL=chunk-GRHLQDHF.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as e}from"./chunk-UMLUOYFK.mjs";var r=class t extends e{constructor(i){super();this.identifier=i}serialize(i){i.serializeStr(this.identifier)}static deserialize(i){let s=i.deserializeStr();return new t(s)}};export{r as a};
|
|
2
|
+
//# sourceMappingURL=chunk-GSCM444Z.mjs.map
|