@aptos-labs/ts-sdk 1.13.3-zeta.0 → 1.13.3-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.
Files changed (223) hide show
  1. package/dist/common/index.d.ts +24 -4
  2. package/dist/common/index.js +11 -11
  3. package/dist/common/index.js.map +1 -1
  4. package/dist/esm/account/Account.mjs +1 -1
  5. package/dist/esm/account/Ed25519Account.mjs +1 -1
  6. package/dist/esm/account/EphemeralKeyPair.d.mts +1 -0
  7. package/dist/esm/account/EphemeralKeyPair.mjs +1 -1
  8. package/dist/esm/account/KeylessAccount.d.mts +23 -4
  9. package/dist/esm/account/KeylessAccount.mjs +1 -1
  10. package/dist/esm/account/MultiKeyAccount.mjs +1 -1
  11. package/dist/esm/account/SingleKeyAccount.mjs +1 -1
  12. package/dist/esm/account/index.d.mts +2 -1
  13. package/dist/esm/account/index.mjs +1 -1
  14. package/dist/esm/api/account.mjs +1 -1
  15. package/dist/esm/api/ans.mjs +1 -1
  16. package/dist/esm/api/aptos.mjs +1 -1
  17. package/dist/esm/api/aptosConfig.mjs +1 -1
  18. package/dist/esm/api/coin.mjs +1 -1
  19. package/dist/esm/api/digitalAsset.mjs +1 -1
  20. package/dist/esm/api/event.mjs +1 -1
  21. package/dist/esm/api/faucet.mjs +1 -1
  22. package/dist/esm/api/fungibleAsset.mjs +1 -1
  23. package/dist/esm/api/general.mjs +1 -1
  24. package/dist/esm/api/index.mjs +1 -1
  25. package/dist/esm/api/keyless.d.mts +3 -1
  26. package/dist/esm/api/keyless.mjs +1 -1
  27. package/dist/esm/api/staking.mjs +1 -1
  28. package/dist/esm/api/transaction.mjs +1 -1
  29. package/dist/esm/api/transactionSubmission/build.mjs +1 -1
  30. package/dist/esm/api/transactionSubmission/management.mjs +1 -1
  31. package/dist/esm/api/transactionSubmission/sign.mjs +1 -1
  32. package/dist/esm/api/transactionSubmission/simulate.mjs +1 -1
  33. package/dist/esm/api/transactionSubmission/submit.mjs +1 -1
  34. package/dist/esm/api/utils.mjs +1 -1
  35. package/dist/esm/bcs/index.mjs +1 -1
  36. package/dist/esm/{chunk-TJPWYYNO.mjs → chunk-2Q6K4CLJ.mjs} +2 -2
  37. package/dist/esm/{chunk-R6PFLI3Z.mjs → chunk-4WMPZEJS.mjs} +2 -2
  38. package/dist/esm/{chunk-X56CTMYB.mjs → chunk-5QBTBH64.mjs} +2 -2
  39. package/dist/esm/chunk-5RBI4QWR.mjs +2 -0
  40. package/dist/esm/chunk-5RBI4QWR.mjs.map +1 -0
  41. package/dist/esm/{chunk-HURQZGUZ.mjs → chunk-6M6XXPQQ.mjs} +2 -2
  42. package/dist/esm/{chunk-CN37OHFT.mjs → chunk-7CW32VZG.mjs} +2 -2
  43. package/dist/esm/{chunk-CQJ4WN7M.mjs → chunk-7JNPSNL6.mjs} +2 -2
  44. package/dist/esm/{chunk-SRLCFTZR.mjs → chunk-ADQGYJZR.mjs} +2 -2
  45. package/dist/esm/{chunk-KCVBUZ6L.mjs → chunk-AN2KSYKO.mjs} +2 -2
  46. package/dist/esm/{chunk-SNQJV7MF.mjs → chunk-CQ6CHOHQ.mjs} +2 -2
  47. package/dist/esm/{chunk-J2IIPYZG.mjs → chunk-D2ALJ5UZ.mjs} +2 -2
  48. package/dist/esm/{chunk-LDMEIVL6.mjs → chunk-D63W6JYG.mjs} +2 -2
  49. package/dist/esm/{chunk-KNHI66FK.mjs → chunk-DLZXY6VZ.mjs} +2 -2
  50. package/dist/esm/chunk-DMKFITUM.mjs +2 -0
  51. package/dist/esm/chunk-DMKFITUM.mjs.map +1 -0
  52. package/dist/esm/{chunk-WO2KROQ6.mjs → chunk-EA5KB322.mjs} +2 -2
  53. package/dist/esm/{chunk-JEUAQVXW.mjs → chunk-EBCDMINE.mjs} +2 -2
  54. package/dist/esm/{chunk-U72H6EST.mjs → chunk-EI7MOA4R.mjs} +2 -2
  55. package/dist/esm/{chunk-6GQAHQGW.mjs → chunk-EJPL4WP3.mjs} +2 -2
  56. package/dist/esm/{chunk-QMIEBNTP.mjs → chunk-G4UC736K.mjs} +2 -2
  57. package/dist/esm/{chunk-QXVGXZJX.mjs → chunk-H6EEHYWO.mjs} +2 -2
  58. package/dist/esm/{chunk-LX7N4NUS.mjs → chunk-ITEV72BZ.mjs} +2 -2
  59. package/dist/esm/{chunk-3LQPAGL6.mjs → chunk-K4OBKJK4.mjs} +2 -2
  60. package/dist/esm/chunk-KAMRUIEM.mjs +2 -0
  61. package/dist/esm/chunk-KAMRUIEM.mjs.map +1 -0
  62. package/dist/esm/{chunk-F6QCHPVS.mjs → chunk-KGJITNRZ.mjs} +2 -2
  63. package/dist/esm/{chunk-TBG3MIIE.mjs → chunk-LRUXIKHV.mjs} +2 -2
  64. package/dist/esm/{chunk-Q7TGZJT4.mjs → chunk-NRJ34FML.mjs} +2 -2
  65. package/dist/esm/chunk-OQMR3WGU.mjs +2 -0
  66. package/dist/esm/chunk-OQMR3WGU.mjs.map +1 -0
  67. package/dist/esm/chunk-P5VCS2F5.mjs +2 -0
  68. package/dist/esm/chunk-P5VCS2F5.mjs.map +1 -0
  69. package/dist/esm/{chunk-6NZNCDDW.mjs → chunk-PFQQIEWF.mjs} +2 -2
  70. package/dist/esm/{chunk-H6BRBIMG.mjs → chunk-PPXY7O7X.mjs} +2 -2
  71. package/dist/esm/{chunk-7FNHL6LU.mjs → chunk-PTIZKRON.mjs} +2 -2
  72. package/dist/esm/{chunk-3PGVEOWR.mjs → chunk-PXS6QB3Q.mjs} +2 -2
  73. package/dist/esm/{chunk-EQKI6NJR.mjs → chunk-QNXQJBSH.mjs} +2 -2
  74. package/dist/esm/{chunk-7MPJPZ73.mjs → chunk-R7BAM2G6.mjs} +2 -2
  75. package/dist/esm/{chunk-DKLA4F3P.mjs → chunk-RROJLXZ6.mjs} +2 -2
  76. package/dist/esm/{chunk-AKGASNN4.mjs → chunk-RSPF5S2J.mjs} +2 -2
  77. package/dist/esm/{chunk-T3W5USZC.mjs → chunk-SW6IHEIE.mjs} +2 -2
  78. package/dist/esm/{chunk-RPXN7HGR.mjs → chunk-T75EO4EY.mjs} +2 -2
  79. package/dist/esm/{chunk-2SD6JLIU.mjs → chunk-TGYE266K.mjs} +2 -2
  80. package/dist/esm/{chunk-3CIA6J5L.mjs → chunk-TKUEWPVF.mjs} +2 -2
  81. package/dist/esm/{chunk-JOYJUVSE.mjs → chunk-UWRDLIBP.mjs} +2 -2
  82. package/dist/esm/{chunk-HFLWASAB.mjs → chunk-VFALS4YR.mjs} +2 -2
  83. package/dist/esm/{chunk-QHIQLTBS.mjs → chunk-VI4ZVGUW.mjs} +2 -2
  84. package/dist/esm/{chunk-7XHVF3ZX.mjs → chunk-VPZ4ZYJA.mjs} +2 -2
  85. package/dist/esm/{chunk-N4B6S6FK.mjs → chunk-W6JXUSH2.mjs} +2 -2
  86. package/dist/esm/chunk-WNXSPLZO.mjs +2 -0
  87. package/dist/esm/{chunk-YGHLXEB4.mjs.map → chunk-WNXSPLZO.mjs.map} +1 -1
  88. package/dist/esm/{chunk-E4Z5IEZP.mjs → chunk-WPVBC4JS.mjs} +2 -2
  89. package/dist/esm/{chunk-6NMHAFIO.mjs → chunk-WTVN3XGK.mjs} +2 -2
  90. package/dist/esm/{chunk-H3LMPXEM.mjs → chunk-X2HZPFTC.mjs} +2 -2
  91. package/dist/esm/{chunk-TE7AJKSU.mjs → chunk-XHPLLMR5.mjs} +2 -2
  92. package/dist/esm/{chunk-HQWIGPYQ.mjs → chunk-YH6UKGIX.mjs} +2 -2
  93. package/dist/esm/{chunk-APEBWN6Q.mjs → chunk-YHEF3FJ4.mjs} +2 -2
  94. package/dist/esm/{chunk-NMVZP3Q2.mjs → chunk-YKANYJTN.mjs} +2 -2
  95. package/dist/esm/{chunk-XEXWFQNP.mjs → chunk-Z5II77T2.mjs} +2 -2
  96. package/dist/esm/{chunk-E36GTDEB.mjs → chunk-ZGTJMNZG.mjs} +2 -2
  97. package/dist/esm/{chunk-274CXZ6R.mjs → chunk-ZXUU37PN.mjs} +2 -2
  98. package/dist/esm/client/core.mjs +1 -1
  99. package/dist/esm/client/get.mjs +1 -1
  100. package/dist/esm/client/index.mjs +1 -1
  101. package/dist/esm/client/post.mjs +1 -1
  102. package/dist/esm/core/crypto/ed25519.mjs +1 -1
  103. package/dist/esm/core/crypto/ephemeral.mjs +1 -1
  104. package/dist/esm/core/crypto/index.mjs +1 -1
  105. package/dist/esm/core/crypto/keyless.mjs +1 -1
  106. package/dist/esm/core/crypto/multiEd25519.mjs +1 -1
  107. package/dist/esm/core/crypto/multiKey.mjs +1 -1
  108. package/dist/esm/core/crypto/publicKey.mjs +1 -1
  109. package/dist/esm/core/crypto/secp256k1.mjs +1 -1
  110. package/dist/esm/core/crypto/signature.mjs +1 -1
  111. package/dist/esm/core/crypto/singleKey.mjs +1 -1
  112. package/dist/esm/core/index.mjs +1 -1
  113. package/dist/esm/index.d.mts +2 -2
  114. package/dist/esm/index.mjs +1 -1
  115. package/dist/esm/internal/account.mjs +1 -1
  116. package/dist/esm/internal/ans.mjs +1 -1
  117. package/dist/esm/internal/coin.mjs +1 -1
  118. package/dist/esm/internal/digitalAsset.mjs +1 -1
  119. package/dist/esm/internal/event.mjs +1 -1
  120. package/dist/esm/internal/faucet.mjs +1 -1
  121. package/dist/esm/internal/fungibleAsset.mjs +1 -1
  122. package/dist/esm/internal/general.mjs +1 -1
  123. package/dist/esm/internal/keyless.d.mts +3 -1
  124. package/dist/esm/internal/keyless.mjs +1 -1
  125. package/dist/esm/internal/staking.mjs +1 -1
  126. package/dist/esm/internal/transaction.mjs +1 -1
  127. package/dist/esm/internal/transactionSubmission.mjs +1 -1
  128. package/dist/esm/internal/view.mjs +1 -1
  129. package/dist/esm/transactions/authenticator/account.mjs +1 -1
  130. package/dist/esm/transactions/authenticator/index.mjs +1 -1
  131. package/dist/esm/transactions/authenticator/transaction.mjs +1 -1
  132. package/dist/esm/transactions/index.mjs +1 -1
  133. package/dist/esm/transactions/instances/index.mjs +1 -1
  134. package/dist/esm/transactions/instances/moduleId.mjs +1 -1
  135. package/dist/esm/transactions/instances/multiAgentTransaction.mjs +1 -1
  136. package/dist/esm/transactions/instances/rawTransaction.mjs +1 -1
  137. package/dist/esm/transactions/instances/rotationProofChallenge.mjs +1 -1
  138. package/dist/esm/transactions/instances/signedTransaction.mjs +1 -1
  139. package/dist/esm/transactions/instances/simpleTransaction.mjs +1 -1
  140. package/dist/esm/transactions/instances/transactionPayload.mjs +1 -1
  141. package/dist/esm/transactions/management/accountSequenceNumber.mjs +1 -1
  142. package/dist/esm/transactions/management/index.mjs +1 -1
  143. package/dist/esm/transactions/management/transactionWorker.mjs +1 -1
  144. package/dist/esm/transactions/transactionBuilder/helpers.mjs +1 -1
  145. package/dist/esm/transactions/transactionBuilder/index.mjs +1 -1
  146. package/dist/esm/transactions/transactionBuilder/remoteAbi.mjs +1 -1
  147. package/dist/esm/transactions/transactionBuilder/signingMessage.mjs +1 -1
  148. package/dist/esm/transactions/transactionBuilder/transactionBuilder.mjs +1 -1
  149. package/dist/esm/transactions/typeTag/index.mjs +1 -1
  150. package/dist/esm/transactions/typeTag/parser.mjs +1 -1
  151. package/dist/esm/utils/apiEndpoints.mjs +1 -1
  152. package/dist/esm/utils/index.mjs +1 -1
  153. package/dist/esm/utils/normalizeBundle.mjs +1 -1
  154. package/dist/esm/version.d.mts +1 -1
  155. package/dist/esm/version.mjs +1 -1
  156. package/package.json +1 -1
  157. package/src/account/EphemeralKeyPair.ts +8 -0
  158. package/src/account/KeylessAccount.ts +70 -11
  159. package/src/api/keyless.ts +2 -1
  160. package/src/internal/keyless.ts +7 -4
  161. package/src/utils/apiEndpoints.ts +6 -6
  162. package/src/version.ts +1 -1
  163. package/dist/esm/chunk-2M7KHFEG.mjs +0 -2
  164. package/dist/esm/chunk-2M7KHFEG.mjs.map +0 -1
  165. package/dist/esm/chunk-5VSMDXZ6.mjs +0 -2
  166. package/dist/esm/chunk-5VSMDXZ6.mjs.map +0 -1
  167. package/dist/esm/chunk-NNA5VEB2.mjs +0 -2
  168. package/dist/esm/chunk-NNA5VEB2.mjs.map +0 -1
  169. package/dist/esm/chunk-PLPCOELE.mjs +0 -2
  170. package/dist/esm/chunk-PLPCOELE.mjs.map +0 -1
  171. package/dist/esm/chunk-W76IQV5K.mjs +0 -2
  172. package/dist/esm/chunk-W76IQV5K.mjs.map +0 -1
  173. package/dist/esm/chunk-YGHLXEB4.mjs +0 -2
  174. /package/dist/esm/{chunk-TJPWYYNO.mjs.map → chunk-2Q6K4CLJ.mjs.map} +0 -0
  175. /package/dist/esm/{chunk-R6PFLI3Z.mjs.map → chunk-4WMPZEJS.mjs.map} +0 -0
  176. /package/dist/esm/{chunk-X56CTMYB.mjs.map → chunk-5QBTBH64.mjs.map} +0 -0
  177. /package/dist/esm/{chunk-HURQZGUZ.mjs.map → chunk-6M6XXPQQ.mjs.map} +0 -0
  178. /package/dist/esm/{chunk-CN37OHFT.mjs.map → chunk-7CW32VZG.mjs.map} +0 -0
  179. /package/dist/esm/{chunk-CQJ4WN7M.mjs.map → chunk-7JNPSNL6.mjs.map} +0 -0
  180. /package/dist/esm/{chunk-SRLCFTZR.mjs.map → chunk-ADQGYJZR.mjs.map} +0 -0
  181. /package/dist/esm/{chunk-KCVBUZ6L.mjs.map → chunk-AN2KSYKO.mjs.map} +0 -0
  182. /package/dist/esm/{chunk-SNQJV7MF.mjs.map → chunk-CQ6CHOHQ.mjs.map} +0 -0
  183. /package/dist/esm/{chunk-J2IIPYZG.mjs.map → chunk-D2ALJ5UZ.mjs.map} +0 -0
  184. /package/dist/esm/{chunk-LDMEIVL6.mjs.map → chunk-D63W6JYG.mjs.map} +0 -0
  185. /package/dist/esm/{chunk-KNHI66FK.mjs.map → chunk-DLZXY6VZ.mjs.map} +0 -0
  186. /package/dist/esm/{chunk-WO2KROQ6.mjs.map → chunk-EA5KB322.mjs.map} +0 -0
  187. /package/dist/esm/{chunk-JEUAQVXW.mjs.map → chunk-EBCDMINE.mjs.map} +0 -0
  188. /package/dist/esm/{chunk-U72H6EST.mjs.map → chunk-EI7MOA4R.mjs.map} +0 -0
  189. /package/dist/esm/{chunk-6GQAHQGW.mjs.map → chunk-EJPL4WP3.mjs.map} +0 -0
  190. /package/dist/esm/{chunk-QMIEBNTP.mjs.map → chunk-G4UC736K.mjs.map} +0 -0
  191. /package/dist/esm/{chunk-QXVGXZJX.mjs.map → chunk-H6EEHYWO.mjs.map} +0 -0
  192. /package/dist/esm/{chunk-LX7N4NUS.mjs.map → chunk-ITEV72BZ.mjs.map} +0 -0
  193. /package/dist/esm/{chunk-3LQPAGL6.mjs.map → chunk-K4OBKJK4.mjs.map} +0 -0
  194. /package/dist/esm/{chunk-F6QCHPVS.mjs.map → chunk-KGJITNRZ.mjs.map} +0 -0
  195. /package/dist/esm/{chunk-TBG3MIIE.mjs.map → chunk-LRUXIKHV.mjs.map} +0 -0
  196. /package/dist/esm/{chunk-Q7TGZJT4.mjs.map → chunk-NRJ34FML.mjs.map} +0 -0
  197. /package/dist/esm/{chunk-6NZNCDDW.mjs.map → chunk-PFQQIEWF.mjs.map} +0 -0
  198. /package/dist/esm/{chunk-H6BRBIMG.mjs.map → chunk-PPXY7O7X.mjs.map} +0 -0
  199. /package/dist/esm/{chunk-7FNHL6LU.mjs.map → chunk-PTIZKRON.mjs.map} +0 -0
  200. /package/dist/esm/{chunk-3PGVEOWR.mjs.map → chunk-PXS6QB3Q.mjs.map} +0 -0
  201. /package/dist/esm/{chunk-EQKI6NJR.mjs.map → chunk-QNXQJBSH.mjs.map} +0 -0
  202. /package/dist/esm/{chunk-7MPJPZ73.mjs.map → chunk-R7BAM2G6.mjs.map} +0 -0
  203. /package/dist/esm/{chunk-DKLA4F3P.mjs.map → chunk-RROJLXZ6.mjs.map} +0 -0
  204. /package/dist/esm/{chunk-AKGASNN4.mjs.map → chunk-RSPF5S2J.mjs.map} +0 -0
  205. /package/dist/esm/{chunk-T3W5USZC.mjs.map → chunk-SW6IHEIE.mjs.map} +0 -0
  206. /package/dist/esm/{chunk-RPXN7HGR.mjs.map → chunk-T75EO4EY.mjs.map} +0 -0
  207. /package/dist/esm/{chunk-2SD6JLIU.mjs.map → chunk-TGYE266K.mjs.map} +0 -0
  208. /package/dist/esm/{chunk-3CIA6J5L.mjs.map → chunk-TKUEWPVF.mjs.map} +0 -0
  209. /package/dist/esm/{chunk-JOYJUVSE.mjs.map → chunk-UWRDLIBP.mjs.map} +0 -0
  210. /package/dist/esm/{chunk-HFLWASAB.mjs.map → chunk-VFALS4YR.mjs.map} +0 -0
  211. /package/dist/esm/{chunk-QHIQLTBS.mjs.map → chunk-VI4ZVGUW.mjs.map} +0 -0
  212. /package/dist/esm/{chunk-7XHVF3ZX.mjs.map → chunk-VPZ4ZYJA.mjs.map} +0 -0
  213. /package/dist/esm/{chunk-N4B6S6FK.mjs.map → chunk-W6JXUSH2.mjs.map} +0 -0
  214. /package/dist/esm/{chunk-E4Z5IEZP.mjs.map → chunk-WPVBC4JS.mjs.map} +0 -0
  215. /package/dist/esm/{chunk-6NMHAFIO.mjs.map → chunk-WTVN3XGK.mjs.map} +0 -0
  216. /package/dist/esm/{chunk-H3LMPXEM.mjs.map → chunk-X2HZPFTC.mjs.map} +0 -0
  217. /package/dist/esm/{chunk-TE7AJKSU.mjs.map → chunk-XHPLLMR5.mjs.map} +0 -0
  218. /package/dist/esm/{chunk-HQWIGPYQ.mjs.map → chunk-YH6UKGIX.mjs.map} +0 -0
  219. /package/dist/esm/{chunk-APEBWN6Q.mjs.map → chunk-YHEF3FJ4.mjs.map} +0 -0
  220. /package/dist/esm/{chunk-NMVZP3Q2.mjs.map → chunk-YKANYJTN.mjs.map} +0 -0
  221. /package/dist/esm/{chunk-XEXWFQNP.mjs.map → chunk-Z5II77T2.mjs.map} +0 -0
  222. /package/dist/esm/{chunk-E36GTDEB.mjs.map → chunk-ZGTJMNZG.mjs.map} +0 -0
  223. /package/dist/esm/{chunk-274CXZ6R.mjs.map → chunk-ZXUU37PN.mjs.map} +0 -0
@@ -1,2 +1,2 @@
1
- import{e as o}from"../../chunk-RPXN7HGR.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-QHIQLTBS.mjs";import"../../chunk-J2IIPYZG.mjs";import"../../chunk-PFFAQZHT.mjs";import"../../chunk-7H3HRFVM.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-QXVGXZJX.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-6NZNCDDW.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-APEBWN6Q.mjs";import"../../chunk-S4SEFF4K.mjs";import"../../chunk-3JPVQHOR.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-NMVZP3Q2.mjs";import"../../chunk-7XHVF3ZX.mjs";import"../../chunk-WO2KROQ6.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-ROXFCLDT.mjs";import"../../chunk-6FBKUTGF.mjs";import"../../chunk-5VSMDXZ6.mjs";import"../../chunk-YGHLXEB4.mjs";import"../../chunk-DKLA4F3P.mjs";import"../../chunk-LX7N4NUS.mjs";import"../../chunk-HQWIGPYQ.mjs";import"../../chunk-2M7KHFEG.mjs";import"../../chunk-W76IQV5K.mjs";import"../../chunk-TJPWYYNO.mjs";import"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-X56CTMYB.mjs";import"../../chunk-E36GTDEB.mjs";import"../../chunk-E4Z5IEZP.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-TE7AJKSU.mjs";import"../../chunk-F6QCHPVS.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-HURQZGUZ.mjs";import"../../chunk-7FNHL6LU.mjs";import"../../chunk-6NMHAFIO.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-7MPJPZ73.mjs";import"../../chunk-CQJ4WN7M.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.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};
1
+ import{e as o}from"../../chunk-T75EO4EY.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-VI4ZVGUW.mjs";import"../../chunk-D2ALJ5UZ.mjs";import"../../chunk-PFFAQZHT.mjs";import"../../chunk-7H3HRFVM.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-H6EEHYWO.mjs";import"../../chunk-PFQQIEWF.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-YHEF3FJ4.mjs";import"../../chunk-S4SEFF4K.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-VPZ4ZYJA.mjs";import"../../chunk-YKANYJTN.mjs";import"../../chunk-EA5KB322.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-ROXFCLDT.mjs";import"../../chunk-6FBKUTGF.mjs";import"../../chunk-5RBI4QWR.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-3JPVQHOR.mjs";import"../../chunk-WNXSPLZO.mjs";import"../../chunk-RROJLXZ6.mjs";import"../../chunk-ITEV72BZ.mjs";import"../../chunk-YH6UKGIX.mjs";import"../../chunk-P5VCS2F5.mjs";import"../../chunk-DMKFITUM.mjs";import"../../chunk-2Q6K4CLJ.mjs";import"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-5QBTBH64.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-ZGTJMNZG.mjs";import"../../chunk-WPVBC4JS.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-KGJITNRZ.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-6M6XXPQQ.mjs";import"../../chunk-PTIZKRON.mjs";import"../../chunk-WTVN3XGK.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-R7BAM2G6.mjs";import"../../chunk-XHPLLMR5.mjs";import"../../chunk-7JNPSNL6.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.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-274CXZ6R.mjs";import"../../chunk-6EMN3BOV.mjs";import"../../chunk-RPXN7HGR.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-QHIQLTBS.mjs";import"../../chunk-J2IIPYZG.mjs";import"../../chunk-PFFAQZHT.mjs";import"../../chunk-7H3HRFVM.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-QXVGXZJX.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-6NZNCDDW.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-APEBWN6Q.mjs";import"../../chunk-S4SEFF4K.mjs";import"../../chunk-3JPVQHOR.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-NMVZP3Q2.mjs";import"../../chunk-7XHVF3ZX.mjs";import"../../chunk-WO2KROQ6.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-ROXFCLDT.mjs";import"../../chunk-6FBKUTGF.mjs";import"../../chunk-5VSMDXZ6.mjs";import"../../chunk-YGHLXEB4.mjs";import"../../chunk-DKLA4F3P.mjs";import"../../chunk-LX7N4NUS.mjs";import"../../chunk-HQWIGPYQ.mjs";import"../../chunk-2M7KHFEG.mjs";import"../../chunk-W76IQV5K.mjs";import"../../chunk-TJPWYYNO.mjs";import"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-X56CTMYB.mjs";import"../../chunk-E36GTDEB.mjs";import"../../chunk-E4Z5IEZP.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-TE7AJKSU.mjs";import"../../chunk-F6QCHPVS.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-HURQZGUZ.mjs";import"../../chunk-7FNHL6LU.mjs";import"../../chunk-6NMHAFIO.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-7MPJPZ73.mjs";import"../../chunk-CQJ4WN7M.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Simulate};
1
+ import{a}from"../../chunk-ZXUU37PN.mjs";import"../../chunk-6EMN3BOV.mjs";import"../../chunk-T75EO4EY.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-VI4ZVGUW.mjs";import"../../chunk-D2ALJ5UZ.mjs";import"../../chunk-PFFAQZHT.mjs";import"../../chunk-7H3HRFVM.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-H6EEHYWO.mjs";import"../../chunk-PFQQIEWF.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-YHEF3FJ4.mjs";import"../../chunk-S4SEFF4K.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-VPZ4ZYJA.mjs";import"../../chunk-YKANYJTN.mjs";import"../../chunk-EA5KB322.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-ROXFCLDT.mjs";import"../../chunk-6FBKUTGF.mjs";import"../../chunk-5RBI4QWR.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-3JPVQHOR.mjs";import"../../chunk-WNXSPLZO.mjs";import"../../chunk-RROJLXZ6.mjs";import"../../chunk-ITEV72BZ.mjs";import"../../chunk-YH6UKGIX.mjs";import"../../chunk-P5VCS2F5.mjs";import"../../chunk-DMKFITUM.mjs";import"../../chunk-2Q6K4CLJ.mjs";import"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-5QBTBH64.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-ZGTJMNZG.mjs";import"../../chunk-WPVBC4JS.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-KGJITNRZ.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-6M6XXPQQ.mjs";import"../../chunk-PTIZKRON.mjs";import"../../chunk-WTVN3XGK.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-R7BAM2G6.mjs";import"../../chunk-XHPLLMR5.mjs";import"../../chunk-7JNPSNL6.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Simulate};
2
2
  //# sourceMappingURL=simulate.mjs.map
@@ -1,2 +1,2 @@
1
- import{a}from"../../chunk-H6BRBIMG.mjs";import"../../chunk-6EMN3BOV.mjs";import"../../chunk-RPXN7HGR.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-QHIQLTBS.mjs";import"../../chunk-J2IIPYZG.mjs";import"../../chunk-PFFAQZHT.mjs";import"../../chunk-7H3HRFVM.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-QXVGXZJX.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-6NZNCDDW.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-APEBWN6Q.mjs";import"../../chunk-S4SEFF4K.mjs";import"../../chunk-3JPVQHOR.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-NMVZP3Q2.mjs";import"../../chunk-7XHVF3ZX.mjs";import"../../chunk-WO2KROQ6.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-ROXFCLDT.mjs";import"../../chunk-6FBKUTGF.mjs";import"../../chunk-5VSMDXZ6.mjs";import"../../chunk-YGHLXEB4.mjs";import"../../chunk-DKLA4F3P.mjs";import"../../chunk-LX7N4NUS.mjs";import"../../chunk-HQWIGPYQ.mjs";import"../../chunk-2M7KHFEG.mjs";import"../../chunk-W76IQV5K.mjs";import"../../chunk-TJPWYYNO.mjs";import"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-X56CTMYB.mjs";import"../../chunk-E36GTDEB.mjs";import"../../chunk-E4Z5IEZP.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-TE7AJKSU.mjs";import"../../chunk-F6QCHPVS.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-HURQZGUZ.mjs";import"../../chunk-7FNHL6LU.mjs";import"../../chunk-6NMHAFIO.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-7MPJPZ73.mjs";import"../../chunk-CQJ4WN7M.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Submit};
1
+ import{a}from"../../chunk-PPXY7O7X.mjs";import"../../chunk-6EMN3BOV.mjs";import"../../chunk-T75EO4EY.mjs";import"../../chunk-I5OYNCZS.mjs";import"../../chunk-JXCZTOYC.mjs";import"../../chunk-VI4ZVGUW.mjs";import"../../chunk-D2ALJ5UZ.mjs";import"../../chunk-PFFAQZHT.mjs";import"../../chunk-7H3HRFVM.mjs";import"../../chunk-BSCOVLWS.mjs";import"../../chunk-V3MBJJTL.mjs";import"../../chunk-H6EEHYWO.mjs";import"../../chunk-PFQQIEWF.mjs";import"../../chunk-AH44UPM4.mjs";import"../../chunk-YHEF3FJ4.mjs";import"../../chunk-S4SEFF4K.mjs";import"../../chunk-N2FKVZ4D.mjs";import"../../chunk-VPZ4ZYJA.mjs";import"../../chunk-YKANYJTN.mjs";import"../../chunk-EA5KB322.mjs";import"../../chunk-GED6IT3S.mjs";import"../../chunk-ROXFCLDT.mjs";import"../../chunk-6FBKUTGF.mjs";import"../../chunk-5RBI4QWR.mjs";import"../../chunk-7Z6DYLCA.mjs";import"../../chunk-3JPVQHOR.mjs";import"../../chunk-WNXSPLZO.mjs";import"../../chunk-RROJLXZ6.mjs";import"../../chunk-ITEV72BZ.mjs";import"../../chunk-YH6UKGIX.mjs";import"../../chunk-P5VCS2F5.mjs";import"../../chunk-DMKFITUM.mjs";import"../../chunk-2Q6K4CLJ.mjs";import"../../chunk-2YDIOWRJ.mjs";import"../../chunk-4NMDYPUD.mjs";import"../../chunk-UYVPNUH3.mjs";import"../../chunk-W637YAND.mjs";import"../../chunk-NC5HHEEM.mjs";import"../../chunk-5QBTBH64.mjs";import"../../chunk-MKUAW7KW.mjs";import"../../chunk-Z2ZR4PTF.mjs";import"../../chunk-IEZO4PIG.mjs";import"../../chunk-3VGX3TXH.mjs";import"../../chunk-ZNEBMSNC.mjs";import"../../chunk-MGOHPDX4.mjs";import"../../chunk-ZGTJMNZG.mjs";import"../../chunk-WPVBC4JS.mjs";import"../../chunk-MWUJCP27.mjs";import"../../chunk-RFSO3JRG.mjs";import"../../chunk-YE5B2S5L.mjs";import"../../chunk-AQ4I7VVB.mjs";import"../../chunk-KGJITNRZ.mjs";import"../../chunk-KUX6GQ2E.mjs";import"../../chunk-6M6XXPQQ.mjs";import"../../chunk-PTIZKRON.mjs";import"../../chunk-WTVN3XGK.mjs";import"../../chunk-FLYEALDB.mjs";import"../../chunk-R7BAM2G6.mjs";import"../../chunk-XHPLLMR5.mjs";import"../../chunk-7JNPSNL6.mjs";import"../../chunk-COW5IGYC.mjs";import"../../chunk-STYDBDYL.mjs";import"../../chunk-TJDC5PWD.mjs";import"../../chunk-S5HG2QUD.mjs";import"../../chunk-7STYQ5ZE.mjs";import"../../chunk-T23OVRNF.mjs";import"../../chunk-FZY4PMEE.mjs";import"../../chunk-C3L4ETUF.mjs";import"../../chunk-3FVRXELT.mjs";import"../../chunk-EB7AI4B4.mjs";import"../../chunk-6RBUXB5I.mjs";import"../../chunk-OKRUEVF3.mjs";import"../../chunk-4WPQQPUF.mjs";import"../../chunk-6IFMQ5AS.mjs";import"../../chunk-TVRJ3M7B.mjs";import"../../chunk-AOCNYMMX.mjs";import"../../chunk-FBPNHF54.mjs";import"../../chunk-56CNRT2K.mjs";import"../../chunk-FVA2OPG4.mjs";export{a as Submit};
2
2
  //# sourceMappingURL=submit.mjs.map
@@ -1,2 +1,2 @@
1
- import{a}from"../chunk-HFLWASAB.mjs";import"../chunk-6NZNCDDW.mjs";import"../chunk-AH44UPM4.mjs";import"../chunk-APEBWN6Q.mjs";import"../chunk-S4SEFF4K.mjs";import"../chunk-3JPVQHOR.mjs";import"../chunk-N2FKVZ4D.mjs";import"../chunk-NMVZP3Q2.mjs";import"../chunk-7XHVF3ZX.mjs";import"../chunk-WO2KROQ6.mjs";import"../chunk-GED6IT3S.mjs";import"../chunk-ROXFCLDT.mjs";import"../chunk-6FBKUTGF.mjs";import"../chunk-5VSMDXZ6.mjs";import"../chunk-YGHLXEB4.mjs";import"../chunk-YE5B2S5L.mjs";import"../chunk-FZY4PMEE.mjs";import"../chunk-C3L4ETUF.mjs";import"../chunk-3FVRXELT.mjs";import"../chunk-EB7AI4B4.mjs";import"../chunk-6RBUXB5I.mjs";import"../chunk-6IFMQ5AS.mjs";import"../chunk-OKRUEVF3.mjs";import"../chunk-4WPQQPUF.mjs";import"../chunk-TVRJ3M7B.mjs";import"../chunk-AOCNYMMX.mjs";import"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FVA2OPG4.mjs";export{a as waitForIndexerOnVersion};
1
+ import{a}from"../chunk-VFALS4YR.mjs";import"../chunk-PFQQIEWF.mjs";import"../chunk-AH44UPM4.mjs";import"../chunk-YHEF3FJ4.mjs";import"../chunk-S4SEFF4K.mjs";import"../chunk-N2FKVZ4D.mjs";import"../chunk-VPZ4ZYJA.mjs";import"../chunk-YKANYJTN.mjs";import"../chunk-EA5KB322.mjs";import"../chunk-GED6IT3S.mjs";import"../chunk-ROXFCLDT.mjs";import"../chunk-6FBKUTGF.mjs";import"../chunk-5RBI4QWR.mjs";import"../chunk-3JPVQHOR.mjs";import"../chunk-WNXSPLZO.mjs";import"../chunk-YE5B2S5L.mjs";import"../chunk-FZY4PMEE.mjs";import"../chunk-C3L4ETUF.mjs";import"../chunk-3FVRXELT.mjs";import"../chunk-EB7AI4B4.mjs";import"../chunk-6RBUXB5I.mjs";import"../chunk-OKRUEVF3.mjs";import"../chunk-4WPQQPUF.mjs";import"../chunk-6IFMQ5AS.mjs";import"../chunk-TVRJ3M7B.mjs";import"../chunk-AOCNYMMX.mjs";import"../chunk-FBPNHF54.mjs";import"../chunk-56CNRT2K.mjs";import"../chunk-FVA2OPG4.mjs";export{a as waitForIndexerOnVersion};
2
2
  //# sourceMappingURL=utils.mjs.map
@@ -1,2 +1,2 @@
1
- import"../chunk-FZY4PMEE.mjs";import{a as h}from"../chunk-C3L4ETUF.mjs";import{a as g}from"../chunk-3FVRXELT.mjs";import{a as p,b as q,c as r}from"../chunk-EB7AI4B4.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-6RBUXB5I.mjs";import{a}from"../chunk-6IFMQ5AS.mjs";import"../chunk-OKRUEVF3.mjs";import"../chunk-4WPQQPUF.mjs";import{a as b,b as c,c as d,d as e,e as f}from"../chunk-TVRJ3M7B.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};
1
+ import"../chunk-FZY4PMEE.mjs";import{a as h}from"../chunk-C3L4ETUF.mjs";import{a as g}from"../chunk-3FVRXELT.mjs";import{a as p,b as q,c as r}from"../chunk-EB7AI4B4.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-6RBUXB5I.mjs";import"../chunk-OKRUEVF3.mjs";import"../chunk-4WPQQPUF.mjs";import{a}from"../chunk-6IFMQ5AS.mjs";import{a as b,b as c,c as d,d as e,e as f}from"../chunk-TVRJ3M7B.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{d as s}from"./chunk-2YDIOWRJ.mjs";import{d as p}from"./chunk-E4Z5IEZP.mjs";import{a as y,b as u}from"./chunk-HURQZGUZ.mjs";import{b as a}from"./chunk-7FNHL6LU.mjs";import{b as i}from"./chunk-CQJ4WN7M.mjs";import{b as g}from"./chunk-T23OVRNF.mjs";var m=class o{constructor(e){this.signingScheme=2;let{privateKey:r,address:t}=e;this.privateKey=r,this.publicKey=new y(r.publicKey()),this.accountAddress=t?g.from(t):this.publicKey.authKey().derivedAddress()}static generate(e={}){let{scheme:r=0}=e,t;switch(r){case 0:t=i.generate();break;case 2:t=a.generate();break;default:throw new Error(`Unsupported signature scheme ${r}`)}return new o({privateKey:t})}static fromDerivationPath(e){let{scheme:r=0,path:t,mnemonic:c}=e,n;switch(r){case 0:n=i.fromDerivationPath(t,c);break;case 2:n=a.fromDerivationPath(t,c);break;default:throw new Error(`Unsupported signature scheme ${r}`)}return new o({privateKey:n})}verifySignature(e){return this.publicKey.verifySignature(e)}signWithAuthenticator(e){let r=this.sign(s(e));return new p(this.publicKey,r)}sign(e){return new u(this.privateKey.sign(e))}signTransaction(e){return this.sign(s(e))}};export{m as a};
2
- //# sourceMappingURL=chunk-TJPWYYNO.mjs.map
1
+ import{d as s}from"./chunk-2YDIOWRJ.mjs";import{d as p}from"./chunk-WPVBC4JS.mjs";import{a as y,b as u}from"./chunk-6M6XXPQQ.mjs";import{b as a}from"./chunk-PTIZKRON.mjs";import{b as i}from"./chunk-7JNPSNL6.mjs";import{b as g}from"./chunk-T23OVRNF.mjs";var m=class o{constructor(e){this.signingScheme=2;let{privateKey:r,address:t}=e;this.privateKey=r,this.publicKey=new y(r.publicKey()),this.accountAddress=t?g.from(t):this.publicKey.authKey().derivedAddress()}static generate(e={}){let{scheme:r=0}=e,t;switch(r){case 0:t=i.generate();break;case 2:t=a.generate();break;default:throw new Error(`Unsupported signature scheme ${r}`)}return new o({privateKey:t})}static fromDerivationPath(e){let{scheme:r=0,path:t,mnemonic:c}=e,n;switch(r){case 0:n=i.fromDerivationPath(t,c);break;case 2:n=a.fromDerivationPath(t,c);break;default:throw new Error(`Unsupported signature scheme ${r}`)}return new o({privateKey:n})}verifySignature(e){return this.publicKey.verifySignature(e)}signWithAuthenticator(e){let r=this.sign(s(e));return new p(this.publicKey,r)}sign(e){return new u(this.privateKey.sign(e))}signTransaction(e){return this.sign(s(e))}};export{m as a};
2
+ //# sourceMappingURL=chunk-2Q6K4CLJ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as g}from"./chunk-SNQJV7MF.mjs";import{a as m}from"./chunk-RPXN7HGR.mjs";import{f as A}from"./chunk-APEBWN6Q.mjs";import{t as f}from"./chunk-S4SEFF4K.mjs";import{b as w}from"./chunk-T23OVRNF.mjs";var T=["A name must be between 3 and 63 characters long,","and can only contain lowercase a-z, 0-9, and hyphens.","A name may not start or end with a hyphen."].join(" ");function E(e){return!(!e||e.length<3||e.length>63||!/^[a-z\d][a-z\d-]{1,61}[a-z\d]$/.test(e))}function c(e){let[n,t,...o]=e.replace(/\.apt$/,"").split(".");if(o.length>0)throw new Error(`${e} is invalid. A name can only have two parts, a domain and a subdomain separated by a "."`);if(!E(n))throw new Error(`${n} is not valid. ${T}`);if(t&&!E(t))throw new Error(`${t} is not valid. ${T}`);return{domainName:t||n,subdomainName:t?n:void 0}}var z="0x37368b46ce665362562c6d1d4ec01a08c8644c488690df5a17e13ba163e20221",G="0x585fc9f0f0c54183b039ffc770ca282ebd87307916c215a3e692f2f8e4305e82",P={testnet:"0x5f8fd2347449685cf41d4db97926ec3a096eaf381332be4f1318ad4d16a8497c",mainnet:"0x867ed1f6bf916171b1de3ee92849b8978b7d1b9e0a8cc982a3d19d535dfd9c0c",local:G,custom:null,devnet:null,randomnet:null};function d(e){let n=P[e.network];if(!n)throw new Error(`The ANS contract is not deployed to ${e.network}`);return n}var b=e=>{if(e&&typeof e=="object"&&"vec"in e&&Array.isArray(e.vec))return e.vec[0]};async function V(e){let{aptosConfig:n,name:t}=e,o=d(n),{domainName:r,subdomainName:s}=c(t),i=await g({aptosConfig:n,payload:{function:`${o}::router::get_owner_addr`,functionArguments:[r,s]}}),a=b(i[0]);return a?w.from(a):void 0}async function j(e){let{aptosConfig:n,expiration:t,name:o,sender:r,targetAddress:s,toAddress:i,options:a,transferable:u}=e,p=d(n),{domainName:N,subdomainName:l}=c(o),S=t.policy==="subdomain:independent"||t.policy==="subdomain:follow-domain";if(l&&!S)throw new Error("Subdomains must have an expiration policy of either 'subdomain:independent' or 'subdomain:follow-domain'");if(S&&!l)throw new Error(`Policy is set to ${t.policy} but no subdomain was provided`);if(t.policy==="domain"){let h=t.years??1;if(h!==1)throw new Error("For now, names can only be registered for 1 year at a time");let D=h*31536e3;return await m({aptosConfig:n,sender:r.accountAddress.toString(),data:{function:`${p}::router::register_domain`,functionArguments:[N,D,s,i]},options:a})}if(!l)throw new Error(`${t.policy} requires a subdomain to be provided.`);let _=await I({aptosConfig:n,name:N});if(!_)throw new Error("The domain does not exist");let x=t.policy==="subdomain:independent"?t.expirationDate:_;if(x>_)throw new Error("The subdomain expiration time cannot be greater than the domain expiration time");return await m({aptosConfig:n,sender:r.accountAddress.toString(),data:{function:`${p}::router::register_subdomain`,functionArguments:[N,l,Math.round(x/1e3),t.policy==="subdomain:follow-domain"?1:0,!!u,s,i]},options:a})}async function I(e){let{aptosConfig:n,name:t}=e,o=d(n),{domainName:r,subdomainName:s}=c(t);try{let i=await g({aptosConfig:n,payload:{function:`${o}::router::get_expiration`,functionArguments:[r,s]}});return Number(i[0])*1e3}catch{return}}async function Y(e){let{aptosConfig:n,address:t}=e,o=d(n),r=await g({aptosConfig:n,payload:{function:`${o}::router::get_primary_name`,functionArguments:[w.from(t).toString()]}}),s=b(r[1]),i=b(r[0]);if(s)return[i,s].filter(Boolean).join(".")}async function K(e){let{aptosConfig:n,sender:t,name:o,options:r}=e,s=d(n);if(!o)return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${s}::router::clear_primary_name`,functionArguments:[]},options:r});let{domainName:i,subdomainName:a}=c(o);return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${s}::router::set_primary_name`,functionArguments:[i,a]},options:r})}async function W(e){let{aptosConfig:n,name:t}=e,o=d(n),{domainName:r,subdomainName:s}=c(t),i=await g({aptosConfig:n,payload:{function:`${o}::router::get_target_addr`,functionArguments:[r,s]}}),a=b(i[0]);return a?w.from(a):void 0}async function F(e){let{aptosConfig:n,sender:t,name:o,address:r,options:s}=e,i=d(n),{domainName:a,subdomainName:u}=c(o);return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${i}::router::set_target_addr`,functionArguments:[a,u,r]},options:s})}async function H(e){let{aptosConfig:n,name:t}=e,{domainName:o,subdomainName:r=""}=c(t),a=(await A({aptosConfig:n,query:{query:f,variables:{where_condition:{domain:{_eq:o},subdomain:{_eq:r},is_active:{_eq:!0}},limit:1}},originMethod:"getName"})).current_aptos_names[0];return a&&(a=y(a)),a}async function J(e){let{aptosConfig:n,options:t,accountAddress:o}=e,r=await C({aptosConfig:n});return(await A({aptosConfig:n,originMethod:"getAccountNames",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},owner_address:{_eq:o.toString()},expiration_timestamp:{_gte:r}}}}})).current_aptos_names.map(y)}async function X(e){let{aptosConfig:n,options:t,accountAddress:o}=e,r=await C({aptosConfig:n});return(await A({aptosConfig:n,originMethod:"getAccountDomains",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},owner_address:{_eq:o.toString()},expiration_timestamp:{_gte:r},subdomain:{_eq:""}}}}})).current_aptos_names.map(y)}async function Z(e){let{aptosConfig:n,options:t,accountAddress:o}=e,r=await C({aptosConfig:n});return(await A({aptosConfig:n,originMethod:"getAccountSubdomains",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},owner_address:{_eq:o.toString()},expiration_timestamp:{_gte:r},subdomain:{_neq:""}}}}})).current_aptos_names.map(y)}async function ee(e){let{aptosConfig:n,options:t,domain:o}=e;return(await A({aptosConfig:n,originMethod:"getDomainSubdomains",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},domain:{_eq:o},subdomain:{_neq:""},is_active:{_eq:!0}}}}})).current_aptos_names.map(y)}async function C(e){let{aptosConfig:n}=e,t=d(n),[o]=await g({aptosConfig:n,payload:{function:`${t}::config::reregistration_grace_sec`,functionArguments:[]}}),r=o/60/60/24,s=()=>new Date;return new Date(s().setDate(s().getDate()-r)).toISOString()}async function ne(e){let{aptosConfig:n,sender:t,name:o,years:r=1,options:s}=e,i=d(n),a=r*31536e3,{domainName:u,subdomainName:p}=c(o);if(p)throw new Error("Subdomains cannot be renewed");if(r!==1)throw new Error("Currently, only 1 year renewals are supported");return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${i}::router::renew_domain`,functionArguments:[u,a]},options:s})}function y(e){return{...e,expiration_timestamp:new Date(e.expiration_timestamp).getTime()}}export{T as a,E as b,c,z as d,G as e,V as f,j as g,I as h,Y as i,K as j,W as k,F as l,H as m,J as n,X as o,Z as p,ee as q,ne as r};
2
- //# sourceMappingURL=chunk-R6PFLI3Z.mjs.map
1
+ import{a as g}from"./chunk-CQ6CHOHQ.mjs";import{a as m}from"./chunk-T75EO4EY.mjs";import{f as A}from"./chunk-YHEF3FJ4.mjs";import{t as f}from"./chunk-S4SEFF4K.mjs";import{b as w}from"./chunk-T23OVRNF.mjs";var T=["A name must be between 3 and 63 characters long,","and can only contain lowercase a-z, 0-9, and hyphens.","A name may not start or end with a hyphen."].join(" ");function E(e){return!(!e||e.length<3||e.length>63||!/^[a-z\d][a-z\d-]{1,61}[a-z\d]$/.test(e))}function c(e){let[n,t,...o]=e.replace(/\.apt$/,"").split(".");if(o.length>0)throw new Error(`${e} is invalid. A name can only have two parts, a domain and a subdomain separated by a "."`);if(!E(n))throw new Error(`${n} is not valid. ${T}`);if(t&&!E(t))throw new Error(`${t} is not valid. ${T}`);return{domainName:t||n,subdomainName:t?n:void 0}}var z="0x37368b46ce665362562c6d1d4ec01a08c8644c488690df5a17e13ba163e20221",G="0x585fc9f0f0c54183b039ffc770ca282ebd87307916c215a3e692f2f8e4305e82",P={testnet:"0x5f8fd2347449685cf41d4db97926ec3a096eaf381332be4f1318ad4d16a8497c",mainnet:"0x867ed1f6bf916171b1de3ee92849b8978b7d1b9e0a8cc982a3d19d535dfd9c0c",local:G,custom:null,devnet:null,randomnet:null};function d(e){let n=P[e.network];if(!n)throw new Error(`The ANS contract is not deployed to ${e.network}`);return n}var b=e=>{if(e&&typeof e=="object"&&"vec"in e&&Array.isArray(e.vec))return e.vec[0]};async function V(e){let{aptosConfig:n,name:t}=e,o=d(n),{domainName:r,subdomainName:s}=c(t),i=await g({aptosConfig:n,payload:{function:`${o}::router::get_owner_addr`,functionArguments:[r,s]}}),a=b(i[0]);return a?w.from(a):void 0}async function j(e){let{aptosConfig:n,expiration:t,name:o,sender:r,targetAddress:s,toAddress:i,options:a,transferable:u}=e,p=d(n),{domainName:N,subdomainName:l}=c(o),S=t.policy==="subdomain:independent"||t.policy==="subdomain:follow-domain";if(l&&!S)throw new Error("Subdomains must have an expiration policy of either 'subdomain:independent' or 'subdomain:follow-domain'");if(S&&!l)throw new Error(`Policy is set to ${t.policy} but no subdomain was provided`);if(t.policy==="domain"){let h=t.years??1;if(h!==1)throw new Error("For now, names can only be registered for 1 year at a time");let D=h*31536e3;return await m({aptosConfig:n,sender:r.accountAddress.toString(),data:{function:`${p}::router::register_domain`,functionArguments:[N,D,s,i]},options:a})}if(!l)throw new Error(`${t.policy} requires a subdomain to be provided.`);let _=await I({aptosConfig:n,name:N});if(!_)throw new Error("The domain does not exist");let x=t.policy==="subdomain:independent"?t.expirationDate:_;if(x>_)throw new Error("The subdomain expiration time cannot be greater than the domain expiration time");return await m({aptosConfig:n,sender:r.accountAddress.toString(),data:{function:`${p}::router::register_subdomain`,functionArguments:[N,l,Math.round(x/1e3),t.policy==="subdomain:follow-domain"?1:0,!!u,s,i]},options:a})}async function I(e){let{aptosConfig:n,name:t}=e,o=d(n),{domainName:r,subdomainName:s}=c(t);try{let i=await g({aptosConfig:n,payload:{function:`${o}::router::get_expiration`,functionArguments:[r,s]}});return Number(i[0])*1e3}catch{return}}async function Y(e){let{aptosConfig:n,address:t}=e,o=d(n),r=await g({aptosConfig:n,payload:{function:`${o}::router::get_primary_name`,functionArguments:[w.from(t).toString()]}}),s=b(r[1]),i=b(r[0]);if(s)return[i,s].filter(Boolean).join(".")}async function K(e){let{aptosConfig:n,sender:t,name:o,options:r}=e,s=d(n);if(!o)return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${s}::router::clear_primary_name`,functionArguments:[]},options:r});let{domainName:i,subdomainName:a}=c(o);return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${s}::router::set_primary_name`,functionArguments:[i,a]},options:r})}async function W(e){let{aptosConfig:n,name:t}=e,o=d(n),{domainName:r,subdomainName:s}=c(t),i=await g({aptosConfig:n,payload:{function:`${o}::router::get_target_addr`,functionArguments:[r,s]}}),a=b(i[0]);return a?w.from(a):void 0}async function F(e){let{aptosConfig:n,sender:t,name:o,address:r,options:s}=e,i=d(n),{domainName:a,subdomainName:u}=c(o);return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${i}::router::set_target_addr`,functionArguments:[a,u,r]},options:s})}async function H(e){let{aptosConfig:n,name:t}=e,{domainName:o,subdomainName:r=""}=c(t),a=(await A({aptosConfig:n,query:{query:f,variables:{where_condition:{domain:{_eq:o},subdomain:{_eq:r},is_active:{_eq:!0}},limit:1}},originMethod:"getName"})).current_aptos_names[0];return a&&(a=y(a)),a}async function J(e){let{aptosConfig:n,options:t,accountAddress:o}=e,r=await C({aptosConfig:n});return(await A({aptosConfig:n,originMethod:"getAccountNames",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},owner_address:{_eq:o.toString()},expiration_timestamp:{_gte:r}}}}})).current_aptos_names.map(y)}async function X(e){let{aptosConfig:n,options:t,accountAddress:o}=e,r=await C({aptosConfig:n});return(await A({aptosConfig:n,originMethod:"getAccountDomains",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},owner_address:{_eq:o.toString()},expiration_timestamp:{_gte:r},subdomain:{_eq:""}}}}})).current_aptos_names.map(y)}async function Z(e){let{aptosConfig:n,options:t,accountAddress:o}=e,r=await C({aptosConfig:n});return(await A({aptosConfig:n,originMethod:"getAccountSubdomains",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},owner_address:{_eq:o.toString()},expiration_timestamp:{_gte:r},subdomain:{_neq:""}}}}})).current_aptos_names.map(y)}async function ee(e){let{aptosConfig:n,options:t,domain:o}=e;return(await A({aptosConfig:n,originMethod:"getDomainSubdomains",query:{query:f,variables:{limit:t?.limit,offset:t?.offset,order_by:t?.orderBy,where_condition:{...e.options?.where??{},domain:{_eq:o},subdomain:{_neq:""},is_active:{_eq:!0}}}}})).current_aptos_names.map(y)}async function C(e){let{aptosConfig:n}=e,t=d(n),[o]=await g({aptosConfig:n,payload:{function:`${t}::config::reregistration_grace_sec`,functionArguments:[]}}),r=o/60/60/24,s=()=>new Date;return new Date(s().setDate(s().getDate()-r)).toISOString()}async function ne(e){let{aptosConfig:n,sender:t,name:o,years:r=1,options:s}=e,i=d(n),a=r*31536e3,{domainName:u,subdomainName:p}=c(o);if(p)throw new Error("Subdomains cannot be renewed");if(r!==1)throw new Error("Currently, only 1 year renewals are supported");return await m({aptosConfig:n,sender:t.accountAddress.toString(),data:{function:`${i}::router::renew_domain`,functionArguments:[u,a]},options:s})}function y(e){return{...e,expiration_timestamp:new Date(e.expiration_timestamp).getTime()}}export{T as a,E as b,c,z as d,G as e,V as f,j as g,I as h,Y as i,K as j,W as k,F as l,H as m,J as n,X as o,Z as p,ee as q,ne as r};
2
+ //# sourceMappingURL=chunk-4WMPZEJS.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-E36GTDEB.mjs";import{a as i}from"./chunk-Z2ZR4PTF.mjs";import{a as r}from"./chunk-TVRJ3M7B.mjs";var n=class o extends r{constructor(t,a){super();this.raw_txn=t,this.authenticator=a}serialize(t){this.raw_txn.serialize(t),this.authenticator.serialize(t)}static deserialize(t){let a=i.deserialize(t),s=e.deserialize(t);return new o(a,s)}};export{n as a};
2
- //# sourceMappingURL=chunk-X56CTMYB.mjs.map
1
+ import{a as i}from"./chunk-Z2ZR4PTF.mjs";import{a as e}from"./chunk-ZGTJMNZG.mjs";import{a as r}from"./chunk-TVRJ3M7B.mjs";var n=class o extends r{constructor(t,a){super();this.raw_txn=t,this.authenticator=a}serialize(t){this.raw_txn.serialize(t),this.authenticator.serialize(t)}static deserialize(t){let a=i.deserialize(t),s=e.deserialize(t);return new o(a,s)}};export{n as a};
2
+ //# sourceMappingURL=chunk-5QBTBH64.mjs.map
@@ -0,0 +1,2 @@
1
+ var s={mainnet:"https://api.mainnet.aptoslabs.com/v1/graphql",testnet:"https://api.testnet.aptoslabs.com/v1/graphql",devnet:"https://api.devnet.aptoslabs.com/v1/graphql",randomnet:"https://indexer-randomnet.hasura.app/v1/graphql",local:"http://127.0.0.1:8090/v1/graphql"},o={mainnet:"https://api.mainnet.aptoslabs.com/v1",testnet:"https://api.testnet.aptoslabs.com/v1",devnet:"https://api.devnet.aptoslabs.com/v1",randomnet:"https://fullnode.random.aptoslabs.com/v1",local:"http://127.0.0.1:8080/v1"},n={mainnet:"https://faucet.mainnet.aptoslabs.com",testnet:"https://faucet.testnet.aptoslabs.com",devnet:"https://faucet.devnet.aptoslabs.com",randomnet:"https://faucet.random.aptoslabs.com",local:"http://127.0.0.1:8081"},a={mainnet:"mainnet not yet ready, requires sdk upgrade",testnet:"https://pepper.keyless.testnet.aptoslabs.com/v0",devnet:"https://pepper.keyless.devnet.aptoslabs.com/v0",local:"https://pepper.keyless.devnet.aptoslabs.com/v0"},p={mainnet:"mainnet not yet ready, requires sdk upgrade",testnet:"https://prover.keyless.testnet.aptoslabs.com/v0",devnet:"https://prover.keyless.devnet.aptoslabs.com/v0",local:"https://prover.keyless.devnet.aptoslabs.com/v0"},e=(t=>(t.MAINNET="mainnet",t.TESTNET="testnet",t.DEVNET="devnet",t.RANDOMNET="randomnet",t.LOCAL="local",t.CUSTOM="custom",t))(e||{}),r={mainnet:1,testnet:2,randomnet:70,local:4},c={mainnet:"mainnet",testnet:"testnet",devnet:"devnet",randomnet:"randomnet",local:"local",custom:"custom"};export{s as a,o as b,n as c,a as d,p as e,e as f,r as g,c as h};
2
+ //# sourceMappingURL=chunk-5RBI4QWR.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/utils/apiEndpoints.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\nexport const NetworkToIndexerAPI: Record<string, string> = {\n mainnet: \"https://api.mainnet.aptoslabs.com/v1/graphql\",\n testnet: \"https://api.testnet.aptoslabs.com/v1/graphql\",\n devnet: \"https://api.devnet.aptoslabs.com/v1/graphql\",\n randomnet: \"https://indexer-randomnet.hasura.app/v1/graphql\",\n local: \"http://127.0.0.1:8090/v1/graphql\",\n};\n\nexport const NetworkToNodeAPI: Record<string, string> = {\n mainnet: \"https://api.mainnet.aptoslabs.com/v1\",\n testnet: \"https://api.testnet.aptoslabs.com/v1\",\n devnet: \"https://api.devnet.aptoslabs.com/v1\",\n randomnet: \"https://fullnode.random.aptoslabs.com/v1\",\n local: \"http://127.0.0.1:8080/v1\",\n};\n\nexport const NetworkToFaucetAPI: Record<string, string> = {\n mainnet: \"https://faucet.mainnet.aptoslabs.com\",\n testnet: \"https://faucet.testnet.aptoslabs.com\",\n devnet: \"https://faucet.devnet.aptoslabs.com\",\n randomnet: \"https://faucet.random.aptoslabs.com\",\n local: \"http://127.0.0.1:8081\",\n};\n\nexport const NetworkToPepperAPI: Record<string, string> = {\n mainnet: \"mainnet not yet ready, requires sdk upgrade\",\n testnet: \"https://pepper.keyless.testnet.aptoslabs.com/v0\",\n devnet: \"https://pepper.keyless.devnet.aptoslabs.com/v0\",\n local: \"https://pepper.keyless.devnet.aptoslabs.com/v0\",\n};\n\nexport const NetworkToProverAPI: Record<string, string> = {\n mainnet: \"mainnet not yet ready, requires sdk upgrade\",\n testnet: \"https://prover.keyless.testnet.aptoslabs.com/v0\",\n devnet: \"https://prover.keyless.devnet.aptoslabs.com/v0\",\n local: \"https://prover.keyless.devnet.aptoslabs.com/v0\",\n};\n\nexport enum Network {\n MAINNET = \"mainnet\",\n TESTNET = \"testnet\",\n DEVNET = \"devnet\",\n RANDOMNET = \"randomnet\",\n LOCAL = \"local\",\n CUSTOM = \"custom\",\n}\n\nexport const NetworkToChainId: Record<string, number> = {\n mainnet: 1,\n testnet: 2,\n randomnet: 70,\n local: 4,\n};\n\nexport const NetworkToNetworkName: Record<string, Network> = {\n mainnet: Network.MAINNET,\n testnet: Network.TESTNET,\n devnet: Network.DEVNET,\n randomnet: Network.RANDOMNET,\n local: Network.LOCAL,\n custom: Network.CUSTOM,\n};\n"],"mappings":"AAGO,IAAMA,EAA8C,CACzD,QAAS,+CACT,QAAS,+CACT,OAAQ,8CACR,UAAW,kDACX,MAAO,kCACT,EAEaC,EAA2C,CACtD,QAAS,uCACT,QAAS,uCACT,OAAQ,sCACR,UAAW,2CACX,MAAO,0BACT,EAEaC,EAA6C,CACxD,QAAS,uCACT,QAAS,uCACT,OAAQ,sCACR,UAAW,sCACX,MAAO,uBACT,EAEaC,EAA6C,CACxD,QAAS,8CACT,QAAS,kDACT,OAAQ,iDACR,MAAO,gDACT,EAEaC,EAA6C,CACxD,QAAS,8CACT,QAAS,kDACT,OAAQ,iDACR,MAAO,gDACT,EAEYC,OACVA,EAAA,QAAU,UACVA,EAAA,QAAU,UACVA,EAAA,OAAS,SACTA,EAAA,UAAY,YACZA,EAAA,MAAQ,QACRA,EAAA,OAAS,SANCA,OAAA,IASCC,EAA2C,CACtD,QAAS,EACT,QAAS,EACT,UAAW,GACX,MAAO,CACT,EAEaC,EAAgD,CAC3D,QAAS,UACT,QAAS,UACT,OAAQ,SACR,UAAW,YACX,MAAO,QACP,OAAQ,QACV","names":["NetworkToIndexerAPI","NetworkToNodeAPI","NetworkToFaucetAPI","NetworkToPepperAPI","NetworkToProverAPI","Network","NetworkToChainId","NetworkToNetworkName"]}
@@ -1,2 +1,2 @@
1
- import{a,c}from"./chunk-7FNHL6LU.mjs";import{i as o,o as l}from"./chunk-6NMHAFIO.mjs";import{a as n,c as s}from"./chunk-CQJ4WN7M.mjs";import{b}from"./chunk-COW5IGYC.mjs";import{a as p}from"./chunk-STYDBDYL.mjs";import{a as y}from"./chunk-7STYQ5ZE.mjs";var f=class t extends b{constructor(e){super();if(this.publicKey=e,e instanceof n)this.variant=0;else if(e instanceof a)this.variant=1;else if(e instanceof o)this.variant=3;else throw new Error("Unsupported public key type")}verifySignature(e){let{message:r,signature:i}=e;return i instanceof u?this.publicKey.verifySignature({message:r,signature:i.signature}):!1}authKey(){return y.fromSchemeAndBytes({scheme:2,input:this.toUint8Array()})}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeU32AsUleb128(this.variant),this.publicKey.serialize(e)}static deserialize(e){let r=e.deserializeUleb128AsU32(),i;switch(r){case 0:i=n.deserialize(e);break;case 1:i=a.deserialize(e);break;case 3:i=o.deserialize(e);break;default:throw new Error(`Unknown variant index for AnyPublicKey: ${r}`)}return new t(i)}static isPublicKey(e){return e instanceof t}isEd25519(){return this.publicKey instanceof n}isSecp256k1PublicKey(){return this.publicKey instanceof a}},u=class t extends p{constructor(e){super();if(this.signature=e,e instanceof s)this.variant=0;else if(e instanceof c)this.variant=1;else if(e instanceof l)this.variant=3;else throw new Error("Unsupported signature type")}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeU32AsUleb128(this.variant),this.signature.serialize(e)}static deserialize(e){let r=e.deserializeUleb128AsU32(),i;switch(r){case 0:i=s.deserialize(e);break;case 1:i=c.deserialize(e);break;case 3:i=l.deserialize(e);break;default:throw new Error(`Unknown variant index for AnySignature: ${r}`)}return new t(i)}};export{f as a,u as b};
2
- //# sourceMappingURL=chunk-HURQZGUZ.mjs.map
1
+ import{a,c}from"./chunk-PTIZKRON.mjs";import{i as o,o as l}from"./chunk-WTVN3XGK.mjs";import{a as n,c as s}from"./chunk-7JNPSNL6.mjs";import{b}from"./chunk-COW5IGYC.mjs";import{a as p}from"./chunk-STYDBDYL.mjs";import{a as y}from"./chunk-7STYQ5ZE.mjs";var f=class t extends b{constructor(e){super();if(this.publicKey=e,e instanceof n)this.variant=0;else if(e instanceof a)this.variant=1;else if(e instanceof o)this.variant=3;else throw new Error("Unsupported public key type")}verifySignature(e){let{message:r,signature:i}=e;return i instanceof u?this.publicKey.verifySignature({message:r,signature:i.signature}):!1}authKey(){return y.fromSchemeAndBytes({scheme:2,input:this.toUint8Array()})}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeU32AsUleb128(this.variant),this.publicKey.serialize(e)}static deserialize(e){let r=e.deserializeUleb128AsU32(),i;switch(r){case 0:i=n.deserialize(e);break;case 1:i=a.deserialize(e);break;case 3:i=o.deserialize(e);break;default:throw new Error(`Unknown variant index for AnyPublicKey: ${r}`)}return new t(i)}static isPublicKey(e){return e instanceof t}isEd25519(){return this.publicKey instanceof n}isSecp256k1PublicKey(){return this.publicKey instanceof a}},u=class t extends p{constructor(e){super();if(this.signature=e,e instanceof s)this.variant=0;else if(e instanceof c)this.variant=1;else if(e instanceof l)this.variant=3;else throw new Error("Unsupported signature type")}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeU32AsUleb128(this.variant),this.signature.serialize(e)}static deserialize(e){let r=e.deserializeUleb128AsU32(),i;switch(r){case 0:i=s.deserialize(e);break;case 1:i=c.deserialize(e);break;case 3:i=l.deserialize(e);break;default:throw new Error(`Unknown variant index for AnySignature: ${r}`)}return new t(i)}};export{f as a,u as b};
2
+ //# sourceMappingURL=chunk-6M6XXPQQ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as n,b as s,c as r,d as i,e as o,f as a,g as c,h as p,i as d,j as g,k as u,l as A,m as y,n as l,o as m,p as T,q as f,r as I,s as C,t as O,u as P,v as D}from"./chunk-JEUAQVXW.mjs";import{a as e}from"./chunk-HFLWASAB.mjs";var V=class{constructor(t){this.config=t}async getCollectionData(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),a({aptosConfig:this.config,...t})}async getCollectionDataByCollectionId(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),c({aptosConfig:this.config,...t})}async getCollectionId(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),p({aptosConfig:this.config,...t})}async getDigitalAssetData(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),n({aptosConfig:this.config,...t})}async getCurrentDigitalAssetOwnership(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),s({aptosConfig:this.config,...t})}async getOwnedDigitalAssets(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),r({aptosConfig:this.config,...t})}async getDigitalAssetActivity(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),i({aptosConfig:this.config,...t})}async createCollectionTransaction(t){return o({aptosConfig:this.config,...t})}async mintDigitalAssetTransaction(t){return d({aptosConfig:this.config,...t})}async transferDigitalAssetTransaction(t){return g({aptosConfig:this.config,...t})}async mintSoulBoundTransaction(t){return u({aptosConfig:this.config,...t})}async burnDigitalAssetTransaction(t){return A({aptosConfig:this.config,...t})}async freezeDigitalAssetTransaferTransaction(t){return y({aptosConfig:this.config,...t})}async unfreezeDigitalAssetTransaferTransaction(t){return l({aptosConfig:this.config,...t})}async setDigitalAssetDescriptionTransaction(t){return m({aptosConfig:this.config,...t})}async setDigitalAssetNameTransaction(t){return T({aptosConfig:this.config,...t})}async setDigitalAssetURITransaction(t){return f({aptosConfig:this.config,...t})}async addDigitalAssetPropertyTransaction(t){return I({aptosConfig:this.config,...t})}async removeDigitalAssetPropertyTransaction(t){return C({aptosConfig:this.config,...t})}async updateDigitalAssetPropertyTransaction(t){return O({aptosConfig:this.config,...t})}async addDigitalAssetTypedPropertyTransaction(t){return P({aptosConfig:this.config,...t})}async updateDigitalAssetTypedPropertyTransaction(t){return D({aptosConfig:this.config,...t})}};export{V as a};
2
- //# sourceMappingURL=chunk-CN37OHFT.mjs.map
1
+ import{a as n,b as s,c as r,d as i,e as o,f as a,g as c,h as p,i as d,j as g,k as u,l as A,m as y,n as l,o as m,p as T,q as f,r as I,s as C,t as O,u as P,v as D}from"./chunk-EBCDMINE.mjs";import{a as e}from"./chunk-VFALS4YR.mjs";var V=class{constructor(t){this.config=t}async getCollectionData(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),a({aptosConfig:this.config,...t})}async getCollectionDataByCollectionId(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),c({aptosConfig:this.config,...t})}async getCollectionId(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),p({aptosConfig:this.config,...t})}async getDigitalAssetData(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),n({aptosConfig:this.config,...t})}async getCurrentDigitalAssetOwnership(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),s({aptosConfig:this.config,...t})}async getOwnedDigitalAssets(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),r({aptosConfig:this.config,...t})}async getDigitalAssetActivity(t){return await e({config:this.config,minimumLedgerVersion:t.minimumLedgerVersion,processorType:"token_v2_processor"}),i({aptosConfig:this.config,...t})}async createCollectionTransaction(t){return o({aptosConfig:this.config,...t})}async mintDigitalAssetTransaction(t){return d({aptosConfig:this.config,...t})}async transferDigitalAssetTransaction(t){return g({aptosConfig:this.config,...t})}async mintSoulBoundTransaction(t){return u({aptosConfig:this.config,...t})}async burnDigitalAssetTransaction(t){return A({aptosConfig:this.config,...t})}async freezeDigitalAssetTransaferTransaction(t){return y({aptosConfig:this.config,...t})}async unfreezeDigitalAssetTransaferTransaction(t){return l({aptosConfig:this.config,...t})}async setDigitalAssetDescriptionTransaction(t){return m({aptosConfig:this.config,...t})}async setDigitalAssetNameTransaction(t){return T({aptosConfig:this.config,...t})}async setDigitalAssetURITransaction(t){return f({aptosConfig:this.config,...t})}async addDigitalAssetPropertyTransaction(t){return I({aptosConfig:this.config,...t})}async removeDigitalAssetPropertyTransaction(t){return C({aptosConfig:this.config,...t})}async updateDigitalAssetPropertyTransaction(t){return O({aptosConfig:this.config,...t})}async addDigitalAssetTypedPropertyTransaction(t){return P({aptosConfig:this.config,...t})}async updateDigitalAssetTypedPropertyTransaction(t){return D({aptosConfig:this.config,...t})}};export{V as a};
2
+ //# sourceMappingURL=chunk-7CW32VZG.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as c}from"./chunk-TJDC5PWD.mjs";import{b as p}from"./chunk-COW5IGYC.mjs";import{a as A}from"./chunk-STYDBDYL.mjs";import{g as d,k as f,l as h}from"./chunk-S5HG2QUD.mjs";import{a as m}from"./chunk-7STYQ5ZE.mjs";import{a as g}from"./chunk-TVRJ3M7B.mjs";import{b as n}from"./chunk-AOCNYMMX.mjs";import{ed25519 as o}from"@noble/curves/ed25519";var K=[237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16],i=class i extends p{constructor(e){super();let t=n.fromHexInput(e);if(t.toUint8Array().length!==i.LENGTH)throw new Error(`PublicKey length should be ${i.LENGTH}`);this.key=t}verifySignature(e){let{message:t,signature:a}=e;if(!(a instanceof y))return!1;let u=c(t),S=n.fromHexInput(u).toUint8Array(),v=a.toUint8Array(),U=this.key.toUint8Array();return a.isCanonicalSignature()?o.verify(v,S,U):!1}authKey(){return m.fromSchemeAndBytes({scheme:0,input:this.toUint8Array()})}toUint8Array(){return this.key.toUint8Array()}serialize(e){e.serializeBytes(this.key.toUint8Array())}static deserialize(e){let t=e.deserializeBytes();return new i(t)}static isPublicKey(e){return e instanceof i}};i.LENGTH=32;var l=i,r=class r extends g{constructor(e){super();let t=n.fromHexInput(e);if(t.toUint8Array().length!==r.LENGTH)throw new Error(`PrivateKey length should be ${r.LENGTH}`);this.signingKey=t}static generate(){let e=o.utils.randomPrivateKey();return new r(e)}static fromDerivationPath(e,t){if(!d(e))throw new Error(`Invalid derivation path ${e}`);return new r(f(e,r.SLIP_0010_SEED,h(t)))}publicKey(){let e=o.getPublicKey(this.signingKey.toUint8Array());return new l(e)}sign(e){let t=c(e),a=n.fromHexInput(t).toUint8Array(),u=o.sign(a,this.signingKey.toUint8Array());return new y(u)}toUint8Array(){return this.signingKey.toUint8Array()}toString(){return this.signingKey.toString()}serialize(e){e.serializeBytes(this.toUint8Array())}static deserialize(e){let t=e.deserializeBytes();return new r(t)}static isPrivateKey(e){return e instanceof r}};r.LENGTH=32,r.SLIP_0010_SEED="ed25519 seed";var H=r,s=class s extends A{constructor(e){super();let t=n.fromHexInput(e);if(t.toUint8Array().length!==s.LENGTH)throw new Error(`Signature length should be ${s.LENGTH}`);this.data=t}toUint8Array(){return this.data.toUint8Array()}serialize(e){e.serializeBytes(this.data.toUint8Array())}static deserialize(e){let t=e.deserializeBytes();return new s(t)}isCanonicalSignature(){let e=this.toUint8Array().slice(32);for(let t=e.length-1;t>=0;t-=1){if(e[t]<K[t])return!0;if(e[t]>K[t])return!1}return!1}};s.LENGTH=64;var y=s;export{l as a,H as b,y as c};
2
- //# sourceMappingURL=chunk-CQJ4WN7M.mjs.map
1
+ import{b as p}from"./chunk-COW5IGYC.mjs";import{a as A}from"./chunk-STYDBDYL.mjs";import{a as c}from"./chunk-TJDC5PWD.mjs";import{g as d,k as f,l as h}from"./chunk-S5HG2QUD.mjs";import{a as m}from"./chunk-7STYQ5ZE.mjs";import{a as g}from"./chunk-TVRJ3M7B.mjs";import{b as n}from"./chunk-AOCNYMMX.mjs";import{ed25519 as o}from"@noble/curves/ed25519";var K=[237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16],i=class i extends p{constructor(e){super();let t=n.fromHexInput(e);if(t.toUint8Array().length!==i.LENGTH)throw new Error(`PublicKey length should be ${i.LENGTH}`);this.key=t}verifySignature(e){let{message:t,signature:a}=e;if(!(a instanceof y))return!1;let u=c(t),S=n.fromHexInput(u).toUint8Array(),v=a.toUint8Array(),U=this.key.toUint8Array();return a.isCanonicalSignature()?o.verify(v,S,U):!1}authKey(){return m.fromSchemeAndBytes({scheme:0,input:this.toUint8Array()})}toUint8Array(){return this.key.toUint8Array()}serialize(e){e.serializeBytes(this.key.toUint8Array())}static deserialize(e){let t=e.deserializeBytes();return new i(t)}static isPublicKey(e){return e instanceof i}};i.LENGTH=32;var l=i,r=class r extends g{constructor(e){super();let t=n.fromHexInput(e);if(t.toUint8Array().length!==r.LENGTH)throw new Error(`PrivateKey length should be ${r.LENGTH}`);this.signingKey=t}static generate(){let e=o.utils.randomPrivateKey();return new r(e)}static fromDerivationPath(e,t){if(!d(e))throw new Error(`Invalid derivation path ${e}`);return new r(f(e,r.SLIP_0010_SEED,h(t)))}publicKey(){let e=o.getPublicKey(this.signingKey.toUint8Array());return new l(e)}sign(e){let t=c(e),a=n.fromHexInput(t).toUint8Array(),u=o.sign(a,this.signingKey.toUint8Array());return new y(u)}toUint8Array(){return this.signingKey.toUint8Array()}toString(){return this.signingKey.toString()}serialize(e){e.serializeBytes(this.toUint8Array())}static deserialize(e){let t=e.deserializeBytes();return new r(t)}static isPrivateKey(e){return e instanceof r}};r.LENGTH=32,r.SLIP_0010_SEED="ed25519 seed";var H=r,s=class s extends A{constructor(e){super();let t=n.fromHexInput(e);if(t.toUint8Array().length!==s.LENGTH)throw new Error(`Signature length should be ${s.LENGTH}`);this.data=t}toUint8Array(){return this.data.toUint8Array()}serialize(e){e.serializeBytes(this.data.toUint8Array())}static deserialize(e){let t=e.deserializeBytes();return new s(t)}isCanonicalSignature(){let e=this.toUint8Array().slice(32);for(let t=e.length-1;t>=0;t-=1){if(e[t]<K[t])return!0;if(e[t]>K[t])return!1}return!1}};s.LENGTH=64;var y=s;export{l as a,H as b,y as c};
2
+ //# sourceMappingURL=chunk-7JNPSNL6.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as A}from"./chunk-274CXZ6R.mjs";import{a as T}from"./chunk-H6BRBIMG.mjs";import{a as y}from"./chunk-T3W5USZC.mjs";import{a as d}from"./chunk-AKGASNN4.mjs";import{d as g,e as a,h as m,i as p,j as f}from"./chunk-RPXN7HGR.mjs";import{a as i,b as s,c as r,d as e,e as c,g as u}from"./chunk-6NZNCDDW.mjs";var h=class{constructor(n){this.config=n,this.build=new y(this.config),this.simulate=new A(this.config),this.submit=new T(this.config),this.batch=new d(this.config)}async getTransactions(n){return i({aptosConfig:this.config,...n})}async getTransactionByVersion(n){return r({aptosConfig:this.config,...n})}async getTransactionByHash(n){return e({aptosConfig:this.config,...n})}async isPendingTransaction(n){return c({aptosConfig:this.config,...n})}async waitForTransaction(n){return u({aptosConfig:this.config,...n})}async getGasPriceEstimation(){return s({aptosConfig:this.config})}getSigningMessage(n){return g(n)}async publishPackageTransaction(n){return p({aptosConfig:this.config,...n})}async rotateAuthKey(n){return f({aptosConfig:this.config,...n})}sign(n){return a({...n})}signAsFeePayer(n){let{signer:t,transaction:o}=n;if(!o.feePayerAddress)throw new Error(`Transaction ${o} is not a Fee Payer transaction`);return o.feePayerAddress=t.accountAddress,a({signer:t,transaction:o})}async batchTransactionsForSingleAccount(n){try{let{sender:t,data:o,options:P}=n;this.batch.forSingleAccount({sender:t,data:o,options:P})}catch(t){throw new Error(`failed to submit transactions with error: ${t}`)}}async signAndSubmitTransaction(n){let{signer:t,transaction:o}=n;return m({aptosConfig:this.config,signer:t,transaction:o})}};export{h as a};
2
- //# sourceMappingURL=chunk-SRLCFTZR.mjs.map
1
+ import{a as A}from"./chunk-ZXUU37PN.mjs";import{a as T}from"./chunk-PPXY7O7X.mjs";import{a as y}from"./chunk-SW6IHEIE.mjs";import{a as d}from"./chunk-RSPF5S2J.mjs";import{d as g,e as a,h as m,i as p,j as f}from"./chunk-T75EO4EY.mjs";import{a as i,b as s,c as r,d as e,e as c,g as u}from"./chunk-PFQQIEWF.mjs";var h=class{constructor(n){this.config=n,this.build=new y(this.config),this.simulate=new A(this.config),this.submit=new T(this.config),this.batch=new d(this.config)}async getTransactions(n){return i({aptosConfig:this.config,...n})}async getTransactionByVersion(n){return r({aptosConfig:this.config,...n})}async getTransactionByHash(n){return e({aptosConfig:this.config,...n})}async isPendingTransaction(n){return c({aptosConfig:this.config,...n})}async waitForTransaction(n){return u({aptosConfig:this.config,...n})}async getGasPriceEstimation(){return s({aptosConfig:this.config})}getSigningMessage(n){return g(n)}async publishPackageTransaction(n){return p({aptosConfig:this.config,...n})}async rotateAuthKey(n){return f({aptosConfig:this.config,...n})}sign(n){return a({...n})}signAsFeePayer(n){let{signer:t,transaction:o}=n;if(!o.feePayerAddress)throw new Error(`Transaction ${o} is not a Fee Payer transaction`);return o.feePayerAddress=t.accountAddress,a({signer:t,transaction:o})}async batchTransactionsForSingleAccount(n){try{let{sender:t,data:o,options:P}=n;this.batch.forSingleAccount({sender:t,data:o,options:P})}catch(t){throw new Error(`failed to submit transactions with error: ${t}`)}}async signAndSubmitTransaction(n){let{signer:t,transaction:o}=n;return m({aptosConfig:this.config,signer:t,transaction:o})}};export{h as a};
2
+ //# sourceMappingURL=chunk-ADQGYJZR.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as i,b as t,c as n,d as o}from"./chunk-TBG3MIIE.mjs";import{a as s}from"./chunk-HFLWASAB.mjs";var r=class{constructor(e){this.config=e}async getFungibleAssetMetadata(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),i({aptosConfig:this.config,...e})}async getFungibleAssetMetadataByAssetType(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),(await i({aptosConfig:this.config,options:{where:{asset_type:{_eq:e.assetType}}}}))[0]}async getFungibleAssetActivities(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),t({aptosConfig:this.config,...e})}async getCurrentFungibleAssetBalances(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),n({aptosConfig:this.config,...e})}async transferFungibleAsset(e){return o({aptosConfig:this.config,...e})}};export{r as a};
2
- //# sourceMappingURL=chunk-KCVBUZ6L.mjs.map
1
+ import{a as i,b as t,c as n,d as o}from"./chunk-LRUXIKHV.mjs";import{a as s}from"./chunk-VFALS4YR.mjs";var r=class{constructor(e){this.config=e}async getFungibleAssetMetadata(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),i({aptosConfig:this.config,...e})}async getFungibleAssetMetadataByAssetType(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),(await i({aptosConfig:this.config,options:{where:{asset_type:{_eq:e.assetType}}}}))[0]}async getFungibleAssetActivities(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),t({aptosConfig:this.config,...e})}async getCurrentFungibleAssetBalances(e){return await s({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"fungible_asset_processor"}),n({aptosConfig:this.config,...e})}async transferFungibleAsset(e){return o({aptosConfig:this.config,...e})}};export{r as a};
2
+ //# sourceMappingURL=chunk-AN2KSYKO.mjs.map
@@ -1,2 +1,2 @@
1
- import{c as r}from"./chunk-QHIQLTBS.mjs";import{b as i}from"./chunk-7XHVF3ZX.mjs";import{b as t}from"./chunk-TVRJ3M7B.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-SNQJV7MF.mjs.map
1
+ import{c as r}from"./chunk-VI4ZVGUW.mjs";import{b as i}from"./chunk-VPZ4ZYJA.mjs";import{b as t}from"./chunk-TVRJ3M7B.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-CQ6CHOHQ.mjs.map
@@ -1,2 +1,2 @@
1
- import{c as A}from"./chunk-PFFAQZHT.mjs";import{a as x,b as c,c as w,d as g,e as M,f as C,g as O,h,i as _,k as V,l as G,m as j,n as k,o as z,p as D,r as i,s as L}from"./chunk-7H3HRFVM.mjs";import{c as I}from"./chunk-QXVGXZJX.mjs";import{n as p}from"./chunk-3VGX3TXH.mjs";import{b as U}from"./chunk-T23OVRNF.mjs";import{a as o,b as S,c as T}from"./chunk-EB7AI4B4.mjs";import{a as d,b as E,c as B,d as v,e as $,f as b,g as F}from"./chunk-6RBUXB5I.mjs";var R=new TextEncoder;function Z(n){return n?.map(e=>c(e)?A(e):e)??[]}async function P(n,e,t,u){let r=await I({aptosConfig:u,accountAddress:n,moduleName:e});if(r.abi)return r.abi.exposed_functions.find(f=>f.name===t)}async function N(n,e,t,u){let r=await P(n,e,t,u);if(!r)throw new Error(`Could not find entry function ABI for '${n}::${e}::${t}'`);if(!r.is_entry)throw new Error(`'${n}::${e}::${t}' is not an entry function`);let f=L(r),y=[];for(let s=f;s<r.params.length;s+=1)y.push(A(r.params[s],{allowGenerics:!0}));return{signers:f,typeParameters:r.generic_type_params,parameters:y}}async function a(n,e,t,u){let r=await P(n,e,t,u);if(!r)throw new Error(`Could not find view function ABI for '${n}::${e}::${t}'`);if(!r.is_view)throw new Error(`'${n}::${e}::${t}' is not an view function`);let f=[];for(let s=0;s<r.params.length;s+=1)f.push(A(r.params[s],{allowGenerics:!0}));let y=[];for(let s=0;s<r.return.length;s+=1)y.push(A(r.return[s],{allowGenerics:!0}));return{typeParameters:r.generic_type_params,parameters:f,returnTypes:y}}function nn(n,e,t,u,r){if(u>=e.parameters.length)throw new Error(`Too many arguments for '${n}', expected ${e.parameters.length}`);let f=e.parameters[u];return l(t,f,u,r)}function l(n,e,t,u){return C(n)?(m(e,n,t),n):X(n,e,t,u)}function X(n,e,t,u){if(e.isBool()){if(x(n))return new d(n);i("boolean",t)}if(e.isAddress()){if(c(n))return U.fromString(n);i("string | AccountAddress",t)}if(e.isU8()){if(w(n))return new E(n);i("number",t)}if(e.isU16()){if(w(n))return new B(n);i("number",t)}if(e.isU32()){if(w(n))return new v(n);i("number",t)}if(e.isU64()){if(g(n))return new $(BigInt(n));i("bigint | number | string",t)}if(e.isU128()){if(g(n))return new b(BigInt(n));i("bigint | number | string",t)}if(e.isU256()){if(g(n))return new F(BigInt(n));i("bigint | number | string",t)}if(e.isGeneric()){let r=e.value;if(r<0||r>=u.length)throw new Error(`Generic argument ${e.toString()} is invalid for argument ${t}`);return l(n,u[r],t,u)}if(e.isVector()){if(e.value.isU8()){if(c(n))return o.U8(R.encode(n));if(n instanceof Uint8Array)return o.U8(n);if(n instanceof ArrayBuffer)return o.U8(new Uint8Array(n))}if(Array.isArray(n))return new o(n.map(r=>l(r,e.value,t,u)));throw new Error(`Type mismatch for argument ${t}, type '${e.toString()}'`)}if(e.isStruct()){if(e.isString()){if(c(n))return new S(n);i("string",t)}if(e.isObject()){if(c(n))return U.fromString(n);i("string | AccountAddress",t)}if(e.isOption())return M(n)?new T(null):new T(l(n,e.value.typeArgs[0],t,u));throw new Error(`Unsupported struct input type for argument ${t}, type '${e.toString()}'`)}throw new Error(`Type mismatch for argument ${t}, type '${e.toString()}'`)}function m(n,e,t){if(n.isBool()){if(O(e))return;i("Bool",t)}if(n.isAddress()){if(h(e))return;i("AccountAddress",t)}if(n.isU8()){if(V(e))return;i("U8",t)}if(n.isU16()){if(G(e))return;i("U16",t)}if(n.isU32()){if(j(e))return;i("U32",t)}if(n.isU64()){if(k(e))return;i("U64",t)}if(n.isU128()){if(z(e))return;i("U128",t)}if(n.isU256()){if(D(e))return;i("U256",t)}if(n.isVector()){if(e instanceof o){e.values.length>0&&m(n.value,e.values[0],t);return}i("MoveVector",t)}if(n instanceof p){if(n.isString()){if(_(e))return;i("MoveString",t)}if(n.isObject()){if(h(e))return;i("AccountAddress",t)}if(n.isOption()){if(e instanceof T){e.value!==void 0&&m(n.value.typeArgs[0],e.value,t);return}i("MoveOption",t)}}throw new Error(`Type mismatch for argument ${t}, expected '${n.toString()}'`)}export{Z as a,P as b,N as c,a as d,nn as e,l as f};
2
- //# sourceMappingURL=chunk-J2IIPYZG.mjs.map
1
+ import{c as A}from"./chunk-PFFAQZHT.mjs";import{a as x,b as c,c as w,d as g,e as M,f as C,g as O,h,i as _,k as V,l as G,m as j,n as k,o as z,p as D,r as i,s as L}from"./chunk-7H3HRFVM.mjs";import{c as I}from"./chunk-H6EEHYWO.mjs";import{n as p}from"./chunk-3VGX3TXH.mjs";import{b as U}from"./chunk-T23OVRNF.mjs";import{a as o,b as S,c as T}from"./chunk-EB7AI4B4.mjs";import{a as d,b as E,c as B,d as v,e as $,f as b,g as F}from"./chunk-6RBUXB5I.mjs";var R=new TextEncoder;function Z(n){return n?.map(e=>c(e)?A(e):e)??[]}async function P(n,e,t,u){let r=await I({aptosConfig:u,accountAddress:n,moduleName:e});if(r.abi)return r.abi.exposed_functions.find(f=>f.name===t)}async function N(n,e,t,u){let r=await P(n,e,t,u);if(!r)throw new Error(`Could not find entry function ABI for '${n}::${e}::${t}'`);if(!r.is_entry)throw new Error(`'${n}::${e}::${t}' is not an entry function`);let f=L(r),y=[];for(let s=f;s<r.params.length;s+=1)y.push(A(r.params[s],{allowGenerics:!0}));return{signers:f,typeParameters:r.generic_type_params,parameters:y}}async function a(n,e,t,u){let r=await P(n,e,t,u);if(!r)throw new Error(`Could not find view function ABI for '${n}::${e}::${t}'`);if(!r.is_view)throw new Error(`'${n}::${e}::${t}' is not an view function`);let f=[];for(let s=0;s<r.params.length;s+=1)f.push(A(r.params[s],{allowGenerics:!0}));let y=[];for(let s=0;s<r.return.length;s+=1)y.push(A(r.return[s],{allowGenerics:!0}));return{typeParameters:r.generic_type_params,parameters:f,returnTypes:y}}function nn(n,e,t,u,r){if(u>=e.parameters.length)throw new Error(`Too many arguments for '${n}', expected ${e.parameters.length}`);let f=e.parameters[u];return l(t,f,u,r)}function l(n,e,t,u){return C(n)?(m(e,n,t),n):X(n,e,t,u)}function X(n,e,t,u){if(e.isBool()){if(x(n))return new d(n);i("boolean",t)}if(e.isAddress()){if(c(n))return U.fromString(n);i("string | AccountAddress",t)}if(e.isU8()){if(w(n))return new E(n);i("number",t)}if(e.isU16()){if(w(n))return new B(n);i("number",t)}if(e.isU32()){if(w(n))return new v(n);i("number",t)}if(e.isU64()){if(g(n))return new $(BigInt(n));i("bigint | number | string",t)}if(e.isU128()){if(g(n))return new b(BigInt(n));i("bigint | number | string",t)}if(e.isU256()){if(g(n))return new F(BigInt(n));i("bigint | number | string",t)}if(e.isGeneric()){let r=e.value;if(r<0||r>=u.length)throw new Error(`Generic argument ${e.toString()} is invalid for argument ${t}`);return l(n,u[r],t,u)}if(e.isVector()){if(e.value.isU8()){if(c(n))return o.U8(R.encode(n));if(n instanceof Uint8Array)return o.U8(n);if(n instanceof ArrayBuffer)return o.U8(new Uint8Array(n))}if(Array.isArray(n))return new o(n.map(r=>l(r,e.value,t,u)));throw new Error(`Type mismatch for argument ${t}, type '${e.toString()}'`)}if(e.isStruct()){if(e.isString()){if(c(n))return new S(n);i("string",t)}if(e.isObject()){if(c(n))return U.fromString(n);i("string | AccountAddress",t)}if(e.isOption())return M(n)?new T(null):new T(l(n,e.value.typeArgs[0],t,u));throw new Error(`Unsupported struct input type for argument ${t}, type '${e.toString()}'`)}throw new Error(`Type mismatch for argument ${t}, type '${e.toString()}'`)}function m(n,e,t){if(n.isBool()){if(O(e))return;i("Bool",t)}if(n.isAddress()){if(h(e))return;i("AccountAddress",t)}if(n.isU8()){if(V(e))return;i("U8",t)}if(n.isU16()){if(G(e))return;i("U16",t)}if(n.isU32()){if(j(e))return;i("U32",t)}if(n.isU64()){if(k(e))return;i("U64",t)}if(n.isU128()){if(z(e))return;i("U128",t)}if(n.isU256()){if(D(e))return;i("U256",t)}if(n.isVector()){if(e instanceof o){e.values.length>0&&m(n.value,e.values[0],t);return}i("MoveVector",t)}if(n instanceof p){if(n.isString()){if(_(e))return;i("MoveString",t)}if(n.isObject()){if(h(e))return;i("AccountAddress",t)}if(n.isOption()){if(e instanceof T){e.value!==void 0&&m(n.value.typeArgs[0],e.value,t);return}i("MoveOption",t)}}throw new Error(`Type mismatch for argument ${t}, expected '${n.toString()}'`)}export{Z as a,P as b,N as c,a as d,nn as e,l as f};
2
+ //# sourceMappingURL=chunk-D2ALJ5UZ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as r}from"./chunk-RPXN7HGR.mjs";import{f as t,i as o}from"./chunk-3VGX3TXH.mjs";import{e as n}from"./chunk-YE5B2S5L.mjs";var u={typeParameters:[{constraints:[]}],parameters:[new o,new t]};async function y(e){let{aptosConfig:i,sender:s,recipient:c,amount:p,coinType:a,options:m}=e;return r({aptosConfig:i,sender:s,data:{function:"0x1::aptos_account::transfer_coins",typeArguments:[a??n],functionArguments:[c,p],abi:u},options:m})}export{y as a};
2
- //# sourceMappingURL=chunk-LDMEIVL6.mjs.map
1
+ import{a as r}from"./chunk-T75EO4EY.mjs";import{f as t,i as o}from"./chunk-3VGX3TXH.mjs";import{e as n}from"./chunk-YE5B2S5L.mjs";var u={typeParameters:[{constraints:[]}],parameters:[new o,new t]};async function y(e){let{aptosConfig:i,sender:s,recipient:c,amount:p,coinType:a,options:m}=e;return r({aptosConfig:i,sender:s,data:{function:"0x1::aptos_account::transfer_coins",typeArguments:[a??n],functionArguments:[c,p],abi:u},options:m})}export{y as a};
2
+ //# sourceMappingURL=chunk-D63W6JYG.mjs.map
@@ -1,2 +1,2 @@
1
- import{f as a}from"./chunk-APEBWN6Q.mjs";import{q as d}from"./chunk-S4SEFF4K.mjs";import{b as p}from"./chunk-T23OVRNF.mjs";var g=300,y=o=>{if(o&&o.length>g)throw new Error(`Event type length exceeds the maximum length of ${g}`)};async function f(o){let{aptosConfig:n,eventType:e,options:t}=o,r={where:{account_address:{_eq:"0x0000000000000000000000000000000000000000000000000000000000000000"},creation_number:{_eq:"0"},sequence_number:{_eq:"0"},indexed_type:{_eq:e}},pagination:t,orderBy:t?.orderBy};return c({aptosConfig:n,options:r})}async function h(o){let{accountAddress:n,aptosConfig:e,creationNumber:t,options:s}=o,i={where:{account_address:{_eq:p.from(n).toStringLong()},creation_number:{_eq:t}},pagination:s,orderBy:s?.orderBy};return c({aptosConfig:e,options:i})}async function _(o){let{accountAddress:n,aptosConfig:e,eventType:t,options:s}=o,i={where:{account_address:{_eq:p.from(n).toStringLong()},indexed_type:{_eq:t}},pagination:s,orderBy:s?.orderBy};return c({aptosConfig:e,options:i})}async function c(o){let{aptosConfig:n,options:e}=o;y(e?.where?.indexed_type?._eq);let t={query:d,variables:{where_condition:e?.where,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await a({aptosConfig:n,query:t,originMethod:"getEvents"})).events}export{f as a,h as b,_ as c,c as d};
2
- //# sourceMappingURL=chunk-KNHI66FK.mjs.map
1
+ import{f as a}from"./chunk-YHEF3FJ4.mjs";import{q as d}from"./chunk-S4SEFF4K.mjs";import{b as p}from"./chunk-T23OVRNF.mjs";var g=300,y=o=>{if(o&&o.length>g)throw new Error(`Event type length exceeds the maximum length of ${g}`)};async function f(o){let{aptosConfig:n,eventType:e,options:t}=o,r={where:{account_address:{_eq:"0x0000000000000000000000000000000000000000000000000000000000000000"},creation_number:{_eq:"0"},sequence_number:{_eq:"0"},indexed_type:{_eq:e}},pagination:t,orderBy:t?.orderBy};return c({aptosConfig:n,options:r})}async function h(o){let{accountAddress:n,aptosConfig:e,creationNumber:t,options:s}=o,i={where:{account_address:{_eq:p.from(n).toStringLong()},creation_number:{_eq:t}},pagination:s,orderBy:s?.orderBy};return c({aptosConfig:e,options:i})}async function _(o){let{accountAddress:n,aptosConfig:e,eventType:t,options:s}=o,i={where:{account_address:{_eq:p.from(n).toStringLong()},indexed_type:{_eq:t}},pagination:s,orderBy:s?.orderBy};return c({aptosConfig:e,options:i})}async function c(o){let{aptosConfig:n,options:e}=o;y(e?.where?.indexed_type?._eq);let t={query:d,variables:{where_condition:e?.where,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await a({aptosConfig:n,query:t,originMethod:"getEvents"})).events}export{f as a,h as b,_ as c,c as d};
2
+ //# sourceMappingURL=chunk-DLZXY6VZ.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as d}from"./chunk-WTVN3XGK.mjs";import{b as u,c as h,e as m}from"./chunk-FLYEALDB.mjs";import{a as p,b as y}from"./chunk-R7BAM2G6.mjs";import{b as s}from"./chunk-7JNPSNL6.mjs";import{a as o}from"./chunk-6IFMQ5AS.mjs";import{a as l}from"./chunk-TVRJ3M7B.mjs";import{b as c}from"./chunk-AOCNYMMX.mjs";import{randomBytes as g}from"@noble/hashes/utils";var b=class i extends l{constructor(e){super();let{privateKey:r,expiryDateSecs:n,blinder:a}=e;this.privateKey=r,this.publicKey=new p(r.publicKey()),this.expiryDateSecs=n||BigInt(f(x()+d)),this.blinder=a!==void 0?c.fromHexInput(a).toUint8Array():S(),this.nonce=this.generateNonce()}getPublicKey(){return this.publicKey}isExpired(){return Math.floor(Date.now()/1e3)>this.expiryDateSecs}serialize(e){e.serializeU32AsUleb128(this.publicKey.variant),e.serializeBytes(this.privateKey.toUint8Array()),e.serializeU64(this.expiryDateSecs),e.serializeFixedBytes(this.blinder)}static deserialize(e){let r=e.deserializeUleb128AsU32(),n;switch(r){case 0:n=s.deserialize(e);break;default:throw new Error(`Unknown variant index for EphemeralPublicKey: ${r}`)}let a=e.deserializeU64(),K=e.deserializeFixedBytes(31);return new i({privateKey:n,expiryDateSecs:a,blinder:K})}static fromBytes(e){return i.deserialize(new o(e))}static generate(e){let r;switch(e?.scheme){case 0:default:r=s.generate()}return new i({privateKey:r})}generateNonce(){let e=u(this.publicKey.bcsToBytes(),93);return e.push(BigInt(this.expiryDateSecs)),e.push(h(this.blinder)),m(e).toString()}sign(e){if(this.isExpired())throw new Error("EphemeralKeyPair has expired");return new y(this.privateKey.sign(e))}};function S(){return g(31)}function x(){return Math.floor(new Date().getTime()/1e3)}function f(i){let t=new Date(i*1e3);return t.setMinutes(0),t.setSeconds(0),t.setMilliseconds(0),Math.floor(t.getTime()/1e3)}export{b as a};
2
+ //# sourceMappingURL=chunk-DMKFITUM.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/account/EphemeralKeyPair.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\nimport { randomBytes } from \"@noble/hashes/utils\";\n\nimport {\n EPK_HORIZON_SECS,\n Ed25519PrivateKey,\n EphemeralPublicKey,\n EphemeralSignature,\n PrivateKey,\n} from \"../core/crypto\";\nimport { Hex } from \"../core/hex\";\nimport { bytesToBigIntLE, padAndPackBytesWithLen, poseidonHash } from \"../core/crypto/poseidon\";\nimport { EphemeralPublicKeyVariant, HexInput, SigningSchemeInput } from \"../types\";\nimport { Deserializer, Serializable, Serializer } from \"../bcs\";\n\nexport class EphemeralKeyPair extends Serializable {\n readonly blinder: Uint8Array;\n\n readonly expiryDateSecs: bigint | number;\n\n readonly nonce: string;\n\n private privateKey: PrivateKey;\n\n private publicKey: EphemeralPublicKey;\n\n constructor(args: { privateKey: PrivateKey; expiryDateSecs?: bigint | number; blinder?: HexInput }) {\n super();\n const { privateKey, expiryDateSecs, blinder } = args;\n this.privateKey = privateKey;\n this.publicKey = new EphemeralPublicKey(privateKey.publicKey());\n this.expiryDateSecs = expiryDateSecs || BigInt(floorToWholeHour(currentTimeInSeconds() + EPK_HORIZON_SECS));\n this.blinder = blinder !== undefined ? Hex.fromHexInput(blinder).toUint8Array() : generateBlinder();\n this.nonce = this.generateNonce();\n }\n\n getPublicKey(): EphemeralPublicKey {\n return this.publicKey;\n }\n\n isExpired(): boolean {\n const currentTimeSecs: number = Math.floor(Date.now() / 1000);\n return currentTimeSecs > this.expiryDateSecs;\n }\n\n serialize(serializer: Serializer): void {\n serializer.serializeU32AsUleb128(this.publicKey.variant);\n serializer.serializeBytes(this.privateKey.toUint8Array());\n serializer.serializeU64(this.expiryDateSecs);\n serializer.serializeFixedBytes(this.blinder);\n }\n\n static deserialize(deserializer: Deserializer): EphemeralKeyPair {\n const variantIndex = deserializer.deserializeUleb128AsU32();\n let privateKey: PrivateKey;\n switch (variantIndex) {\n case EphemeralPublicKeyVariant.Ed25519:\n privateKey = Ed25519PrivateKey.deserialize(deserializer);\n break;\n default:\n throw new Error(`Unknown variant index for EphemeralPublicKey: ${variantIndex}`);\n }\n const expiryDateSecs = deserializer.deserializeU64();\n const blinder = deserializer.deserializeFixedBytes(31);\n return new EphemeralKeyPair({ privateKey, expiryDateSecs, blinder });\n }\n\n static fromBytes(bytes: Uint8Array): EphemeralKeyPair {\n return EphemeralKeyPair.deserialize(new Deserializer(bytes));\n }\n\n static generate(args?: { scheme: SigningSchemeInput }): EphemeralKeyPair {\n let privateKey: PrivateKey;\n\n switch (args?.scheme) {\n case SigningSchemeInput.Ed25519:\n default:\n privateKey = Ed25519PrivateKey.generate();\n }\n\n return new EphemeralKeyPair({ privateKey });\n }\n\n generateNonce(): string {\n const fields = padAndPackBytesWithLen(this.publicKey.bcsToBytes(), 93);\n fields.push(BigInt(this.expiryDateSecs));\n fields.push(bytesToBigIntLE(this.blinder));\n const nonceHash = poseidonHash(fields);\n return nonceHash.toString();\n }\n\n /**\n * Sign the given message with the private key.\n * *\n * @param data in HexInput format\n * @returns EphemeralSignature\n */\n sign(data: HexInput): EphemeralSignature {\n if (this.isExpired()) {\n throw new Error(\"EphemeralKeyPair has expired\")\n }\n return new EphemeralSignature(this.privateKey.sign(data));\n }\n}\n\nfunction generateBlinder(): Uint8Array {\n return randomBytes(31);\n}\n\nfunction currentTimeInSeconds(): number {\n return Math.floor(new Date().getTime() / 1000);\n}\n\nfunction floorToWholeHour(timestampInSeconds: number): number {\n const date = new Date(timestampInSeconds * 1000);\n // Reset minutes and seconds to zero\n date.setMinutes(0);\n date.setSeconds(0);\n date.setMilliseconds(0);\n return Math.floor(date.getTime() / 1000);\n}\n"],"mappings":"oTAGA,OAAS,eAAAA,MAAmB,sBAcrB,IAAMC,EAAN,MAAMC,UAAyBC,CAAa,CAWjD,YAAYC,EAAwF,CAClG,MAAM,EACN,GAAM,CAAE,WAAAC,EAAY,eAAAC,EAAgB,QAAAC,CAAQ,EAAIH,EAChD,KAAK,WAAaC,EAClB,KAAK,UAAY,IAAIG,EAAmBH,EAAW,UAAU,CAAC,EAC9D,KAAK,eAAiBC,GAAkB,OAAOG,EAAiBC,EAAqB,EAAIC,CAAgB,CAAC,EAC1G,KAAK,QAAUJ,IAAY,OAAYK,EAAI,aAAaL,CAAO,EAAE,aAAa,EAAIM,EAAgB,EAClG,KAAK,MAAQ,KAAK,cAAc,CAClC,CAEA,cAAmC,CACjC,OAAO,KAAK,SACd,CAEA,WAAqB,CAEnB,OADgC,KAAK,MAAM,KAAK,IAAI,EAAI,GAAI,EACnC,KAAK,cAChC,CAEA,UAAUC,EAA8B,CACtCA,EAAW,sBAAsB,KAAK,UAAU,OAAO,EACvDA,EAAW,eAAe,KAAK,WAAW,aAAa,CAAC,EACxDA,EAAW,aAAa,KAAK,cAAc,EAC3CA,EAAW,oBAAoB,KAAK,OAAO,CAC7C,CAEA,OAAO,YAAYC,EAA8C,CAC/D,IAAMC,EAAeD,EAAa,wBAAwB,EACtDV,EACJ,OAAQW,EAAc,CACpB,OACEX,EAAaY,EAAkB,YAAYF,CAAY,EACvD,MACF,QACE,MAAM,IAAI,MAAM,iDAAiDC,CAAY,EAAE,CACnF,CACA,IAAMV,EAAiBS,EAAa,eAAe,EAC7CR,EAAUQ,EAAa,sBAAsB,EAAE,EACrD,OAAO,IAAIb,EAAiB,CAAE,WAAAG,EAAY,eAAAC,EAAgB,QAAAC,CAAQ,CAAC,CACrE,CAEA,OAAO,UAAUW,EAAqC,CACpD,OAAOhB,EAAiB,YAAY,IAAIiB,EAAaD,CAAK,CAAC,CAC7D,CAEA,OAAO,SAASd,EAAyD,CACvE,IAAIC,EAEJ,OAAQD,GAAM,OAAQ,CACpB,OACA,QACEC,EAAaY,EAAkB,SAAS,CAC5C,CAEA,OAAO,IAAIf,EAAiB,CAAE,WAAAG,CAAW,CAAC,CAC5C,CAEA,eAAwB,CACtB,IAAMe,EAASC,EAAuB,KAAK,UAAU,WAAW,EAAG,EAAE,EACrE,OAAAD,EAAO,KAAK,OAAO,KAAK,cAAc,CAAC,EACvCA,EAAO,KAAKE,EAAgB,KAAK,OAAO,CAAC,EACvBC,EAAaH,CAAM,EACpB,SAAS,CAC5B,CAQA,KAAKI,EAAoC,CACvC,GAAI,KAAK,UAAU,EACjB,MAAM,IAAI,MAAM,8BAA8B,EAEhD,OAAO,IAAIC,EAAmB,KAAK,WAAW,KAAKD,CAAI,CAAC,CAC1D,CACF,EAEA,SAASX,GAA8B,CACrC,OAAOa,EAAY,EAAE,CACvB,CAEA,SAAShB,GAA+B,CACtC,OAAO,KAAK,MAAM,IAAI,KAAK,EAAE,QAAQ,EAAI,GAAI,CAC/C,CAEA,SAASD,EAAiBkB,EAAoC,CAC5D,IAAMC,EAAO,IAAI,KAAKD,EAAqB,GAAI,EAE/C,OAAAC,EAAK,WAAW,CAAC,EACjBA,EAAK,WAAW,CAAC,EACjBA,EAAK,gBAAgB,CAAC,EACf,KAAK,MAAMA,EAAK,QAAQ,EAAI,GAAI,CACzC","names":["randomBytes","EphemeralKeyPair","_EphemeralKeyPair","Serializable","args","privateKey","expiryDateSecs","blinder","EphemeralPublicKey","floorToWholeHour","currentTimeInSeconds","EPK_HORIZON_SECS","Hex","generateBlinder","serializer","deserializer","variantIndex","Ed25519PrivateKey","bytes","Deserializer","fields","padAndPackBytesWithLen","bytesToBigIntLE","poseidonHash","data","EphemeralSignature","randomBytes","timestampInSeconds","date"]}
@@ -1,2 +1,2 @@
1
- import{a}from"./chunk-6FBKUTGF.mjs";import{a as R}from"./chunk-YGHLXEB4.mjs";var c={400:"Bad Request",401:"Unauthorized",403:"Forbidden",404:"Not Found",429:"Too Many Requests",500:"Internal Server Error",502:"Bad Gateway",503:"Service Unavailable"};async function l(s,i){let{url:u,method:n,body:d,contentType:p,params:t,overrides:e,originMethod:o}=s,r={...e?.HEADERS,"x-aptos-client":`aptos-typescript-sdk/${R}`,"content-type":p??"application/json","x-aptos-typescript-sdk-origin-method":o};return e?.AUTH_TOKEN&&(r.Authorization=`Bearer ${e?.AUTH_TOKEN}`),e?.API_KEY&&(r.Authorization=`Bearer ${e?.API_KEY}`),i.provider({url:u,method:n,body:d,params:t,headers:r,overrides:e})}async function N(s,i,u){let{url:n,path:d}=s,p=d?`${n}/${d}`:n,t=await l({...s,url:p},i.client),e={status:t.status,statusText:t.statusText,data:t.data,headers:t.headers,config:t.config,request:t.request,url:p};if(e.status===401)throw new a(s,e,`Error: ${e.data}`);if(u==="Indexer"){let r=e.data;if(r.errors)throw new a(s,e,`Indexer error: ${r.errors[0].message}`??`Indexer unhandled Error ${t.status} : ${t.statusText}`);e.data=r.data}if(e.status>=200&&e.status<300)return e;if(e.status>=500)throw new a(s,e,`${t.data}`);if(i.isPepperServiceRequest(n))throw new a(s,e,`${t.data}`);let o;throw e&&e.data&&"message"in e.data&&"error_code"in e.data?o=JSON.stringify(e.data):e.status in c?o=c[e.status]:o=`Unhandled Error ${e.status} : ${e.statusText}`,new a(s,e,`${u} error: ${o}`)}export{l as a,N as b};
2
- //# sourceMappingURL=chunk-WO2KROQ6.mjs.map
1
+ import{a}from"./chunk-6FBKUTGF.mjs";import{a as R}from"./chunk-WNXSPLZO.mjs";var c={400:"Bad Request",401:"Unauthorized",403:"Forbidden",404:"Not Found",429:"Too Many Requests",500:"Internal Server Error",502:"Bad Gateway",503:"Service Unavailable"};async function l(s,i){let{url:u,method:n,body:d,contentType:p,params:t,overrides:e,originMethod:o}=s,r={...e?.HEADERS,"x-aptos-client":`aptos-typescript-sdk/${R}`,"content-type":p??"application/json","x-aptos-typescript-sdk-origin-method":o};return e?.AUTH_TOKEN&&(r.Authorization=`Bearer ${e?.AUTH_TOKEN}`),e?.API_KEY&&(r.Authorization=`Bearer ${e?.API_KEY}`),i.provider({url:u,method:n,body:d,params:t,headers:r,overrides:e})}async function N(s,i,u){let{url:n,path:d}=s,p=d?`${n}/${d}`:n,t=await l({...s,url:p},i.client),e={status:t.status,statusText:t.statusText,data:t.data,headers:t.headers,config:t.config,request:t.request,url:p};if(e.status===401)throw new a(s,e,`Error: ${e.data}`);if(u==="Indexer"){let r=e.data;if(r.errors)throw new a(s,e,`Indexer error: ${r.errors[0].message}`??`Indexer unhandled Error ${t.status} : ${t.statusText}`);e.data=r.data}if(e.status>=200&&e.status<300)return e;if(e.status>=500)throw new a(s,e,`${t.data}`);if(i.isPepperServiceRequest(n))throw new a(s,e,`${t.data}`);let o;throw e&&e.data&&"message"in e.data&&"error_code"in e.data?o=JSON.stringify(e.data):e.status in c?o=c[e.status]:o=`Unhandled Error ${e.status} : ${e.statusText}`,new a(s,e,`${u} error: ${o}`)}export{l as a,N as b};
2
+ //# sourceMappingURL=chunk-EA5KB322.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as d}from"./chunk-RPXN7HGR.mjs";import{f as M}from"./chunk-J2IIPYZG.mjs";import{c as V}from"./chunk-PFFAQZHT.mjs";import{f as b}from"./chunk-APEBWN6Q.mjs";import{n as x,w as E,x as G,y as q}from"./chunk-S4SEFF4K.mjs";import{b as w,f as v,i as h,l as A,m as f,n as s,q as p,s as g}from"./chunk-3VGX3TXH.mjs";import{b as u}from"./chunk-T23OVRNF.mjs";import{a as I,b as c}from"./chunk-EB7AI4B4.mjs";import{a as T,e as S}from"./chunk-6RBUXB5I.mjs";import{d as O}from"./chunk-56CNRT2K.mjs";var C={BOOLEAN:"bool",U8:"u8",U16:"u16",U32:"u32",U64:"u64",U128:"u128",U256:"u256",ADDRESS:"address",STRING:"0x1::string::String",ARRAY:"vector<u8>"},m="0x4::token::Token";async function It(t){let{aptosConfig:o,digitalAssetAddress:n}=t,e={token_data_id:{_eq:u.from(n).toStringLong()}};return(await b({aptosConfig:o,query:{query:q,variables:{where_condition:e}},originMethod:"getDigitalAssetData"})).current_token_datas_v2[0]}async function _t(t){let{aptosConfig:o,digitalAssetAddress:n}=t,e={token_data_id:{_eq:u.from(n).toStringLong()},amount:{_gt:0}};return(await b({aptosConfig:o,query:{query:G,variables:{where_condition:e}},originMethod:"getCurrentDigitalAssetOwnership"})).current_token_ownerships_v2[0]}async function Pt(t){let{aptosConfig:o,ownerAddress:n,options:e}=t,r={owner_address:{_eq:u.from(n).toStringLong()},amount:{_gt:0}},i={query:G,variables:{where_condition:r,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await b({aptosConfig:o,query:i,originMethod:"getOwnedDigitalAssets"})).current_token_ownerships_v2}async function kt(t){let{aptosConfig:o,digitalAssetAddress:n,options:e}=t,r={token_data_id:{_eq:u.from(n).toStringLong()}},i={query:E,variables:{where_condition:r,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await b({aptosConfig:o,query:i,originMethod:"getDigitalAssetActivity"})).token_activities_v2}var Q={typeParameters:[],parameters:[new s(p()),new v,new s(p()),new s(p()),new w,new w,new w,new w,new w,new w,new w,new w,new w,new v,new v]};async function Dt(t){let{aptosConfig:o,options:n,creator:e}=t;return d({aptosConfig:o,sender:e.accountAddress,data:{function:"0x4::aptos_token::create_collection",functionArguments:[new c(t.description),new S(t.maxSupply??O),new c(t.name),new c(t.uri),new T(t.mutableDescription??!0),new T(t.mutableRoyalty??!0),new T(t.mutableURI??!0),new T(t.mutableTokenDescription??!0),new T(t.mutableTokenName??!0),new T(t.mutableTokenProperties??!0),new T(t.mutableTokenURI??!0),new T(t.tokensBurnableByCreator??!0),new T(t.tokensFreezableByCreator??!0),new S(t.royaltyNumerator??0),new S(t.royaltyDenominator??1)],abi:Q},options:n})}async function U(t){let{aptosConfig:o,creatorAddress:n,collectionName:e,options:r}=t,i=u.from(n),a={collection_name:{_eq:e},creator_address:{_eq:i.toStringLong()}};return r?.tokenStandard&&(a.token_standard={_eq:r?.tokenStandard??"v2"}),(await b({aptosConfig:o,query:{query:x,variables:{where_condition:a}},originMethod:"getCollectionData"})).current_collections_v2[0]}async function St(t){let{aptosConfig:o,collectionId:n}=t,r={collection_id:{_eq:u.from(n).toStringLong()}};return(await b({aptosConfig:o,query:{query:x,variables:{where_condition:r}},originMethod:"getCollectionData"})).current_collections_v2[0]}async function vt(t){return(await U(t)).collection_id}var F={typeParameters:[],parameters:[new s(p()),new s(p()),new s(p()),new s(p()),new f(new s(p())),new f(new s(p())),new f(f.u8())]};async function ht(t){let{aptosConfig:o,options:n,creator:e,collection:r,description:i,name:a,uri:l,propertyKeys:y,propertyTypes:P,propertyValues:_}=t,k=P?.map(D=>C[D]);return d({aptosConfig:o,sender:e.accountAddress,data:{function:"0x4::aptos_token::mint",functionArguments:[new c(r),new c(i),new c(a),new c(l),I.MoveString(y??[]),I.MoveString(k??[]),R(_??[],k??[])],abi:F},options:n})}var N={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new h]};async function xt(t){let{aptosConfig:o,sender:n,digitalAssetAddress:e,recipient:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x1::object::transfer",typeArguments:[i??m],functionArguments:[u.from(e),u.from(r)],abi:N},options:a})}var Y={typeParameters:[],parameters:[new s(p()),new s(p()),new s(p()),new s(p()),new f(new s(p())),new f(new s(p())),new f(f.u8()),new h]};async function Gt(t){let{aptosConfig:o,account:n,collection:e,description:r,name:i,uri:a,recipient:l,propertyKeys:y,propertyTypes:P,propertyValues:_,options:k}=t;if(y?.length!==_?.length)throw new Error("Property keys and property values counts do not match");if(P?.length!==_?.length)throw new Error("Property types and property values counts do not match");let D=P?.map(K=>C[K]);return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::mint_soul_bound",functionArguments:[e,r,i,a,I.MoveString(y??[]),I.MoveString(D??[]),R(_??[],D??[]),l],abi:Y},options:k})}var z={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0)))]};async function Bt(t){let{aptosConfig:o,creator:n,digitalAssetAddress:e,digitalAssetType:r,options:i}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::burn",typeArguments:[r??m],functionArguments:[u.from(e)],abi:z},options:i})}var L={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0)))]};async function Ot(t){let{aptosConfig:o,creator:n,digitalAssetAddress:e,digitalAssetType:r,options:i}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::freeze_transfer",typeArguments:[r??m],functionArguments:[e],abi:L},options:i})}var j={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0)))]};async function Et(t){let{aptosConfig:o,creator:n,digitalAssetAddress:e,digitalAssetType:r,options:i}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::unfreeze_transfer",typeArguments:[r??m],functionArguments:[e],abi:j},options:i})}var X={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function qt(t){let{aptosConfig:o,creator:n,description:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::set_description",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:X},options:a})}var H={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function Vt(t){let{aptosConfig:o,creator:n,name:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::set_name",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:H},options:a})}var J={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function Mt(t){let{aptosConfig:o,creator:n,uri:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::set_uri",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:J},options:a})}var W={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p()),new s(p()),f.u8()]};async function Rt(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::add_property",typeArguments:[l??m],functionArguments:[u.from(a),new c(e),new c(C[r]),I.U8(B(i,C[r]))],abi:W},options:y})}var Z={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function Kt(t){let{aptosConfig:o,creator:n,propertyKey:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::remove_property",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:Z},options:a})}var $={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p()),new s(p()),f.u8()]};async function Qt(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::update_property",typeArguments:[l??m],functionArguments:[u.from(a),new c(e),new c(C[r]),B(i,C[r])],abi:$},options:y})}var tt={typeParameters:[{constraints:["key"]},{constraints:[]}],parameters:[new s(g(new A(0))),new s(p()),new A(1)]};async function Ut(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::add_typed_property",typeArguments:[l??m,C[r]],functionArguments:[u.from(a),new c(e),i],abi:tt},options:y})}var et={typeParameters:[{constraints:["key"]},{constraints:[]}],parameters:[new s(g(new A(0))),new s(p()),new A(1)]};async function Ft(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::update_typed_property",typeArguments:[l??m,C[r]],functionArguments:[u.from(a),new c(e),i],abi:et},options:y})}function R(t,o){let n=new Array;return o.forEach((e,r)=>{n.push(B(t[r],e))}),n}function B(t,o){let n=V(o);return M(t,n,0,[]).bcsToBytes()}export{It as a,_t as b,Pt as c,kt as d,Dt as e,U as f,St as g,vt as h,ht as i,xt as j,Gt as k,Bt as l,Ot as m,Et as n,qt as o,Vt as p,Mt as q,Rt as r,Kt as s,Qt as t,Ut as u,Ft as v};
2
- //# sourceMappingURL=chunk-JEUAQVXW.mjs.map
1
+ import{a as d}from"./chunk-T75EO4EY.mjs";import{f as M}from"./chunk-D2ALJ5UZ.mjs";import{c as V}from"./chunk-PFFAQZHT.mjs";import{f as b}from"./chunk-YHEF3FJ4.mjs";import{n as x,w as E,x as G,y as q}from"./chunk-S4SEFF4K.mjs";import{b as w,f as v,i as h,l as A,m as f,n as s,q as p,s as g}from"./chunk-3VGX3TXH.mjs";import{b as u}from"./chunk-T23OVRNF.mjs";import{a as I,b as c}from"./chunk-EB7AI4B4.mjs";import{a as T,e as S}from"./chunk-6RBUXB5I.mjs";import{d as O}from"./chunk-56CNRT2K.mjs";var C={BOOLEAN:"bool",U8:"u8",U16:"u16",U32:"u32",U64:"u64",U128:"u128",U256:"u256",ADDRESS:"address",STRING:"0x1::string::String",ARRAY:"vector<u8>"},m="0x4::token::Token";async function It(t){let{aptosConfig:o,digitalAssetAddress:n}=t,e={token_data_id:{_eq:u.from(n).toStringLong()}};return(await b({aptosConfig:o,query:{query:q,variables:{where_condition:e}},originMethod:"getDigitalAssetData"})).current_token_datas_v2[0]}async function _t(t){let{aptosConfig:o,digitalAssetAddress:n}=t,e={token_data_id:{_eq:u.from(n).toStringLong()},amount:{_gt:0}};return(await b({aptosConfig:o,query:{query:G,variables:{where_condition:e}},originMethod:"getCurrentDigitalAssetOwnership"})).current_token_ownerships_v2[0]}async function Pt(t){let{aptosConfig:o,ownerAddress:n,options:e}=t,r={owner_address:{_eq:u.from(n).toStringLong()},amount:{_gt:0}},i={query:G,variables:{where_condition:r,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await b({aptosConfig:o,query:i,originMethod:"getOwnedDigitalAssets"})).current_token_ownerships_v2}async function kt(t){let{aptosConfig:o,digitalAssetAddress:n,options:e}=t,r={token_data_id:{_eq:u.from(n).toStringLong()}},i={query:E,variables:{where_condition:r,offset:e?.offset,limit:e?.limit,order_by:e?.orderBy}};return(await b({aptosConfig:o,query:i,originMethod:"getDigitalAssetActivity"})).token_activities_v2}var Q={typeParameters:[],parameters:[new s(p()),new v,new s(p()),new s(p()),new w,new w,new w,new w,new w,new w,new w,new w,new w,new v,new v]};async function Dt(t){let{aptosConfig:o,options:n,creator:e}=t;return d({aptosConfig:o,sender:e.accountAddress,data:{function:"0x4::aptos_token::create_collection",functionArguments:[new c(t.description),new S(t.maxSupply??O),new c(t.name),new c(t.uri),new T(t.mutableDescription??!0),new T(t.mutableRoyalty??!0),new T(t.mutableURI??!0),new T(t.mutableTokenDescription??!0),new T(t.mutableTokenName??!0),new T(t.mutableTokenProperties??!0),new T(t.mutableTokenURI??!0),new T(t.tokensBurnableByCreator??!0),new T(t.tokensFreezableByCreator??!0),new S(t.royaltyNumerator??0),new S(t.royaltyDenominator??1)],abi:Q},options:n})}async function U(t){let{aptosConfig:o,creatorAddress:n,collectionName:e,options:r}=t,i=u.from(n),a={collection_name:{_eq:e},creator_address:{_eq:i.toStringLong()}};return r?.tokenStandard&&(a.token_standard={_eq:r?.tokenStandard??"v2"}),(await b({aptosConfig:o,query:{query:x,variables:{where_condition:a}},originMethod:"getCollectionData"})).current_collections_v2[0]}async function St(t){let{aptosConfig:o,collectionId:n}=t,r={collection_id:{_eq:u.from(n).toStringLong()}};return(await b({aptosConfig:o,query:{query:x,variables:{where_condition:r}},originMethod:"getCollectionData"})).current_collections_v2[0]}async function vt(t){return(await U(t)).collection_id}var F={typeParameters:[],parameters:[new s(p()),new s(p()),new s(p()),new s(p()),new f(new s(p())),new f(new s(p())),new f(f.u8())]};async function ht(t){let{aptosConfig:o,options:n,creator:e,collection:r,description:i,name:a,uri:l,propertyKeys:y,propertyTypes:P,propertyValues:_}=t,k=P?.map(D=>C[D]);return d({aptosConfig:o,sender:e.accountAddress,data:{function:"0x4::aptos_token::mint",functionArguments:[new c(r),new c(i),new c(a),new c(l),I.MoveString(y??[]),I.MoveString(k??[]),R(_??[],k??[])],abi:F},options:n})}var N={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new h]};async function xt(t){let{aptosConfig:o,sender:n,digitalAssetAddress:e,recipient:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x1::object::transfer",typeArguments:[i??m],functionArguments:[u.from(e),u.from(r)],abi:N},options:a})}var Y={typeParameters:[],parameters:[new s(p()),new s(p()),new s(p()),new s(p()),new f(new s(p())),new f(new s(p())),new f(f.u8()),new h]};async function Gt(t){let{aptosConfig:o,account:n,collection:e,description:r,name:i,uri:a,recipient:l,propertyKeys:y,propertyTypes:P,propertyValues:_,options:k}=t;if(y?.length!==_?.length)throw new Error("Property keys and property values counts do not match");if(P?.length!==_?.length)throw new Error("Property types and property values counts do not match");let D=P?.map(K=>C[K]);return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::mint_soul_bound",functionArguments:[e,r,i,a,I.MoveString(y??[]),I.MoveString(D??[]),R(_??[],D??[]),l],abi:Y},options:k})}var z={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0)))]};async function Bt(t){let{aptosConfig:o,creator:n,digitalAssetAddress:e,digitalAssetType:r,options:i}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::burn",typeArguments:[r??m],functionArguments:[u.from(e)],abi:z},options:i})}var L={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0)))]};async function Ot(t){let{aptosConfig:o,creator:n,digitalAssetAddress:e,digitalAssetType:r,options:i}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::freeze_transfer",typeArguments:[r??m],functionArguments:[e],abi:L},options:i})}var j={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0)))]};async function Et(t){let{aptosConfig:o,creator:n,digitalAssetAddress:e,digitalAssetType:r,options:i}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::unfreeze_transfer",typeArguments:[r??m],functionArguments:[e],abi:j},options:i})}var X={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function qt(t){let{aptosConfig:o,creator:n,description:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::set_description",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:X},options:a})}var H={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function Vt(t){let{aptosConfig:o,creator:n,name:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::set_name",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:H},options:a})}var J={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function Mt(t){let{aptosConfig:o,creator:n,uri:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::set_uri",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:J},options:a})}var W={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p()),new s(p()),f.u8()]};async function Rt(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::add_property",typeArguments:[l??m],functionArguments:[u.from(a),new c(e),new c(C[r]),I.U8(B(i,C[r]))],abi:W},options:y})}var Z={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p())]};async function Kt(t){let{aptosConfig:o,creator:n,propertyKey:e,digitalAssetAddress:r,digitalAssetType:i,options:a}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::remove_property",typeArguments:[i??m],functionArguments:[u.from(r),new c(e)],abi:Z},options:a})}var $={typeParameters:[{constraints:["key"]}],parameters:[new s(g(new A(0))),new s(p()),new s(p()),f.u8()]};async function Qt(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::update_property",typeArguments:[l??m],functionArguments:[u.from(a),new c(e),new c(C[r]),B(i,C[r])],abi:$},options:y})}var tt={typeParameters:[{constraints:["key"]},{constraints:[]}],parameters:[new s(g(new A(0))),new s(p()),new A(1)]};async function Ut(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::add_typed_property",typeArguments:[l??m,C[r]],functionArguments:[u.from(a),new c(e),i],abi:tt},options:y})}var et={typeParameters:[{constraints:["key"]},{constraints:[]}],parameters:[new s(g(new A(0))),new s(p()),new A(1)]};async function Ft(t){let{aptosConfig:o,creator:n,propertyKey:e,propertyType:r,propertyValue:i,digitalAssetAddress:a,digitalAssetType:l,options:y}=t;return d({aptosConfig:o,sender:n.accountAddress,data:{function:"0x4::aptos_token::update_typed_property",typeArguments:[l??m,C[r]],functionArguments:[u.from(a),new c(e),i],abi:et},options:y})}function R(t,o){let n=new Array;return o.forEach((e,r)=>{n.push(B(t[r],e))}),n}function B(t,o){let n=V(o);return M(t,n,0,[]).bcsToBytes()}export{It as a,_t as b,Pt as c,kt as d,Dt as e,U as f,St as g,vt as h,ht as i,xt as j,Gt as k,Bt as l,Ot as m,Et as n,qt as o,Vt as p,Mt as q,Rt as r,Kt as s,Qt as t,Ut as u,Ft as v};
2
+ //# sourceMappingURL=chunk-EBCDMINE.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as r,b as i,c as s}from"./chunk-Q7TGZJT4.mjs";import{a as o}from"./chunk-HFLWASAB.mjs";var t=class{constructor(e){this.config=e}async getNumberOfDelegators(e){return await o({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"stake_processor"}),r({aptosConfig:this.config,...e})}async getNumberOfDelegatorsForAllPools(e){return await o({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"stake_processor"}),i({aptosConfig:this.config,...e})}async getDelegatedStakingActivities(e){return await o({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"stake_processor"}),s({aptosConfig:this.config,...e})}};export{t as a};
2
- //# sourceMappingURL=chunk-U72H6EST.mjs.map
1
+ import{a as r,b as i,c as s}from"./chunk-NRJ34FML.mjs";import{a as o}from"./chunk-VFALS4YR.mjs";var t=class{constructor(e){this.config=e}async getNumberOfDelegators(e){return await o({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"stake_processor"}),r({aptosConfig:this.config,...e})}async getNumberOfDelegatorsForAllPools(e){return await o({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"stake_processor"}),i({aptosConfig:this.config,...e})}async getDelegatedStakingActivities(e){return await o({config:this.config,minimumLedgerVersion:e?.minimumLedgerVersion,processorType:"stake_processor"}),s({aptosConfig:this.config,...e})}};export{t as a};
2
+ //# sourceMappingURL=chunk-EI7MOA4R.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as t,b as n,c as i,d as r,e as o}from"./chunk-5VSMDXZ6.mjs";import f from"@aptos-labs/aptos-client";var l=class{constructor(e){this.network=e?.network??"devnet",this.fullnode=e?.fullnode,this.faucet=e?.faucet,this.pepper=e?.pepper,this.prover=e?.prover,this.indexer=e?.indexer,this.client=e?.client??{provider:f},this.clientConfig=e?.clientConfig??{},this.fullnodeConfig=e?.fullnodeConfig??{},this.indexerConfig=e?.indexerConfig??{},this.faucetConfig=e?.faucetConfig??{}}getRequestUrl(e){switch(e){case"Fullnode":if(this.fullnode!==void 0)return this.fullnode;if(this.network==="custom")throw new Error("Please provide a custom full node url");return n[this.network];case"Faucet":if(this.faucet!==void 0)return this.faucet;if(this.network==="custom")throw new Error("Please provide a custom faucet url");return i[this.network];case"Indexer":if(this.indexer!==void 0)return this.indexer;if(this.network==="custom")throw new Error("Please provide a custom indexer url");return t[this.network];case"Pepper":if(this.pepper!==void 0)return this.pepper;if(this.network==="custom")throw new Error("Please provide a custom pepper service url");return r[this.network];case"Prover":if(this.prover!==void 0)return this.prover;if(this.network==="custom")throw new Error("Please provide a custom prover service url");return o[this.network];default:throw Error(`apiType ${e} is not supported`)}}isPepperServiceRequest(e){return r[this.network]===e}isProverServiceRequest(e){return o[this.network]===e}};export{l as a};
2
- //# sourceMappingURL=chunk-6GQAHQGW.mjs.map
1
+ import{a as t,b as n,c as i,d as r,e as o}from"./chunk-5RBI4QWR.mjs";import f from"@aptos-labs/aptos-client";var l=class{constructor(e){this.network=e?.network??"devnet",this.fullnode=e?.fullnode,this.faucet=e?.faucet,this.pepper=e?.pepper,this.prover=e?.prover,this.indexer=e?.indexer,this.client=e?.client??{provider:f},this.clientConfig=e?.clientConfig??{},this.fullnodeConfig=e?.fullnodeConfig??{},this.indexerConfig=e?.indexerConfig??{},this.faucetConfig=e?.faucetConfig??{}}getRequestUrl(e){switch(e){case"Fullnode":if(this.fullnode!==void 0)return this.fullnode;if(this.network==="custom")throw new Error("Please provide a custom full node url");return n[this.network];case"Faucet":if(this.faucet!==void 0)return this.faucet;if(this.network==="custom")throw new Error("Please provide a custom faucet url");return i[this.network];case"Indexer":if(this.indexer!==void 0)return this.indexer;if(this.network==="custom")throw new Error("Please provide a custom indexer url");return t[this.network];case"Pepper":if(this.pepper!==void 0)return this.pepper;if(this.network==="custom")throw new Error("Please provide a custom pepper service url");return r[this.network];case"Prover":if(this.prover!==void 0)return this.prover;if(this.network==="custom")throw new Error("Please provide a custom prover service url");return o[this.network];default:throw Error(`apiType ${e} is not supported`)}}isPepperServiceRequest(e){return r[this.network]===e}isProverServiceRequest(e){return o[this.network]===e}};export{l as a};
2
+ //# sourceMappingURL=chunk-EJPL4WP3.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as o}from"./chunk-LDMEIVL6.mjs";var t=class{constructor(n){this.config=n}async transferCoinTransaction(n){return o({aptosConfig:this.config,...n})}};export{t as a};
2
- //# sourceMappingURL=chunk-QMIEBNTP.mjs.map
1
+ import{a as o}from"./chunk-D63W6JYG.mjs";var t=class{constructor(n){this.config=n}async transferCoinTransaction(n){return o({aptosConfig:this.config,...n})}};export{t as a};
2
+ //# sourceMappingURL=chunk-G4UC736K.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as P}from"./chunk-AH44UPM4.mjs";import{d as v,f as d}from"./chunk-APEBWN6Q.mjs";import{d as C,e as w,f as h,g as k,h as T,j as b,k as O,l as q}from"./chunk-S4SEFF4K.mjs";import{b as p,d as f}from"./chunk-NMVZP3Q2.mjs";import{a as _}from"./chunk-6FBKUTGF.mjs";import{a as A}from"./chunk-DKLA4F3P.mjs";import{a as m}from"./chunk-HURQZGUZ.mjs";import{b as y}from"./chunk-7FNHL6LU.mjs";import{b as l}from"./chunk-CQJ4WN7M.mjs";import{a as g}from"./chunk-7STYQ5ZE.mjs";import{b as c}from"./chunk-T23OVRNF.mjs";async function S(t){let{aptosConfig:n,accountAddress:e}=t,{data:o}=await p({aptosConfig:n,originMethod:"getInfo",path:`accounts/${c.from(e).toString()}`});return o}async function z(t){let{aptosConfig:n,accountAddress:e,options:o}=t;return f({aptosConfig:n,originMethod:"getModules",path:`accounts/${c.from(e).toString()}/modules`,params:{ledger_version:o?.ledgerVersion,start:o?.offset,limit:o?.limit??1e3}})}async function H(t){return t.options?.ledgerVersion!==void 0?G(t):P(async()=>G(t),`module-${t.accountAddress}-${t.moduleName}`,1e3*60*5)()}async function G(t){let{aptosConfig:n,accountAddress:e,moduleName:o,options:s}=t,{data:r}=await p({aptosConfig:n,originMethod:"getModule",path:`accounts/${c.from(e).toString()}/module/${o}`,params:{ledger_version:s?.ledgerVersion}});return r}async function J(t){let{aptosConfig:n,accountAddress:e,options:o}=t;return f({aptosConfig:n,originMethod:"getTransactions",path:`accounts/${c.from(e).toString()}/transactions`,params:{start:o?.offset,limit:o?.limit}})}async function U(t){let{aptosConfig:n,accountAddress:e,options:o}=t;return f({aptosConfig:n,originMethod:"getResources",path:`accounts/${c.from(e).toString()}/resources`,params:{ledger_version:o?.ledgerVersion,start:o?.offset,limit:o?.limit??999}})}async function K(t){let{aptosConfig:n,accountAddress:e,resourceType:o,options:s}=t,{data:r}=await p({aptosConfig:n,originMethod:"getResource",path:`accounts/${c.from(e).toString()}/resource/${o}`,params:{ledger_version:s?.ledgerVersion}});return r.data}async function Q(t){let{aptosConfig:n,authenticationKey:e,options:o}=t,s=await K({aptosConfig:n,accountAddress:"0x1",resourceType:"0x1::account::OriginatingAddress",options:o}),{address_map:{handle:r}}=s,a=c.from(e);try{let i=await v({aptosConfig:n,handle:r,data:{key:a.toString(),key_type:"address",value_type:"address"},options:o});return c.from(i)}catch(i){if(i instanceof _&&i.data.error_code==="table_item_not_found")return a;throw i}}async function X(t){let{aptosConfig:n,accountAddress:e}=t,s={owner_address:{_eq:c.from(e).toStringLong()},amount:{_gt:0}},a=await d({aptosConfig:n,query:{query:O,variables:{where_condition:s}},originMethod:"getAccountTokensCount"});return a.current_token_ownerships_v2_aggregate.aggregate?a.current_token_ownerships_v2_aggregate.aggregate.count:0}async function Y(t){let{aptosConfig:n,accountAddress:e,options:o}=t,r={owner_address:{_eq:c.from(e).toStringLong()},amount:{_gt:0}};o?.tokenStandard&&(r.token_standard={_eq:o?.tokenStandard});let a={query:T,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountOwnedTokens"})).current_token_ownerships_v2}async function Z(t){let{aptosConfig:n,accountAddress:e,collectionAddress:o,options:s}=t,r=c.from(e).toStringLong(),a=c.from(o).toStringLong(),i={owner_address:{_eq:r},current_token_data:{collection_id:{_eq:a}},amount:{_gt:0}};s?.tokenStandard&&(i.token_standard={_eq:s?.tokenStandard});let u={query:b,variables:{where_condition:i,offset:s?.offset,limit:s?.limit,order_by:s?.orderBy}};return(await d({aptosConfig:n,query:u,originMethod:"getAccountOwnedTokensFromCollectionAddress"})).current_token_ownerships_v2}async function oo(t){let{aptosConfig:n,accountAddress:e,options:o}=t,r={owner_address:{_eq:c.from(e).toStringLong()},amount:{_gt:0}};o?.tokenStandard&&(r.current_collection={token_standard:{_eq:o?.tokenStandard}});let a={query:h,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountCollectionsWithOwnedTokens"})).current_collection_ownership_v2_view}async function to(t){let{aptosConfig:n,accountAddress:e}=t,o=c.from(e).toStringLong(),r=await d({aptosConfig:n,query:{query:q,variables:{address:o}},originMethod:"getAccountTransactionsCount"});return r.account_transactions_aggregate.aggregate?r.account_transactions_aggregate.aggregate.count:0}async function eo(t){let{aptosConfig:n,accountAddress:e,coinType:o}=t,s=c.from(e).toStringLong(),r=await I({aptosConfig:n,accountAddress:s,options:{where:{asset_type:{_eq:o}}}});return r[0]?r[0].amount:0}async function I(t){let{aptosConfig:n,accountAddress:e,options:o}=t,s=c.from(e).toStringLong(),r={...o?.where,owner_address:{_eq:s}},a={query:w,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountCoinsData"})).current_fungible_asset_balances}async function no(t){let{aptosConfig:n,accountAddress:e}=t,o=c.from(e).toStringLong(),r=await d({aptosConfig:n,query:{query:C,variables:{address:o}},originMethod:"getAccountCoinsCount"});if(!r.current_fungible_asset_balances_aggregate.aggregate)throw Error("Failed to get the count of account coins");return r.current_fungible_asset_balances_aggregate.aggregate.count}async function ro(t){let{aptosConfig:n,accountAddress:e,options:o}=t,r={owner_address:{_eq:c.from(e).toStringLong()}},a={query:k,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountOwnedObjects"})).current_objects}async function so(t){let{aptosConfig:n,privateKey:e}=t,o=new m(e.publicKey());if(e instanceof y){let r=g.fromPublicKey({publicKey:o}).derivedAddress();return A.fromPrivateKey({privateKey:e,address:r})}if(e instanceof l){let s=g.fromPublicKey({publicKey:o});if(await M({authKey:s,aptosConfig:n})){let u=s.derivedAddress();return A.fromPrivateKey({privateKey:e,address:u,legacy:!1})}let a=g.fromPublicKey({publicKey:o.publicKey});if(await M({authKey:a,aptosConfig:n})){let u=a.derivedAddress();return A.fromPrivateKey({privateKey:e,address:u,legacy:!0})}}throw new Error(`Can't derive account from private key ${e}`)}async function M(t){let{aptosConfig:n,authKey:e}=t,o=await Q({aptosConfig:n,authenticationKey:e.derivedAddress()});try{return await S({aptosConfig:n,accountAddress:o}),!0}catch(s){if(s.status===404)return!1;throw new Error(`Error while looking for an account info ${o.toString()}`)}}export{S as a,z as b,H as c,J as d,U as e,K as f,Q as g,X as h,Y as i,Z as j,oo as k,to as l,eo as m,I as n,no as o,ro as p,so as q,M as r};
2
- //# sourceMappingURL=chunk-QXVGXZJX.mjs.map
1
+ import{a as P}from"./chunk-AH44UPM4.mjs";import{d as v,f as d}from"./chunk-YHEF3FJ4.mjs";import{d as C,e as w,f as h,g as k,h as T,j as b,k as O,l as q}from"./chunk-S4SEFF4K.mjs";import{b as p,d as f}from"./chunk-YKANYJTN.mjs";import{a as _}from"./chunk-6FBKUTGF.mjs";import{a as A}from"./chunk-RROJLXZ6.mjs";import{a as m}from"./chunk-6M6XXPQQ.mjs";import{b as y}from"./chunk-PTIZKRON.mjs";import{b as l}from"./chunk-7JNPSNL6.mjs";import{a as g}from"./chunk-7STYQ5ZE.mjs";import{b as c}from"./chunk-T23OVRNF.mjs";async function S(t){let{aptosConfig:n,accountAddress:e}=t,{data:o}=await p({aptosConfig:n,originMethod:"getInfo",path:`accounts/${c.from(e).toString()}`});return o}async function z(t){let{aptosConfig:n,accountAddress:e,options:o}=t;return f({aptosConfig:n,originMethod:"getModules",path:`accounts/${c.from(e).toString()}/modules`,params:{ledger_version:o?.ledgerVersion,start:o?.offset,limit:o?.limit??1e3}})}async function H(t){return t.options?.ledgerVersion!==void 0?G(t):P(async()=>G(t),`module-${t.accountAddress}-${t.moduleName}`,1e3*60*5)()}async function G(t){let{aptosConfig:n,accountAddress:e,moduleName:o,options:s}=t,{data:r}=await p({aptosConfig:n,originMethod:"getModule",path:`accounts/${c.from(e).toString()}/module/${o}`,params:{ledger_version:s?.ledgerVersion}});return r}async function J(t){let{aptosConfig:n,accountAddress:e,options:o}=t;return f({aptosConfig:n,originMethod:"getTransactions",path:`accounts/${c.from(e).toString()}/transactions`,params:{start:o?.offset,limit:o?.limit}})}async function U(t){let{aptosConfig:n,accountAddress:e,options:o}=t;return f({aptosConfig:n,originMethod:"getResources",path:`accounts/${c.from(e).toString()}/resources`,params:{ledger_version:o?.ledgerVersion,start:o?.offset,limit:o?.limit??999}})}async function K(t){let{aptosConfig:n,accountAddress:e,resourceType:o,options:s}=t,{data:r}=await p({aptosConfig:n,originMethod:"getResource",path:`accounts/${c.from(e).toString()}/resource/${o}`,params:{ledger_version:s?.ledgerVersion}});return r.data}async function Q(t){let{aptosConfig:n,authenticationKey:e,options:o}=t,s=await K({aptosConfig:n,accountAddress:"0x1",resourceType:"0x1::account::OriginatingAddress",options:o}),{address_map:{handle:r}}=s,a=c.from(e);try{let i=await v({aptosConfig:n,handle:r,data:{key:a.toString(),key_type:"address",value_type:"address"},options:o});return c.from(i)}catch(i){if(i instanceof _&&i.data.error_code==="table_item_not_found")return a;throw i}}async function X(t){let{aptosConfig:n,accountAddress:e}=t,s={owner_address:{_eq:c.from(e).toStringLong()},amount:{_gt:0}},a=await d({aptosConfig:n,query:{query:O,variables:{where_condition:s}},originMethod:"getAccountTokensCount"});return a.current_token_ownerships_v2_aggregate.aggregate?a.current_token_ownerships_v2_aggregate.aggregate.count:0}async function Y(t){let{aptosConfig:n,accountAddress:e,options:o}=t,r={owner_address:{_eq:c.from(e).toStringLong()},amount:{_gt:0}};o?.tokenStandard&&(r.token_standard={_eq:o?.tokenStandard});let a={query:T,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountOwnedTokens"})).current_token_ownerships_v2}async function Z(t){let{aptosConfig:n,accountAddress:e,collectionAddress:o,options:s}=t,r=c.from(e).toStringLong(),a=c.from(o).toStringLong(),i={owner_address:{_eq:r},current_token_data:{collection_id:{_eq:a}},amount:{_gt:0}};s?.tokenStandard&&(i.token_standard={_eq:s?.tokenStandard});let u={query:b,variables:{where_condition:i,offset:s?.offset,limit:s?.limit,order_by:s?.orderBy}};return(await d({aptosConfig:n,query:u,originMethod:"getAccountOwnedTokensFromCollectionAddress"})).current_token_ownerships_v2}async function oo(t){let{aptosConfig:n,accountAddress:e,options:o}=t,r={owner_address:{_eq:c.from(e).toStringLong()},amount:{_gt:0}};o?.tokenStandard&&(r.current_collection={token_standard:{_eq:o?.tokenStandard}});let a={query:h,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountCollectionsWithOwnedTokens"})).current_collection_ownership_v2_view}async function to(t){let{aptosConfig:n,accountAddress:e}=t,o=c.from(e).toStringLong(),r=await d({aptosConfig:n,query:{query:q,variables:{address:o}},originMethod:"getAccountTransactionsCount"});return r.account_transactions_aggregate.aggregate?r.account_transactions_aggregate.aggregate.count:0}async function eo(t){let{aptosConfig:n,accountAddress:e,coinType:o}=t,s=c.from(e).toStringLong(),r=await I({aptosConfig:n,accountAddress:s,options:{where:{asset_type:{_eq:o}}}});return r[0]?r[0].amount:0}async function I(t){let{aptosConfig:n,accountAddress:e,options:o}=t,s=c.from(e).toStringLong(),r={...o?.where,owner_address:{_eq:s}},a={query:w,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountCoinsData"})).current_fungible_asset_balances}async function no(t){let{aptosConfig:n,accountAddress:e}=t,o=c.from(e).toStringLong(),r=await d({aptosConfig:n,query:{query:C,variables:{address:o}},originMethod:"getAccountCoinsCount"});if(!r.current_fungible_asset_balances_aggregate.aggregate)throw Error("Failed to get the count of account coins");return r.current_fungible_asset_balances_aggregate.aggregate.count}async function ro(t){let{aptosConfig:n,accountAddress:e,options:o}=t,r={owner_address:{_eq:c.from(e).toStringLong()}},a={query:k,variables:{where_condition:r,offset:o?.offset,limit:o?.limit,order_by:o?.orderBy}};return(await d({aptosConfig:n,query:a,originMethod:"getAccountOwnedObjects"})).current_objects}async function so(t){let{aptosConfig:n,privateKey:e}=t,o=new m(e.publicKey());if(e instanceof y){let r=g.fromPublicKey({publicKey:o}).derivedAddress();return A.fromPrivateKey({privateKey:e,address:r})}if(e instanceof l){let s=g.fromPublicKey({publicKey:o});if(await M({authKey:s,aptosConfig:n})){let u=s.derivedAddress();return A.fromPrivateKey({privateKey:e,address:u,legacy:!1})}let a=g.fromPublicKey({publicKey:o.publicKey});if(await M({authKey:a,aptosConfig:n})){let u=a.derivedAddress();return A.fromPrivateKey({privateKey:e,address:u,legacy:!0})}}throw new Error(`Can't derive account from private key ${e}`)}async function M(t){let{aptosConfig:n,authKey:e}=t,o=await Q({aptosConfig:n,authenticationKey:e.derivedAddress()});try{return await S({aptosConfig:n,accountAddress:o}),!0}catch(s){if(s.status===404)return!1;throw new Error(`Error while looking for an account info ${o.toString()}`)}}export{S as a,z as b,H as c,J as d,U as e,K as f,Q as g,X as h,Y as i,Z as j,oo as k,to as l,eo as m,I as n,no as o,ro as p,so as q,M as r};
2
+ //# sourceMappingURL=chunk-H6EEHYWO.mjs.map
@@ -1,2 +1,2 @@
1
- import{d as i}from"./chunk-2YDIOWRJ.mjs";import{b as o}from"./chunk-E4Z5IEZP.mjs";import{b as n}from"./chunk-CQJ4WN7M.mjs";import{b as a}from"./chunk-T23OVRNF.mjs";var c=class s{constructor(e){this.signingScheme=0;let{privateKey:r,address:t}=e;this.privateKey=r,this.publicKey=r.publicKey(),this.accountAddress=t?a.from(t):this.publicKey.authKey().derivedAddress()}static generate(){let e=n.generate();return new s({privateKey:e})}static fromDerivationPath(e){let{path:r,mnemonic:t}=e,u=n.fromDerivationPath(r,t);return new s({privateKey:u})}verifySignature(e){return this.publicKey.verifySignature(e)}signWithAuthenticator(e){let r=this.privateKey.sign(i(e));return new o(this.publicKey,r)}sign(e){return this.privateKey.sign(e)}signTransaction(e){return this.sign(i(e))}};export{c as a};
2
- //# sourceMappingURL=chunk-LX7N4NUS.mjs.map
1
+ import{d as i}from"./chunk-2YDIOWRJ.mjs";import{b as o}from"./chunk-WPVBC4JS.mjs";import{b as n}from"./chunk-7JNPSNL6.mjs";import{b as a}from"./chunk-T23OVRNF.mjs";var c=class s{constructor(e){this.signingScheme=0;let{privateKey:r,address:t}=e;this.privateKey=r,this.publicKey=r.publicKey(),this.accountAddress=t?a.from(t):this.publicKey.authKey().derivedAddress()}static generate(){let e=n.generate();return new s({privateKey:e})}static fromDerivationPath(e){let{path:r,mnemonic:t}=e,u=n.fromDerivationPath(r,t);return new s({privateKey:u})}verifySignature(e){return this.publicKey.verifySignature(e)}signWithAuthenticator(e){let r=this.privateKey.sign(i(e));return new o(this.publicKey,r)}sign(e){return this.privateKey.sign(e)}signTransaction(e){return this.sign(i(e))}};export{c as a};
2
+ //# sourceMappingURL=chunk-ITEV72BZ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as i}from"./chunk-XEXWFQNP.mjs";import{h as t}from"./chunk-6NZNCDDW.mjs";var r=class{constructor(o){this.config=o}async fundAccount(o){let n=await i({aptosConfig:this.config,...o});return o.options?.waitForIndexer!==!1&&await t({aptosConfig:this.config,minimumLedgerVersion:BigInt(n.version)}),n}};export{r as a};
2
- //# sourceMappingURL=chunk-3LQPAGL6.mjs.map
1
+ import{a as i}from"./chunk-Z5II77T2.mjs";import{h as t}from"./chunk-PFQQIEWF.mjs";var r=class{constructor(o){this.config=o}async fundAccount(o){let n=await i({aptosConfig:this.config,...o});return o.options?.waitForIndexer!==!1&&await t({aptosConfig:this.config,minimumLedgerVersion:BigInt(n.version)}),n}};export{r as a};
2
+ //# sourceMappingURL=chunk-K4OBKJK4.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as r,c as o}from"./chunk-OQMR3WGU.mjs";var t=class{constructor(e){this.config=e}async getPepper(e){return r({aptosConfig:this.config,...e})}async deriveKeylessAccount(e){return o({aptosConfig:this.config,...e})}};export{t as a};
2
+ //# sourceMappingURL=chunk-KAMRUIEM.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/api/keyless.ts"],"sourcesContent":["// Copyright © Aptos Foundation\n// SPDX-License-Identifier: Apache-2.0\n\nimport { EphemeralKeyPair, KeylessAccount, ProofFetchCallback } from \"../account\";\nimport { deriveKeylessAccount, getPepper } from \"../internal/keyless\";\nimport { HexInput } from \"../types\";\nimport { AptosConfig } from \"./aptosConfig\";\n\n/**\n * A class to query all `OIDB` related queries on Aptos.\n */\nexport class Keyless {\n constructor(readonly config: AptosConfig) {}\n\n /**\n * TODO\n *\n * @param args.jwt jwt token\n * @returns The pepper\n */\n async getPepper(args: { jwt: string; ephemeralKeyPair: EphemeralKeyPair }): Promise<Uint8Array> {\n return getPepper({ aptosConfig: this.config, ...args });\n }\n\n async deriveKeylessAccount(args: {\n jwt: string;\n ephemeralKeyPair: EphemeralKeyPair;\n uidKey?: string;\n pepper?: HexInput;\n extraFieldKey?: string;\n proofFetchCallback?: ProofFetchCallback;\n }): Promise<KeylessAccount> {\n return deriveKeylessAccount({ aptosConfig: this.config, ...args });\n }\n}\n"],"mappings":"gDAWO,IAAMA,EAAN,KAAc,CACnB,YAAqBC,EAAqB,CAArB,YAAAA,CAAsB,CAQ3C,MAAM,UAAUC,EAAgF,CAC9F,OAAOC,EAAU,CAAE,YAAa,KAAK,OAAQ,GAAGD,CAAK,CAAC,CACxD,CAEA,MAAM,qBAAqBA,EAOC,CAC1B,OAAOE,EAAqB,CAAE,YAAa,KAAK,OAAQ,GAAGF,CAAK,CAAC,CACnE,CACF","names":["Keyless","config","args","getPepper","deriveKeylessAccount"]}
@@ -1,2 +1,2 @@
1
- import{a as u,b as l}from"./chunk-HURQZGUZ.mjs";import{b as g}from"./chunk-COW5IGYC.mjs";import{a as f}from"./chunk-STYDBDYL.mjs";import{a as m}from"./chunk-7STYQ5ZE.mjs";function p(y){let o=y;return o-=o>>1&1431655765,o=(o&858993459)+(o>>2&858993459),(o+(o>>4)&252645135)*16843009>>24}var d=class y extends g{constructor(e){super();let{publicKeys:i,signaturesRequired:t}=e;if(t<1)throw new Error("The number of required signatures needs to be greater than 0");if(i.length<t)throw new Error(`Provided ${i.length} public keys is smaller than the ${t} required signatures`);this.publicKeys=i.map(r=>r instanceof u?r:new u(r)),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 i=e.deserializeVector(u),t=e.deserializeU8();return new y({publicKeys:i,signaturesRequired:t})}createBitmap(e){let{bits:i}=e,t=128,r=new Uint8Array([0,0,0,0]),s=new Set;return i.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(s.has(n))throw new Error(`Duplicate bit ${n} detected.`);s.add(n);let h=Math.floor(n/8),b=r[h];b|=t>>n%8,r[h]=b}),r}getIndex(e){let i=e instanceof u?e:new u(e),t=this.publicKeys.findIndex(r=>r.toString()===i.toString());if(t!==-1)return t;throw new Error("Public key not found in MultiKey")}},a=class a extends f{constructor(e){super();let{signatures:i,bitmap:t}=e;if(i.length>a.MAX_SIGNATURES_SUPPORTED)throw new Error(`The number of signatures cannot be greater than ${a.MAX_SIGNATURES_SUPPORTED}`);if(this.signatures=i.map(s=>s instanceof l?s:new l(s)),!(t instanceof Uint8Array))this.bitmap=a.createBitmap({bits:t});else{if(t.length!==a.BITMAP_LEN)throw new Error(`"bitmap" length should be ${a.BITMAP_LEN}`);this.bitmap=t}let r=this.bitmap.reduce((s,n)=>s+p(n),0);if(r!==this.signatures.length)throw new Error(`Expecting ${r} signatures from the bitmap, but got ${this.signatures.length}`)}static createBitmap(e){let{bits:i}=e,t=128,r=new Uint8Array([0,0,0,0]),s=new Set;return i.forEach(n=>{if(n>=a.MAX_SIGNATURES_SUPPORTED)throw new Error(`Cannot have a signature larger than ${a.MAX_SIGNATURES_SUPPORTED-1}.`);if(s.has(n))throw new Error("Duplicate bits detected.");s.add(n);let c=Math.floor(n/8),h=r[c];h|=t>>n%8,r[c]=h}),r}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeVector(this.signatures),e.serializeBytes(this.bitmap)}static deserialize(e){let i=e.deserializeBytes(),t=i.reduce((s,n)=>s+p(n),0),r=[];for(let s=0;s<t;s+=1){let n=l.deserialize(e);r.push(n)}return new a({signatures:r,bitmap:i})}};a.BITMAP_LEN=4,a.MAX_SIGNATURES_SUPPORTED=a.BITMAP_LEN*8;var A=a;export{d as a,A as b};
2
- //# sourceMappingURL=chunk-F6QCHPVS.mjs.map
1
+ import{a as u,b as l}from"./chunk-6M6XXPQQ.mjs";import{b as g}from"./chunk-COW5IGYC.mjs";import{a as f}from"./chunk-STYDBDYL.mjs";import{a as m}from"./chunk-7STYQ5ZE.mjs";function p(y){let o=y;return o-=o>>1&1431655765,o=(o&858993459)+(o>>2&858993459),(o+(o>>4)&252645135)*16843009>>24}var d=class y extends g{constructor(e){super();let{publicKeys:i,signaturesRequired:t}=e;if(t<1)throw new Error("The number of required signatures needs to be greater than 0");if(i.length<t)throw new Error(`Provided ${i.length} public keys is smaller than the ${t} required signatures`);this.publicKeys=i.map(r=>r instanceof u?r:new u(r)),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 i=e.deserializeVector(u),t=e.deserializeU8();return new y({publicKeys:i,signaturesRequired:t})}createBitmap(e){let{bits:i}=e,t=128,r=new Uint8Array([0,0,0,0]),s=new Set;return i.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(s.has(n))throw new Error(`Duplicate bit ${n} detected.`);s.add(n);let h=Math.floor(n/8),b=r[h];b|=t>>n%8,r[h]=b}),r}getIndex(e){let i=e instanceof u?e:new u(e),t=this.publicKeys.findIndex(r=>r.toString()===i.toString());if(t!==-1)return t;throw new Error("Public key not found in MultiKey")}},a=class a extends f{constructor(e){super();let{signatures:i,bitmap:t}=e;if(i.length>a.MAX_SIGNATURES_SUPPORTED)throw new Error(`The number of signatures cannot be greater than ${a.MAX_SIGNATURES_SUPPORTED}`);if(this.signatures=i.map(s=>s instanceof l?s:new l(s)),!(t instanceof Uint8Array))this.bitmap=a.createBitmap({bits:t});else{if(t.length!==a.BITMAP_LEN)throw new Error(`"bitmap" length should be ${a.BITMAP_LEN}`);this.bitmap=t}let r=this.bitmap.reduce((s,n)=>s+p(n),0);if(r!==this.signatures.length)throw new Error(`Expecting ${r} signatures from the bitmap, but got ${this.signatures.length}`)}static createBitmap(e){let{bits:i}=e,t=128,r=new Uint8Array([0,0,0,0]),s=new Set;return i.forEach(n=>{if(n>=a.MAX_SIGNATURES_SUPPORTED)throw new Error(`Cannot have a signature larger than ${a.MAX_SIGNATURES_SUPPORTED-1}.`);if(s.has(n))throw new Error("Duplicate bits detected.");s.add(n);let c=Math.floor(n/8),h=r[c];h|=t>>n%8,r[c]=h}),r}toUint8Array(){return this.bcsToBytes()}serialize(e){e.serializeVector(this.signatures),e.serializeBytes(this.bitmap)}static deserialize(e){let i=e.deserializeBytes(),t=i.reduce((s,n)=>s+p(n),0),r=[];for(let s=0;s<t;s+=1){let n=l.deserialize(e);r.push(n)}return new a({signatures:r,bitmap:i})}};a.BITMAP_LEN=4,a.MAX_SIGNATURES_SUPPORTED=a.BITMAP_LEN*8;var A=a;export{d as a,A as b};
2
+ //# sourceMappingURL=chunk-KGJITNRZ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as c}from"./chunk-RPXN7HGR.mjs";import{c as p}from"./chunk-PFFAQZHT.mjs";import{f as o}from"./chunk-APEBWN6Q.mjs";import{o as u,r as g,s as A}from"./chunk-S4SEFF4K.mjs";import{f as a,i as r}from"./chunk-3VGX3TXH.mjs";async function G(t){let{aptosConfig:s,options:e}=t,n={query:A,variables:{where_condition:e?.where,limit:e?.limit,offset:e?.offset}};return(await o({aptosConfig:s,query:n,originMethod:"getFungibleAssetMetadata"})).fungible_asset_metadata}async function h(t){let{aptosConfig:s,options:e}=t,n={query:g,variables:{where_condition:e?.where,limit:e?.limit,offset:e?.offset}};return(await o({aptosConfig:s,query:n,originMethod:"getFungibleAssetActivities"})).fungible_asset_activities}async function M(t){let{aptosConfig:s,options:e}=t,n={query:u,variables:{where_condition:e?.where,limit:e?.limit,offset:e?.offset}};return(await o({aptosConfig:s,query:n,originMethod:"getCurrentFungibleAssetBalances"})).current_fungible_asset_balances}var b={typeParameters:[],parameters:[p("0x1::object::Object"),new r,new a]};async function x(t){let{aptosConfig:s,sender:e,fungibleAssetMetadataAddress:n,recipient:i,amount:l,options:f}=t;return c({aptosConfig:s,sender:e.accountAddress,data:{function:"0x1::primary_fungible_store::transfer",typeArguments:["0x1::fungible_asset::Metadata"],functionArguments:[n,i,l],abi:b},options:f})}export{G as a,h as b,M as c,x as d};
2
- //# sourceMappingURL=chunk-TBG3MIIE.mjs.map
1
+ import{a as c}from"./chunk-T75EO4EY.mjs";import{c as p}from"./chunk-PFFAQZHT.mjs";import{f as o}from"./chunk-YHEF3FJ4.mjs";import{o as u,r as g,s as A}from"./chunk-S4SEFF4K.mjs";import{f as a,i as r}from"./chunk-3VGX3TXH.mjs";async function G(t){let{aptosConfig:s,options:e}=t,n={query:A,variables:{where_condition:e?.where,limit:e?.limit,offset:e?.offset}};return(await o({aptosConfig:s,query:n,originMethod:"getFungibleAssetMetadata"})).fungible_asset_metadata}async function h(t){let{aptosConfig:s,options:e}=t,n={query:g,variables:{where_condition:e?.where,limit:e?.limit,offset:e?.offset}};return(await o({aptosConfig:s,query:n,originMethod:"getFungibleAssetActivities"})).fungible_asset_activities}async function M(t){let{aptosConfig:s,options:e}=t,n={query:u,variables:{where_condition:e?.where,limit:e?.limit,offset:e?.offset}};return(await o({aptosConfig:s,query:n,originMethod:"getCurrentFungibleAssetBalances"})).current_fungible_asset_balances}var b={typeParameters:[],parameters:[p("0x1::object::Object"),new r,new a]};async function x(t){let{aptosConfig:s,sender:e,fungibleAssetMetadataAddress:n,recipient:i,amount:l,options:f}=t;return c({aptosConfig:s,sender:e.accountAddress,data:{function:"0x1::primary_fungible_store::transfer",typeArguments:["0x1::fungible_asset::Metadata"],functionArguments:[n,i,l],abi:b},options:f})}export{G as a,h as b,M as c,x as d};
2
+ //# sourceMappingURL=chunk-LRUXIKHV.mjs.map
@@ -1,2 +1,2 @@
1
- import{f as n}from"./chunk-APEBWN6Q.mjs";import{p as g,u as d}from"./chunk-S4SEFF4K.mjs";import{b as s}from"./chunk-T23OVRNF.mjs";async function m(e){let{aptosConfig:t,poolAddress:o}=e,r=s.from(o).toStringLong(),i=await n({aptosConfig:t,query:{query:d,variables:{where_condition:{pool_address:{_eq:r}}}}});return i.num_active_delegator_per_pool[0]?i.num_active_delegator_per_pool[0].num_active_delegator:0}async function f(e){let{aptosConfig:t,options:o}=e,r={query:d,variables:{order_by:o?.orderBy}};return(await n({aptosConfig:t,query:r})).num_active_delegator_per_pool}async function A(e){let{aptosConfig:t,delegatorAddress:o,poolAddress:r}=e,a={query:g,variables:{delegatorAddress:s.from(o).toStringLong(),poolAddress:s.from(r).toStringLong()}};return(await n({aptosConfig:t,query:a})).delegated_staking_activities}export{m as a,f as b,A as c};
2
- //# sourceMappingURL=chunk-Q7TGZJT4.mjs.map
1
+ import{f as n}from"./chunk-YHEF3FJ4.mjs";import{p as g,u as d}from"./chunk-S4SEFF4K.mjs";import{b as s}from"./chunk-T23OVRNF.mjs";async function m(e){let{aptosConfig:t,poolAddress:o}=e,r=s.from(o).toStringLong(),i=await n({aptosConfig:t,query:{query:d,variables:{where_condition:{pool_address:{_eq:r}}}}});return i.num_active_delegator_per_pool[0]?i.num_active_delegator_per_pool[0].num_active_delegator:0}async function f(e){let{aptosConfig:t,options:o}=e,r={query:d,variables:{order_by:o?.orderBy}};return(await n({aptosConfig:t,query:r})).num_active_delegator_per_pool}async function A(e){let{aptosConfig:t,delegatorAddress:o,poolAddress:r}=e,a={query:g,variables:{delegatorAddress:s.from(o).toStringLong(),poolAddress:s.from(r).toStringLong()}};return(await n({aptosConfig:t,query:a})).delegated_staking_activities}export{m as a,f as b,A as c};
2
+ //# sourceMappingURL=chunk-NRJ34FML.mjs.map
@@ -0,0 +1,2 @@
1
+ import{e as b,f as x}from"./chunk-VPZ4ZYJA.mjs";import{c as E}from"./chunk-YKANYJTN.mjs";import{a as l}from"./chunk-P5VCS2F5.mjs";import{a as m,l as h,m as A}from"./chunk-WTVN3XGK.mjs";import{b as S}from"./chunk-R7BAM2G6.mjs";import{c as d}from"./chunk-S5HG2QUD.mjs";import{b as _}from"./chunk-TVRJ3M7B.mjs";import{b as a}from"./chunk-AOCNYMMX.mjs";import{jwtDecode as K}from"jwt-decode";import{bls12_381 as p}from"@noble/curves/bls12-381";var v="APTOS_KEYLESS_PEPPER_PINKAS_VUF_DST";function w(e){return new TextEncoder().encode(e)}var I=p.G2.hashToCurve(w("APTOS_KEYLESS_PEPPER_PINKAS_VUF_SECRET_KEY_BASE"),{DST:v}).toAffine();function C(e){let{jwt:i,uidKey:t}=e,r=K(i),o=new _;o.serializeStr(r.iss),o.serializeStr(r.aud),o.serializeStr(r[t||"sub"]),o.serializeStr(t||"sub");let s=o.toUint8Array(),n=p.G1.hashToCurve(s,{DST:"APTOS_PEPPER_SERVICE_BLS12381_VUF_DST"}).toAffine();return p.G1.ProjectivePoint.fromAffine(n)}async function F(e){let{aptosConfig:i,pepperInput:t,pepperBase:r}=e,{data:o}=await E({aptosConfig:i,path:"vrf-pub-key",originMethod:"getPepper"}),s=p.G2.ProjectivePoint.fromHex(o.vrf_public_key_hex_string);return p.verifyShortSignature(r,t,s)}async function j(e){let{aptosConfig:i,jwt:t,ephemeralKeyPair:r,uidKey:o,verify:s}=e,{derivationPath:n}=e,c={jwt_b64:t,epk:r.getPublicKey().bcsToHex().toStringWithoutPrefix(),exp_date_secs:Number(r.expiryDateSecs),epk_blinder:a.fromHexInput(r.blinder).toStringWithoutPrefix(),uid_key:o},{data:f}=await b({aptosConfig:i,path:"fetch",body:c,originMethod:"getPepper",overrides:{WITH_CREDENTIALS:!1}}),P=a.fromHexInput(f.signature).toUint8Array();if(s&&!F({aptosConfig:i,pepperBase:P,pepperInput:C(e)}))throw new Error("Unable to verify");let u=p.pairing(p.G1.ProjectivePoint.fromHex(P),p.G2.ProjectivePoint.fromAffine(I));return n===void 0&&(n=d),l.fromDerivationPath(n,p.fields.Fp12.toBytes(u)).slice(0,31)}async function k(e){let{aptosConfig:i,jwt:t,ephemeralKeyPair:r,pepper:o,uidKey:s,extraFieldKey:n}=e,c=K(t),f;if(n){let T=c[n];f=`"${n}":"${T}",`}let P={jwt_b64:t,epk:r.getPublicKey().bcsToHex().toStringWithoutPrefix(),epk_blinder:a.fromHexInput(r.blinder).toStringWithoutPrefix(),exp_date_secs:Number(r.expiryDateSecs),exp_horizon_secs:m,pepper:a.fromHexInput(o).toStringWithoutPrefix(),extra_field:n,uid_key:s||"sub"},{data:u}=await x({aptosConfig:i,path:"prove",body:P,originMethod:"getProof",overrides:{WITH_CREDENTIALS:!1}}),y=u.proof,g=new h({a:y.a,b:y.b,c:y.c});return new A({proof:g,extraField:f,trainingWheelsSignature:S.fromHex(u.training_wheels_signature)})}async function O(e){let{proofFetchCallback:i}=e,{pepper:t}=e;if(t===void 0)t=await j(e);else if(a.fromHexInput(t).toUint8Array().length!==31)throw new Error("Pepper needs to be 31 bytes");let r=k({...e,pepper:t}),o=i?r:await r;return l.fromJWTAndProof({...e,proof:o,pepper:t,proofFetchCallback:i})}export{j as a,k as b,O as c};
2
+ //# sourceMappingURL=chunk-OQMR3WGU.mjs.map