@aeternity/aepp-sdk 13.3.2 → 14.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1033) hide show
  1. package/README.md +4 -2
  2. package/bin/aesophia_cli +0 -0
  3. package/dist/aepp-sdk.browser-script.cjs +3 -0
  4. package/dist/aepp-sdk.browser-script.cjs.LICENSE.txt +10 -0
  5. package/dist/aepp-sdk.browser-script.cjs.map +1 -0
  6. package/dist/aepp-sdk.browser.cjs +3 -0
  7. package/dist/aepp-sdk.browser.cjs.map +1 -0
  8. package/dist/aepp-sdk.cjs +33535 -0
  9. package/dist/aepp-sdk.cjs.map +1 -0
  10. package/es/AeSdk.d.ts +4 -4
  11. package/es/AeSdk.js +76 -0
  12. package/es/AeSdk.js.map +1 -0
  13. package/es/AeSdkAepp.d.ts +13 -8
  14. package/es/AeSdkAepp.js +153 -0
  15. package/es/AeSdkAepp.js.map +1 -0
  16. package/es/AeSdkBase.d.ts +5 -40
  17. package/es/AeSdkBase.js +225 -0
  18. package/es/AeSdkBase.js.map +1 -0
  19. package/es/AeSdkMethods.d.ts +10 -33
  20. package/es/AeSdkMethods.js +81 -0
  21. package/es/AeSdkMethods.js.map +1 -0
  22. package/es/AeSdkWallet.d.ts +13 -8
  23. package/es/AeSdkWallet.js +347 -0
  24. package/es/AeSdkWallet.js.map +1 -0
  25. package/es/Middleware.d.ts +9 -25
  26. package/es/Middleware.js +97 -0
  27. package/es/Middleware.js.map +1 -0
  28. package/es/MiddlewareSubscriber.d.ts +2 -3
  29. package/es/MiddlewareSubscriber.js +165 -0
  30. package/es/MiddlewareSubscriber.js.map +1 -0
  31. package/es/Node.d.ts +5 -21
  32. package/es/Node.js +97 -0
  33. package/es/Node.js.map +1 -0
  34. package/es/account/Base.d.ts +7 -71
  35. package/es/account/Base.js +6 -0
  36. package/es/account/Base.js.map +1 -0
  37. package/es/account/BaseFactory.d.ts +19 -0
  38. package/es/account/BaseFactory.js +28 -0
  39. package/es/account/BaseFactory.js.map +1 -0
  40. package/es/account/Generalized.d.ts +2 -6
  41. package/es/account/Generalized.js +108 -0
  42. package/es/account/Generalized.js.map +1 -0
  43. package/es/account/Ledger.d.ts +3 -7
  44. package/es/account/Ledger.js +107 -0
  45. package/es/account/Ledger.js.map +1 -0
  46. package/es/account/LedgerFactory.d.ts +16 -16
  47. package/es/account/LedgerFactory.js +80 -0
  48. package/es/account/LedgerFactory.js.map +1 -0
  49. package/es/account/Memory.d.ts +6 -22
  50. package/es/account/Memory.js +97 -0
  51. package/es/account/Memory.js.map +1 -0
  52. package/es/account/Metamask.d.ts +26 -0
  53. package/es/account/Metamask.js +76 -0
  54. package/es/account/Metamask.js.map +1 -0
  55. package/es/account/MetamaskFactory.d.ts +40 -0
  56. package/es/account/MetamaskFactory.js +110 -0
  57. package/es/account/MetamaskFactory.js.map +1 -0
  58. package/es/account/MnemonicFactory.d.ts +35 -0
  59. package/es/account/MnemonicFactory.js +88 -0
  60. package/es/account/MnemonicFactory.js.map +1 -0
  61. package/es/account/Rpc.d.ts +5 -19
  62. package/es/account/Rpc.js +86 -0
  63. package/es/account/Rpc.js.map +1 -0
  64. package/es/aens.d.ts +125 -166
  65. package/es/aens.js +258 -0
  66. package/es/aens.js.map +1 -0
  67. package/es/aepp-wallet-communication/WalletConnectorFrame.d.ts +25 -0
  68. package/es/aepp-wallet-communication/WalletConnectorFrame.js +39 -0
  69. package/es/aepp-wallet-communication/WalletConnectorFrame.js.map +1 -0
  70. package/es/aepp-wallet-communication/WalletConnectorFrameBase.d.ts +43 -0
  71. package/es/aepp-wallet-communication/WalletConnectorFrameBase.js +110 -0
  72. package/es/aepp-wallet-communication/WalletConnectorFrameBase.js.map +1 -0
  73. package/es/aepp-wallet-communication/WalletConnectorFrameWithNode.d.ts +27 -0
  74. package/es/aepp-wallet-communication/WalletConnectorFrameWithNode.js +43 -0
  75. package/es/aepp-wallet-communication/WalletConnectorFrameWithNode.js.map +1 -0
  76. package/es/aepp-wallet-communication/connection/Browser.js +53 -0
  77. package/es/aepp-wallet-communication/connection/Browser.js.map +1 -0
  78. package/es/aepp-wallet-communication/connection/BrowserRuntime.d.ts +1 -1
  79. package/es/aepp-wallet-communication/connection/BrowserRuntime.js +54 -0
  80. package/es/aepp-wallet-communication/connection/BrowserRuntime.js.map +1 -0
  81. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.d.ts +2 -2
  82. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.js +90 -0
  83. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.js.map +1 -0
  84. package/es/aepp-wallet-communication/connection-proxy.d.ts +2 -2
  85. package/es/aepp-wallet-communication/connection-proxy.js +17 -0
  86. package/es/aepp-wallet-communication/connection-proxy.js.map +1 -0
  87. package/es/aepp-wallet-communication/rpc/RpcClient.d.ts +1 -1
  88. package/es/aepp-wallet-communication/rpc/RpcClient.js +119 -0
  89. package/es/aepp-wallet-communication/rpc/RpcClient.js.map +1 -0
  90. package/es/aepp-wallet-communication/rpc/types.d.ts +13 -19
  91. package/es/aepp-wallet-communication/rpc/types.js +3 -0
  92. package/es/aepp-wallet-communication/rpc/types.js.map +1 -0
  93. package/es/aepp-wallet-communication/schema.d.ts +10 -3
  94. package/es/aepp-wallet-communication/schema.js +202 -0
  95. package/es/aepp-wallet-communication/schema.js.map +1 -0
  96. package/es/aepp-wallet-communication/wallet-detector.d.ts +4 -4
  97. package/es/aepp-wallet-communication/wallet-detector.js +44 -0
  98. package/es/aepp-wallet-communication/wallet-detector.js.map +1 -0
  99. package/es/apis/compiler/compiler.d.ts +2 -2
  100. package/es/apis/compiler/compiler.js +513 -0
  101. package/es/apis/compiler/compiler.js.map +1 -0
  102. package/es/apis/compiler/index.d.ts +2 -2
  103. package/es/apis/compiler/index.js +3 -0
  104. package/es/apis/compiler/index.js.map +1 -0
  105. package/es/apis/compiler/models/index.js +2 -0
  106. package/es/apis/compiler/models/index.js.map +1 -0
  107. package/es/apis/compiler/models/mappers.js +554 -0
  108. package/es/apis/compiler/models/mappers.js.map +1 -0
  109. package/es/apis/compiler/models/parameters.js +67 -0
  110. package/es/apis/compiler/models/parameters.js.map +1 -0
  111. package/es/apis/middleware/index.d.ts +2 -2
  112. package/es/apis/middleware/index.js +3 -0
  113. package/es/apis/middleware/index.js.map +1 -0
  114. package/es/apis/middleware/middleware.d.ts +142 -134
  115. package/es/apis/middleware/middleware.js +1677 -0
  116. package/es/apis/middleware/middleware.js.map +1 -0
  117. package/es/apis/middleware/models/index.d.ts +1998 -819
  118. package/es/apis/middleware/models/index.js +1364 -0
  119. package/es/apis/middleware/models/index.js.map +1 -0
  120. package/es/apis/middleware/models/mappers.d.ts +135 -80
  121. package/es/apis/middleware/models/mappers.js +6054 -0
  122. package/es/apis/middleware/models/mappers.js.map +1 -0
  123. package/es/apis/middleware/models/parameters.d.ts +58 -14
  124. package/es/apis/middleware/models/parameters.js +909 -0
  125. package/es/apis/middleware/models/parameters.js.map +1 -0
  126. package/es/apis/node/index.d.ts +2 -2
  127. package/es/apis/node/index.js +3 -0
  128. package/es/apis/node/index.js.map +1 -0
  129. package/es/apis/node/models/index.d.ts +643 -636
  130. package/es/apis/node/models/index.js +2 -0
  131. package/es/apis/node/models/index.js.map +1 -0
  132. package/es/apis/node/models/mappers.d.ts +55 -55
  133. package/es/apis/node/models/mappers.js +5322 -0
  134. package/es/apis/node/models/mappers.js.map +1 -0
  135. package/es/apis/node/models/parameters.d.ts +5 -5
  136. package/es/apis/node/models/parameters.js +165 -0
  137. package/es/apis/node/models/parameters.js.map +1 -0
  138. package/es/apis/node/node.d.ts +101 -96
  139. package/es/apis/node/node.js +1238 -0
  140. package/es/apis/node/node.js.map +1 -0
  141. package/es/chain.d.ts +21 -21
  142. package/es/chain.js +442 -0
  143. package/es/chain.js.map +1 -0
  144. package/es/channel/Base.d.ts +13 -15
  145. package/es/channel/Base.js +246 -0
  146. package/es/channel/Base.js.map +1 -0
  147. package/es/channel/Contract.d.ts +9 -9
  148. package/es/channel/Contract.js +382 -0
  149. package/es/channel/Contract.js.map +1 -0
  150. package/es/channel/Spend.d.ts +11 -11
  151. package/es/channel/Spend.js +357 -0
  152. package/es/channel/Spend.js.map +1 -0
  153. package/es/channel/handlers.d.ts +4 -3
  154. package/es/channel/handlers.js +395 -0
  155. package/es/channel/handlers.js.map +1 -0
  156. package/es/channel/internal.d.ts +32 -25
  157. package/es/channel/internal.js +224 -0
  158. package/es/channel/internal.js.map +1 -0
  159. package/es/contract/Contract.d.ts +17 -19
  160. package/es/contract/Contract.js +525 -0
  161. package/es/contract/Contract.js.map +1 -0
  162. package/es/contract/compiler/Base.d.ts +1 -1
  163. package/es/contract/compiler/Base.js +5 -0
  164. package/es/contract/compiler/Base.js.map +1 -0
  165. package/es/contract/compiler/Cli.d.ts +2 -2
  166. package/es/contract/compiler/Cli.js +167 -0
  167. package/es/contract/compiler/Cli.js.map +1 -0
  168. package/es/contract/compiler/Http.d.ts +3 -3
  169. package/es/contract/compiler/Http.js +124 -0
  170. package/es/contract/compiler/Http.js.map +1 -0
  171. package/es/contract/compiler/HttpNode.d.ts +3 -3
  172. package/es/contract/compiler/HttpNode.js +29 -0
  173. package/es/contract/compiler/HttpNode.js.map +1 -0
  174. package/es/contract/compiler/getFileSystem.js +32 -0
  175. package/es/contract/compiler/getFileSystem.js.map +1 -0
  176. package/es/contract/ga.d.ts +8 -12
  177. package/es/contract/ga.js +136 -0
  178. package/es/contract/ga.js.map +1 -0
  179. package/es/index-browser.d.ts +56 -51
  180. package/es/index-browser.js +55 -0
  181. package/es/index-browser.js.map +1 -0
  182. package/es/index.d.ts +4 -5
  183. package/es/index.js +5 -0
  184. package/es/index.js.map +1 -0
  185. package/es/oracle/Oracle.d.ts +70 -0
  186. package/es/oracle/Oracle.js +173 -0
  187. package/es/oracle/Oracle.js.map +1 -0
  188. package/es/oracle/OracleBase.d.ts +41 -0
  189. package/es/oracle/OracleBase.js +52 -0
  190. package/es/oracle/OracleBase.js.map +1 -0
  191. package/es/oracle/OracleClient.d.ts +57 -0
  192. package/es/oracle/OracleClient.js +100 -0
  193. package/es/oracle/OracleClient.js.map +1 -0
  194. package/es/send-transaction.d.ts +8 -8
  195. package/es/send-transaction.js +110 -0
  196. package/es/send-transaction.js.map +1 -0
  197. package/es/spend.d.ts +8 -13
  198. package/es/spend.js +93 -0
  199. package/es/spend.js.map +1 -0
  200. package/es/tx/builder/SchemaTypes.d.ts +3 -3
  201. package/es/tx/builder/SchemaTypes.js +2 -0
  202. package/es/tx/builder/SchemaTypes.js.map +1 -0
  203. package/es/tx/builder/common.d.ts +2 -2
  204. package/es/tx/builder/common.js +38 -0
  205. package/es/tx/builder/common.js.map +1 -0
  206. package/es/tx/builder/constants.d.ts +2 -26
  207. package/es/tx/builder/constants.js +120 -0
  208. package/es/tx/builder/constants.js.map +1 -0
  209. package/es/tx/builder/delegation/index.d.ts +3 -3
  210. package/es/tx/builder/delegation/index.js +24 -0
  211. package/es/tx/builder/delegation/index.js.map +1 -0
  212. package/es/tx/builder/delegation/schema.d.ts +21 -4
  213. package/es/tx/builder/delegation/schema.generated.d.ts +2 -2
  214. package/es/tx/builder/delegation/schema.generated.js +2 -0
  215. package/es/tx/builder/delegation/schema.generated.js.map +1 -0
  216. package/es/tx/builder/delegation/schema.js +68 -0
  217. package/es/tx/builder/delegation/schema.js.map +1 -0
  218. package/es/tx/builder/entry/constants.d.ts +32 -0
  219. package/es/tx/builder/entry/constants.js +36 -0
  220. package/es/tx/builder/entry/constants.js.map +1 -0
  221. package/es/tx/builder/entry/index.d.ts +38 -0
  222. package/es/tx/builder/entry/index.js +37 -0
  223. package/es/tx/builder/entry/index.js.map +1 -0
  224. package/es/tx/builder/entry/schema.d.ts +1030 -0
  225. package/es/tx/builder/entry/schema.generated.d.ts +607 -0
  226. package/es/tx/builder/entry/schema.generated.js +2 -0
  227. package/es/tx/builder/entry/schema.generated.js.map +1 -0
  228. package/es/tx/builder/entry/schema.js +204 -0
  229. package/es/tx/builder/entry/schema.js.map +1 -0
  230. package/es/tx/builder/field-types/abi-version.d.ts +4 -5
  231. package/es/tx/builder/field-types/abi-version.js +34 -0
  232. package/es/tx/builder/field-types/abi-version.js.map +1 -0
  233. package/es/tx/builder/field-types/address.d.ts +2 -3
  234. package/es/tx/builder/field-types/address.js +46 -0
  235. package/es/tx/builder/field-types/address.js.map +1 -0
  236. package/es/tx/builder/field-types/array.js +11 -0
  237. package/es/tx/builder/field-types/array.js.map +1 -0
  238. package/es/tx/builder/field-types/boolean.d.ts +0 -1
  239. package/es/tx/builder/field-types/boolean.js +10 -0
  240. package/es/tx/builder/field-types/boolean.js.map +1 -0
  241. package/es/tx/builder/field-types/coin-amount.d.ts +3 -4
  242. package/es/tx/builder/field-types/coin-amount.js +18 -0
  243. package/es/tx/builder/field-types/coin-amount.js.map +1 -0
  244. package/es/tx/builder/field-types/ct-version.d.ts +4 -19
  245. package/es/tx/builder/field-types/ct-version.js +58 -0
  246. package/es/tx/builder/field-types/ct-version.js.map +1 -0
  247. package/es/tx/builder/field-types/encoded.d.ts +1 -2
  248. package/es/tx/builder/field-types/encoded.js +18 -0
  249. package/es/tx/builder/field-types/encoded.js.map +1 -0
  250. package/es/tx/builder/field-types/entry.d.ts +5 -6
  251. package/es/tx/builder/field-types/entry.js +26 -0
  252. package/es/tx/builder/field-types/entry.js.map +1 -0
  253. package/es/tx/builder/field-types/enumeration.d.ts +0 -1
  254. package/es/tx/builder/field-types/enumeration.js +27 -0
  255. package/es/tx/builder/field-types/enumeration.js.map +1 -0
  256. package/es/tx/builder/field-types/fee.d.ts +9 -10
  257. package/es/tx/builder/field-types/fee.js +160 -0
  258. package/es/tx/builder/field-types/fee.js.map +1 -0
  259. package/es/tx/builder/field-types/field.d.ts +0 -1
  260. package/es/tx/builder/field-types/field.js +10 -0
  261. package/es/tx/builder/field-types/field.js.map +1 -0
  262. package/es/tx/builder/field-types/gas-limit.d.ts +4 -5
  263. package/es/tx/builder/field-types/gas-limit.js +31 -0
  264. package/es/tx/builder/field-types/gas-limit.js.map +1 -0
  265. package/es/tx/builder/field-types/gas-price.d.ts +7 -8
  266. package/es/tx/builder/field-types/gas-price.js +53 -0
  267. package/es/tx/builder/field-types/gas-price.js.map +1 -0
  268. package/es/tx/builder/field-types/interface.d.ts +7 -0
  269. package/es/tx/builder/field-types/interface.js +2 -0
  270. package/es/tx/builder/field-types/interface.js.map +1 -0
  271. package/es/tx/builder/field-types/map.d.ts +6 -7
  272. package/es/tx/builder/field-types/map.js +38 -0
  273. package/es/tx/builder/field-types/map.js.map +1 -0
  274. package/es/tx/builder/field-types/mptree.d.ts +12 -13
  275. package/es/tx/builder/field-types/mptree.js +223 -0
  276. package/es/tx/builder/field-types/mptree.js.map +1 -0
  277. package/es/tx/builder/field-types/name-fee.d.ts +3 -4
  278. package/es/tx/builder/field-types/name-fee.js +22 -0
  279. package/es/tx/builder/field-types/name-fee.js.map +1 -0
  280. package/es/tx/builder/field-types/name-id.d.ts +2 -3
  281. package/es/tx/builder/field-types/name-id.js +14 -0
  282. package/es/tx/builder/field-types/name-id.js.map +1 -0
  283. package/es/tx/builder/field-types/name.d.ts +1 -2
  284. package/es/tx/builder/field-types/name.js +16 -0
  285. package/es/tx/builder/field-types/name.js.map +1 -0
  286. package/es/tx/builder/field-types/nonce.d.ts +6 -4
  287. package/es/tx/builder/field-types/nonce.js +40 -0
  288. package/es/tx/builder/field-types/nonce.js.map +1 -0
  289. package/es/tx/builder/field-types/pointers.d.ts +9 -18
  290. package/es/tx/builder/field-types/pointers.js +69 -0
  291. package/es/tx/builder/field-types/pointers.js.map +1 -0
  292. package/es/tx/builder/field-types/query-fee.d.ts +4 -5
  293. package/es/tx/builder/field-types/query-fee.js +21 -0
  294. package/es/tx/builder/field-types/query-fee.js.map +1 -0
  295. package/es/tx/builder/field-types/raw.d.ts +0 -1
  296. package/es/tx/builder/field-types/raw.js +10 -0
  297. package/es/tx/builder/field-types/raw.js.map +1 -0
  298. package/es/tx/builder/field-types/short-u-int-const.d.ts +0 -1
  299. package/es/tx/builder/field-types/short-u-int-const.js +20 -0
  300. package/es/tx/builder/field-types/short-u-int-const.js.map +1 -0
  301. package/es/tx/builder/field-types/short-u-int.d.ts +0 -1
  302. package/es/tx/builder/field-types/short-u-int.js +10 -0
  303. package/es/tx/builder/field-types/short-u-int.js.map +1 -0
  304. package/es/tx/builder/field-types/string.d.ts +0 -1
  305. package/es/tx/builder/field-types/string.js +10 -0
  306. package/es/tx/builder/field-types/string.js.map +1 -0
  307. package/es/tx/builder/field-types/transaction.d.ts +10 -0
  308. package/es/tx/builder/field-types/transaction.js +26 -0
  309. package/es/tx/builder/field-types/transaction.js.map +1 -0
  310. package/es/tx/builder/field-types/ttl.d.ts +6 -11
  311. package/es/tx/builder/field-types/ttl.js +33 -0
  312. package/es/tx/builder/field-types/ttl.js.map +1 -0
  313. package/es/tx/builder/field-types/u-int.d.ts +1 -2
  314. package/es/tx/builder/field-types/u-int.js +13 -0
  315. package/es/tx/builder/field-types/u-int.js.map +1 -0
  316. package/es/tx/builder/field-types/with-default.js +9 -0
  317. package/es/tx/builder/field-types/with-default.js.map +1 -0
  318. package/es/tx/builder/field-types/with-formatting.js +9 -0
  319. package/es/tx/builder/field-types/with-formatting.js.map +1 -0
  320. package/es/tx/builder/field-types/wrapped.d.ts +5 -6
  321. package/es/tx/builder/field-types/wrapped.js +20 -0
  322. package/es/tx/builder/field-types/wrapped.js.map +1 -0
  323. package/es/tx/builder/helpers.d.ts +5 -6
  324. package/es/tx/builder/helpers.js +207 -0
  325. package/es/tx/builder/helpers.js.map +1 -0
  326. package/es/tx/builder/index.d.ts +4 -13
  327. package/es/tx/builder/index.js +91 -0
  328. package/es/tx/builder/index.js.map +1 -0
  329. package/es/tx/builder/schema.d.ts +583 -1723
  330. package/es/tx/builder/schema.generated.d.ts +36 -992
  331. package/es/tx/builder/schema.generated.js +2 -0
  332. package/es/tx/builder/schema.generated.js.map +1 -0
  333. package/es/tx/builder/schema.js +355 -0
  334. package/es/tx/builder/schema.js.map +1 -0
  335. package/es/tx/execution-cost.d.ts +2 -2
  336. package/es/tx/execution-cost.js +140 -0
  337. package/es/tx/execution-cost.js.map +1 -0
  338. package/es/tx/transaction-signer.d.ts +1 -1
  339. package/es/tx/transaction-signer.js +24 -0
  340. package/es/tx/transaction-signer.js.map +1 -0
  341. package/es/tx/validator.d.ts +2 -2
  342. package/es/tx/validator.js +206 -0
  343. package/es/tx/validator.js.map +1 -0
  344. package/es/typings/blakejs/index.d.js +2 -0
  345. package/es/typings/blakejs/index.d.js.map +1 -0
  346. package/es/typings/sha-js/index.d.js +2 -0
  347. package/es/typings/sha-js/index.d.js.map +1 -0
  348. package/es/typings/tweetnacl-auth/index.d.js +2 -0
  349. package/es/typings/tweetnacl-auth/index.d.js.map +1 -0
  350. package/es/utils/MiddlewarePage.d.ts +36 -0
  351. package/es/utils/MiddlewarePage.js +57 -0
  352. package/es/utils/MiddlewarePage.js.map +1 -0
  353. package/es/utils/amount-formatter.d.ts +6 -6
  354. package/es/utils/amount-formatter.js +97 -0
  355. package/es/utils/amount-formatter.js.map +1 -0
  356. package/es/utils/autorest.d.ts +6 -1
  357. package/es/utils/autorest.js +206 -0
  358. package/es/utils/autorest.js.map +1 -0
  359. package/es/utils/bignumber.d.ts +1 -1
  360. package/es/utils/bignumber.js +21 -0
  361. package/es/utils/bignumber.js.map +1 -0
  362. package/es/utils/bytes.d.ts +1 -2
  363. package/es/utils/bytes.js +30 -0
  364. package/es/utils/bytes.js.map +1 -0
  365. package/es/utils/crypto.d.ts +2 -46
  366. package/es/utils/crypto.js +111 -0
  367. package/es/utils/crypto.js.map +1 -0
  368. package/es/utils/encoder-types.d.ts +2 -0
  369. package/es/utils/encoder-types.js +36 -0
  370. package/es/utils/encoder-types.js.map +1 -0
  371. package/es/utils/encoder.d.ts +2 -3
  372. package/es/utils/encoder.js +104 -0
  373. package/es/utils/encoder.js.map +1 -0
  374. package/es/utils/errors.d.ts +4 -10
  375. package/es/utils/errors.js +746 -0
  376. package/es/utils/errors.js.map +1 -0
  377. package/es/utils/json-big.d.ts +1 -1
  378. package/es/utils/json-big.js +25 -0
  379. package/es/utils/json-big.js.map +1 -0
  380. package/es/utils/jwt.d.ts +2 -2
  381. package/es/utils/jwt.js +112 -0
  382. package/es/utils/jwt.js.map +1 -0
  383. package/es/utils/other.d.ts +4 -4
  384. package/es/utils/other.js +48 -0
  385. package/es/utils/other.js.map +1 -0
  386. package/es/utils/semver-satisfies.js +12 -0
  387. package/es/utils/semver-satisfies.js.map +1 -0
  388. package/es/utils/string.js +18 -0
  389. package/es/utils/string.js.map +1 -0
  390. package/es/utils/typed-data.d.ts +1 -2
  391. package/es/utils/typed-data.js +52 -0
  392. package/es/utils/typed-data.js.map +1 -0
  393. package/es/utils/wrap-proxy.js +15 -0
  394. package/es/utils/wrap-proxy.js.map +1 -0
  395. package/package.json +85 -105
  396. package/bin/aesophia_cli_8 +0 -0
  397. package/dist/aepp-sdk.browser-script.js +0 -3
  398. package/dist/aepp-sdk.browser-script.js.LICENSE.txt +0 -12
  399. package/dist/aepp-sdk.browser-script.js.map +0 -1
  400. package/dist/aepp-sdk.browser.js +0 -3
  401. package/dist/aepp-sdk.browser.js.map +0 -1
  402. package/dist/aepp-sdk.js +0 -30474
  403. package/dist/aepp-sdk.js.map +0 -1
  404. package/es/AeSdk.mjs +0 -76
  405. package/es/AeSdk.mjs.map +0 -1
  406. package/es/AeSdkAepp.mjs +0 -145
  407. package/es/AeSdkAepp.mjs.map +0 -1
  408. package/es/AeSdkBase.mjs +0 -289
  409. package/es/AeSdkBase.mjs.map +0 -1
  410. package/es/AeSdkMethods.mjs +0 -92
  411. package/es/AeSdkMethods.mjs.map +0 -1
  412. package/es/AeSdkWallet.mjs +0 -365
  413. package/es/AeSdkWallet.mjs.map +0 -1
  414. package/es/Middleware.mjs +0 -94
  415. package/es/Middleware.mjs.map +0 -1
  416. package/es/MiddlewareSubscriber.mjs +0 -189
  417. package/es/MiddlewareSubscriber.mjs.map +0 -1
  418. package/es/Node.mjs +0 -148
  419. package/es/Node.mjs.map +0 -1
  420. package/es/account/Base.mjs +0 -134
  421. package/es/account/Base.mjs.map +0 -1
  422. package/es/account/Generalized.mjs +0 -129
  423. package/es/account/Generalized.mjs.map +0 -1
  424. package/es/account/Ledger.mjs +0 -131
  425. package/es/account/Ledger.mjs.map +0 -1
  426. package/es/account/LedgerFactory.mjs +0 -79
  427. package/es/account/LedgerFactory.mjs.map +0 -1
  428. package/es/account/Memory.mjs +0 -187
  429. package/es/account/Memory.mjs.map +0 -1
  430. package/es/account/Rpc.mjs +0 -178
  431. package/es/account/Rpc.mjs.map +0 -1
  432. package/es/aens.mjs +0 -290
  433. package/es/aens.mjs.map +0 -1
  434. package/es/aepp-wallet-communication/connection/Browser.mjs +0 -52
  435. package/es/aepp-wallet-communication/connection/Browser.mjs.map +0 -1
  436. package/es/aepp-wallet-communication/connection/BrowserRuntime.mjs +0 -55
  437. package/es/aepp-wallet-communication/connection/BrowserRuntime.mjs.map +0 -1
  438. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.mjs +0 -98
  439. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.mjs.map +0 -1
  440. package/es/aepp-wallet-communication/connection-proxy.mjs +0 -17
  441. package/es/aepp-wallet-communication/connection-proxy.mjs.map +0 -1
  442. package/es/aepp-wallet-communication/rpc/RpcClient.mjs +0 -134
  443. package/es/aepp-wallet-communication/rpc/RpcClient.mjs.map +0 -1
  444. package/es/aepp-wallet-communication/rpc/types.mjs +0 -3
  445. package/es/aepp-wallet-communication/rpc/types.mjs.map +0 -1
  446. package/es/aepp-wallet-communication/schema.mjs +0 -187
  447. package/es/aepp-wallet-communication/schema.mjs.map +0 -1
  448. package/es/aepp-wallet-communication/wallet-detector.mjs +0 -44
  449. package/es/aepp-wallet-communication/wallet-detector.mjs.map +0 -1
  450. package/es/apis/compiler/compiler.mjs +0 -513
  451. package/es/apis/compiler/compiler.mjs.map +0 -1
  452. package/es/apis/compiler/index.mjs +0 -3
  453. package/es/apis/compiler/index.mjs.map +0 -1
  454. package/es/apis/compiler/models/index.mjs +0 -2
  455. package/es/apis/compiler/models/index.mjs.map +0 -1
  456. package/es/apis/compiler/models/mappers.mjs +0 -554
  457. package/es/apis/compiler/models/mappers.mjs.map +0 -1
  458. package/es/apis/compiler/models/parameters.mjs +0 -67
  459. package/es/apis/compiler/models/parameters.mjs.map +0 -1
  460. package/es/apis/middleware/index.mjs +0 -3
  461. package/es/apis/middleware/index.mjs.map +0 -1
  462. package/es/apis/middleware/middleware.mjs +0 -1623
  463. package/es/apis/middleware/middleware.mjs.map +0 -1
  464. package/es/apis/middleware/models/index.mjs +0 -630
  465. package/es/apis/middleware/models/index.mjs.map +0 -1
  466. package/es/apis/middleware/models/mappers.mjs +0 -3707
  467. package/es/apis/middleware/models/mappers.mjs.map +0 -1
  468. package/es/apis/middleware/models/parameters.mjs +0 -444
  469. package/es/apis/middleware/models/parameters.mjs.map +0 -1
  470. package/es/apis/node/index.mjs +0 -3
  471. package/es/apis/node/index.mjs.map +0 -1
  472. package/es/apis/node/models/index.mjs +0 -2
  473. package/es/apis/node/models/index.mjs.map +0 -1
  474. package/es/apis/node/models/mappers.mjs +0 -4395
  475. package/es/apis/node/models/mappers.mjs.map +0 -1
  476. package/es/apis/node/models/parameters.mjs +0 -165
  477. package/es/apis/node/models/parameters.mjs.map +0 -1
  478. package/es/apis/node/node.mjs +0 -1240
  479. package/es/apis/node/node.mjs.map +0 -1
  480. package/es/chain.mjs +0 -441
  481. package/es/chain.mjs.map +0 -1
  482. package/es/channel/Base.mjs +0 -254
  483. package/es/channel/Base.mjs.map +0 -1
  484. package/es/channel/Contract.mjs +0 -383
  485. package/es/channel/Contract.mjs.map +0 -1
  486. package/es/channel/Spend.mjs +0 -357
  487. package/es/channel/Spend.mjs.map +0 -1
  488. package/es/channel/handlers.mjs +0 -383
  489. package/es/channel/handlers.mjs.map +0 -1
  490. package/es/channel/internal.mjs +0 -237
  491. package/es/channel/internal.mjs.map +0 -1
  492. package/es/contract/Contract.mjs +0 -540
  493. package/es/contract/Contract.mjs.map +0 -1
  494. package/es/contract/compiler/Base.mjs +0 -5
  495. package/es/contract/compiler/Base.mjs.map +0 -1
  496. package/es/contract/compiler/Cli.mjs +0 -197
  497. package/es/contract/compiler/Cli.mjs.map +0 -1
  498. package/es/contract/compiler/Cli8.d.ts +0 -13
  499. package/es/contract/compiler/Cli8.mjs +0 -22
  500. package/es/contract/compiler/Cli8.mjs.map +0 -1
  501. package/es/contract/compiler/Http.mjs +0 -126
  502. package/es/contract/compiler/Http.mjs.map +0 -1
  503. package/es/contract/compiler/HttpNode.mjs +0 -31
  504. package/es/contract/compiler/HttpNode.mjs.map +0 -1
  505. package/es/contract/compiler/getFileSystem.mjs +0 -40
  506. package/es/contract/compiler/getFileSystem.mjs.map +0 -1
  507. package/es/contract/delegation-signature.d.ts +0 -45
  508. package/es/contract/delegation-signature.mjs +0 -80
  509. package/es/contract/delegation-signature.mjs.map +0 -1
  510. package/es/contract/ga.mjs +0 -135
  511. package/es/contract/ga.mjs.map +0 -1
  512. package/es/deprecated.d.ts +0 -62
  513. package/es/deprecated.mjs +0 -87
  514. package/es/deprecated.mjs.map +0 -1
  515. package/es/index-browser.mjs +0 -49
  516. package/es/index-browser.mjs.map +0 -1
  517. package/es/index.mjs +0 -6
  518. package/es/index.mjs.map +0 -1
  519. package/es/oracle.d.ts +0 -125
  520. package/es/oracle.mjs +0 -242
  521. package/es/oracle.mjs.map +0 -1
  522. package/es/send-transaction.mjs +0 -109
  523. package/es/send-transaction.mjs.map +0 -1
  524. package/es/spend.mjs +0 -90
  525. package/es/spend.mjs.map +0 -1
  526. package/es/tx/builder/SchemaTypes.mjs +0 -2
  527. package/es/tx/builder/SchemaTypes.mjs.map +0 -1
  528. package/es/tx/builder/common.mjs +0 -42
  529. package/es/tx/builder/common.mjs.map +0 -1
  530. package/es/tx/builder/constants.mjs +0 -147
  531. package/es/tx/builder/constants.mjs.map +0 -1
  532. package/es/tx/builder/delegation/index.mjs +0 -24
  533. package/es/tx/builder/delegation/index.mjs.map +0 -1
  534. package/es/tx/builder/delegation/schema.generated.mjs +0 -2
  535. package/es/tx/builder/delegation/schema.generated.mjs.map +0 -1
  536. package/es/tx/builder/delegation/schema.mjs +0 -54
  537. package/es/tx/builder/delegation/schema.mjs.map +0 -1
  538. package/es/tx/builder/field-types/abi-version.mjs +0 -37
  539. package/es/tx/builder/field-types/abi-version.mjs.map +0 -1
  540. package/es/tx/builder/field-types/address.mjs +0 -48
  541. package/es/tx/builder/field-types/address.mjs.map +0 -1
  542. package/es/tx/builder/field-types/array.mjs +0 -11
  543. package/es/tx/builder/field-types/array.mjs.map +0 -1
  544. package/es/tx/builder/field-types/boolean.mjs +0 -13
  545. package/es/tx/builder/field-types/boolean.mjs.map +0 -1
  546. package/es/tx/builder/field-types/coin-amount.mjs +0 -18
  547. package/es/tx/builder/field-types/coin-amount.mjs.map +0 -1
  548. package/es/tx/builder/field-types/ct-version.mjs +0 -75
  549. package/es/tx/builder/field-types/ct-version.mjs.map +0 -1
  550. package/es/tx/builder/field-types/encoded.mjs +0 -21
  551. package/es/tx/builder/field-types/encoded.mjs.map +0 -1
  552. package/es/tx/builder/field-types/entry.mjs +0 -29
  553. package/es/tx/builder/field-types/entry.mjs.map +0 -1
  554. package/es/tx/builder/field-types/enumeration.mjs +0 -30
  555. package/es/tx/builder/field-types/enumeration.mjs.map +0 -1
  556. package/es/tx/builder/field-types/fee.mjs +0 -160
  557. package/es/tx/builder/field-types/fee.mjs.map +0 -1
  558. package/es/tx/builder/field-types/field.mjs +0 -13
  559. package/es/tx/builder/field-types/field.mjs.map +0 -1
  560. package/es/tx/builder/field-types/gas-limit.mjs +0 -31
  561. package/es/tx/builder/field-types/gas-limit.mjs.map +0 -1
  562. package/es/tx/builder/field-types/gas-price.mjs +0 -60
  563. package/es/tx/builder/field-types/gas-price.mjs.map +0 -1
  564. package/es/tx/builder/field-types/index.d.ts +0 -39
  565. package/es/tx/builder/field-types/index.mjs +0 -32
  566. package/es/tx/builder/field-types/index.mjs.map +0 -1
  567. package/es/tx/builder/field-types/map.mjs +0 -38
  568. package/es/tx/builder/field-types/map.mjs.map +0 -1
  569. package/es/tx/builder/field-types/mptree.mjs +0 -251
  570. package/es/tx/builder/field-types/mptree.mjs.map +0 -1
  571. package/es/tx/builder/field-types/name-fee.mjs +0 -22
  572. package/es/tx/builder/field-types/name-fee.mjs.map +0 -1
  573. package/es/tx/builder/field-types/name-id.mjs +0 -14
  574. package/es/tx/builder/field-types/name-id.mjs.map +0 -1
  575. package/es/tx/builder/field-types/name.mjs +0 -16
  576. package/es/tx/builder/field-types/name.mjs.map +0 -1
  577. package/es/tx/builder/field-types/nonce.mjs +0 -31
  578. package/es/tx/builder/field-types/nonce.mjs.map +0 -1
  579. package/es/tx/builder/field-types/pointers.mjs +0 -33
  580. package/es/tx/builder/field-types/pointers.mjs.map +0 -1
  581. package/es/tx/builder/field-types/pointers2.d.ts +0 -23
  582. package/es/tx/builder/field-types/pointers2.mjs +0 -65
  583. package/es/tx/builder/field-types/pointers2.mjs.map +0 -1
  584. package/es/tx/builder/field-types/query-fee.mjs +0 -20
  585. package/es/tx/builder/field-types/query-fee.mjs.map +0 -1
  586. package/es/tx/builder/field-types/raw.mjs +0 -13
  587. package/es/tx/builder/field-types/raw.mjs.map +0 -1
  588. package/es/tx/builder/field-types/short-u-int-const.mjs +0 -20
  589. package/es/tx/builder/field-types/short-u-int-const.mjs.map +0 -1
  590. package/es/tx/builder/field-types/short-u-int.mjs +0 -10
  591. package/es/tx/builder/field-types/short-u-int.mjs.map +0 -1
  592. package/es/tx/builder/field-types/string.mjs +0 -10
  593. package/es/tx/builder/field-types/string.mjs.map +0 -1
  594. package/es/tx/builder/field-types/ttl.mjs +0 -32
  595. package/es/tx/builder/field-types/ttl.mjs.map +0 -1
  596. package/es/tx/builder/field-types/u-int.mjs +0 -13
  597. package/es/tx/builder/field-types/u-int.mjs.map +0 -1
  598. package/es/tx/builder/field-types/with-default.mjs +0 -9
  599. package/es/tx/builder/field-types/with-default.mjs.map +0 -1
  600. package/es/tx/builder/field-types/with-formatting.mjs +0 -9
  601. package/es/tx/builder/field-types/with-formatting.mjs.map +0 -1
  602. package/es/tx/builder/field-types/wrapped.mjs +0 -20
  603. package/es/tx/builder/field-types/wrapped.mjs.map +0 -1
  604. package/es/tx/builder/helpers.mjs +0 -200
  605. package/es/tx/builder/helpers.mjs.map +0 -1
  606. package/es/tx/builder/index.mjs +0 -98
  607. package/es/tx/builder/index.mjs.map +0 -1
  608. package/es/tx/builder/schema.generated.mjs +0 -2
  609. package/es/tx/builder/schema.generated.mjs.map +0 -1
  610. package/es/tx/builder/schema.mjs +0 -513
  611. package/es/tx/builder/schema.mjs.map +0 -1
  612. package/es/tx/execution-cost.mjs +0 -139
  613. package/es/tx/execution-cost.mjs.map +0 -1
  614. package/es/tx/transaction-signer.mjs +0 -24
  615. package/es/tx/transaction-signer.mjs.map +0 -1
  616. package/es/tx/validator.mjs +0 -214
  617. package/es/tx/validator.mjs.map +0 -1
  618. package/es/typings/@aeternity__uuid/index.d.mjs +0 -2
  619. package/es/typings/@aeternity__uuid/index.d.mjs.map +0 -1
  620. package/es/typings/bip32-path/index.d.mjs +0 -2
  621. package/es/typings/bip32-path/index.d.mjs.map +0 -1
  622. package/es/typings/blakejs/index.d.mjs +0 -2
  623. package/es/typings/blakejs/index.d.mjs.map +0 -1
  624. package/es/typings/sha-js/index.d.mjs +0 -2
  625. package/es/typings/sha-js/index.d.mjs.map +0 -1
  626. package/es/typings/tweetnacl-auth/index.d.mjs +0 -2
  627. package/es/typings/tweetnacl-auth/index.d.mjs.map +0 -1
  628. package/es/utils/amount-formatter.mjs +0 -97
  629. package/es/utils/amount-formatter.mjs.map +0 -1
  630. package/es/utils/autorest.mjs +0 -141
  631. package/es/utils/autorest.mjs.map +0 -1
  632. package/es/utils/bignumber.mjs +0 -21
  633. package/es/utils/bignumber.mjs.map +0 -1
  634. package/es/utils/bytes.mjs +0 -32
  635. package/es/utils/bytes.mjs.map +0 -1
  636. package/es/utils/crypto.mjs +0 -193
  637. package/es/utils/crypto.mjs.map +0 -1
  638. package/es/utils/encoder-types.mjs +0 -35
  639. package/es/utils/encoder-types.mjs.map +0 -1
  640. package/es/utils/encoder.mjs +0 -110
  641. package/es/utils/encoder.mjs.map +0 -1
  642. package/es/utils/errors.mjs +0 -756
  643. package/es/utils/errors.mjs.map +0 -1
  644. package/es/utils/hd-wallet.d.ts +0 -60
  645. package/es/utils/hd-wallet.mjs +0 -169
  646. package/es/utils/hd-wallet.mjs.map +0 -1
  647. package/es/utils/json-big.mjs +0 -25
  648. package/es/utils/json-big.mjs.map +0 -1
  649. package/es/utils/jwt.mjs +0 -120
  650. package/es/utils/jwt.mjs.map +0 -1
  651. package/es/utils/keystore.d.ts +0 -57
  652. package/es/utils/keystore.mjs +0 -140
  653. package/es/utils/keystore.mjs.map +0 -1
  654. package/es/utils/other.mjs +0 -49
  655. package/es/utils/other.mjs.map +0 -1
  656. package/es/utils/semver-satisfies.mjs +0 -12
  657. package/es/utils/semver-satisfies.mjs.map +0 -1
  658. package/es/utils/string.mjs +0 -18
  659. package/es/utils/string.mjs.map +0 -1
  660. package/es/utils/typed-data.mjs +0 -55
  661. package/es/utils/typed-data.mjs.map +0 -1
  662. package/es/utils/wrap-proxy.mjs +0 -15
  663. package/es/utils/wrap-proxy.mjs.map +0 -1
  664. package/src/AeSdk.ts +0 -75
  665. package/src/AeSdkAepp.ts +0 -179
  666. package/src/AeSdkBase.ts +0 -315
  667. package/src/AeSdkMethods.ts +0 -149
  668. package/src/AeSdkWallet.ts +0 -382
  669. package/src/Middleware.ts +0 -149
  670. package/src/MiddlewareSubscriber.ts +0 -207
  671. package/src/Node.ts +0 -213
  672. package/src/account/Base.ts +0 -224
  673. package/src/account/Generalized.ts +0 -113
  674. package/src/account/Ledger.ts +0 -161
  675. package/src/account/LedgerFactory.ts +0 -86
  676. package/src/account/Memory.ts +0 -218
  677. package/src/account/Rpc.ts +0 -170
  678. package/src/aens.ts +0 -372
  679. package/src/aepp-wallet-communication/connection/Browser.ts +0 -54
  680. package/src/aepp-wallet-communication/connection/BrowserRuntime.ts +0 -57
  681. package/src/aepp-wallet-communication/connection/BrowserWindowMessage.ts +0 -105
  682. package/src/aepp-wallet-communication/connection-proxy.ts +0 -19
  683. package/src/aepp-wallet-communication/rpc/RpcClient.ts +0 -153
  684. package/src/aepp-wallet-communication/rpc/types.ts +0 -115
  685. package/src/aepp-wallet-communication/schema.ts +0 -212
  686. package/src/aepp-wallet-communication/wallet-detector.ts +0 -54
  687. package/src/apis/compiler/compiler.ts +0 -527
  688. package/src/apis/compiler/index.ts +0 -2
  689. package/src/apis/compiler/models/index.ts +0 -236
  690. package/src/apis/compiler/models/mappers.ts +0 -555
  691. package/src/apis/compiler/models/parameters.ts +0 -87
  692. package/src/apis/middleware/index.ts +0 -2
  693. package/src/apis/middleware/middleware.ts +0 -1928
  694. package/src/apis/middleware/models/index.ts +0 -1949
  695. package/src/apis/middleware/models/mappers.ts +0 -3808
  696. package/src/apis/middleware/models/parameters.ts +0 -493
  697. package/src/apis/node/index.ts +0 -2
  698. package/src/apis/node/models/index.ts +0 -1335
  699. package/src/apis/node/models/mappers.ts +0 -4508
  700. package/src/apis/node/models/parameters.ts +0 -188
  701. package/src/apis/node/node.ts +0 -1420
  702. package/src/chain.ts +0 -433
  703. package/src/channel/Base.ts +0 -302
  704. package/src/channel/Contract.ts +0 -465
  705. package/src/channel/Spend.ts +0 -385
  706. package/src/channel/handlers.ts +0 -386
  707. package/src/channel/internal.ts +0 -454
  708. package/src/contract/Contract.ts +0 -629
  709. package/src/contract/compiler/Base.ts +0 -123
  710. package/src/contract/compiler/Cli.ts +0 -173
  711. package/src/contract/compiler/Cli8.ts +0 -17
  712. package/src/contract/compiler/Http.ts +0 -134
  713. package/src/contract/compiler/HttpNode.ts +0 -32
  714. package/src/contract/compiler/getFileSystem.ts +0 -42
  715. package/src/contract/delegation-signature.ts +0 -88
  716. package/src/contract/ga.ts +0 -138
  717. package/src/deprecated.ts +0 -77
  718. package/src/index-browser.ts +0 -121
  719. package/src/index.ts +0 -6
  720. package/src/oracle.ts +0 -311
  721. package/src/send-transaction.ts +0 -136
  722. package/src/spend.ts +0 -136
  723. package/src/tx/builder/SchemaTypes.ts +0 -79
  724. package/src/tx/builder/common.ts +0 -74
  725. package/src/tx/builder/constants.ts +0 -155
  726. package/src/tx/builder/delegation/index.ts +0 -28
  727. package/src/tx/builder/delegation/schema.generated.ts +0 -143
  728. package/src/tx/builder/delegation/schema.ts +0 -61
  729. package/src/tx/builder/field-types/abi-version.ts +0 -44
  730. package/src/tx/builder/field-types/address.ts +0 -62
  731. package/src/tx/builder/field-types/array.ts +0 -19
  732. package/src/tx/builder/field-types/boolean.ts +0 -9
  733. package/src/tx/builder/field-types/coin-amount.ts +0 -26
  734. package/src/tx/builder/field-types/ct-version.ts +0 -83
  735. package/src/tx/builder/field-types/encoded.ts +0 -27
  736. package/src/tx/builder/field-types/entry.ts +0 -33
  737. package/src/tx/builder/field-types/enumeration.ts +0 -32
  738. package/src/tx/builder/field-types/fee.ts +0 -191
  739. package/src/tx/builder/field-types/field.ts +0 -9
  740. package/src/tx/builder/field-types/gas-limit.ts +0 -46
  741. package/src/tx/builder/field-types/gas-price.ts +0 -67
  742. package/src/tx/builder/field-types/index.ts +0 -40
  743. package/src/tx/builder/field-types/map.ts +0 -45
  744. package/src/tx/builder/field-types/mptree.ts +0 -243
  745. package/src/tx/builder/field-types/name-fee.ts +0 -32
  746. package/src/tx/builder/field-types/name-id.ts +0 -17
  747. package/src/tx/builder/field-types/name.ts +0 -18
  748. package/src/tx/builder/field-types/nonce.ts +0 -46
  749. package/src/tx/builder/field-types/pointers.ts +0 -41
  750. package/src/tx/builder/field-types/pointers2.ts +0 -62
  751. package/src/tx/builder/field-types/query-fee.ts +0 -25
  752. package/src/tx/builder/field-types/raw.ts +0 -9
  753. package/src/tx/builder/field-types/short-u-int-const.ts +0 -30
  754. package/src/tx/builder/field-types/short-u-int.ts +0 -11
  755. package/src/tx/builder/field-types/string.ts +0 -11
  756. package/src/tx/builder/field-types/ttl.ts +0 -34
  757. package/src/tx/builder/field-types/u-int.ts +0 -15
  758. package/src/tx/builder/field-types/with-default.ts +0 -18
  759. package/src/tx/builder/field-types/with-formatting.ts +0 -18
  760. package/src/tx/builder/field-types/wrapped.ts +0 -32
  761. package/src/tx/builder/helpers.ts +0 -243
  762. package/src/tx/builder/index.ts +0 -123
  763. package/src/tx/builder/schema.generated.ts +0 -2049
  764. package/src/tx/builder/schema.ts +0 -612
  765. package/src/tx/execution-cost.ts +0 -164
  766. package/src/tx/transaction-signer.ts +0 -27
  767. package/src/tx/validator.ts +0 -222
  768. package/src/typings/@aeternity__uuid/index.d.ts +0 -5
  769. package/src/typings/bip32-path/index.d.ts +0 -33
  770. package/src/typings/blakejs/index.d.ts +0 -5
  771. package/src/typings/sha-js/index.d.ts +0 -5
  772. package/src/typings/tweetnacl-auth/index.d.ts +0 -14
  773. package/src/utils/amount-formatter.ts +0 -98
  774. package/src/utils/autorest.ts +0 -153
  775. package/src/utils/bignumber.ts +0 -21
  776. package/src/utils/bytes.ts +0 -28
  777. package/src/utils/crypto.ts +0 -216
  778. package/src/utils/encoder-types.ts +0 -63
  779. package/src/utils/encoder.ts +0 -145
  780. package/src/utils/errors.ts +0 -777
  781. package/src/utils/hd-wallet.ts +0 -189
  782. package/src/utils/json-big.ts +0 -27
  783. package/src/utils/jwt.ts +0 -126
  784. package/src/utils/keystore.ts +0 -189
  785. package/src/utils/other.ts +0 -64
  786. package/src/utils/semver-satisfies.ts +0 -22
  787. package/src/utils/string.ts +0 -17
  788. package/src/utils/typed-data.ts +0 -69
  789. package/src/utils/wrap-proxy.ts +0 -24
  790. package/types-legacy/ts4.2/AeSdk.d.ts +0 -44
  791. package/types-legacy/ts4.2/AeSdkAepp.d.ts +0 -71
  792. package/types-legacy/ts4.2/AeSdkBase.d.ts +0 -164
  793. package/types-legacy/ts4.2/AeSdkMethods.d.ts +0 -146
  794. package/types-legacy/ts4.2/AeSdkWallet.d.ts +0 -90
  795. package/types-legacy/ts4.2/Middleware.d.ts +0 -46
  796. package/types-legacy/ts4.2/MiddlewareSubscriber.d.ts +0 -30
  797. package/types-legacy/ts4.2/Node.d.ts +0 -95
  798. package/types-legacy/ts4.2/account/Base.d.ts +0 -147
  799. package/types-legacy/ts4.2/account/Generalized.d.ts +0 -22
  800. package/types-legacy/ts4.2/account/Ledger.d.ts +0 -34
  801. package/types-legacy/ts4.2/account/LedgerFactory.d.ts +0 -39
  802. package/types-legacy/ts4.2/account/Memory.d.ts +0 -46
  803. package/types-legacy/ts4.2/account/Rpc.d.ts +0 -35
  804. package/types-legacy/ts4.2/aens.d.ts +0 -193
  805. package/types-legacy/ts4.2/aepp-wallet-communication/connection/Browser.d.ts +0 -33
  806. package/types-legacy/ts4.2/aepp-wallet-communication/connection/BrowserRuntime.d.ts +0 -22
  807. package/types-legacy/ts4.2/aepp-wallet-communication/connection/BrowserWindowMessage.d.ts +0 -36
  808. package/types-legacy/ts4.2/aepp-wallet-communication/connection-proxy.d.ts +0 -11
  809. package/types-legacy/ts4.2/aepp-wallet-communication/rpc/RpcClient.d.ts +0 -34
  810. package/types-legacy/ts4.2/aepp-wallet-communication/rpc/types.d.ts +0 -120
  811. package/types-legacy/ts4.2/aepp-wallet-communication/schema.d.ts +0 -129
  812. package/types-legacy/ts4.2/aepp-wallet-communication/wallet-detector.d.ts +0 -22
  813. package/types-legacy/ts4.2/apis/compiler/compiler.d.ts +0 -86
  814. package/types-legacy/ts4.2/apis/compiler/index.d.ts +0 -2
  815. package/types-legacy/ts4.2/apis/compiler/models/index.d.ts +0 -191
  816. package/types-legacy/ts4.2/apis/compiler/models/mappers.d.ts +0 -22
  817. package/types-legacy/ts4.2/apis/compiler/models/parameters.d.ts +0 -12
  818. package/types-legacy/ts4.2/apis/middleware/index.d.ts +0 -2
  819. package/types-legacy/ts4.2/apis/middleware/middleware.d.ts +0 -327
  820. package/types-legacy/ts4.2/apis/middleware/models/index.d.ts +0 -1645
  821. package/types-legacy/ts4.2/apis/middleware/models/mappers.d.ts +0 -109
  822. package/types-legacy/ts4.2/apis/middleware/models/parameters.d.ts +0 -46
  823. package/types-legacy/ts4.2/apis/node/index.d.ts +0 -2
  824. package/types-legacy/ts4.2/apis/node/models/index.d.ts +0 -1129
  825. package/types-legacy/ts4.2/apis/node/models/mappers.d.ts +0 -99
  826. package/types-legacy/ts4.2/apis/node/models/parameters.d.ts +0 -17
  827. package/types-legacy/ts4.2/apis/node/node.d.ts +0 -236
  828. package/types-legacy/ts4.2/chain.d.ts +0 -227
  829. package/types-legacy/ts4.2/channel/Base.d.ts +0 -168
  830. package/types-legacy/ts4.2/channel/Contract.d.ts +0 -239
  831. package/types-legacy/ts4.2/channel/Spend.d.ts +0 -213
  832. package/types-legacy/ts4.2/channel/handlers.d.ts +0 -21
  833. package/types-legacy/ts4.2/channel/internal.d.ts +0 -226
  834. package/types-legacy/ts4.2/contract/Contract.d.ts +0 -164
  835. package/types-legacy/ts4.2/contract/compiler/Base.d.ts +0 -104
  836. package/types-legacy/ts4.2/contract/compiler/Cli.d.ts +0 -26
  837. package/types-legacy/ts4.2/contract/compiler/Cli8.d.ts +0 -13
  838. package/types-legacy/ts4.2/contract/compiler/Http.d.ts +0 -28
  839. package/types-legacy/ts4.2/contract/compiler/HttpNode.d.ts +0 -15
  840. package/types-legacy/ts4.2/contract/compiler/getFileSystem.d.ts +0 -6
  841. package/types-legacy/ts4.2/contract/delegation-signature.d.ts +0 -45
  842. package/types-legacy/ts4.2/contract/ga.d.ts +0 -59
  843. package/types-legacy/ts4.2/deprecated.d.ts +0 -62
  844. package/types-legacy/ts4.2/globals.d.ts +0 -16
  845. package/types-legacy/ts4.2/index-browser.d.ts +0 -51
  846. package/types-legacy/ts4.2/index.d.ts +0 -6
  847. package/types-legacy/ts4.2/oracle.d.ts +0 -125
  848. package/types-legacy/ts4.2/send-transaction.d.ts +0 -53
  849. package/types-legacy/ts4.2/spend.d.ts +0 -56
  850. package/types-legacy/ts4.2/tx/builder/SchemaTypes.d.ts +0 -37
  851. package/types-legacy/ts4.2/tx/builder/common.d.ts +0 -32
  852. package/types-legacy/ts4.2/tx/builder/constants.d.ts +0 -100
  853. package/types-legacy/ts4.2/tx/builder/delegation/index.d.ts +0 -20
  854. package/types-legacy/ts4.2/tx/builder/delegation/schema.d.ts +0 -136
  855. package/types-legacy/ts4.2/tx/builder/delegation/schema.generated.d.ts +0 -141
  856. package/types-legacy/ts4.2/tx/builder/field-types/abi-version.d.ts +0 -19
  857. package/types-legacy/ts4.2/tx/builder/field-types/address.d.ts +0 -21
  858. package/types-legacy/ts4.2/tx/builder/field-types/array.d.ts +0 -7
  859. package/types-legacy/ts4.2/tx/builder/field-types/boolean.d.ts +0 -6
  860. package/types-legacy/ts4.2/tx/builder/field-types/coin-amount.d.ts +0 -11
  861. package/types-legacy/ts4.2/tx/builder/field-types/ct-version.d.ts +0 -72
  862. package/types-legacy/ts4.2/tx/builder/field-types/encoded.d.ts +0 -6
  863. package/types-legacy/ts4.2/tx/builder/field-types/entry.d.ts +0 -11
  864. package/types-legacy/ts4.2/tx/builder/field-types/enumeration.d.ts +0 -7
  865. package/types-legacy/ts4.2/tx/builder/field-types/fee.d.ts +0 -30
  866. package/types-legacy/ts4.2/tx/builder/field-types/field.d.ts +0 -6
  867. package/types-legacy/ts4.2/tx/builder/field-types/gas-limit.d.ts +0 -16
  868. package/types-legacy/ts4.2/tx/builder/field-types/gas-price.d.ts +0 -17
  869. package/types-legacy/ts4.2/tx/builder/field-types/index.d.ts +0 -45
  870. package/types-legacy/ts4.2/tx/builder/field-types/map.d.ts +0 -13
  871. package/types-legacy/ts4.2/tx/builder/field-types/mptree.d.ts +0 -48
  872. package/types-legacy/ts4.2/tx/builder/field-types/name-fee.d.ts +0 -18
  873. package/types-legacy/ts4.2/tx/builder/field-types/name-id.d.ts +0 -11
  874. package/types-legacy/ts4.2/tx/builder/field-types/name.d.ts +0 -13
  875. package/types-legacy/ts4.2/tx/builder/field-types/nonce.d.ts +0 -15
  876. package/types-legacy/ts4.2/tx/builder/field-types/pointers.d.ts +0 -26
  877. package/types-legacy/ts4.2/tx/builder/field-types/pointers2.d.ts +0 -26
  878. package/types-legacy/ts4.2/tx/builder/field-types/query-fee.d.ts +0 -19
  879. package/types-legacy/ts4.2/tx/builder/field-types/raw.d.ts +0 -6
  880. package/types-legacy/ts4.2/tx/builder/field-types/short-u-int-const.d.ts +0 -7
  881. package/types-legacy/ts4.2/tx/builder/field-types/short-u-int.d.ts +0 -6
  882. package/types-legacy/ts4.2/tx/builder/field-types/string.d.ts +0 -6
  883. package/types-legacy/ts4.2/tx/builder/field-types/ttl.d.ts +0 -20
  884. package/types-legacy/ts4.2/tx/builder/field-types/u-int.d.ts +0 -7
  885. package/types-legacy/ts4.2/tx/builder/field-types/with-default.d.ts +0 -7
  886. package/types-legacy/ts4.2/tx/builder/field-types/with-formatting.d.ts +0 -7
  887. package/types-legacy/ts4.2/tx/builder/field-types/wrapped.d.ts +0 -14
  888. package/types-legacy/ts4.2/tx/builder/helpers.d.ts +0 -119
  889. package/types-legacy/ts4.2/tx/builder/index.d.ts +0 -62
  890. package/types-legacy/ts4.2/tx/builder/schema.d.ts +0 -3256
  891. package/types-legacy/ts4.2/tx/builder/schema.generated.d.ts +0 -2047
  892. package/types-legacy/ts4.2/tx/execution-cost.d.ts +0 -53
  893. package/types-legacy/ts4.2/tx/transaction-signer.d.ts +0 -6
  894. package/types-legacy/ts4.2/tx/validator.d.ts +0 -18
  895. package/types-legacy/ts4.2/utils/amount-formatter.d.ts +0 -41
  896. package/types-legacy/ts4.2/utils/autorest.d.ts +0 -7
  897. package/types-legacy/ts4.2/utils/bignumber.d.ts +0 -13
  898. package/types-legacy/ts4.2/utils/bytes.d.ts +0 -9
  899. package/types-legacy/ts4.2/utils/crypto.d.ts +0 -100
  900. package/types-legacy/ts4.2/utils/encoder-types.d.ts +0 -61
  901. package/types-legacy/ts4.2/utils/encoder.d.ts +0 -24
  902. package/types-legacy/ts4.2/utils/errors.d.ts +0 -464
  903. package/types-legacy/ts4.2/utils/hd-wallet.d.ts +0 -67
  904. package/types-legacy/ts4.2/utils/json-big.d.ts +0 -5
  905. package/types-legacy/ts4.2/utils/jwt.d.ts +0 -53
  906. package/types-legacy/ts4.2/utils/keystore.d.ts +0 -57
  907. package/types-legacy/ts4.2/utils/other.d.ts +0 -32
  908. package/types-legacy/ts4.2/utils/semver-satisfies.d.ts +0 -1
  909. package/types-legacy/ts4.2/utils/string.d.ts +0 -12
  910. package/types-legacy/ts4.2/utils/typed-data.d.ts +0 -58
  911. package/types-legacy/ts4.2/utils/wrap-proxy.d.ts +0 -2
  912. package/types-legacy/ts4.5/AeSdk.d.ts +0 -44
  913. package/types-legacy/ts4.5/AeSdkAepp.d.ts +0 -71
  914. package/types-legacy/ts4.5/AeSdkBase.d.ts +0 -164
  915. package/types-legacy/ts4.5/AeSdkMethods.d.ts +0 -146
  916. package/types-legacy/ts4.5/AeSdkWallet.d.ts +0 -90
  917. package/types-legacy/ts4.5/Middleware.d.ts +0 -46
  918. package/types-legacy/ts4.5/MiddlewareSubscriber.d.ts +0 -30
  919. package/types-legacy/ts4.5/Node.d.ts +0 -95
  920. package/types-legacy/ts4.5/account/Base.d.ts +0 -147
  921. package/types-legacy/ts4.5/account/Generalized.d.ts +0 -22
  922. package/types-legacy/ts4.5/account/Ledger.d.ts +0 -34
  923. package/types-legacy/ts4.5/account/LedgerFactory.d.ts +0 -39
  924. package/types-legacy/ts4.5/account/Memory.d.ts +0 -46
  925. package/types-legacy/ts4.5/account/Rpc.d.ts +0 -35
  926. package/types-legacy/ts4.5/aens.d.ts +0 -193
  927. package/types-legacy/ts4.5/aepp-wallet-communication/connection/Browser.d.ts +0 -33
  928. package/types-legacy/ts4.5/aepp-wallet-communication/connection/BrowserRuntime.d.ts +0 -22
  929. package/types-legacy/ts4.5/aepp-wallet-communication/connection/BrowserWindowMessage.d.ts +0 -36
  930. package/types-legacy/ts4.5/aepp-wallet-communication/connection-proxy.d.ts +0 -11
  931. package/types-legacy/ts4.5/aepp-wallet-communication/rpc/RpcClient.d.ts +0 -34
  932. package/types-legacy/ts4.5/aepp-wallet-communication/rpc/types.d.ts +0 -120
  933. package/types-legacy/ts4.5/aepp-wallet-communication/schema.d.ts +0 -129
  934. package/types-legacy/ts4.5/aepp-wallet-communication/wallet-detector.d.ts +0 -22
  935. package/types-legacy/ts4.5/apis/compiler/compiler.d.ts +0 -86
  936. package/types-legacy/ts4.5/apis/compiler/index.d.ts +0 -2
  937. package/types-legacy/ts4.5/apis/compiler/models/index.d.ts +0 -191
  938. package/types-legacy/ts4.5/apis/compiler/models/mappers.d.ts +0 -22
  939. package/types-legacy/ts4.5/apis/compiler/models/parameters.d.ts +0 -12
  940. package/types-legacy/ts4.5/apis/middleware/index.d.ts +0 -2
  941. package/types-legacy/ts4.5/apis/middleware/middleware.d.ts +0 -327
  942. package/types-legacy/ts4.5/apis/middleware/models/index.d.ts +0 -1645
  943. package/types-legacy/ts4.5/apis/middleware/models/mappers.d.ts +0 -109
  944. package/types-legacy/ts4.5/apis/middleware/models/parameters.d.ts +0 -46
  945. package/types-legacy/ts4.5/apis/node/index.d.ts +0 -2
  946. package/types-legacy/ts4.5/apis/node/models/index.d.ts +0 -1129
  947. package/types-legacy/ts4.5/apis/node/models/mappers.d.ts +0 -99
  948. package/types-legacy/ts4.5/apis/node/models/parameters.d.ts +0 -17
  949. package/types-legacy/ts4.5/apis/node/node.d.ts +0 -236
  950. package/types-legacy/ts4.5/chain.d.ts +0 -227
  951. package/types-legacy/ts4.5/channel/Base.d.ts +0 -168
  952. package/types-legacy/ts4.5/channel/Contract.d.ts +0 -239
  953. package/types-legacy/ts4.5/channel/Spend.d.ts +0 -213
  954. package/types-legacy/ts4.5/channel/handlers.d.ts +0 -21
  955. package/types-legacy/ts4.5/channel/internal.d.ts +0 -226
  956. package/types-legacy/ts4.5/contract/Contract.d.ts +0 -164
  957. package/types-legacy/ts4.5/contract/compiler/Base.d.ts +0 -104
  958. package/types-legacy/ts4.5/contract/compiler/Cli.d.ts +0 -26
  959. package/types-legacy/ts4.5/contract/compiler/Cli8.d.ts +0 -13
  960. package/types-legacy/ts4.5/contract/compiler/Http.d.ts +0 -28
  961. package/types-legacy/ts4.5/contract/compiler/HttpNode.d.ts +0 -15
  962. package/types-legacy/ts4.5/contract/compiler/getFileSystem.d.ts +0 -6
  963. package/types-legacy/ts4.5/contract/delegation-signature.d.ts +0 -45
  964. package/types-legacy/ts4.5/contract/ga.d.ts +0 -59
  965. package/types-legacy/ts4.5/deprecated.d.ts +0 -62
  966. package/types-legacy/ts4.5/index-browser.d.ts +0 -51
  967. package/types-legacy/ts4.5/index.d.ts +0 -5
  968. package/types-legacy/ts4.5/oracle.d.ts +0 -125
  969. package/types-legacy/ts4.5/send-transaction.d.ts +0 -53
  970. package/types-legacy/ts4.5/spend.d.ts +0 -56
  971. package/types-legacy/ts4.5/tx/builder/SchemaTypes.d.ts +0 -37
  972. package/types-legacy/ts4.5/tx/builder/common.d.ts +0 -32
  973. package/types-legacy/ts4.5/tx/builder/constants.d.ts +0 -100
  974. package/types-legacy/ts4.5/tx/builder/delegation/index.d.ts +0 -20
  975. package/types-legacy/ts4.5/tx/builder/delegation/schema.d.ts +0 -136
  976. package/types-legacy/ts4.5/tx/builder/delegation/schema.generated.d.ts +0 -141
  977. package/types-legacy/ts4.5/tx/builder/field-types/abi-version.d.ts +0 -19
  978. package/types-legacy/ts4.5/tx/builder/field-types/address.d.ts +0 -21
  979. package/types-legacy/ts4.5/tx/builder/field-types/array.d.ts +0 -7
  980. package/types-legacy/ts4.5/tx/builder/field-types/boolean.d.ts +0 -6
  981. package/types-legacy/ts4.5/tx/builder/field-types/coin-amount.d.ts +0 -11
  982. package/types-legacy/ts4.5/tx/builder/field-types/ct-version.d.ts +0 -72
  983. package/types-legacy/ts4.5/tx/builder/field-types/encoded.d.ts +0 -6
  984. package/types-legacy/ts4.5/tx/builder/field-types/entry.d.ts +0 -11
  985. package/types-legacy/ts4.5/tx/builder/field-types/enumeration.d.ts +0 -7
  986. package/types-legacy/ts4.5/tx/builder/field-types/fee.d.ts +0 -30
  987. package/types-legacy/ts4.5/tx/builder/field-types/field.d.ts +0 -6
  988. package/types-legacy/ts4.5/tx/builder/field-types/gas-limit.d.ts +0 -16
  989. package/types-legacy/ts4.5/tx/builder/field-types/gas-price.d.ts +0 -17
  990. package/types-legacy/ts4.5/tx/builder/field-types/index.d.ts +0 -45
  991. package/types-legacy/ts4.5/tx/builder/field-types/map.d.ts +0 -13
  992. package/types-legacy/ts4.5/tx/builder/field-types/mptree.d.ts +0 -48
  993. package/types-legacy/ts4.5/tx/builder/field-types/name-fee.d.ts +0 -18
  994. package/types-legacy/ts4.5/tx/builder/field-types/name-id.d.ts +0 -11
  995. package/types-legacy/ts4.5/tx/builder/field-types/name.d.ts +0 -13
  996. package/types-legacy/ts4.5/tx/builder/field-types/nonce.d.ts +0 -15
  997. package/types-legacy/ts4.5/tx/builder/field-types/pointers.d.ts +0 -26
  998. package/types-legacy/ts4.5/tx/builder/field-types/pointers2.d.ts +0 -26
  999. package/types-legacy/ts4.5/tx/builder/field-types/query-fee.d.ts +0 -19
  1000. package/types-legacy/ts4.5/tx/builder/field-types/raw.d.ts +0 -6
  1001. package/types-legacy/ts4.5/tx/builder/field-types/short-u-int-const.d.ts +0 -7
  1002. package/types-legacy/ts4.5/tx/builder/field-types/short-u-int.d.ts +0 -6
  1003. package/types-legacy/ts4.5/tx/builder/field-types/string.d.ts +0 -6
  1004. package/types-legacy/ts4.5/tx/builder/field-types/ttl.d.ts +0 -20
  1005. package/types-legacy/ts4.5/tx/builder/field-types/u-int.d.ts +0 -7
  1006. package/types-legacy/ts4.5/tx/builder/field-types/with-default.d.ts +0 -7
  1007. package/types-legacy/ts4.5/tx/builder/field-types/with-formatting.d.ts +0 -7
  1008. package/types-legacy/ts4.5/tx/builder/field-types/wrapped.d.ts +0 -14
  1009. package/types-legacy/ts4.5/tx/builder/helpers.d.ts +0 -119
  1010. package/types-legacy/ts4.5/tx/builder/index.d.ts +0 -62
  1011. package/types-legacy/ts4.5/tx/builder/schema.d.ts +0 -3256
  1012. package/types-legacy/ts4.5/tx/builder/schema.generated.d.ts +0 -2047
  1013. package/types-legacy/ts4.5/tx/execution-cost.d.ts +0 -53
  1014. package/types-legacy/ts4.5/tx/transaction-signer.d.ts +0 -6
  1015. package/types-legacy/ts4.5/tx/validator.d.ts +0 -18
  1016. package/types-legacy/ts4.5/utils/amount-formatter.d.ts +0 -41
  1017. package/types-legacy/ts4.5/utils/autorest.d.ts +0 -7
  1018. package/types-legacy/ts4.5/utils/bignumber.d.ts +0 -13
  1019. package/types-legacy/ts4.5/utils/bytes.d.ts +0 -9
  1020. package/types-legacy/ts4.5/utils/crypto.d.ts +0 -100
  1021. package/types-legacy/ts4.5/utils/encoder-types.d.ts +0 -61
  1022. package/types-legacy/ts4.5/utils/encoder.d.ts +0 -24
  1023. package/types-legacy/ts4.5/utils/errors.d.ts +0 -464
  1024. package/types-legacy/ts4.5/utils/hd-wallet.d.ts +0 -67
  1025. package/types-legacy/ts4.5/utils/json-big.d.ts +0 -5
  1026. package/types-legacy/ts4.5/utils/jwt.d.ts +0 -53
  1027. package/types-legacy/ts4.5/utils/keystore.d.ts +0 -57
  1028. package/types-legacy/ts4.5/utils/other.d.ts +0 -32
  1029. package/types-legacy/ts4.5/utils/semver-satisfies.d.ts +0 -1
  1030. package/types-legacy/ts4.5/utils/string.d.ts +0 -12
  1031. package/types-legacy/ts4.5/utils/typed-data.d.ts +0 -58
  1032. package/types-legacy/ts4.5/utils/wrap-proxy.d.ts +0 -2
  1033. /package/dist/{aepp-sdk.browser.js.LICENSE.txt → aepp-sdk.browser.cjs.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"file":"aepp-sdk.browser.js","mappings":";CAAA,SAA2CA,EAAMC,GAC1B,iBAAZC,SAA0C,iBAAXC,OAC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ACJ5H,KAAM,YACNkoC,UACE,kFACFC,gBAAiB,IACZghC,GACAvhE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB+qC,GACX,CACEtrE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,qFACFC,gBAAiB,IACZihC,GACAxhE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBgrC,GACX,CACEvrE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,oGACFC,gBAAiB,IACZshC,GACA7hE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBirC,GACX,CACExrE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,gEACFC,gBAAiB,IACZwhC,GACA/hE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBkrC,GACX,CACEzrE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,wFACFC,gBAAiB,IACZogC,GAAkB3gE,KAAKugC,mBACvB8hC,GACAriE,KAAKugC,mBAKHmrC,GACX,CACE1rE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,8FACFC,gBAAiB,IACZmiC,GACA1iE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBorC,GACX,CACE3rE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,+EACFC,gBAAiB,IACZwiC,GACA/iE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBqrC,GACX,CACE5rE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,6EACFC,gBAAiB,IACZyiC,GACAhjE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBsrC,GACX,CACE7rE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,gFACFC,gBAAiB,IACZ0iC,GACAjjE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBurC,GACX,CACE9rE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,iEACFC,gBAAiB,IACZgjC,GACAvjE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBwrC,GACX,CACE/rE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,oEACFC,gBAAiB,IACZmjC,GACA1jE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrByrC,GACX,CACEhsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,0EACFC,gBAAiB,IACZwjC,GACA/jE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB0rC,GACX,CACEjsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,wEACFC,gBAAiB,IACZ6jC,GACApkE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB2rC,GACX,CACElsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,qEACFC,gBAAiB,IACZukC,GACA9kE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB4rC,GACX,CACEnsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,qEACFC,gBAAiB,IACZklC,GACAzlE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB6rC,GACX,CACEpsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,wFACFC,gBAAiB,IACZmlC,GACA1lE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB8rC,GACX,CACErsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,6EACFC,gBAAiB,IACZulC,GACA9lE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrB+rC,GACX,CACEtsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,gEACFC,gBAAiB,IACZwlC,GACA/lE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBgsC,GACX,CACEvsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,sEACFC,gBAAiB,IACZ0mC,GACAjnE,KAAKugC,mBACLogC,GAAkB3gE,KAAKugC,mBAKrBisC,GACX,CACExsE,KAAM,CACJ5H,KAAM,YACNkoC,UACE,kEACFC,gBAAiB,IACZinC,GACAxnE,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GAKbE,GAAa,CAAEh2E,KAAM60B,GAAiB2D,MAAO7qC,MAAO,KAKpDsoF,GAAY,CAAEj2E,KAAM60B,GAAiB2D,MAAO7qC,MAAO,IAKnDuoF,GAAe,CAAEl2E,KAAM60B,GAAiB2D,MAAO7qC,MAAO","sources":["webpack://Aeternity/webpack/universalModuleDefinition","webpack://Aeternity/./node_modules/blakejs/blake2b.js","webpack://Aeternity/./node_modules/blakejs/util.js","webpack://Aeternity/./node_modules/inherits/inherits_browser.js","webpack://Aeternity/./node_modules/safe-buffer/index.js","webpack://Aeternity/./node_modules/sha.js/hash.js","webpack://Aeternity/./node_modules/sha.js/sha256.js","webpack://Aeternity/external umd \"@aeternity/aepp-calldata\"","webpack://Aeternity/external umd \"@aeternity/argon2\"","webpack://Aeternity/external umd \"@aeternity/uuid\"","webpack://Aeternity/external umd \"@azure/core-client\"","webpack://Aeternity/external umd \"@azure/core-rest-pipeline\"","webpack://Aeternity/external umd \"aes-js\"","webpack://Aeternity/external umd \"bignumber.js\"","webpack://Aeternity/external umd \"bip32-path\"","webpack://Aeternity/external umd \"bs58\"","webpack://Aeternity/external umd \"buffer\"","webpack://Aeternity/external umd \"canonicalize\"","webpack://Aeternity/external umd \"events\"","webpack://Aeternity/external umd \"isomorphic-ws\"","webpack://Aeternity/external umd \"json-bigint\"","webpack://Aeternity/external umd \"rlp\"","webpack://Aeternity/external umd \"tweetnacl\"","webpack://Aeternity/external umd \"tweetnacl-auth\"","webpack://Aeternity/external umd \"varuint-bitcoin\"","webpack://Aeternity/external umd \"websocket\"","webpack://Aeternity/./node_modules/core-js-pure/actual/object/define-property.js","webpack://Aeternity/./node_modules/core-js-pure/actual/symbol/index.js","webpack://Aeternity/./node_modules/core-js-pure/actual/symbol/iterator.js","webpack://Aeternity/./node_modules/core-js-pure/actual/symbol/to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/es/object/define-property.js","webpack://Aeternity/./node_modules/core-js-pure/es/symbol/index.js","webpack://Aeternity/./node_modules/core-js-pure/es/symbol/iterator.js","webpack://Aeternity/./node_modules/core-js-pure/es/symbol/to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/full/object/define-property.js","webpack://Aeternity/./node_modules/core-js-pure/full/symbol/index.js","webpack://Aeternity/./node_modules/core-js-pure/full/symbol/iterator.js","webpack://Aeternity/./node_modules/core-js-pure/full/symbol/to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/internals/a-callable.js","webpack://Aeternity/./node_modules/core-js-pure/internals/a-possible-prototype.js","webpack://Aeternity/./node_modules/core-js-pure/internals/add-to-unscopables.js","webpack://Aeternity/./node_modules/core-js-pure/internals/an-object.js","webpack://Aeternity/./node_modules/core-js-pure/internals/array-includes.js","webpack://Aeternity/./node_modules/core-js-pure/internals/array-iteration.js","webpack://Aeternity/./node_modules/core-js-pure/internals/array-method-has-species-support.js","webpack://Aeternity/./node_modules/core-js-pure/internals/array-slice.js","webpack://Aeternity/./node_modules/core-js-pure/internals/array-species-constructor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/array-species-create.js","webpack://Aeternity/./node_modules/core-js-pure/internals/classof-raw.js","webpack://Aeternity/./node_modules/core-js-pure/internals/classof.js","webpack://Aeternity/./node_modules/core-js-pure/internals/correct-prototype-getter.js","webpack://Aeternity/./node_modules/core-js-pure/internals/create-iter-result-object.js","webpack://Aeternity/./node_modules/core-js-pure/internals/create-non-enumerable-property.js","webpack://Aeternity/./node_modules/core-js-pure/internals/create-property-descriptor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/create-property.js","webpack://Aeternity/./node_modules/core-js-pure/internals/define-built-in-accessor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/define-built-in.js","webpack://Aeternity/./node_modules/core-js-pure/internals/define-global-property.js","webpack://Aeternity/./node_modules/core-js-pure/internals/descriptors.js","webpack://Aeternity/./node_modules/core-js-pure/internals/document-create-element.js","webpack://Aeternity/./node_modules/core-js-pure/internals/does-not-exceed-safe-integer.js","webpack://Aeternity/./node_modules/core-js-pure/internals/dom-iterables.js","webpack://Aeternity/./node_modules/core-js-pure/internals/engine-user-agent.js","webpack://Aeternity/./node_modules/core-js-pure/internals/engine-v8-version.js","webpack://Aeternity/./node_modules/core-js-pure/internals/enum-bug-keys.js","webpack://Aeternity/./node_modules/core-js-pure/internals/export.js","webpack://Aeternity/./node_modules/core-js-pure/internals/fails.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-apply.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-bind-context.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-bind-native.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-call.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-name.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-uncurry-this-accessor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-uncurry-this-clause.js","webpack://Aeternity/./node_modules/core-js-pure/internals/function-uncurry-this.js","webpack://Aeternity/./node_modules/core-js-pure/internals/get-built-in.js","webpack://Aeternity/./node_modules/core-js-pure/internals/get-json-replacer-function.js","webpack://Aeternity/./node_modules/core-js-pure/internals/get-method.js","webpack://Aeternity/./node_modules/core-js-pure/internals/global.js","webpack://Aeternity/./node_modules/core-js-pure/internals/has-own-property.js","webpack://Aeternity/./node_modules/core-js-pure/internals/hidden-keys.js","webpack://Aeternity/./node_modules/core-js-pure/internals/html.js","webpack://Aeternity/./node_modules/core-js-pure/internals/ie8-dom-define.js","webpack://Aeternity/./node_modules/core-js-pure/internals/indexed-object.js","webpack://Aeternity/./node_modules/core-js-pure/internals/inspect-source.js","webpack://Aeternity/./node_modules/core-js-pure/internals/internal-state.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-array.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-callable.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-constructor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-forced.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-null-or-undefined.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-object.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-possible-prototype.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-pure.js","webpack://Aeternity/./node_modules/core-js-pure/internals/is-symbol.js","webpack://Aeternity/./node_modules/core-js-pure/internals/iterator-create-constructor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/iterator-define.js","webpack://Aeternity/./node_modules/core-js-pure/internals/iterators-core.js","webpack://Aeternity/./node_modules/core-js-pure/internals/iterators.js","webpack://Aeternity/./node_modules/core-js-pure/internals/length-of-array-like.js","webpack://Aeternity/./node_modules/core-js-pure/internals/math-trunc.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-create.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-define-properties.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-define-property.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-get-own-property-descriptor.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-get-own-property-names-external.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-get-own-property-names.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-get-own-property-symbols.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-get-prototype-of.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-is-prototype-of.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-keys-internal.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-keys.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-property-is-enumerable.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-set-prototype-of.js","webpack://Aeternity/./node_modules/core-js-pure/internals/object-to-string.js","webpack://Aeternity/./node_modules/core-js-pure/internals/ordinary-to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/internals/path.js","webpack://Aeternity/./node_modules/core-js-pure/internals/require-object-coercible.js","webpack://Aeternity/./node_modules/core-js-pure/internals/set-to-string-tag.js","webpack://Aeternity/./node_modules/core-js-pure/internals/shared-key.js","webpack://Aeternity/./node_modules/core-js-pure/internals/shared-store.js","webpack://Aeternity/./node_modules/core-js-pure/internals/shared.js","webpack://Aeternity/./node_modules/core-js-pure/internals/string-multibyte.js","webpack://Aeternity/./node_modules/core-js-pure/internals/symbol-constructor-detection.js","webpack://Aeternity/./node_modules/core-js-pure/internals/symbol-define-to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/internals/symbol-is-registered.js","webpack://Aeternity/./node_modules/core-js-pure/internals/symbol-is-well-known.js","webpack://Aeternity/./node_modules/core-js-pure/internals/symbol-registry-detection.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-absolute-index.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-indexed-object.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-integer-or-infinity.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-length.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-object.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-property-key.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-string-tag-support.js","webpack://Aeternity/./node_modules/core-js-pure/internals/to-string.js","webpack://Aeternity/./node_modules/core-js-pure/internals/try-to-string.js","webpack://Aeternity/./node_modules/core-js-pure/internals/uid.js","webpack://Aeternity/./node_modules/core-js-pure/internals/use-symbol-as-uid.js","webpack://Aeternity/./node_modules/core-js-pure/internals/v8-prototype-define-bug.js","webpack://Aeternity/./node_modules/core-js-pure/internals/weak-map-basic-detection.js","webpack://Aeternity/./node_modules/core-js-pure/internals/well-known-symbol-define.js","webpack://Aeternity/./node_modules/core-js-pure/internals/well-known-symbol-wrapped.js","webpack://Aeternity/./node_modules/core-js-pure/internals/well-known-symbol.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.array.concat.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.array.iterator.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.json.stringify.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.json.to-string-tag.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.object.define-property.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.object.get-own-property-symbols.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.string.iterator.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.async-iterator.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.constructor.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.for.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.has-instance.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.is-concat-spreadable.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.iterator.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.key-for.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.match-all.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.match.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.replace.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.search.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.species.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.split.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.to-primitive.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.to-string-tag.js","webpack://Aeternity/./node_modules/core-js-pure/modules/es.symbol.unscopables.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.function.metadata.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.async-dispose.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.dispose.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.is-registered-symbol.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.is-registered.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.is-well-known-symbol.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.is-well-known.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.matcher.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.metadata-key.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.metadata.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.observable.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.pattern-match.js","webpack://Aeternity/./node_modules/core-js-pure/modules/esnext.symbol.replace-all.js","webpack://Aeternity/./node_modules/core-js-pure/modules/web.dom-collections.iterator.js","webpack://Aeternity/./node_modules/core-js-pure/stable/object/define-property.js","webpack://Aeternity/./node_modules/core-js-pure/stable/symbol/index.js","webpack://Aeternity/./node_modules/core-js-pure/stable/symbol/iterator.js","webpack://Aeternity/./node_modules/core-js-pure/stable/symbol/to-primitive.js","webpack://Aeternity/webpack/bootstrap","webpack://Aeternity/webpack/runtime/compat get default export","webpack://Aeternity/webpack/runtime/define property getters","webpack://Aeternity/webpack/runtime/global","webpack://Aeternity/webpack/runtime/hasOwnProperty shorthand","webpack://Aeternity/webpack/runtime/make namespace object","webpack://Aeternity/./src/utils/bignumber.ts","webpack://Aeternity/./src/utils/errors.ts","webpack://Aeternity/./src/utils/amount-formatter.ts","webpack://Aeternity/./src/utils/other.ts","webpack://Aeternity/./src/utils/wrap-proxy.ts","webpack://Aeternity/./src/utils/encoder-types.ts","webpack://Aeternity/./src/utils/encoder.ts","webpack://Aeternity/./src/utils/crypto.ts","webpack://Aeternity/./src/utils/bytes.ts","webpack://Aeternity/./src/tx/builder/constants.ts","webpack://Aeternity/./src/tx/builder/helpers.ts","webpack://Aeternity/./src/chain.ts","webpack://Aeternity/./src/tx/builder/field-types/ct-version.ts","webpack://Aeternity/./src/tx/builder/field-types/entry.ts","webpack://Aeternity/./src/tx/builder/field-types/array.ts","webpack://Aeternity/./src/tx/builder/field-types/map.ts","webpack://Aeternity/./src/tx/builder/field-types/with-default.ts","webpack://Aeternity/./src/tx/builder/field-types/u-int.ts","webpack://Aeternity/./src/tx/builder/field-types/short-u-int.ts","webpack://Aeternity/./src/tx/builder/field-types/with-formatting.ts","webpack://Aeternity/./src/tx/builder/field-types/short-u-int-const.ts","webpack://Aeternity/./src/tx/builder/field-types/address.ts","webpack://Aeternity/./src/tx/builder/field-types/encoded.ts","webpack://Aeternity/./src/tx/builder/field-types/raw.ts","webpack://Aeternity/./src/tx/builder/field-types/coin-amount.ts","webpack://Aeternity/./src/utils/semver-satisfies.ts","webpack://Aeternity/./src/tx/builder/field-types/gas-price.ts","webpack://Aeternity/./src/tx/builder/field-types/fee.ts","webpack://Aeternity/./src/tx/builder/field-types/ttl.ts","webpack://Aeternity/./src/tx/builder/field-types/nonce.ts","webpack://Aeternity/./src/tx/builder/field-types/pointers.ts","webpack://Aeternity/./src/tx/builder/field-types/field.ts","webpack://Aeternity/./src/tx/builder/field-types/name.ts","webpack://Aeternity/./src/tx/builder/field-types/name-fee.ts","webpack://Aeternity/./src/tx/builder/field-types/name-id.ts","webpack://Aeternity/./src/tx/builder/field-types/pointers2.ts","webpack://Aeternity/./src/tx/builder/field-types/boolean.ts","webpack://Aeternity/./src/tx/builder/field-types/gas-limit.ts","webpack://Aeternity/./src/tx/builder/field-types/abi-version.ts","webpack://Aeternity/./src/tx/builder/field-types/enumeration.ts","webpack://Aeternity/./src/tx/builder/field-types/string.ts","webpack://Aeternity/./src/tx/builder/field-types/query-fee.ts","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/classPrivateFieldGet2.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/assertClassBrand.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/classPrivateFieldSet.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/classApplyDescriptorSet.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/classPrivateFieldGet.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/classApplyDescriptorGet.js","webpack://Aeternity/./src/tx/builder/field-types/mptree.ts","webpack://Aeternity/./src/tx/builder/field-types/wrapped.ts","webpack://Aeternity/./src/tx/builder/schema.ts","webpack://Aeternity/./src/tx/builder/common.ts","webpack://Aeternity/./src/tx/builder/index.ts","webpack://Aeternity/./src/utils/autorest.ts","webpack://Aeternity/./src/apis/node/models/mappers.ts","webpack://Aeternity/./src/apis/node/models/parameters.ts","webpack://Aeternity/./src/apis/node/node.ts","webpack://Aeternity/./src/Node.ts","webpack://Aeternity/./src/tx/transaction-signer.ts","webpack://Aeternity/./src/account/Base.ts","webpack://Aeternity/./src/utils/typed-data.ts","webpack://Aeternity/./src/tx/builder/delegation/schema.ts","webpack://Aeternity/./src/tx/builder/delegation/index.ts","webpack://Aeternity/./src/account/Memory.ts","webpack://Aeternity/./src/tx/execution-cost.ts","webpack://Aeternity/./src/tx/validator.ts","webpack://Aeternity/./src/send-transaction.ts","webpack://Aeternity/./src/utils/jwt.ts","webpack://Aeternity/./src/utils/keystore.ts","webpack://Aeternity/./src/utils/hd-wallet.ts","webpack://Aeternity/./src/aens.ts","webpack://Aeternity/./src/contract/Contract.ts","webpack://Aeternity/./src/oracle.ts","webpack://Aeternity/./src/spend.ts","webpack://Aeternity/./src/contract/ga.ts","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/typeof.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/defineProperty.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/toPropertyKey.js","webpack://Aeternity/./node_modules/@babel/runtime-corejs3/helpers/esm/toPrimitive.js","webpack://Aeternity/./src/AeSdkMethods.ts","webpack://Aeternity/./src/contract/delegation-signature.ts","webpack://Aeternity/./src/AeSdkBase.ts","webpack://Aeternity/./src/AeSdk.ts","webpack://Aeternity/./src/aepp-wallet-communication/schema.ts","webpack://Aeternity/./src/account/Rpc.ts","webpack://Aeternity/./src/aepp-wallet-communication/rpc/RpcClient.ts","webpack://Aeternity/./src/AeSdkAepp.ts","webpack://Aeternity/./src/aepp-wallet-communication/rpc/types.ts","webpack://Aeternity/./src/utils/json-big.ts","webpack://Aeternity/./src/AeSdkWallet.ts","webpack://Aeternity/./src/account/Generalized.ts","webpack://Aeternity/./src/account/Ledger.ts","webpack://Aeternity/./src/account/LedgerFactory.ts","webpack://Aeternity/./src/contract/compiler/Base.ts","webpack://Aeternity/./src/apis/compiler/models/mappers.ts","webpack://Aeternity/./src/apis/compiler/models/parameters.ts","webpack://Aeternity/./src/apis/compiler/compiler.ts","webpack://Aeternity/./src/contract/compiler/Http.ts","webpack://Aeternity/./src/utils/string.ts","webpack://Aeternity/./src/channel/internal.ts","webpack://Aeternity/./src/channel/handlers.ts","webpack://Aeternity/./src/channel/Base.ts","webpack://Aeternity/./src/channel/Spend.ts","webpack://Aeternity/./src/channel/Contract.ts","webpack://Aeternity/./src/MiddlewareSubscriber.ts","webpack://Aeternity/./src/apis/middleware/models/parameters.ts","webpack://Aeternity/./src/apis/middleware/models/mappers.ts","webpack://Aeternity/./src/apis/middleware/middleware.ts","webpack://Aeternity/./src/Middleware.ts","webpack://Aeternity/./src/aepp-wallet-communication/connection-proxy.ts","webpack://Aeternity/./src/aepp-wallet-communication/connection/Browser.ts","webpack://Aeternity/./src/aepp-wallet-communication/connection/BrowserWindowMessage.ts","webpack://Aeternity/./src/aepp-wallet-communication/wallet-detector.ts","webpack://Aeternity/./src/aepp-wallet-communication/connection/BrowserRuntime.ts","webpack://Aeternity/./src/deprecated.ts"],"sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory(require(\"bignumber.js\"), require(\"@azure/core-rest-pipeline\"), require(\"buffer\"), require(\"tweetnacl\"), require(\"varuint-bitcoin\"), require(\"bs58\"), require(\"rlp\"), require(\"@azure/core-client\"), require(\"@aeternity/aepp-calldata\"), require(\"canonicalize\"), require(\"@aeternity/uuid\"), require(\"@aeternity/argon2\"), require(\"tweetnacl-auth\"), require(\"bip32-path\"), require(\"aes-js\"), require(\"json-bigint\"), require(\"websocket\"), require(\"events\"), require(\"isomorphic-ws\"));\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([\"bignumber.js\", \"@azure/core-rest-pipeline\", \"buffer\", \"tweetnacl\", \"varuint-bitcoin\", \"bs58\", \"rlp\", \"@azure/core-client\", \"@aeternity/aepp-calldata\", \"canonicalize\", \"@aeternity/uuid\", \"@aeternity/argon2\", \"tweetnacl-auth\", \"bip32-path\", \"aes-js\", \"json-bigint\", \"websocket\", \"events\", \"isomorphic-ws\"], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"Aeternity\"] = factory(require(\"bignumber.js\"), require(\"@azure/core-rest-pipeline\"), require(\"buffer\"), require(\"tweetnacl\"), require(\"varuint-bitcoin\"), require(\"bs58\"), require(\"rlp\"), require(\"@azure/core-client\"), require(\"@aeternity/aepp-calldata\"), require(\"canonicalize\"), require(\"@aeternity/uuid\"), require(\"@aeternity/argon2\"), require(\"tweetnacl-auth\"), require(\"bip32-path\"), require(\"aes-js\"), require(\"json-bigint\"), require(\"websocket\"), require(\"events\"), require(\"isomorphic-ws\"));\n\telse\n\t\troot[\"Aeternity\"] = factory(root[\"bignumber.js\"], root[\"@azure/core-rest-pipeline\"], root[\"buffer\"], root[\"tweetnacl\"], root[\"varuint-bitcoin\"], root[\"bs58\"], root[\"rlp\"], root[\"@azure/core-client\"], root[\"@aeternity/aepp-calldata\"], root[\"canonicalize\"], root[\"@aeternity/uuid\"], root[\"@aeternity/argon2\"], root[\"tweetnacl-auth\"], root[\"bip32-path\"], root[\"aes-js\"], root[\"json-bigint\"], root[\"websocket\"], root[\"events\"], root[\"isomorphic-ws\"]);\n})(self, function(__WEBPACK_EXTERNAL_MODULE__6168__, __WEBPACK_EXTERNAL_MODULE__833__, __WEBPACK_EXTERNAL_MODULE__18__, __WEBPACK_EXTERNAL_MODULE__1655__, __WEBPACK_EXTERNAL_MODULE__4054__, __WEBPACK_EXTERNAL_MODULE__4578__, __WEBPACK_EXTERNAL_MODULE__6514__, __WEBPACK_EXTERNAL_MODULE__1081__, __WEBPACK_EXTERNAL_MODULE__2853__, __WEBPACK_EXTERNAL_MODULE__6016__, __WEBPACK_EXTERNAL_MODULE__1635__, __WEBPACK_EXTERNAL_MODULE__6717__, __WEBPACK_EXTERNAL_MODULE__5196__, __WEBPACK_EXTERNAL_MODULE__5898__, __WEBPACK_EXTERNAL_MODULE__8921__, __WEBPACK_EXTERNAL_MODULE__4146__, __WEBPACK_EXTERNAL_MODULE__8963__, __WEBPACK_EXTERNAL_MODULE__761__, __WEBPACK_EXTERNAL_MODULE__7250__) {\nreturn ","// Blake2B in pure Javascript\n// Adapted from the reference implementation in RFC7693\n// Ported to Javascript by DC - https://github.com/dcposch\n\nconst util = require('./util')\n\n// 64-bit unsigned addition\n// Sets v[a,a+1] += v[b,b+1]\n// v should be a Uint32Array\nfunction ADD64AA (v, a, b) {\n const o0 = v[a] + v[b]\n let o1 = v[a + 1] + v[b + 1]\n if (o0 >= 0x100000000) {\n o1++\n }\n v[a] = o0\n v[a + 1] = o1\n}\n\n// 64-bit unsigned addition\n// Sets v[a,a+1] += b\n// b0 is the low 32 bits of b, b1 represents the high 32 bits\nfunction ADD64AC (v, a, b0, b1) {\n let o0 = v[a] + b0\n if (b0 < 0) {\n o0 += 0x100000000\n }\n let o1 = v[a + 1] + b1\n if (o0 >= 0x100000000) {\n o1++\n }\n v[a] = o0\n v[a + 1] = o1\n}\n\n// Little-endian byte access\nfunction B2B_GET32 (arr, i) {\n return arr[i] ^ (arr[i + 1] << 8) ^ (arr[i + 2] << 16) ^ (arr[i + 3] << 24)\n}\n\n// G Mixing function\n// The ROTRs are inlined for speed\nfunction B2B_G (a, b, c, d, ix, iy) {\n const x0 = m[ix]\n const x1 = m[ix + 1]\n const y0 = m[iy]\n const y1 = m[iy + 1]\n\n ADD64AA(v, a, b) // v[a,a+1] += v[b,b+1] ... in JS we must store a uint64 as two uint32s\n ADD64AC(v, a, x0, x1) // v[a, a+1] += x ... x0 is the low 32 bits of x, x1 is the high 32 bits\n\n // v[d,d+1] = (v[d,d+1] xor v[a,a+1]) rotated to the right by 32 bits\n let xor0 = v[d] ^ v[a]\n let xor1 = v[d + 1] ^ v[a + 1]\n v[d] = xor1\n v[d + 1] = xor0\n\n ADD64AA(v, c, d)\n\n // v[b,b+1] = (v[b,b+1] xor v[c,c+1]) rotated right by 24 bits\n xor0 = v[b] ^ v[c]\n xor1 = v[b + 1] ^ v[c + 1]\n v[b] = (xor0 >>> 24) ^ (xor1 << 8)\n v[b + 1] = (xor1 >>> 24) ^ (xor0 << 8)\n\n ADD64AA(v, a, b)\n ADD64AC(v, a, y0, y1)\n\n // v[d,d+1] = (v[d,d+1] xor v[a,a+1]) rotated right by 16 bits\n xor0 = v[d] ^ v[a]\n xor1 = v[d + 1] ^ v[a + 1]\n v[d] = (xor0 >>> 16) ^ (xor1 << 16)\n v[d + 1] = (xor1 >>> 16) ^ (xor0 << 16)\n\n ADD64AA(v, c, d)\n\n // v[b,b+1] = (v[b,b+1] xor v[c,c+1]) rotated right by 63 bits\n xor0 = v[b] ^ v[c]\n xor1 = v[b + 1] ^ v[c + 1]\n v[b] = (xor1 >>> 31) ^ (xor0 << 1)\n v[b + 1] = (xor0 >>> 31) ^ (xor1 << 1)\n}\n\n// Initialization Vector\nconst BLAKE2B_IV32 = new Uint32Array([\n 0xf3bcc908, 0x6a09e667, 0x84caa73b, 0xbb67ae85, 0xfe94f82b, 0x3c6ef372,\n 0x5f1d36f1, 0xa54ff53a, 0xade682d1, 0x510e527f, 0x2b3e6c1f, 0x9b05688c,\n 0xfb41bd6b, 0x1f83d9ab, 0x137e2179, 0x5be0cd19\n])\n\nconst SIGMA8 = [\n 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 14, 10, 4, 8, 9, 15, 13,\n 6, 1, 12, 0, 2, 11, 7, 5, 3, 11, 8, 12, 0, 5, 2, 15, 13, 10, 14, 3, 6, 7, 1,\n 9, 4, 7, 9, 3, 1, 13, 12, 11, 14, 2, 6, 5, 10, 4, 0, 15, 8, 9, 0, 5, 7, 2, 4,\n 10, 15, 14, 1, 11, 12, 6, 8, 3, 13, 2, 12, 6, 10, 0, 11, 8, 3, 4, 13, 7, 5,\n 15, 14, 1, 9, 12, 5, 1, 15, 14, 13, 4, 10, 0, 7, 6, 3, 9, 2, 8, 11, 13, 11, 7,\n 14, 12, 1, 3, 9, 5, 0, 15, 4, 8, 6, 2, 10, 6, 15, 14, 9, 11, 3, 0, 8, 12, 2,\n 13, 7, 1, 4, 10, 5, 10, 2, 8, 4, 7, 6, 1, 5, 15, 11, 9, 14, 3, 12, 13, 0, 0,\n 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 14, 10, 4, 8, 9, 15, 13, 6,\n 1, 12, 0, 2, 11, 7, 5, 3\n]\n\n// These are offsets into a uint64 buffer.\n// Multiply them all by 2 to make them offsets into a uint32 buffer,\n// because this is Javascript and we don't have uint64s\nconst SIGMA82 = new Uint8Array(\n SIGMA8.map(function (x) {\n return x * 2\n })\n)\n\n// Compression function. 'last' flag indicates last block.\n// Note we're representing 16 uint64s as 32 uint32s\nconst v = new Uint32Array(32)\nconst m = new Uint32Array(32)\nfunction blake2bCompress (ctx, last) {\n let i = 0\n\n // init work variables\n for (i = 0; i < 16; i++) {\n v[i] = ctx.h[i]\n v[i + 16] = BLAKE2B_IV32[i]\n }\n\n // low 64 bits of offset\n v[24] = v[24] ^ ctx.t\n v[25] = v[25] ^ (ctx.t / 0x100000000)\n // high 64 bits not supported, offset may not be higher than 2**53-1\n\n // last block flag set ?\n if (last) {\n v[28] = ~v[28]\n v[29] = ~v[29]\n }\n\n // get little-endian words\n for (i = 0; i < 32; i++) {\n m[i] = B2B_GET32(ctx.b, 4 * i)\n }\n\n // twelve rounds of mixing\n // uncomment the DebugPrint calls to log the computation\n // and match the RFC sample documentation\n // util.debugPrint(' m[16]', m, 64)\n for (i = 0; i < 12; i++) {\n // util.debugPrint(' (i=' + (i < 10 ? ' ' : '') + i + ') v[16]', v, 64)\n B2B_G(0, 8, 16, 24, SIGMA82[i * 16 + 0], SIGMA82[i * 16 + 1])\n B2B_G(2, 10, 18, 26, SIGMA82[i * 16 + 2], SIGMA82[i * 16 + 3])\n B2B_G(4, 12, 20, 28, SIGMA82[i * 16 + 4], SIGMA82[i * 16 + 5])\n B2B_G(6, 14, 22, 30, SIGMA82[i * 16 + 6], SIGMA82[i * 16 + 7])\n B2B_G(0, 10, 20, 30, SIGMA82[i * 16 + 8], SIGMA82[i * 16 + 9])\n B2B_G(2, 12, 22, 24, SIGMA82[i * 16 + 10], SIGMA82[i * 16 + 11])\n B2B_G(4, 14, 16, 26, SIGMA82[i * 16 + 12], SIGMA82[i * 16 + 13])\n B2B_G(6, 8, 18, 28, SIGMA82[i * 16 + 14], SIGMA82[i * 16 + 15])\n }\n // util.debugPrint(' (i=12) v[16]', v, 64)\n\n for (i = 0; i < 16; i++) {\n ctx.h[i] = ctx.h[i] ^ v[i] ^ v[i + 16]\n }\n // util.debugPrint('h[8]', ctx.h, 64)\n}\n\n// reusable parameterBlock\nconst parameterBlock = new Uint8Array([\n 0,\n 0,\n 0,\n 0, // 0: outlen, keylen, fanout, depth\n 0,\n 0,\n 0,\n 0, // 4: leaf length, sequential mode\n 0,\n 0,\n 0,\n 0, // 8: node offset\n 0,\n 0,\n 0,\n 0, // 12: node offset\n 0,\n 0,\n 0,\n 0, // 16: node depth, inner length, rfu\n 0,\n 0,\n 0,\n 0, // 20: rfu\n 0,\n 0,\n 0,\n 0, // 24: rfu\n 0,\n 0,\n 0,\n 0, // 28: rfu\n 0,\n 0,\n 0,\n 0, // 32: salt\n 0,\n 0,\n 0,\n 0, // 36: salt\n 0,\n 0,\n 0,\n 0, // 40: salt\n 0,\n 0,\n 0,\n 0, // 44: salt\n 0,\n 0,\n 0,\n 0, // 48: personal\n 0,\n 0,\n 0,\n 0, // 52: personal\n 0,\n 0,\n 0,\n 0, // 56: personal\n 0,\n 0,\n 0,\n 0 // 60: personal\n])\n\n// Creates a BLAKE2b hashing context\n// Requires an output length between 1 and 64 bytes\n// Takes an optional Uint8Array key\n// Takes an optinal Uint8Array salt\n// Takes an optinal Uint8Array personal\nfunction blake2bInit (outlen, key, salt, personal) {\n if (outlen === 0 || outlen > 64) {\n throw new Error('Illegal output length, expected 0 < length <= 64')\n }\n if (key && key.length > 64) {\n throw new Error('Illegal key, expected Uint8Array with 0 < length <= 64')\n }\n if (salt && salt.length !== 16) {\n throw new Error('Illegal salt, expected Uint8Array with length is 16')\n }\n if (personal && personal.length !== 16) {\n throw new Error('Illegal personal, expected Uint8Array with length is 16')\n }\n\n // state, 'param block'\n const ctx = {\n b: new Uint8Array(128),\n h: new Uint32Array(16),\n t: 0, // input count\n c: 0, // pointer within buffer\n outlen: outlen // output length in bytes\n }\n\n // initialize parameterBlock before usage\n parameterBlock.fill(0)\n parameterBlock[0] = outlen\n if (key) parameterBlock[1] = key.length\n parameterBlock[2] = 1 // fanout\n parameterBlock[3] = 1 // depth\n if (salt) parameterBlock.set(salt, 32)\n if (personal) parameterBlock.set(personal, 48)\n\n // initialize hash state\n for (let i = 0; i < 16; i++) {\n ctx.h[i] = BLAKE2B_IV32[i] ^ B2B_GET32(parameterBlock, i * 4)\n }\n\n // key the hash, if applicable\n if (key) {\n blake2bUpdate(ctx, key)\n // at the end\n ctx.c = 128\n }\n\n return ctx\n}\n\n// Updates a BLAKE2b streaming hash\n// Requires hash context and Uint8Array (byte array)\nfunction blake2bUpdate (ctx, input) {\n for (let i = 0; i < input.length; i++) {\n if (ctx.c === 128) {\n // buffer full ?\n ctx.t += ctx.c // add counters\n blake2bCompress(ctx, false) // compress (not last)\n ctx.c = 0 // counter to zero\n }\n ctx.b[ctx.c++] = input[i]\n }\n}\n\n// Completes a BLAKE2b streaming hash\n// Returns a Uint8Array containing the message digest\nfunction blake2bFinal (ctx) {\n ctx.t += ctx.c // mark last block offset\n\n while (ctx.c < 128) {\n // fill up with zeros\n ctx.b[ctx.c++] = 0\n }\n blake2bCompress(ctx, true) // final block flag = 1\n\n // little endian convert and store\n const out = new Uint8Array(ctx.outlen)\n for (let i = 0; i < ctx.outlen; i++) {\n out[i] = ctx.h[i >> 2] >> (8 * (i & 3))\n }\n return out\n}\n\n// Computes the BLAKE2B hash of a string or byte array, and returns a Uint8Array\n//\n// Returns a n-byte Uint8Array\n//\n// Parameters:\n// - input - the input bytes, as a string, Buffer or Uint8Array\n// - key - optional key Uint8Array, up to 64 bytes\n// - outlen - optional output length in bytes, default 64\n// - salt - optional salt bytes, string, Buffer or Uint8Array\n// - personal - optional personal bytes, string, Buffer or Uint8Array\nfunction blake2b (input, key, outlen, salt, personal) {\n // preprocess inputs\n outlen = outlen || 64\n input = util.normalizeInput(input)\n if (salt) {\n salt = util.normalizeInput(salt)\n }\n if (personal) {\n personal = util.normalizeInput(personal)\n }\n\n // do the math\n const ctx = blake2bInit(outlen, key, salt, personal)\n blake2bUpdate(ctx, input)\n return blake2bFinal(ctx)\n}\n\n// Computes the BLAKE2B hash of a string or byte array\n//\n// Returns an n-byte hash in hex, all lowercase\n//\n// Parameters:\n// - input - the input bytes, as a string, Buffer, or Uint8Array\n// - key - optional key Uint8Array, up to 64 bytes\n// - outlen - optional output length in bytes, default 64\n// - salt - optional salt bytes, string, Buffer or Uint8Array\n// - personal - optional personal bytes, string, Buffer or Uint8Array\nfunction blake2bHex (input, key, outlen, salt, personal) {\n const output = blake2b(input, key, outlen, salt, personal)\n return util.toHex(output)\n}\n\nmodule.exports = {\n blake2b: blake2b,\n blake2bHex: blake2bHex,\n blake2bInit: blake2bInit,\n blake2bUpdate: blake2bUpdate,\n blake2bFinal: blake2bFinal\n}\n","const ERROR_MSG_INPUT = 'Input must be an string, Buffer or Uint8Array'\n\n// For convenience, let people hash a string, not just a Uint8Array\nfunction normalizeInput (input) {\n let ret\n if (input instanceof Uint8Array) {\n ret = input\n } else if (typeof input === 'string') {\n const encoder = new TextEncoder()\n ret = encoder.encode(input)\n } else {\n throw new Error(ERROR_MSG_INPUT)\n }\n return ret\n}\n\n// Converts a Uint8Array to a hexadecimal string\n// For example, toHex([255, 0, 255]) returns \"ff00ff\"\nfunction toHex (bytes) {\n return Array.prototype.map\n .call(bytes, function (n) {\n return (n < 16 ? '0' : '') + n.toString(16)\n })\n .join('')\n}\n\n// Converts any value in [0...2^32-1] to an 8-character hex string\nfunction uint32ToHex (val) {\n return (0x100000000 + val).toString(16).substring(1)\n}\n\n// For debugging: prints out hash state in the same format as the RFC\n// sample computation exactly, so that you can diff\nfunction debugPrint (label, arr, size) {\n let msg = '\\n' + label + ' = '\n for (let i = 0; i < arr.length; i += 2) {\n if (size === 32) {\n msg += uint32ToHex(arr[i]).toUpperCase()\n msg += ' '\n msg += uint32ToHex(arr[i + 1]).toUpperCase()\n } else if (size === 64) {\n msg += uint32ToHex(arr[i + 1]).toUpperCase()\n msg += uint32ToHex(arr[i]).toUpperCase()\n } else throw new Error('Invalid size ' + size)\n if (i % 6 === 4) {\n msg += '\\n' + new Array(label.length + 4).join(' ')\n } else if (i < arr.length - 2) {\n msg += ' '\n }\n }\n console.log(msg)\n}\n\n// For performance testing: generates N bytes of input, hashes M times\n// Measures and prints MB/second hash performance each time\nfunction testSpeed (hashFn, N, M) {\n let startMs = new Date().getTime()\n\n const input = new Uint8Array(N)\n for (let i = 0; i < N; i++) {\n input[i] = i % 256\n }\n const genMs = new Date().getTime()\n console.log('Generated random input in ' + (genMs - startMs) + 'ms')\n startMs = genMs\n\n for (let i = 0; i < M; i++) {\n const hashHex = hashFn(input)\n const hashMs = new Date().getTime()\n const ms = hashMs - startMs\n startMs = hashMs\n console.log('Hashed in ' + ms + 'ms: ' + hashHex.substring(0, 20) + '...')\n console.log(\n Math.round((N / (1 << 20) / (ms / 1000)) * 100) / 100 + ' MB PER SECOND'\n )\n }\n}\n\nmodule.exports = {\n normalizeInput: normalizeInput,\n toHex: toHex,\n debugPrint: debugPrint,\n testSpeed: testSpeed\n}\n","if (typeof Object.create === 'function') {\n // implementation from standard node.js 'util' module\n module.exports = function inherits(ctor, superCtor) {\n if (superCtor) {\n ctor.super_ = superCtor\n ctor.prototype = Object.create(superCtor.prototype, {\n constructor: {\n value: ctor,\n enumerable: false,\n writable: true,\n configurable: true\n }\n })\n }\n };\n} else {\n // old school shim for old browsers\n module.exports = function inherits(ctor, superCtor) {\n if (superCtor) {\n ctor.super_ = superCtor\n var TempCtor = function () {}\n TempCtor.prototype = superCtor.prototype\n ctor.prototype = new TempCtor()\n ctor.prototype.constructor = ctor\n }\n }\n}\n","/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */\n/* eslint-disable node/no-deprecated-api */\nvar buffer = require('buffer')\nvar Buffer = buffer.Buffer\n\n// alternative to using Object.keys for old browsers\nfunction copyProps (src, dst) {\n for (var key in src) {\n dst[key] = src[key]\n }\n}\nif (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) {\n module.exports = buffer\n} else {\n // Copy properties from require('buffer')\n copyProps(buffer, exports)\n exports.Buffer = SafeBuffer\n}\n\nfunction SafeBuffer (arg, encodingOrOffset, length) {\n return Buffer(arg, encodingOrOffset, length)\n}\n\nSafeBuffer.prototype = Object.create(Buffer.prototype)\n\n// Copy static methods from Buffer\ncopyProps(Buffer, SafeBuffer)\n\nSafeBuffer.from = function (arg, encodingOrOffset, length) {\n if (typeof arg === 'number') {\n throw new TypeError('Argument must not be a number')\n }\n return Buffer(arg, encodingOrOffset, length)\n}\n\nSafeBuffer.alloc = function (size, fill, encoding) {\n if (typeof size !== 'number') {\n throw new TypeError('Argument must be a number')\n }\n var buf = Buffer(size)\n if (fill !== undefined) {\n if (typeof encoding === 'string') {\n buf.fill(fill, encoding)\n } else {\n buf.fill(fill)\n }\n } else {\n buf.fill(0)\n }\n return buf\n}\n\nSafeBuffer.allocUnsafe = function (size) {\n if (typeof size !== 'number') {\n throw new TypeError('Argument must be a number')\n }\n return Buffer(size)\n}\n\nSafeBuffer.allocUnsafeSlow = function (size) {\n if (typeof size !== 'number') {\n throw new TypeError('Argument must be a number')\n }\n return buffer.SlowBuffer(size)\n}\n","var Buffer = require('safe-buffer').Buffer\n\n// prototype class for hash functions\nfunction Hash (blockSize, finalSize) {\n this._block = Buffer.alloc(blockSize)\n this._finalSize = finalSize\n this._blockSize = blockSize\n this._len = 0\n}\n\nHash.prototype.update = function (data, enc) {\n if (typeof data === 'string') {\n enc = enc || 'utf8'\n data = Buffer.from(data, enc)\n }\n\n var block = this._block\n var blockSize = this._blockSize\n var length = data.length\n var accum = this._len\n\n for (var offset = 0; offset < length;) {\n var assigned = accum % blockSize\n var remainder = Math.min(length - offset, blockSize - assigned)\n\n for (var i = 0; i < remainder; i++) {\n block[assigned + i] = data[offset + i]\n }\n\n accum += remainder\n offset += remainder\n\n if ((accum % blockSize) === 0) {\n this._update(block)\n }\n }\n\n this._len += length\n return this\n}\n\nHash.prototype.digest = function (enc) {\n var rem = this._len % this._blockSize\n\n this._block[rem] = 0x80\n\n // zero (rem + 1) trailing bits, where (rem + 1) is the smallest\n // non-negative solution to the equation (length + 1 + (rem + 1)) === finalSize mod blockSize\n this._block.fill(0, rem + 1)\n\n if (rem >= this._finalSize) {\n this._update(this._block)\n this._block.fill(0)\n }\n\n var bits = this._len * 8\n\n // uint32\n if (bits <= 0xffffffff) {\n this._block.writeUInt32BE(bits, this._blockSize - 4)\n\n // uint64\n } else {\n var lowBits = (bits & 0xffffffff) >>> 0\n var highBits = (bits - lowBits) / 0x100000000\n\n this._block.writeUInt32BE(highBits, this._blockSize - 8)\n this._block.writeUInt32BE(lowBits, this._blockSize - 4)\n }\n\n this._update(this._block)\n var hash = this._hash()\n\n return enc ? hash.toString(enc) : hash\n}\n\nHash.prototype._update = function () {\n throw new Error('_update must be implemented by subclass')\n}\n\nmodule.exports = Hash\n","/**\n * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined\n * in FIPS 180-2\n * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009.\n * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet\n *\n */\n\nvar inherits = require('inherits')\nvar Hash = require('./hash')\nvar Buffer = require('safe-buffer').Buffer\n\nvar K = [\n 0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5,\n 0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5,\n 0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3,\n 0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174,\n 0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC,\n 0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA,\n 0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7,\n 0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967,\n 0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13,\n 0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85,\n 0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3,\n 0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070,\n 0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5,\n 0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3,\n 0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208,\n 0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2\n]\n\nvar W = new Array(64)\n\nfunction Sha256 () {\n this.init()\n\n this._w = W // new Array(64)\n\n Hash.call(this, 64, 56)\n}\n\ninherits(Sha256, Hash)\n\nSha256.prototype.init = function () {\n this._a = 0x6a09e667\n this._b = 0xbb67ae85\n this._c = 0x3c6ef372\n this._d = 0xa54ff53a\n this._e = 0x510e527f\n this._f = 0x9b05688c\n this._g = 0x1f83d9ab\n this._h = 0x5be0cd19\n\n return this\n}\n\nfunction ch (x, y, z) {\n return z ^ (x & (y ^ z))\n}\n\nfunction maj (x, y, z) {\n return (x & y) | (z & (x | y))\n}\n\nfunction sigma0 (x) {\n return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10)\n}\n\nfunction sigma1 (x) {\n return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7)\n}\n\nfunction gamma0 (x) {\n return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ (x >>> 3)\n}\n\nfunction gamma1 (x) {\n return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ (x >>> 10)\n}\n\nSha256.prototype._update = function (M) {\n var W = this._w\n\n var a = this._a | 0\n var b = this._b | 0\n var c = this._c | 0\n var d = this._d | 0\n var e = this._e | 0\n var f = this._f | 0\n var g = this._g | 0\n var h = this._h | 0\n\n for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4)\n for (; i < 64; ++i) W[i] = (gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16]) | 0\n\n for (var j = 0; j < 64; ++j) {\n var T1 = (h + sigma1(e) + ch(e, f, g) + K[j] + W[j]) | 0\n var T2 = (sigma0(a) + maj(a, b, c)) | 0\n\n h = g\n g = f\n f = e\n e = (d + T1) | 0\n d = c\n c = b\n b = a\n a = (T1 + T2) | 0\n }\n\n this._a = (a + this._a) | 0\n this._b = (b + this._b) | 0\n this._c = (c + this._c) | 0\n this._d = (d + this._d) | 0\n this._e = (e + this._e) | 0\n this._f = (f + this._f) | 0\n this._g = (g + this._g) | 0\n this._h = (h + this._h) | 0\n}\n\nSha256.prototype._hash = function () {\n var H = Buffer.allocUnsafe(32)\n\n H.writeInt32BE(this._a, 0)\n H.writeInt32BE(this._b, 4)\n H.writeInt32BE(this._c, 8)\n H.writeInt32BE(this._d, 12)\n H.writeInt32BE(this._e, 16)\n H.writeInt32BE(this._f, 20)\n H.writeInt32BE(this._g, 24)\n H.writeInt32BE(this._h, 28)\n\n return H\n}\n\nmodule.exports = Sha256\n","module.exports = __WEBPACK_EXTERNAL_MODULE__2853__;","module.exports = __WEBPACK_EXTERNAL_MODULE__6717__;","module.exports = __WEBPACK_EXTERNAL_MODULE__1635__;","module.exports = __WEBPACK_EXTERNAL_MODULE__1081__;","module.exports = __WEBPACK_EXTERNAL_MODULE__833__;","module.exports = __WEBPACK_EXTERNAL_MODULE__8921__;","module.exports = __WEBPACK_EXTERNAL_MODULE__6168__;","module.exports = __WEBPACK_EXTERNAL_MODULE__5898__;","module.exports = __WEBPACK_EXTERNAL_MODULE__4578__;","module.exports = __WEBPACK_EXTERNAL_MODULE__18__;","module.exports = __WEBPACK_EXTERNAL_MODULE__6016__;","module.exports = __WEBPACK_EXTERNAL_MODULE__761__;","module.exports = __WEBPACK_EXTERNAL_MODULE__7250__;","module.exports = __WEBPACK_EXTERNAL_MODULE__4146__;","module.exports = __WEBPACK_EXTERNAL_MODULE__6514__;","module.exports = __WEBPACK_EXTERNAL_MODULE__1655__;","module.exports = __WEBPACK_EXTERNAL_MODULE__5196__;","module.exports = __WEBPACK_EXTERNAL_MODULE__4054__;","module.exports = __WEBPACK_EXTERNAL_MODULE__8963__;","'use strict';\nvar parent = require('../../stable/object/define-property');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../stable/symbol');\n\nrequire('../../modules/esnext.function.metadata');\nrequire('../../modules/esnext.symbol.async-dispose');\nrequire('../../modules/esnext.symbol.dispose');\nrequire('../../modules/esnext.symbol.metadata');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../stable/symbol/iterator');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../stable/symbol/to-primitive');\n\nmodule.exports = parent;\n","'use strict';\nrequire('../../modules/es.object.define-property');\nvar path = require('../../internals/path');\n\nvar Object = path.Object;\n\nvar defineProperty = module.exports = function defineProperty(it, key, desc) {\n return Object.defineProperty(it, key, desc);\n};\n\nif (Object.defineProperty.sham) defineProperty.sham = true;\n","'use strict';\nrequire('../../modules/es.array.concat');\nrequire('../../modules/es.object.to-string');\nrequire('../../modules/es.symbol');\nrequire('../../modules/es.symbol.async-iterator');\nrequire('../../modules/es.symbol.description');\nrequire('../../modules/es.symbol.has-instance');\nrequire('../../modules/es.symbol.is-concat-spreadable');\nrequire('../../modules/es.symbol.iterator');\nrequire('../../modules/es.symbol.match');\nrequire('../../modules/es.symbol.match-all');\nrequire('../../modules/es.symbol.replace');\nrequire('../../modules/es.symbol.search');\nrequire('../../modules/es.symbol.species');\nrequire('../../modules/es.symbol.split');\nrequire('../../modules/es.symbol.to-primitive');\nrequire('../../modules/es.symbol.to-string-tag');\nrequire('../../modules/es.symbol.unscopables');\nrequire('../../modules/es.json.to-string-tag');\nrequire('../../modules/es.math.to-string-tag');\nrequire('../../modules/es.reflect.to-string-tag');\nvar path = require('../../internals/path');\n\nmodule.exports = path.Symbol;\n","'use strict';\nrequire('../../modules/es.array.iterator');\nrequire('../../modules/es.object.to-string');\nrequire('../../modules/es.string.iterator');\nrequire('../../modules/es.symbol.iterator');\nvar WrappedWellKnownSymbolModule = require('../../internals/well-known-symbol-wrapped');\n\nmodule.exports = WrappedWellKnownSymbolModule.f('iterator');\n","'use strict';\nrequire('../../modules/es.date.to-primitive');\nrequire('../../modules/es.symbol.to-primitive');\nvar WrappedWellKnownSymbolModule = require('../../internals/well-known-symbol-wrapped');\n\nmodule.exports = WrappedWellKnownSymbolModule.f('toPrimitive');\n","'use strict';\nvar parent = require('../../actual/object/define-property');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../actual/symbol');\nrequire('../../modules/esnext.symbol.is-registered-symbol');\nrequire('../../modules/esnext.symbol.is-well-known-symbol');\nrequire('../../modules/esnext.symbol.matcher');\nrequire('../../modules/esnext.symbol.observable');\n// TODO: Remove from `core-js@4`\nrequire('../../modules/esnext.symbol.is-registered');\nrequire('../../modules/esnext.symbol.is-well-known');\nrequire('../../modules/esnext.symbol.metadata-key');\nrequire('../../modules/esnext.symbol.pattern-match');\nrequire('../../modules/esnext.symbol.replace-all');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../actual/symbol/iterator');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../actual/symbol/to-primitive');\n\nmodule.exports = parent;\n","'use strict';\nvar isCallable = require('../internals/is-callable');\nvar tryToString = require('../internals/try-to-string');\n\nvar $TypeError = TypeError;\n\n// `Assert: IsCallable(argument) is true`\nmodule.exports = function (argument) {\n if (isCallable(argument)) return argument;\n throw new $TypeError(tryToString(argument) + ' is not a function');\n};\n","'use strict';\nvar isPossiblePrototype = require('../internals/is-possible-prototype');\n\nvar $String = String;\nvar $TypeError = TypeError;\n\nmodule.exports = function (argument) {\n if (isPossiblePrototype(argument)) return argument;\n throw new $TypeError(\"Can't set \" + $String(argument) + ' as a prototype');\n};\n","'use strict';\nmodule.exports = function () { /* empty */ };\n","'use strict';\nvar isObject = require('../internals/is-object');\n\nvar $String = String;\nvar $TypeError = TypeError;\n\n// `Assert: Type(argument) is Object`\nmodule.exports = function (argument) {\n if (isObject(argument)) return argument;\n throw new $TypeError($String(argument) + ' is not an object');\n};\n","'use strict';\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = lengthOfArrayLike(O);\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare -- NaN check\n if (IS_INCLUDES && el !== el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare -- NaN check\n if (value !== value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.es/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.es/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n","'use strict';\nvar bind = require('../internals/function-bind-context');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IndexedObject = require('../internals/indexed-object');\nvar toObject = require('../internals/to-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar arraySpeciesCreate = require('../internals/array-species-create');\n\nvar push = uncurryThis([].push);\n\n// `Array.prototype.{ forEach, map, filter, some, every, find, findIndex, filterReject }` methods implementation\nvar createMethod = function (TYPE) {\n var IS_MAP = TYPE === 1;\n var IS_FILTER = TYPE === 2;\n var IS_SOME = TYPE === 3;\n var IS_EVERY = TYPE === 4;\n var IS_FIND_INDEX = TYPE === 6;\n var IS_FILTER_REJECT = TYPE === 7;\n var NO_HOLES = TYPE === 5 || IS_FIND_INDEX;\n return function ($this, callbackfn, that, specificCreate) {\n var O = toObject($this);\n var self = IndexedObject(O);\n var length = lengthOfArrayLike(self);\n var boundFunction = bind(callbackfn, that);\n var index = 0;\n var create = specificCreate || arraySpeciesCreate;\n var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_REJECT ? create($this, 0) : undefined;\n var value, result;\n for (;length > index; index++) if (NO_HOLES || index in self) {\n value = self[index];\n result = boundFunction(value, index, O);\n if (TYPE) {\n if (IS_MAP) target[index] = result; // map\n else if (result) switch (TYPE) {\n case 3: return true; // some\n case 5: return value; // find\n case 6: return index; // findIndex\n case 2: push(target, value); // filter\n } else switch (TYPE) {\n case 4: return false; // every\n case 7: push(target, value); // filterReject\n }\n }\n }\n return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.forEach` method\n // https://tc39.es/ecma262/#sec-array.prototype.foreach\n forEach: createMethod(0),\n // `Array.prototype.map` method\n // https://tc39.es/ecma262/#sec-array.prototype.map\n map: createMethod(1),\n // `Array.prototype.filter` method\n // https://tc39.es/ecma262/#sec-array.prototype.filter\n filter: createMethod(2),\n // `Array.prototype.some` method\n // https://tc39.es/ecma262/#sec-array.prototype.some\n some: createMethod(3),\n // `Array.prototype.every` method\n // https://tc39.es/ecma262/#sec-array.prototype.every\n every: createMethod(4),\n // `Array.prototype.find` method\n // https://tc39.es/ecma262/#sec-array.prototype.find\n find: createMethod(5),\n // `Array.prototype.findIndex` method\n // https://tc39.es/ecma262/#sec-array.prototype.findIndex\n findIndex: createMethod(6),\n // `Array.prototype.filterReject` method\n // https://github.com/tc39/proposal-array-filtering\n filterReject: createMethod(7)\n};\n","'use strict';\nvar fails = require('../internals/fails');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (METHOD_NAME) {\n // We can't use this feature detection in V8 since it causes\n // deoptimization and serious performance degradation\n // https://github.com/zloirock/core-js/issues/677\n return V8_VERSION >= 51 || !fails(function () {\n var array = [];\n var constructor = array.constructor = {};\n constructor[SPECIES] = function () {\n return { foo: 1 };\n };\n return array[METHOD_NAME](Boolean).foo !== 1;\n });\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis([].slice);\n","'use strict';\nvar isArray = require('../internals/is-array');\nvar isConstructor = require('../internals/is-constructor');\nvar isObject = require('../internals/is-object');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar SPECIES = wellKnownSymbol('species');\nvar $Array = Array;\n\n// a part of `ArraySpeciesCreate` abstract operation\n// https://tc39.es/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray) {\n var C;\n if (isArray(originalArray)) {\n C = originalArray.constructor;\n // cross-realm fallback\n if (isConstructor(C) && (C === $Array || isArray(C.prototype))) C = undefined;\n else if (isObject(C)) {\n C = C[SPECIES];\n if (C === null) C = undefined;\n }\n } return C === undefined ? $Array : C;\n};\n","'use strict';\nvar arraySpeciesConstructor = require('../internals/array-species-constructor');\n\n// `ArraySpeciesCreate` abstract operation\n// https://tc39.es/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray, length) {\n return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar toString = uncurryThis({}.toString);\nvar stringSlice = uncurryThis(''.slice);\n\nmodule.exports = function (it) {\n return stringSlice(toString(it), 8, -1);\n};\n","'use strict';\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar isCallable = require('../internals/is-callable');\nvar classofRaw = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar $Object = Object;\n\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n // eslint-disable-next-line es/no-object-getprototypeof -- required for testing\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n","'use strict';\n// `CreateIterResultObject` abstract operation\n// https://tc39.es/ecma262/#sec-createiterresultobject\nmodule.exports = function (value, done) {\n return { value: value, done: done };\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n","'use strict';\nmodule.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n","'use strict';\nvar toPropertyKey = require('../internals/to-property-key');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = function (object, key, value) {\n var propertyKey = toPropertyKey(key);\n if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));\n else object[propertyKey] = value;\n};\n","'use strict';\nvar defineProperty = require('../internals/object-define-property');\n\nmodule.exports = function (target, name, descriptor) {\n return defineProperty.f(target, name, descriptor);\n};\n","'use strict';\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\nmodule.exports = function (target, key, value, options) {\n if (options && options.enumerable) target[key] = value;\n else createNonEnumerableProperty(target, key, value);\n return target;\n};\n","'use strict';\nvar global = require('../internals/global');\n\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar defineProperty = Object.defineProperty;\n\nmodule.exports = function (key, value) {\n try {\n defineProperty(global, key, { value: value, configurable: true, writable: true });\n } catch (error) {\n global[key] = value;\n } return value;\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\n// Detect IE8's incomplete defineProperty implementation\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;\n});\n","'use strict';\nvar global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n","'use strict';\nvar $TypeError = TypeError;\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991\n\nmodule.exports = function (it) {\n if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded');\n return it;\n};\n","'use strict';\n// iterable DOM collections\n// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods\nmodule.exports = {\n CSSRuleList: 0,\n CSSStyleDeclaration: 0,\n CSSValueList: 0,\n ClientRectList: 0,\n DOMRectList: 0,\n DOMStringList: 0,\n DOMTokenList: 1,\n DataTransferItemList: 0,\n FileList: 0,\n HTMLAllCollection: 0,\n HTMLCollection: 0,\n HTMLFormElement: 0,\n HTMLSelectElement: 0,\n MediaList: 0,\n MimeTypeArray: 0,\n NamedNodeMap: 0,\n NodeList: 1,\n PaintRequestList: 0,\n Plugin: 0,\n PluginArray: 0,\n SVGLengthList: 0,\n SVGNumberList: 0,\n SVGPathSegList: 0,\n SVGPointList: 0,\n SVGStringList: 0,\n SVGTransformList: 0,\n SourceBufferList: 0,\n StyleSheetList: 0,\n TextTrackCueList: 0,\n TextTrackList: 0,\n TouchList: 0\n};\n","'use strict';\nmodule.exports = typeof navigator != 'undefined' && String(navigator.userAgent) || '';\n","'use strict';\nvar global = require('../internals/global');\nvar userAgent = require('../internals/engine-user-agent');\n\nvar process = global.process;\nvar Deno = global.Deno;\nvar versions = process && process.versions || Deno && Deno.version;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n // in old Chrome, versions of V8 isn't V8 = Chrome / 10\n // but their correct versions are not interesting for us\n version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);\n}\n\n// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`\n// so check `userAgent` even if `.v8` exists, but 0\nif (!version && userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = +match[1];\n }\n}\n\nmodule.exports = version;\n","'use strict';\n// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n","'use strict';\nvar global = require('../internals/global');\nvar apply = require('../internals/function-apply');\nvar uncurryThis = require('../internals/function-uncurry-this-clause');\nvar isCallable = require('../internals/is-callable');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar isForced = require('../internals/is-forced');\nvar path = require('../internals/path');\nvar bind = require('../internals/function-bind-context');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\n\nvar wrapConstructor = function (NativeConstructor) {\n var Wrapper = function (a, b, c) {\n if (this instanceof Wrapper) {\n switch (arguments.length) {\n case 0: return new NativeConstructor();\n case 1: return new NativeConstructor(a);\n case 2: return new NativeConstructor(a, b);\n } return new NativeConstructor(a, b, c);\n } return apply(NativeConstructor, this, arguments);\n };\n Wrapper.prototype = NativeConstructor.prototype;\n return Wrapper;\n};\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.dontCallGetSet - prevent calling a getter on target\n options.name - the .name of the function if it does not match the key\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var PROTO = options.proto;\n\n var nativeSource = GLOBAL ? global : STATIC ? global[TARGET] : global[TARGET] && global[TARGET].prototype;\n\n var target = GLOBAL ? path : path[TARGET] || createNonEnumerableProperty(path, TARGET, {})[TARGET];\n var targetPrototype = target.prototype;\n\n var FORCED, USE_NATIVE, VIRTUAL_PROTOTYPE;\n var key, sourceProperty, targetProperty, nativeProperty, resultProperty, descriptor;\n\n for (key in source) {\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contains in native\n USE_NATIVE = !FORCED && nativeSource && hasOwn(nativeSource, key);\n\n targetProperty = target[key];\n\n if (USE_NATIVE) if (options.dontCallGetSet) {\n descriptor = getOwnPropertyDescriptor(nativeSource, key);\n nativeProperty = descriptor && descriptor.value;\n } else nativeProperty = nativeSource[key];\n\n // export native or implementation\n sourceProperty = (USE_NATIVE && nativeProperty) ? nativeProperty : source[key];\n\n if (!FORCED && !PROTO && typeof targetProperty == typeof sourceProperty) continue;\n\n // bind methods to global for calling from export context\n if (options.bind && USE_NATIVE) resultProperty = bind(sourceProperty, global);\n // wrap global constructors for prevent changes in this version\n else if (options.wrap && USE_NATIVE) resultProperty = wrapConstructor(sourceProperty);\n // make static versions for prototype methods\n else if (PROTO && isCallable(sourceProperty)) resultProperty = uncurryThis(sourceProperty);\n // default case\n else resultProperty = sourceProperty;\n\n // add a flag to not completely full polyfills\n if (options.sham || (sourceProperty && sourceProperty.sham) || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(resultProperty, 'sham', true);\n }\n\n createNonEnumerableProperty(target, key, resultProperty);\n\n if (PROTO) {\n VIRTUAL_PROTOTYPE = TARGET + 'Prototype';\n if (!hasOwn(path, VIRTUAL_PROTOTYPE)) {\n createNonEnumerableProperty(path, VIRTUAL_PROTOTYPE, {});\n }\n // export virtual prototype methods\n createNonEnumerableProperty(path[VIRTUAL_PROTOTYPE], key, sourceProperty);\n // export real prototype methods\n if (options.real && targetPrototype && (FORCED || !targetPrototype[key])) {\n createNonEnumerableProperty(targetPrototype, key, sourceProperty);\n }\n }\n }\n};\n","'use strict';\nmodule.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n","'use strict';\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar FunctionPrototype = Function.prototype;\nvar apply = FunctionPrototype.apply;\nvar call = FunctionPrototype.call;\n\n// eslint-disable-next-line es/no-reflect -- safe\nmodule.exports = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call.bind(apply) : function () {\n return call.apply(apply, arguments);\n});\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this-clause');\nvar aCallable = require('../internals/a-callable');\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar bind = uncurryThis(uncurryThis.bind);\n\n// optional / simple context binding\nmodule.exports = function (fn, that) {\n aCallable(fn);\n return that === undefined ? fn : NATIVE_BIND ? bind(fn, that) : function (/* ...args */) {\n return fn.apply(that, arguments);\n };\n};\n","'use strict';\nvar fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-function-prototype-bind -- safe\n var test = (function () { /* empty */ }).bind();\n // eslint-disable-next-line no-prototype-builtins -- safe\n return typeof test != 'function' || test.hasOwnProperty('prototype');\n});\n","'use strict';\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar call = Function.prototype.call;\n\nmodule.exports = NATIVE_BIND ? call.bind(call) : function () {\n return call.apply(call, arguments);\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar hasOwn = require('../internals/has-own-property');\n\nvar FunctionPrototype = Function.prototype;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;\n\nvar EXISTS = hasOwn(FunctionPrototype, 'name');\n// additional protection from minified / mangled / dropped function names\nvar PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';\nvar CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));\n\nmodule.exports = {\n EXISTS: EXISTS,\n PROPER: PROPER,\n CONFIGURABLE: CONFIGURABLE\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar aCallable = require('../internals/a-callable');\n\nmodule.exports = function (object, key, method) {\n try {\n // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n return uncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));\n } catch (error) { /* empty */ }\n};\n","'use strict';\nvar classofRaw = require('../internals/classof-raw');\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = function (fn) {\n // Nashorn bug:\n // https://github.com/zloirock/core-js/issues/1128\n // https://github.com/zloirock/core-js/issues/1130\n if (classofRaw(fn) === 'Function') return uncurryThis(fn);\n};\n","'use strict';\nvar NATIVE_BIND = require('../internals/function-bind-native');\n\nvar FunctionPrototype = Function.prototype;\nvar call = FunctionPrototype.call;\nvar uncurryThisWithBind = NATIVE_BIND && FunctionPrototype.bind.bind(call, call);\n\nmodule.exports = NATIVE_BIND ? uncurryThisWithBind : function (fn) {\n return function () {\n return call.apply(fn, arguments);\n };\n};\n","'use strict';\nvar path = require('../internals/path');\nvar global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar aFunction = function (variable) {\n return isCallable(variable) ? variable : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(path[namespace]) || aFunction(global[namespace])\n : path[namespace] && path[namespace][method] || global[namespace] && global[namespace][method];\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isArray = require('../internals/is-array');\nvar isCallable = require('../internals/is-callable');\nvar classof = require('../internals/classof-raw');\nvar toString = require('../internals/to-string');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (replacer) {\n if (isCallable(replacer)) return replacer;\n if (!isArray(replacer)) return;\n var rawLength = replacer.length;\n var keys = [];\n for (var i = 0; i < rawLength; i++) {\n var element = replacer[i];\n if (typeof element == 'string') push(keys, element);\n else if (typeof element == 'number' || classof(element) === 'Number' || classof(element) === 'String') push(keys, toString(element));\n }\n var keysLength = keys.length;\n var root = true;\n return function (key, value) {\n if (root) {\n root = false;\n return value;\n }\n if (isArray(this)) return value;\n for (var j = 0; j < keysLength; j++) if (keys[j] === key) return value;\n };\n};\n","'use strict';\nvar aCallable = require('../internals/a-callable');\nvar isNullOrUndefined = require('../internals/is-null-or-undefined');\n\n// `GetMethod` abstract operation\n// https://tc39.es/ecma262/#sec-getmethod\nmodule.exports = function (V, P) {\n var func = V[P];\n return isNullOrUndefined(func) ? undefined : aCallable(func);\n};\n","'use strict';\nvar check = function (it) {\n return it && it.Math === Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line es/no-global-this -- safe\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n // eslint-disable-next-line no-restricted-globals -- safe\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n check(typeof this == 'object' && this) ||\n // eslint-disable-next-line no-new-func -- fallback\n (function () { return this; })() || Function('return this')();\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar hasOwnProperty = uncurryThis({}.hasOwnProperty);\n\n// `HasOwnProperty` abstract operation\n// https://tc39.es/ecma262/#sec-hasownproperty\n// eslint-disable-next-line es/no-object-hasown -- safe\nmodule.exports = Object.hasOwn || function hasOwn(it, key) {\n return hasOwnProperty(toObject(it), key);\n};\n","'use strict';\nmodule.exports = {};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('document', 'documentElement');\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\nvar createElement = require('../internals/document-create-element');\n\n// Thanks to IE8 for its funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a !== 7;\n});\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar classof = require('../internals/classof-raw');\n\nvar $Object = Object;\nvar split = uncurryThis(''.split);\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins -- safe\n return !$Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) === 'String' ? split(it, '') : $Object(it);\n} : $Object;\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isCallable = require('../internals/is-callable');\nvar store = require('../internals/shared-store');\n\nvar functionToString = uncurryThis(Function.toString);\n\n// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper\nif (!isCallable(store.inspectSource)) {\n store.inspectSource = function (it) {\n return functionToString(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n","'use strict';\nvar NATIVE_WEAK_MAP = require('../internals/weak-map-basic-detection');\nvar global = require('../internals/global');\nvar isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\nvar shared = require('../internals/shared-store');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar OBJECT_ALREADY_INITIALIZED = 'Object already initialized';\nvar TypeError = global.TypeError;\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw new TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP || shared.state) {\n var store = shared.state || (shared.state = new WeakMap());\n /* eslint-disable no-self-assign -- prototype methods protection */\n store.get = store.get;\n store.has = store.has;\n store.set = store.set;\n /* eslint-enable no-self-assign -- prototype methods protection */\n set = function (it, metadata) {\n if (store.has(it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n store.set(it, metadata);\n return metadata;\n };\n get = function (it) {\n return store.get(it) || {};\n };\n has = function (it) {\n return store.has(it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return hasOwn(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return hasOwn(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n","'use strict';\nvar classof = require('../internals/classof-raw');\n\n// `IsArray` abstract operation\n// https://tc39.es/ecma262/#sec-isarray\n// eslint-disable-next-line es/no-array-isarray -- safe\nmodule.exports = Array.isArray || function isArray(argument) {\n return classof(argument) === 'Array';\n};\n","'use strict';\n// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot\nvar documentAll = typeof document == 'object' && document.all;\n\n// `IsCallable` abstract operation\n// https://tc39.es/ecma262/#sec-iscallable\n// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing\nmodule.exports = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {\n return typeof argument == 'function' || argument === documentAll;\n} : function (argument) {\n return typeof argument == 'function';\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar classof = require('../internals/classof');\nvar getBuiltIn = require('../internals/get-built-in');\nvar inspectSource = require('../internals/inspect-source');\n\nvar noop = function () { /* empty */ };\nvar construct = getBuiltIn('Reflect', 'construct');\nvar constructorRegExp = /^\\s*(?:class|function)\\b/;\nvar exec = uncurryThis(constructorRegExp.exec);\nvar INCORRECT_TO_STRING = !constructorRegExp.test(noop);\n\nvar isConstructorModern = function isConstructor(argument) {\n if (!isCallable(argument)) return false;\n try {\n construct(noop, [], argument);\n return true;\n } catch (error) {\n return false;\n }\n};\n\nvar isConstructorLegacy = function isConstructor(argument) {\n if (!isCallable(argument)) return false;\n switch (classof(argument)) {\n case 'AsyncFunction':\n case 'GeneratorFunction':\n case 'AsyncGeneratorFunction': return false;\n }\n try {\n // we can't check .prototype since constructors produced by .bind haven't it\n // `Function#toString` throws on some built-it function in some legacy engines\n // (for example, `DOMQuad` and similar in FF41-)\n return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource(argument));\n } catch (error) {\n return true;\n }\n};\n\nisConstructorLegacy.sham = true;\n\n// `IsConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-isconstructor\nmodule.exports = !construct || fails(function () {\n var called;\n return isConstructorModern(isConstructorModern.call)\n || !isConstructorModern(Object)\n || !isConstructorModern(function () { called = true; })\n || called;\n}) ? isConstructorLegacy : isConstructorModern;\n","'use strict';\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value === POLYFILL ? true\n : value === NATIVE ? false\n : isCallable(detection) ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n","'use strict';\n// we can't use just `it == null` since of `document.all` special case\n// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec\nmodule.exports = function (it) {\n return it === null || it === undefined;\n};\n","'use strict';\nvar isCallable = require('../internals/is-callable');\n\nmodule.exports = function (it) {\n return typeof it == 'object' ? it !== null : isCallable(it);\n};\n","'use strict';\nvar isObject = require('../internals/is-object');\n\nmodule.exports = function (argument) {\n return isObject(argument) || argument === null;\n};\n","'use strict';\nmodule.exports = true;\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar $Object = Object;\n\nmodule.exports = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n var $Symbol = getBuiltIn('Symbol');\n return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, $Object(it));\n};\n","'use strict';\nvar IteratorPrototype = require('../internals/iterators-core').IteratorPrototype;\nvar create = require('../internals/object-create');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar Iterators = require('../internals/iterators');\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {\n var TO_STRING_TAG = NAME + ' Iterator';\n IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });\n setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);\n Iterators[TO_STRING_TAG] = returnThis;\n return IteratorConstructor;\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar call = require('../internals/function-call');\nvar IS_PURE = require('../internals/is-pure');\nvar FunctionName = require('../internals/function-name');\nvar isCallable = require('../internals/is-callable');\nvar createIteratorConstructor = require('../internals/iterator-create-constructor');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\nvar IteratorsCore = require('../internals/iterators-core');\n\nvar PROPER_FUNCTION_NAME = FunctionName.PROPER;\nvar CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;\nvar IteratorPrototype = IteratorsCore.IteratorPrototype;\nvar BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;\nvar ITERATOR = wellKnownSymbol('iterator');\nvar KEYS = 'keys';\nvar VALUES = 'values';\nvar ENTRIES = 'entries';\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {\n createIteratorConstructor(IteratorConstructor, NAME, next);\n\n var getIterationMethod = function (KIND) {\n if (KIND === DEFAULT && defaultIterator) return defaultIterator;\n if (!BUGGY_SAFARI_ITERATORS && KIND && KIND in IterablePrototype) return IterablePrototype[KIND];\n\n switch (KIND) {\n case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };\n case VALUES: return function values() { return new IteratorConstructor(this, KIND); };\n case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };\n }\n\n return function () { return new IteratorConstructor(this); };\n };\n\n var TO_STRING_TAG = NAME + ' Iterator';\n var INCORRECT_VALUES_NAME = false;\n var IterablePrototype = Iterable.prototype;\n var nativeIterator = IterablePrototype[ITERATOR]\n || IterablePrototype['@@iterator']\n || DEFAULT && IterablePrototype[DEFAULT];\n var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);\n var anyNativeIterator = NAME === 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;\n var CurrentIteratorPrototype, methods, KEY;\n\n // fix native\n if (anyNativeIterator) {\n CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));\n if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {\n if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {\n if (setPrototypeOf) {\n setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);\n } else if (!isCallable(CurrentIteratorPrototype[ITERATOR])) {\n defineBuiltIn(CurrentIteratorPrototype, ITERATOR, returnThis);\n }\n }\n // Set @@toStringTag to native iterators\n setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);\n if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;\n }\n }\n\n // fix Array.prototype.{ values, @@iterator }.name in V8 / FF\n if (PROPER_FUNCTION_NAME && DEFAULT === VALUES && nativeIterator && nativeIterator.name !== VALUES) {\n if (!IS_PURE && CONFIGURABLE_FUNCTION_NAME) {\n createNonEnumerableProperty(IterablePrototype, 'name', VALUES);\n } else {\n INCORRECT_VALUES_NAME = true;\n defaultIterator = function values() { return call(nativeIterator, this); };\n }\n }\n\n // export additional methods\n if (DEFAULT) {\n methods = {\n values: getIterationMethod(VALUES),\n keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),\n entries: getIterationMethod(ENTRIES)\n };\n if (FORCED) for (KEY in methods) {\n if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {\n defineBuiltIn(IterablePrototype, KEY, methods[KEY]);\n }\n } else $({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);\n }\n\n // define iterator\n if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {\n defineBuiltIn(IterablePrototype, ITERATOR, defaultIterator, { name: DEFAULT });\n }\n Iterators[NAME] = defaultIterator;\n\n return methods;\n};\n","'use strict';\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar create = require('../internals/object-create');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IS_PURE = require('../internals/is-pure');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false;\n\n// `%IteratorPrototype%` object\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-object\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n\n/* eslint-disable es/no-array-prototype-keys -- safe */\nif ([].keys) {\n arrayIterator = [].keys();\n // Safari 8 has buggy iterators w/o `next`\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;\n else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nvar NEW_ITERATOR_PROTOTYPE = !isObject(IteratorPrototype) || fails(function () {\n var test = {};\n // FF44- legacy iterators case\n return IteratorPrototype[ITERATOR].call(test) !== test;\n});\n\nif (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};\nelse if (IS_PURE) IteratorPrototype = create(IteratorPrototype);\n\n// `%IteratorPrototype%[@@iterator]()` method\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator\nif (!isCallable(IteratorPrototype[ITERATOR])) {\n defineBuiltIn(IteratorPrototype, ITERATOR, function () {\n return this;\n });\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};\n","'use strict';\nmodule.exports = {};\n","'use strict';\nvar toLength = require('../internals/to-length');\n\n// `LengthOfArrayLike` abstract operation\n// https://tc39.es/ecma262/#sec-lengthofarraylike\nmodule.exports = function (obj) {\n return toLength(obj.length);\n};\n","'use strict';\nvar ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `Math.trunc` method\n// https://tc39.es/ecma262/#sec-math.trunc\n// eslint-disable-next-line es/no-math-trunc -- safe\nmodule.exports = Math.trunc || function trunc(x) {\n var n = +x;\n return (n > 0 ? floor : ceil)(n);\n};\n","'use strict';\n/* global ActiveXObject -- old IE, WSH */\nvar anObject = require('../internals/an-object');\nvar definePropertiesModule = require('../internals/object-define-properties');\nvar enumBugKeys = require('../internals/enum-bug-keys');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar html = require('../internals/html');\nvar documentCreateElement = require('../internals/document-create-element');\nvar sharedKey = require('../internals/shared-key');\n\nvar GT = '>';\nvar LT = '<';\nvar PROTOTYPE = 'prototype';\nvar SCRIPT = 'script';\nvar IE_PROTO = sharedKey('IE_PROTO');\n\nvar EmptyConstructor = function () { /* empty */ };\n\nvar scriptTag = function (content) {\n return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;\n};\n\n// Create object with fake `null` prototype: use ActiveX Object with cleared prototype\nvar NullProtoObjectViaActiveX = function (activeXDocument) {\n activeXDocument.write(scriptTag(''));\n activeXDocument.close();\n var temp = activeXDocument.parentWindow.Object;\n activeXDocument = null; // avoid memory leak\n return temp;\n};\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar NullProtoObjectViaIFrame = function () {\n // Thrash, waste and sodomy: IE GC bug\n var iframe = documentCreateElement('iframe');\n var JS = 'java' + SCRIPT + ':';\n var iframeDocument;\n iframe.style.display = 'none';\n html.appendChild(iframe);\n // https://github.com/zloirock/core-js/issues/475\n iframe.src = String(JS);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(scriptTag('document.F=Object'));\n iframeDocument.close();\n return iframeDocument.F;\n};\n\n// Check for document.domain and active x support\n// No need to use active x approach when document.domain is not set\n// see https://github.com/es-shims/es5-shim/issues/150\n// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346\n// avoid IE GC bug\nvar activeXDocument;\nvar NullProtoObject = function () {\n try {\n activeXDocument = new ActiveXObject('htmlfile');\n } catch (error) { /* ignore */ }\n NullProtoObject = typeof document != 'undefined'\n ? document.domain && activeXDocument\n ? NullProtoObjectViaActiveX(activeXDocument) // old IE\n : NullProtoObjectViaIFrame()\n : NullProtoObjectViaActiveX(activeXDocument); // WSH\n var length = enumBugKeys.length;\n while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];\n return NullProtoObject();\n};\n\nhiddenKeys[IE_PROTO] = true;\n\n// `Object.create` method\n// https://tc39.es/ecma262/#sec-object.create\n// eslint-disable-next-line es/no-object-create -- safe\nmodule.exports = Object.create || function create(O, Properties) {\n var result;\n if (O !== null) {\n EmptyConstructor[PROTOTYPE] = anObject(O);\n result = new EmptyConstructor();\n EmptyConstructor[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = NullProtoObject();\n return Properties === undefined ? result : definePropertiesModule.f(result, Properties);\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar definePropertyModule = require('../internals/object-define-property');\nvar anObject = require('../internals/an-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar objectKeys = require('../internals/object-keys');\n\n// `Object.defineProperties` method\n// https://tc39.es/ecma262/#sec-object.defineproperties\n// eslint-disable-next-line es/no-object-defineproperties -- safe\nexports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var props = toIndexedObject(Properties);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);\n return O;\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\nvar V8_PROTOTYPE_DEFINE_BUG = require('../internals/v8-prototype-define-bug');\nvar anObject = require('../internals/an-object');\nvar toPropertyKey = require('../internals/to-property-key');\n\nvar $TypeError = TypeError;\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar $defineProperty = Object.defineProperty;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\nvar ENUMERABLE = 'enumerable';\nvar CONFIGURABLE = 'configurable';\nvar WRITABLE = 'writable';\n\n// `Object.defineProperty` method\n// https://tc39.es/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {\n var current = $getOwnPropertyDescriptor(O, P);\n if (current && current[WRITABLE]) {\n O[P] = Attributes.value;\n Attributes = {\n configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],\n enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],\n writable: false\n };\n }\n } return $defineProperty(O, P, Attributes);\n} : $defineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return $defineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw new $TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar call = require('../internals/function-call');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar hasOwn = require('../internals/has-own-property');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\n\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPropertyKey(P);\n if (IE8_DOM_DEFINE) try {\n return $getOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);\n};\n","'use strict';\n/* eslint-disable es/no-object-getownpropertynames -- safe */\nvar classof = require('../internals/classof-raw');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar $getOwnPropertyNames = require('../internals/object-get-own-property-names').f;\nvar arraySlice = require('../internals/array-slice');\n\nvar windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames\n ? Object.getOwnPropertyNames(window) : [];\n\nvar getWindowNames = function (it) {\n try {\n return $getOwnPropertyNames(it);\n } catch (error) {\n return arraySlice(windowNames);\n }\n};\n\n// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window\nmodule.exports.f = function getOwnPropertyNames(it) {\n return windowNames && classof(it) === 'Window'\n ? getWindowNames(it)\n : $getOwnPropertyNames(toIndexedObject(it));\n};\n","'use strict';\nvar internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.es/ecma262/#sec-object.getownpropertynames\n// eslint-disable-next-line es/no-object-getownpropertynames -- safe\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n","'use strict';\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe\nexports.f = Object.getOwnPropertySymbols;\n","'use strict';\nvar hasOwn = require('../internals/has-own-property');\nvar isCallable = require('../internals/is-callable');\nvar toObject = require('../internals/to-object');\nvar sharedKey = require('../internals/shared-key');\nvar CORRECT_PROTOTYPE_GETTER = require('../internals/correct-prototype-getter');\n\nvar IE_PROTO = sharedKey('IE_PROTO');\nvar $Object = Object;\nvar ObjectPrototype = $Object.prototype;\n\n// `Object.getPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.getprototypeof\n// eslint-disable-next-line es/no-object-getprototypeof -- safe\nmodule.exports = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {\n var object = toObject(O);\n if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];\n var constructor = object.constructor;\n if (isCallable(constructor) && object instanceof constructor) {\n return constructor.prototype;\n } return object instanceof $Object ? ObjectPrototype : null;\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis({}.isPrototypeOf);\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar indexOf = require('../internals/array-includes').indexOf;\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (hasOwn(O, key = names[i++])) {\n ~indexOf(result, key) || push(result, key);\n }\n return result;\n};\n","'use strict';\nvar internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\n// `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n// eslint-disable-next-line es/no-object-keys -- safe\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};\n","'use strict';\nvar $propertyIsEnumerable = {}.propertyIsEnumerable;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : $propertyIsEnumerable;\n","'use strict';\n/* eslint-disable no-proto -- safe */\nvar uncurryThisAccessor = require('../internals/function-uncurry-this-accessor');\nvar anObject = require('../internals/an-object');\nvar aPossiblePrototype = require('../internals/a-possible-prototype');\n\n// `Object.setPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n// eslint-disable-next-line es/no-object-setprototypeof -- safe\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n","'use strict';\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar classof = require('../internals/classof');\n\n// `Object.prototype.toString` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.tostring\nmodule.exports = TO_STRING_TAG_SUPPORT ? {}.toString : function toString() {\n return '[object ' + classof(this) + ']';\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\n\nvar $TypeError = TypeError;\n\n// `OrdinaryToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-ordinarytoprimitive\nmodule.exports = function (input, pref) {\n var fn, val;\n if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;\n if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n throw new $TypeError(\"Can't convert object to primitive value\");\n};\n","'use strict';\nmodule.exports = {};\n","'use strict';\nvar isNullOrUndefined = require('../internals/is-null-or-undefined');\n\nvar $TypeError = TypeError;\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.es/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (isNullOrUndefined(it)) throw new $TypeError(\"Can't call method on \" + it);\n return it;\n};\n","'use strict';\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar defineProperty = require('../internals/object-define-property').f;\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\nvar toString = require('../internals/object-to-string');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n\nmodule.exports = function (it, TAG, STATIC, SET_METHOD) {\n var target = STATIC ? it : it && it.prototype;\n if (target) {\n if (!hasOwn(target, TO_STRING_TAG)) {\n defineProperty(target, TO_STRING_TAG, { configurable: true, value: TAG });\n }\n if (SET_METHOD && !TO_STRING_TAG_SUPPORT) {\n createNonEnumerableProperty(target, 'toString', toString);\n }\n }\n};\n","'use strict';\nvar shared = require('../internals/shared');\nvar uid = require('../internals/uid');\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n","'use strict';\nvar global = require('../internals/global');\nvar defineGlobalProperty = require('../internals/define-global-property');\n\nvar SHARED = '__core-js_shared__';\nvar store = global[SHARED] || defineGlobalProperty(SHARED, {});\n\nmodule.exports = store;\n","'use strict';\nvar IS_PURE = require('../internals/is-pure');\nvar store = require('../internals/shared-store');\n\n(module.exports = function (key, value) {\n return store[key] || (store[key] = value !== undefined ? value : {});\n})('versions', []).push({\n version: '3.35.1',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',\n license: 'https://github.com/zloirock/core-js/blob/v3.35.1/LICENSE',\n source: 'https://github.com/zloirock/core-js'\n});\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toString = require('../internals/to-string');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar stringSlice = uncurryThis(''.slice);\n\nvar createMethod = function (CONVERT_TO_STRING) {\n return function ($this, pos) {\n var S = toString(requireObjectCoercible($this));\n var position = toIntegerOrInfinity(pos);\n var size = S.length;\n var first, second;\n if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;\n first = charCodeAt(S, position);\n return first < 0xD800 || first > 0xDBFF || position + 1 === size\n || (second = charCodeAt(S, position + 1)) < 0xDC00 || second > 0xDFFF\n ? CONVERT_TO_STRING\n ? charAt(S, position)\n : first\n : CONVERT_TO_STRING\n ? stringSlice(S, position, position + 2)\n : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;\n };\n};\n\nmodule.exports = {\n // `String.prototype.codePointAt` method\n // https://tc39.es/ecma262/#sec-string.prototype.codepointat\n codeAt: createMethod(false),\n // `String.prototype.at` method\n // https://github.com/mathiasbynens/String.prototype.at\n charAt: createMethod(true)\n};\n","'use strict';\n/* eslint-disable es/no-symbol -- required for testing */\nvar V8_VERSION = require('../internals/engine-v8-version');\nvar fails = require('../internals/fails');\nvar global = require('../internals/global');\n\nvar $String = global.String;\n\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n var symbol = Symbol('symbol detection');\n // Chrome 38 Symbol has incorrect toString conversion\n // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances\n // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,\n // of course, fail.\n return !$String(symbol) || !(Object(symbol) instanceof Symbol) ||\n // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances\n !Symbol.sham && V8_VERSION && V8_VERSION < 41;\n});\n","'use strict';\nvar call = require('../internals/function-call');\nvar getBuiltIn = require('../internals/get-built-in');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar defineBuiltIn = require('../internals/define-built-in');\n\nmodule.exports = function () {\n var Symbol = getBuiltIn('Symbol');\n var SymbolPrototype = Symbol && Symbol.prototype;\n var valueOf = SymbolPrototype && SymbolPrototype.valueOf;\n var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n if (SymbolPrototype && !SymbolPrototype[TO_PRIMITIVE]) {\n // `Symbol.prototype[@@toPrimitive]` method\n // https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive\n // eslint-disable-next-line no-unused-vars -- required for .length\n defineBuiltIn(SymbolPrototype, TO_PRIMITIVE, function (hint) {\n return call(valueOf, this);\n }, { arity: 1 });\n }\n};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar Symbol = getBuiltIn('Symbol');\nvar keyFor = Symbol.keyFor;\nvar thisSymbolValue = uncurryThis(Symbol.prototype.valueOf);\n\n// `Symbol.isRegisteredSymbol` method\n// https://tc39.es/proposal-symbol-predicates/#sec-symbol-isregisteredsymbol\nmodule.exports = Symbol.isRegisteredSymbol || function isRegisteredSymbol(value) {\n try {\n return keyFor(thisSymbolValue(value)) !== undefined;\n } catch (error) {\n return false;\n }\n};\n","'use strict';\nvar shared = require('../internals/shared');\nvar getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isSymbol = require('../internals/is-symbol');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar Symbol = getBuiltIn('Symbol');\nvar $isWellKnownSymbol = Symbol.isWellKnownSymbol;\nvar getOwnPropertyNames = getBuiltIn('Object', 'getOwnPropertyNames');\nvar thisSymbolValue = uncurryThis(Symbol.prototype.valueOf);\nvar WellKnownSymbolsStore = shared('wks');\n\nfor (var i = 0, symbolKeys = getOwnPropertyNames(Symbol), symbolKeysLength = symbolKeys.length; i < symbolKeysLength; i++) {\n // some old engines throws on access to some keys like `arguments` or `caller`\n try {\n var symbolKey = symbolKeys[i];\n if (isSymbol(Symbol[symbolKey])) wellKnownSymbol(symbolKey);\n } catch (error) { /* empty */ }\n}\n\n// `Symbol.isWellKnownSymbol` method\n// https://tc39.es/proposal-symbol-predicates/#sec-symbol-iswellknownsymbol\n// We should patch it for newly added well-known symbols. If it's not required, this module just will not be injected\nmodule.exports = function isWellKnownSymbol(value) {\n if ($isWellKnownSymbol && $isWellKnownSymbol(value)) return true;\n try {\n var symbol = thisSymbolValue(value);\n for (var j = 0, keys = getOwnPropertyNames(WellKnownSymbolsStore), keysLength = keys.length; j < keysLength; j++) {\n // eslint-disable-next-line eqeqeq -- polyfilled symbols case\n if (WellKnownSymbolsStore[keys[j]] == symbol) return true;\n }\n } catch (error) { /* empty */ }\n return false;\n};\n","'use strict';\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n\n/* eslint-disable es/no-symbol -- safe */\nmodule.exports = NATIVE_SYMBOL && !!Symbol['for'] && !!Symbol.keyFor;\n","'use strict';\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toIntegerOrInfinity(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n","'use strict';\n// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = require('../internals/indexed-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n","'use strict';\nvar trunc = require('../internals/math-trunc');\n\n// `ToIntegerOrInfinity` abstract operation\n// https://tc39.es/ecma262/#sec-tointegerorinfinity\nmodule.exports = function (argument) {\n var number = +argument;\n // eslint-disable-next-line no-self-compare -- NaN check\n return number !== number || number === 0 ? 0 : trunc(number);\n};\n","'use strict';\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.es/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n var len = toIntegerOrInfinity(argument);\n return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n","'use strict';\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar $Object = Object;\n\n// `ToObject` abstract operation\n// https://tc39.es/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return $Object(requireObjectCoercible(argument));\n};\n","'use strict';\nvar call = require('../internals/function-call');\nvar isObject = require('../internals/is-object');\nvar isSymbol = require('../internals/is-symbol');\nvar getMethod = require('../internals/get-method');\nvar ordinaryToPrimitive = require('../internals/ordinary-to-primitive');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar $TypeError = TypeError;\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n// `ToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-toprimitive\nmodule.exports = function (input, pref) {\n if (!isObject(input) || isSymbol(input)) return input;\n var exoticToPrim = getMethod(input, TO_PRIMITIVE);\n var result;\n if (exoticToPrim) {\n if (pref === undefined) pref = 'default';\n result = call(exoticToPrim, input, pref);\n if (!isObject(result) || isSymbol(result)) return result;\n throw new $TypeError(\"Can't convert object to primitive value\");\n }\n if (pref === undefined) pref = 'number';\n return ordinaryToPrimitive(input, pref);\n};\n","'use strict';\nvar toPrimitive = require('../internals/to-primitive');\nvar isSymbol = require('../internals/is-symbol');\n\n// `ToPropertyKey` abstract operation\n// https://tc39.es/ecma262/#sec-topropertykey\nmodule.exports = function (argument) {\n var key = toPrimitive(argument, 'string');\n return isSymbol(key) ? key : key + '';\n};\n","'use strict';\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n","'use strict';\nvar classof = require('../internals/classof');\n\nvar $String = String;\n\nmodule.exports = function (argument) {\n if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');\n return $String(argument);\n};\n","'use strict';\nvar $String = String;\n\nmodule.exports = function (argument) {\n try {\n return $String(argument);\n } catch (error) {\n return 'Object';\n }\n};\n","'use strict';\nvar uncurryThis = require('../internals/function-uncurry-this');\n\nvar id = 0;\nvar postfix = Math.random();\nvar toString = uncurryThis(1.0.toString);\n\nmodule.exports = function (key) {\n return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);\n};\n","'use strict';\n/* eslint-disable es/no-symbol -- required for testing */\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n\nmodule.exports = NATIVE_SYMBOL\n && !Symbol.sham\n && typeof Symbol.iterator == 'symbol';\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\n\n// V8 ~ Chrome 36-\n// https://bugs.chromium.org/p/v8/issues/detail?id=3334\nmodule.exports = DESCRIPTORS && fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty(function () { /* empty */ }, 'prototype', {\n value: 42,\n writable: false\n }).prototype !== 42;\n});\n","'use strict';\nvar global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = isCallable(WeakMap) && /native code/.test(String(WeakMap));\n","'use strict';\nvar path = require('../internals/path');\nvar hasOwn = require('../internals/has-own-property');\nvar wrappedWellKnownSymbolModule = require('../internals/well-known-symbol-wrapped');\nvar defineProperty = require('../internals/object-define-property').f;\n\nmodule.exports = function (NAME) {\n var Symbol = path.Symbol || (path.Symbol = {});\n if (!hasOwn(Symbol, NAME)) defineProperty(Symbol, NAME, {\n value: wrappedWellKnownSymbolModule.f(NAME)\n });\n};\n","'use strict';\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nexports.f = wellKnownSymbol;\n","'use strict';\nvar global = require('../internals/global');\nvar shared = require('../internals/shared');\nvar hasOwn = require('../internals/has-own-property');\nvar uid = require('../internals/uid');\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar Symbol = global.Symbol;\nvar WellKnownSymbolsStore = shared('wks');\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol['for'] || Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!hasOwn(WellKnownSymbolsStore, name)) {\n WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn(Symbol, name)\n ? Symbol[name]\n : createWellKnownSymbol('Symbol.' + name);\n } return WellKnownSymbolsStore[name];\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar fails = require('../internals/fails');\nvar isArray = require('../internals/is-array');\nvar isObject = require('../internals/is-object');\nvar toObject = require('../internals/to-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar doesNotExceedSafeInteger = require('../internals/does-not-exceed-safe-integer');\nvar createProperty = require('../internals/create-property');\nvar arraySpeciesCreate = require('../internals/array-species-create');\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');\n\n// We can't use this feature detection in V8 since it causes\n// deoptimization and serious performance degradation\n// https://github.com/zloirock/core-js/issues/679\nvar IS_CONCAT_SPREADABLE_SUPPORT = V8_VERSION >= 51 || !fails(function () {\n var array = [];\n array[IS_CONCAT_SPREADABLE] = false;\n return array.concat()[0] !== array;\n});\n\nvar isConcatSpreadable = function (O) {\n if (!isObject(O)) return false;\n var spreadable = O[IS_CONCAT_SPREADABLE];\n return spreadable !== undefined ? !!spreadable : isArray(O);\n};\n\nvar FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !arrayMethodHasSpeciesSupport('concat');\n\n// `Array.prototype.concat` method\n// https://tc39.es/ecma262/#sec-array.prototype.concat\n// with adding support of @@isConcatSpreadable and @@species\n$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n concat: function concat(arg) {\n var O = toObject(this);\n var A = arraySpeciesCreate(O, 0);\n var n = 0;\n var i, k, length, len, E;\n for (i = -1, length = arguments.length; i < length; i++) {\n E = i === -1 ? O : arguments[i];\n if (isConcatSpreadable(E)) {\n len = lengthOfArrayLike(E);\n doesNotExceedSafeInteger(n + len);\n for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);\n } else {\n doesNotExceedSafeInteger(n + 1);\n createProperty(A, n++, E);\n }\n }\n A.length = n;\n return A;\n }\n});\n","'use strict';\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar addToUnscopables = require('../internals/add-to-unscopables');\nvar Iterators = require('../internals/iterators');\nvar InternalStateModule = require('../internals/internal-state');\nvar defineProperty = require('../internals/object-define-property').f;\nvar defineIterator = require('../internals/iterator-define');\nvar createIterResultObject = require('../internals/create-iter-result-object');\nvar IS_PURE = require('../internals/is-pure');\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar ARRAY_ITERATOR = 'Array Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);\n\n// `Array.prototype.entries` method\n// https://tc39.es/ecma262/#sec-array.prototype.entries\n// `Array.prototype.keys` method\n// https://tc39.es/ecma262/#sec-array.prototype.keys\n// `Array.prototype.values` method\n// https://tc39.es/ecma262/#sec-array.prototype.values\n// `Array.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-array.prototype-@@iterator\n// `CreateArrayIterator` internal method\n// https://tc39.es/ecma262/#sec-createarrayiterator\nmodule.exports = defineIterator(Array, 'Array', function (iterated, kind) {\n setInternalState(this, {\n type: ARRAY_ITERATOR,\n target: toIndexedObject(iterated), // target\n index: 0, // next index\n kind: kind // kind\n });\n// `%ArrayIteratorPrototype%.next` method\n// https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next\n}, function () {\n var state = getInternalState(this);\n var target = state.target;\n var index = state.index++;\n if (!target || index >= target.length) {\n state.target = undefined;\n return createIterResultObject(undefined, true);\n }\n switch (state.kind) {\n case 'keys': return createIterResultObject(index, false);\n case 'values': return createIterResultObject(target[index], false);\n } return createIterResultObject([index, target[index]], false);\n}, 'values');\n\n// argumentsList[@@iterator] is %ArrayProto_values%\n// https://tc39.es/ecma262/#sec-createunmappedargumentsobject\n// https://tc39.es/ecma262/#sec-createmappedargumentsobject\nvar values = Iterators.Arguments = Iterators.Array;\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries');\n\n// V8 ~ Chrome 45- bug\nif (!IS_PURE && DESCRIPTORS && values.name !== 'values') try {\n defineProperty(values, 'name', { value: 'values' });\n} catch (error) { /* empty */ }\n","'use strict';\nvar $ = require('../internals/export');\nvar getBuiltIn = require('../internals/get-built-in');\nvar apply = require('../internals/function-apply');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar isSymbol = require('../internals/is-symbol');\nvar arraySlice = require('../internals/array-slice');\nvar getReplacerFunction = require('../internals/get-json-replacer-function');\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\n\nvar $String = String;\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar exec = uncurryThis(/./.exec);\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar replace = uncurryThis(''.replace);\nvar numberToString = uncurryThis(1.0.toString);\n\nvar tester = /[\\uD800-\\uDFFF]/g;\nvar low = /^[\\uD800-\\uDBFF]$/;\nvar hi = /^[\\uDC00-\\uDFFF]$/;\n\nvar WRONG_SYMBOLS_CONVERSION = !NATIVE_SYMBOL || fails(function () {\n var symbol = getBuiltIn('Symbol')('stringify detection');\n // MS Edge converts symbol values to JSON as {}\n return $stringify([symbol]) !== '[null]'\n // WebKit converts symbol values to JSON as null\n || $stringify({ a: symbol }) !== '{}'\n // V8 throws on boxed symbols\n || $stringify(Object(symbol)) !== '{}';\n});\n\n// https://github.com/tc39/proposal-well-formed-stringify\nvar ILL_FORMED_UNICODE = fails(function () {\n return $stringify('\\uDF06\\uD834') !== '\"\\\\udf06\\\\ud834\"'\n || $stringify('\\uDEAD') !== '\"\\\\udead\"';\n});\n\nvar stringifyWithSymbolsFix = function (it, replacer) {\n var args = arraySlice(arguments);\n var $replacer = getReplacerFunction(replacer);\n if (!isCallable($replacer) && (it === undefined || isSymbol(it))) return; // IE8 returns string on undefined\n args[1] = function (key, value) {\n // some old implementations (like WebKit) could pass numbers as keys\n if (isCallable($replacer)) value = call($replacer, this, $String(key), value);\n if (!isSymbol(value)) return value;\n };\n return apply($stringify, null, args);\n};\n\nvar fixIllFormed = function (match, offset, string) {\n var prev = charAt(string, offset - 1);\n var next = charAt(string, offset + 1);\n if ((exec(low, match) && !exec(hi, next)) || (exec(hi, match) && !exec(low, prev))) {\n return '\\\\u' + numberToString(charCodeAt(match, 0), 16);\n } return match;\n};\n\nif ($stringify) {\n // `JSON.stringify` method\n // https://tc39.es/ecma262/#sec-json.stringify\n $({ target: 'JSON', stat: true, arity: 3, forced: WRONG_SYMBOLS_CONVERSION || ILL_FORMED_UNICODE }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n stringify: function stringify(it, replacer, space) {\n var args = arraySlice(arguments);\n var result = apply(WRONG_SYMBOLS_CONVERSION ? stringifyWithSymbolsFix : $stringify, null, args);\n return ILL_FORMED_UNICODE && typeof result == 'string' ? replace(result, tester, fixIllFormed) : result;\n }\n });\n}\n","'use strict';\nvar global = require('../internals/global');\nvar setToStringTag = require('../internals/set-to-string-tag');\n\n// JSON[@@toStringTag] property\n// https://tc39.es/ecma262/#sec-json-@@tostringtag\nsetToStringTag(global.JSON, 'JSON', true);\n","'use strict';\nvar $ = require('../internals/export');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar defineProperty = require('../internals/object-define-property').f;\n\n// `Object.defineProperty` method\n// https://tc39.es/ecma262/#sec-object.defineproperty\n// eslint-disable-next-line es/no-object-defineproperty -- safe\n$({ target: 'Object', stat: true, forced: Object.defineProperty !== defineProperty, sham: !DESCRIPTORS }, {\n defineProperty: defineProperty\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\nvar fails = require('../internals/fails');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar toObject = require('../internals/to-object');\n\n// V8 ~ Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives\n// https://bugs.chromium.org/p/v8/issues/detail?id=3443\nvar FORCED = !NATIVE_SYMBOL || fails(function () { getOwnPropertySymbolsModule.f(1); });\n\n// `Object.getOwnPropertySymbols` method\n// https://tc39.es/ecma262/#sec-object.getownpropertysymbols\n$({ target: 'Object', stat: true, forced: FORCED }, {\n getOwnPropertySymbols: function getOwnPropertySymbols(it) {\n var $getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return $getOwnPropertySymbols ? $getOwnPropertySymbols(toObject(it)) : [];\n }\n});\n","'use strict';\nvar charAt = require('../internals/string-multibyte').charAt;\nvar toString = require('../internals/to-string');\nvar InternalStateModule = require('../internals/internal-state');\nvar defineIterator = require('../internals/iterator-define');\nvar createIterResultObject = require('../internals/create-iter-result-object');\n\nvar STRING_ITERATOR = 'String Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);\n\n// `String.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-string.prototype-@@iterator\ndefineIterator(String, 'String', function (iterated) {\n setInternalState(this, {\n type: STRING_ITERATOR,\n string: toString(iterated),\n index: 0\n });\n// `%StringIteratorPrototype%.next` method\n// https://tc39.es/ecma262/#sec-%stringiteratorprototype%.next\n}, function next() {\n var state = getInternalState(this);\n var string = state.string;\n var index = state.index;\n var point;\n if (index >= string.length) return createIterResultObject(undefined, true);\n point = charAt(string, index);\n state.index += point.length;\n return createIterResultObject(point, false);\n});\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.asyncIterator` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.asynciterator\ndefineWellKnownSymbol('asyncIterator');\n","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar IS_PURE = require('../internals/is-pure');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar NATIVE_SYMBOL = require('../internals/symbol-constructor-detection');\nvar fails = require('../internals/fails');\nvar hasOwn = require('../internals/has-own-property');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar anObject = require('../internals/an-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar $toString = require('../internals/to-string');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar nativeObjectCreate = require('../internals/object-create');\nvar objectKeys = require('../internals/object-keys');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertyNamesExternal = require('../internals/object-get-own-property-names-external');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\nvar definePropertiesModule = require('../internals/object-define-properties');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar defineBuiltIn = require('../internals/define-built-in');\nvar defineBuiltInAccessor = require('../internals/define-built-in-accessor');\nvar shared = require('../internals/shared');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar uid = require('../internals/uid');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar wrappedWellKnownSymbolModule = require('../internals/well-known-symbol-wrapped');\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\nvar defineSymbolToPrimitive = require('../internals/symbol-define-to-primitive');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar InternalStateModule = require('../internals/internal-state');\nvar $forEach = require('../internals/array-iteration').forEach;\n\nvar HIDDEN = sharedKey('hidden');\nvar SYMBOL = 'Symbol';\nvar PROTOTYPE = 'prototype';\n\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(SYMBOL);\n\nvar ObjectPrototype = Object[PROTOTYPE];\nvar $Symbol = global.Symbol;\nvar SymbolPrototype = $Symbol && $Symbol[PROTOTYPE];\nvar RangeError = global.RangeError;\nvar TypeError = global.TypeError;\nvar QObject = global.QObject;\nvar nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\nvar nativeDefineProperty = definePropertyModule.f;\nvar nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f;\nvar nativePropertyIsEnumerable = propertyIsEnumerableModule.f;\nvar push = uncurryThis([].push);\n\nvar AllSymbols = shared('symbols');\nvar ObjectPrototypeSymbols = shared('op-symbols');\nvar WellKnownSymbolsStore = shared('wks');\n\n// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173\nvar USE_SETTER = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;\n\n// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687\nvar fallbackDefineProperty = function (O, P, Attributes) {\n var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor(ObjectPrototype, P);\n if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];\n nativeDefineProperty(O, P, Attributes);\n if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {\n nativeDefineProperty(ObjectPrototype, P, ObjectPrototypeDescriptor);\n }\n};\n\nvar setSymbolDescriptor = DESCRIPTORS && fails(function () {\n return nativeObjectCreate(nativeDefineProperty({}, 'a', {\n get: function () { return nativeDefineProperty(this, 'a', { value: 7 }).a; }\n })).a !== 7;\n}) ? fallbackDefineProperty : nativeDefineProperty;\n\nvar wrap = function (tag, description) {\n var symbol = AllSymbols[tag] = nativeObjectCreate(SymbolPrototype);\n setInternalState(symbol, {\n type: SYMBOL,\n tag: tag,\n description: description\n });\n if (!DESCRIPTORS) symbol.description = description;\n return symbol;\n};\n\nvar $defineProperty = function defineProperty(O, P, Attributes) {\n if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);\n anObject(O);\n var key = toPropertyKey(P);\n anObject(Attributes);\n if (hasOwn(AllSymbols, key)) {\n if (!Attributes.enumerable) {\n if (!hasOwn(O, HIDDEN)) nativeDefineProperty(O, HIDDEN, createPropertyDescriptor(1, nativeObjectCreate(null)));\n O[HIDDEN][key] = true;\n } else {\n if (hasOwn(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;\n Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });\n } return setSymbolDescriptor(O, key, Attributes);\n } return nativeDefineProperty(O, key, Attributes);\n};\n\nvar $defineProperties = function defineProperties(O, Properties) {\n anObject(O);\n var properties = toIndexedObject(Properties);\n var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));\n $forEach(keys, function (key) {\n if (!DESCRIPTORS || call($propertyIsEnumerable, properties, key)) $defineProperty(O, key, properties[key]);\n });\n return O;\n};\n\nvar $create = function create(O, Properties) {\n return Properties === undefined ? nativeObjectCreate(O) : $defineProperties(nativeObjectCreate(O), Properties);\n};\n\nvar $propertyIsEnumerable = function propertyIsEnumerable(V) {\n var P = toPropertyKey(V);\n var enumerable = call(nativePropertyIsEnumerable, this, P);\n if (this === ObjectPrototype && hasOwn(AllSymbols, P) && !hasOwn(ObjectPrototypeSymbols, P)) return false;\n return enumerable || !hasOwn(this, P) || !hasOwn(AllSymbols, P) || hasOwn(this, HIDDEN) && this[HIDDEN][P]\n ? enumerable : true;\n};\n\nvar $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {\n var it = toIndexedObject(O);\n var key = toPropertyKey(P);\n if (it === ObjectPrototype && hasOwn(AllSymbols, key) && !hasOwn(ObjectPrototypeSymbols, key)) return;\n var descriptor = nativeGetOwnPropertyDescriptor(it, key);\n if (descriptor && hasOwn(AllSymbols, key) && !(hasOwn(it, HIDDEN) && it[HIDDEN][key])) {\n descriptor.enumerable = true;\n }\n return descriptor;\n};\n\nvar $getOwnPropertyNames = function getOwnPropertyNames(O) {\n var names = nativeGetOwnPropertyNames(toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (!hasOwn(AllSymbols, key) && !hasOwn(hiddenKeys, key)) push(result, key);\n });\n return result;\n};\n\nvar $getOwnPropertySymbols = function (O) {\n var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;\n var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));\n var result = [];\n $forEach(names, function (key) {\n if (hasOwn(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || hasOwn(ObjectPrototype, key))) {\n push(result, AllSymbols[key]);\n }\n });\n return result;\n};\n\n// `Symbol` constructor\n// https://tc39.es/ecma262/#sec-symbol-constructor\nif (!NATIVE_SYMBOL) {\n $Symbol = function Symbol() {\n if (isPrototypeOf(SymbolPrototype, this)) throw new TypeError('Symbol is not a constructor');\n var description = !arguments.length || arguments[0] === undefined ? undefined : $toString(arguments[0]);\n var tag = uid(description);\n var setter = function (value) {\n var $this = this === undefined ? global : this;\n if ($this === ObjectPrototype) call(setter, ObjectPrototypeSymbols, value);\n if (hasOwn($this, HIDDEN) && hasOwn($this[HIDDEN], tag)) $this[HIDDEN][tag] = false;\n var descriptor = createPropertyDescriptor(1, value);\n try {\n setSymbolDescriptor($this, tag, descriptor);\n } catch (error) {\n if (!(error instanceof RangeError)) throw error;\n fallbackDefineProperty($this, tag, descriptor);\n }\n };\n if (DESCRIPTORS && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });\n return wrap(tag, description);\n };\n\n SymbolPrototype = $Symbol[PROTOTYPE];\n\n defineBuiltIn(SymbolPrototype, 'toString', function toString() {\n return getInternalState(this).tag;\n });\n\n defineBuiltIn($Symbol, 'withoutSetter', function (description) {\n return wrap(uid(description), description);\n });\n\n propertyIsEnumerableModule.f = $propertyIsEnumerable;\n definePropertyModule.f = $defineProperty;\n definePropertiesModule.f = $defineProperties;\n getOwnPropertyDescriptorModule.f = $getOwnPropertyDescriptor;\n getOwnPropertyNamesModule.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames;\n getOwnPropertySymbolsModule.f = $getOwnPropertySymbols;\n\n wrappedWellKnownSymbolModule.f = function (name) {\n return wrap(wellKnownSymbol(name), name);\n };\n\n if (DESCRIPTORS) {\n // https://github.com/tc39/proposal-Symbol-description\n defineBuiltInAccessor(SymbolPrototype, 'description', {\n configurable: true,\n get: function description() {\n return getInternalState(this).description;\n }\n });\n if (!IS_PURE) {\n defineBuiltIn(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });\n }\n }\n}\n\n$({ global: true, constructor: true, wrap: true, forced: !NATIVE_SYMBOL, sham: !NATIVE_SYMBOL }, {\n Symbol: $Symbol\n});\n\n$forEach(objectKeys(WellKnownSymbolsStore), function (name) {\n defineWellKnownSymbol(name);\n});\n\n$({ target: SYMBOL, stat: true, forced: !NATIVE_SYMBOL }, {\n useSetter: function () { USE_SETTER = true; },\n useSimple: function () { USE_SETTER = false; }\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL, sham: !DESCRIPTORS }, {\n // `Object.create` method\n // https://tc39.es/ecma262/#sec-object.create\n create: $create,\n // `Object.defineProperty` method\n // https://tc39.es/ecma262/#sec-object.defineproperty\n defineProperty: $defineProperty,\n // `Object.defineProperties` method\n // https://tc39.es/ecma262/#sec-object.defineproperties\n defineProperties: $defineProperties,\n // `Object.getOwnPropertyDescriptor` method\n // https://tc39.es/ecma262/#sec-object.getownpropertydescriptors\n getOwnPropertyDescriptor: $getOwnPropertyDescriptor\n});\n\n$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL }, {\n // `Object.getOwnPropertyNames` method\n // https://tc39.es/ecma262/#sec-object.getownpropertynames\n getOwnPropertyNames: $getOwnPropertyNames\n});\n\n// `Symbol.prototype[@@toPrimitive]` method\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive\ndefineSymbolToPrimitive();\n\n// `Symbol.prototype[@@toStringTag]` property\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@tostringtag\nsetToStringTag($Symbol, SYMBOL);\n\nhiddenKeys[HIDDEN] = true;\n","'use strict';\nvar $ = require('../internals/export');\nvar getBuiltIn = require('../internals/get-built-in');\nvar hasOwn = require('../internals/has-own-property');\nvar toString = require('../internals/to-string');\nvar shared = require('../internals/shared');\nvar NATIVE_SYMBOL_REGISTRY = require('../internals/symbol-registry-detection');\n\nvar StringToSymbolRegistry = shared('string-to-symbol-registry');\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\n\n// `Symbol.for` method\n// https://tc39.es/ecma262/#sec-symbol.for\n$({ target: 'Symbol', stat: true, forced: !NATIVE_SYMBOL_REGISTRY }, {\n 'for': function (key) {\n var string = toString(key);\n if (hasOwn(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];\n var symbol = getBuiltIn('Symbol')(string);\n StringToSymbolRegistry[string] = symbol;\n SymbolToStringRegistry[symbol] = string;\n return symbol;\n }\n});\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.hasInstance` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.hasinstance\ndefineWellKnownSymbol('hasInstance');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.isConcatSpreadable` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.isconcatspreadable\ndefineWellKnownSymbol('isConcatSpreadable');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.iterator` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.iterator\ndefineWellKnownSymbol('iterator');\n","'use strict';\n// TODO: Remove this module from `core-js@4` since it's split to modules listed below\nrequire('../modules/es.symbol.constructor');\nrequire('../modules/es.symbol.for');\nrequire('../modules/es.symbol.key-for');\nrequire('../modules/es.json.stringify');\nrequire('../modules/es.object.get-own-property-symbols');\n","'use strict';\nvar $ = require('../internals/export');\nvar hasOwn = require('../internals/has-own-property');\nvar isSymbol = require('../internals/is-symbol');\nvar tryToString = require('../internals/try-to-string');\nvar shared = require('../internals/shared');\nvar NATIVE_SYMBOL_REGISTRY = require('../internals/symbol-registry-detection');\n\nvar SymbolToStringRegistry = shared('symbol-to-string-registry');\n\n// `Symbol.keyFor` method\n// https://tc39.es/ecma262/#sec-symbol.keyfor\n$({ target: 'Symbol', stat: true, forced: !NATIVE_SYMBOL_REGISTRY }, {\n keyFor: function keyFor(sym) {\n if (!isSymbol(sym)) throw new TypeError(tryToString(sym) + ' is not a symbol');\n if (hasOwn(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];\n }\n});\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.matchAll` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.matchall\ndefineWellKnownSymbol('matchAll');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.match` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.match\ndefineWellKnownSymbol('match');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.replace` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.replace\ndefineWellKnownSymbol('replace');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.search` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.search\ndefineWellKnownSymbol('search');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.species` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.species\ndefineWellKnownSymbol('species');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.split` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.split\ndefineWellKnownSymbol('split');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\nvar defineSymbolToPrimitive = require('../internals/symbol-define-to-primitive');\n\n// `Symbol.toPrimitive` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.toprimitive\ndefineWellKnownSymbol('toPrimitive');\n\n// `Symbol.prototype[@@toPrimitive]` method\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive\ndefineSymbolToPrimitive();\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\nvar setToStringTag = require('../internals/set-to-string-tag');\n\n// `Symbol.toStringTag` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.tostringtag\ndefineWellKnownSymbol('toStringTag');\n\n// `Symbol.prototype[@@toStringTag]` property\n// https://tc39.es/ecma262/#sec-symbol.prototype-@@tostringtag\nsetToStringTag(getBuiltIn('Symbol'), 'Symbol');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.unscopables` well-known symbol\n// https://tc39.es/ecma262/#sec-symbol.unscopables\ndefineWellKnownSymbol('unscopables');\n","'use strict';\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar defineProperty = require('../internals/object-define-property').f;\n\nvar METADATA = wellKnownSymbol('metadata');\nvar FunctionPrototype = Function.prototype;\n\n// Function.prototype[@@metadata]\n// https://github.com/tc39/proposal-decorator-metadata\nif (FunctionPrototype[METADATA] === undefined) {\n defineProperty(FunctionPrototype, METADATA, {\n value: null\n });\n}\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.asyncDispose` well-known symbol\n// https://github.com/tc39/proposal-async-explicit-resource-management\ndefineWellKnownSymbol('asyncDispose');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.dispose` well-known symbol\n// https://github.com/tc39/proposal-explicit-resource-management\ndefineWellKnownSymbol('dispose');\n","'use strict';\nvar $ = require('../internals/export');\nvar isRegisteredSymbol = require('../internals/symbol-is-registered');\n\n// `Symbol.isRegisteredSymbol` method\n// https://tc39.es/proposal-symbol-predicates/#sec-symbol-isregisteredsymbol\n$({ target: 'Symbol', stat: true }, {\n isRegisteredSymbol: isRegisteredSymbol\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar isRegisteredSymbol = require('../internals/symbol-is-registered');\n\n// `Symbol.isRegistered` method\n// obsolete version of https://tc39.es/proposal-symbol-predicates/#sec-symbol-isregisteredsymbol\n$({ target: 'Symbol', stat: true, name: 'isRegisteredSymbol' }, {\n isRegistered: isRegisteredSymbol\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar isWellKnownSymbol = require('../internals/symbol-is-well-known');\n\n// `Symbol.isWellKnownSymbol` method\n// https://tc39.es/proposal-symbol-predicates/#sec-symbol-iswellknownsymbol\n// We should patch it for newly added well-known symbols. If it's not required, this module just will not be injected\n$({ target: 'Symbol', stat: true, forced: true }, {\n isWellKnownSymbol: isWellKnownSymbol\n});\n","'use strict';\nvar $ = require('../internals/export');\nvar isWellKnownSymbol = require('../internals/symbol-is-well-known');\n\n// `Symbol.isWellKnown` method\n// obsolete version of https://tc39.es/proposal-symbol-predicates/#sec-symbol-iswellknownsymbol\n// We should patch it for newly added well-known symbols. If it's not required, this module just will not be injected\n$({ target: 'Symbol', stat: true, name: 'isWellKnownSymbol', forced: true }, {\n isWellKnown: isWellKnownSymbol\n});\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.matcher` well-known symbol\n// https://github.com/tc39/proposal-pattern-matching\ndefineWellKnownSymbol('matcher');\n","'use strict';\n// TODO: Remove from `core-js@4`\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.metadataKey` well-known symbol\n// https://github.com/tc39/proposal-decorator-metadata\ndefineWellKnownSymbol('metadataKey');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.metadata` well-known symbol\n// https://github.com/tc39/proposal-decorators\ndefineWellKnownSymbol('metadata');\n","'use strict';\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.observable` well-known symbol\n// https://github.com/tc39/proposal-observable\ndefineWellKnownSymbol('observable');\n","'use strict';\n// TODO: remove from `core-js@4`\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\n// `Symbol.patternMatch` well-known symbol\n// https://github.com/tc39/proposal-pattern-matching\ndefineWellKnownSymbol('patternMatch');\n","'use strict';\n// TODO: remove from `core-js@4`\nvar defineWellKnownSymbol = require('../internals/well-known-symbol-define');\n\ndefineWellKnownSymbol('replaceAll');\n","'use strict';\nrequire('../modules/es.array.iterator');\nvar DOMIterables = require('../internals/dom-iterables');\nvar global = require('../internals/global');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar Iterators = require('../internals/iterators');\n\nfor (var COLLECTION_NAME in DOMIterables) {\n setToStringTag(global[COLLECTION_NAME], COLLECTION_NAME);\n Iterators[COLLECTION_NAME] = Iterators.Array;\n}\n","'use strict';\nvar parent = require('../../es/object/define-property');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../es/symbol');\nrequire('../../modules/web.dom-collections.iterator');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../es/symbol/iterator');\nrequire('../../modules/web.dom-collections.iterator');\n\nmodule.exports = parent;\n","'use strict';\nvar parent = require('../../es/symbol/to-primitive');\n\nmodule.exports = parent;\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","/**\n * Big Number Helpers\n */\nimport BigNumber from 'bignumber.js';\n\n/**\n * Check if value is BigNumber, Number, BigInt or number string representation\n * @param number - number to check\n */\nexport const isBigNumber = (number: string | number | bigint | BigNumber): boolean => {\n if (typeof number === 'bigint') return true;\n return ['number', 'object', 'string'].includes(typeof number)\n // eslint-disable-next-line no-restricted-globals\n && (!isNaN(number as number) || Number.isInteger(number) || BigNumber.isBigNumber(number));\n};\n\n/**\n * BigNumber ceil operation\n */\nexport const ceil = (bigNumber: BigNumber): BigNumber => bigNumber\n .integerValue(BigNumber.ROUND_CEIL);\n","// eslint-disable-next-line max-classes-per-file\nimport BigNumber from 'bignumber.js';\nimport { AensName, Int } from '../tx/builder/constants';\nimport * as Encoded from './encoder-types';\n\n/**\n * aepp-sdk originated error\n * @category exception\n */\nexport abstract class BaseError extends Error {\n constructor(message: string) {\n super(message);\n this.name = 'BaseError';\n }\n}\n\n/**\n * @category exception\n */\nexport class AccountError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'AccountError';\n }\n}\n\n/**\n * @category exception\n */\nexport class AensError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'AensError';\n }\n}\n\n/**\n * @category exception\n */\nexport class AeppError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'AeppError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ChannelError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'ChannelError';\n }\n}\n\n/**\n * @category exception\n */\nexport class CompilerError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'CompilerError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ContractError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'ContractError';\n }\n}\n\n/**\n * @category exception\n */\nexport class CryptographyError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'CryptographyError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NodeError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'NodeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class TransactionError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'TransactionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class WalletError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'WalletError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ArgumentError extends BaseError {\n constructor(argumentName: string, requirement: unknown, argumentValue: unknown) {\n super(`${argumentName} should be ${requirement}, got ${argumentValue} instead`);\n this.name = 'ArgumentError';\n }\n}\n\n/**\n * @category exception\n */\nexport class IllegalArgumentError extends CryptographyError {\n constructor(message: string) {\n super(message);\n this.name = 'IllegalArgumentError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ArgumentCountMismatchError extends BaseError {\n constructor(functionName: string, requiredCount: number, providedCount: number) {\n super(`${functionName} expects ${requiredCount} arguments, got ${providedCount} instead`);\n this.name = 'ArgumentCountMismatchError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InsufficientBalanceError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'InsufficientBalanceError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingParamError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'MissingParamError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NoSerializerFoundError extends BaseError {\n constructor() {\n super('Byte serialization not supported');\n this.name = 'NoSerializerFoundError';\n }\n}\n\n/**\n * @category exception\n */\nexport class RequestTimedOutError extends BaseError {\n constructor(height: number) {\n super(`Giving up at height ${height}`);\n this.name = 'RequestTimedOutError';\n }\n}\n\n/**\n * @category exception\n */\nexport class TxTimedOutError extends BaseError {\n constructor(blocks: number, th: Encoded.TxHash) {\n super([\n `Giving up after ${blocks} blocks mined`,\n `transaction hash: ${th}`,\n ].join(', '));\n this.name = 'TxTimedOutError';\n }\n}\n\n/**\n * @category exception\n */\nexport class TypeError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'TypeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnsupportedPlatformError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'UnsupportedPlatformError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnsupportedProtocolError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'UnsupportedProtocolError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NotImplementedError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'NotImplementedError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnsupportedVersionError extends BaseError {\n constructor(dependency: string, version: string, geVersion: string, ltVersion: string) {\n super(`Unsupported ${dependency} version ${version}. Supported: >= ${geVersion} < ${ltVersion}`);\n this.name = 'UnsupportedVersionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class LogicError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'LogicError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InternalError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'InternalError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnexpectedTsError extends InternalError {\n constructor(message = 'Expected to not happen, required for TS') {\n super(message);\n this.name = 'UnexpectedTsError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnavailableAccountError extends AccountError {\n constructor(address: Encoded.AccountAddress) {\n super(`Account for ${address} not available`);\n this.name = 'UnavailableAccountError';\n }\n}\n\n/**\n * @category exception\n */\nexport class AensPointerContextError extends AensError {\n constructor(nameOrId: AensName | Encoded.Name, prefix: string) {\n super(`Name ${nameOrId} don't have pointers for ${prefix}`);\n this.name = 'AensPointerContextError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InsufficientNameFeeError extends AensError {\n constructor(nameFee: BigNumber, minNameFee: BigNumber) {\n super(`the provided fee ${nameFee.toString()} is not enough to execute the claim, required: ${minNameFee.toString()}`);\n this.name = 'InsufficientNameFeeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidAensNameError extends AensError {\n constructor(message: string) {\n super(message);\n this.name = 'InvalidAensNameError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidRpcMessageError extends AeppError {\n constructor(message: string) {\n super(`Received invalid message: ${message}`);\n this.name = 'InvalidRpcMessageError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingCallbackError extends AeppError {\n constructor(id: number) {\n super(`Can't find callback for this messageId ${id}`);\n this.name = 'MissingCallbackError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnAuthorizedAccountError extends AeppError {\n constructor(onAccount: Encoded.AccountAddress) {\n super(`You do not have access to account ${onAccount}`);\n this.name = 'UnAuthorizedAccountError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnknownRpcClientError extends AeppError {\n constructor(id: string) {\n super(`RpcClient with id ${id} do not exist`);\n this.name = 'UnknownRpcClientError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnsubscribedAccountError extends AeppError {\n constructor() {\n super('You are not subscribed for an account.');\n this.name = 'UnsubscribedAccountError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ChannelCallError extends ChannelError {\n constructor(message: string) {\n super(message);\n this.name = 'ChannelCallError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ChannelConnectionError extends ChannelError {\n constructor(message: string) {\n super(message);\n this.name = 'ChannelConnectionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ChannelPingTimedOutError extends ChannelError {\n constructor() {\n super('Server pong timed out');\n this.name = 'ChannelPingTimedOutError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnexpectedChannelMessageError extends ChannelError {\n constructor(message: string) {\n super(message);\n this.name = 'UnexpectedChannelMessageError';\n }\n}\n\n/**\n * @category exception\n */\nexport class ChannelIncomingMessageError extends ChannelError {\n handlerError: Error;\n\n incomingMessage: { [key: string]: any };\n\n constructor(handlerError: Error, incomingMessage: { [key: string]: any }) {\n super(handlerError.message);\n this.handlerError = handlerError;\n this.incomingMessage = incomingMessage;\n this.name = 'ChannelIncomingMessageError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnknownChannelStateError extends ChannelError {\n constructor() {\n super('State Channels FSM entered unknown state');\n this.name = 'UnknownChannelStateError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidAuthDataError extends CompilerError {\n constructor(message: string) {\n super(message);\n this.name = 'InvalidAuthDataError';\n }\n}\n\n/**\n * @category exception\n */\nexport class BytecodeMismatchError extends ContractError {\n constructor(source: 'source code' | 'bytecode') {\n super(`Contract ${source} do not correspond to the bytecode deployed on the chain`);\n this.name = 'BytecodeMismatchError';\n }\n}\n\n/**\n * @category exception\n */\nexport class DuplicateContractError extends ContractError {\n constructor() {\n super('Contract already deployed');\n this.name = 'DuplicateContractError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InactiveContractError extends ContractError {\n constructor(contractAddress: Encoded.ContractAddress) {\n super(`Contract with address ${contractAddress} not active`);\n this.name = 'InactiveContractError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidMethodInvocationError extends ContractError {\n constructor(message: string) {\n super(message);\n this.name = 'InvalidMethodInvocationError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingContractAddressError extends ContractError {\n constructor(message: string) {\n super(message);\n this.name = 'MissingContractAddressError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingContractDefError extends ContractError {\n constructor() {\n super('Either ACI or sourceCode or sourceCodePath is required');\n this.name = 'MissingContractDefError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingFunctionNameError extends ContractError {\n constructor() {\n super('Function name is required');\n this.name = 'MissingFunctionNameError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NodeInvocationError extends ContractError {\n transaction?: Encoded.Transaction;\n\n constructor(message: string, transaction?: Encoded.Transaction) {\n super(`Invocation failed${message == null ? '' : `: \"${message}\"`}`);\n this.name = 'NodeInvocationError';\n this.transaction = transaction;\n }\n}\n\n/**\n * @category exception\n */\nexport class NoSuchContractFunctionError extends ContractError {\n constructor(name: string) {\n super(`Function ${name} doesn't exist in contract`);\n this.name = 'NoSuchContractFunctionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NotPayableFunctionError extends ContractError {\n constructor(amount: Int, fn: string) {\n super(\n `You try to pay \"${amount}\" to function \"${fn}\" which is not payable. `\n + 'Only payable function can accept coins',\n );\n this.name = 'NotPayableFunctionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingEventDefinitionError extends ContractError {\n constructor(eventNameHash: string, eventAddress: Encoded.ContractAddress) {\n super(\n `Can't find definition of ${eventNameHash} event emitted by ${eventAddress}`\n + ' (use omitUnknown option to ignore events like this)',\n );\n this.name = 'MissingEventDefinitionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class AmbiguousEventDefinitionError extends ContractError {\n constructor(eventAddress: Encoded.ContractAddress, matchedEvents: Array<[string, string]>) {\n super(\n `Found multiple definitions of \"${matchedEvents[0][1]}\" event with different types emitted by`\n + ` ${eventAddress} in ${matchedEvents.map(([name]) => `\"${name}\"`).join(', ')} contracts`\n + ' (use contractAddressToName option to specify contract name corresponding to address)',\n );\n this.name = 'AmbiguousEventDefinitionError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidChecksumError extends CryptographyError {\n constructor() {\n super('Invalid checksum');\n this.name = 'InvalidChecksumError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidPasswordError extends CryptographyError {\n constructor() {\n super('Invalid password or nonce');\n this.name = 'InvalidPasswordError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MerkleTreeHashMismatchError extends CryptographyError {\n constructor() {\n super('Node hash is not equal to provided one');\n this.name = 'MerkleTreeHashMismatchError';\n }\n}\n\n/**\n * @category exception\n */\nexport class MissingNodeInTreeError extends CryptographyError {\n constructor(message: string) {\n super(message);\n this.name = 'MissingNodeInTreeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnknownNodeLengthError extends CryptographyError {\n constructor(nodeLength: number) {\n super(`Unknown node length: ${nodeLength}`);\n this.name = 'UnknownNodeLengthError';\n }\n}\n\n/**\n * @category exception\n */\nexport class UnknownPathNibbleError extends CryptographyError {\n constructor(nibble: number) {\n super(`Unknown path nibble: ${nibble}`);\n this.name = 'UnknownPathNibbleError';\n }\n}\n\n/**\n * @category exception\n */\nexport class DuplicateNodeError extends NodeError {\n constructor(name: string) {\n super(`Node with name ${name} already exist`);\n this.name = 'DuplicateNodeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NodeNotFoundError extends NodeError {\n constructor(message: string) {\n super(message);\n this.name = 'NodeNotFoundError';\n }\n}\n\n/**\n * @category exception\n */\nexport class DecodeError extends TransactionError {\n constructor(message: string) {\n super(message);\n this.name = 'DecodeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class PayloadLengthError extends TransactionError {\n constructor(message: string) {\n super(message);\n this.name = 'PayloadLengthError';\n }\n}\n\n/**\n * @category exception\n */\nexport class DryRunError extends TransactionError {\n constructor(message: string) {\n super(message);\n this.name = 'DryRunError';\n }\n}\n\n/**\n * @category exception\n */\nexport class IllegalBidFeeError extends TransactionError {\n constructor(message: string) {\n super(message);\n this.name = 'IllegalBidFeeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class InvalidSignatureError extends TransactionError {\n constructor(message: string) {\n super(message);\n this.name = 'InvalidSignatureError';\n }\n}\n\n/**\n * @category exception\n */\nexport class PrefixNotFoundError extends TransactionError {\n constructor(tag: number) {\n super(`Prefix for id-tag ${tag} not found.`);\n this.name = 'PrefixNotFoundError';\n }\n}\n\n/**\n * @category exception\n */\nexport class SchemaNotFoundError extends TransactionError {\n constructor(key: string, version: number) {\n super(`Transaction schema not implemented for tag ${key} version ${version}`);\n this.name = 'SchemaNotFoundError';\n }\n}\n\n/**\n * @category exception\n */\nexport class TagNotFoundError extends TransactionError {\n constructor(prefix: string) {\n super(`Id tag for prefix ${prefix} not found.`);\n this.name = 'DecodeError';\n }\n}\n\n/**\n * @category exception\n */\nexport class TxNotInChainError extends TransactionError {\n constructor(txHash: Encoded.TxHash) {\n super(`Transaction ${txHash} is removed from chain`);\n this.name = 'TxNotInChainError';\n }\n}\n\n/**\n * @category exception\n */\nexport class AlreadyConnectedError extends WalletError {\n constructor(message: string) {\n super(message);\n this.name = 'AlreadyConnectedError';\n }\n}\n\n/**\n * @category exception\n */\nexport class NoWalletConnectedError extends WalletError {\n constructor(message: string) {\n super(message);\n this.name = 'NoWalletConnectedError';\n }\n}\n\n/**\n * @category exception\n */\nexport class RpcConnectionError extends WalletError {\n constructor(message: string) {\n super(message);\n this.name = 'RpcConnectionError';\n }\n}\n","import BigNumber from 'bignumber.js';\nimport { isBigNumber } from './bignumber';\nimport { ArgumentError } from './errors';\n\nexport enum AE_AMOUNT_FORMATS {\n AE = 'ae',\n MILI_AE = 'miliAE',\n MICRO_AE = 'microAE',\n NANO_AE = 'nanoAE',\n PICO_AE = 'picoAE',\n FEMTO_AE = 'femtoAE',\n AETTOS = 'aettos',\n}\n\n/**\n * DENOMINATION_MAGNITUDE\n */\nconst DENOMINATION_MAGNITUDE = {\n [AE_AMOUNT_FORMATS.AE]: 0,\n [AE_AMOUNT_FORMATS.MILI_AE]: -3,\n [AE_AMOUNT_FORMATS.MICRO_AE]: -6,\n [AE_AMOUNT_FORMATS.NANO_AE]: -9,\n [AE_AMOUNT_FORMATS.PICO_AE]: -12,\n [AE_AMOUNT_FORMATS.FEMTO_AE]: -15,\n [AE_AMOUNT_FORMATS.AETTOS]: -18,\n} as const;\n\n/**\n * Convert amount from one to other denomination\n * @param value - amount to convert\n * @param options - options\n * @param options.denomination - denomination of amount, can be ['ae', 'aettos']\n * @param options.targetDenomination - target denomination,\n * can be ['ae', 'aettos']\n */\nexport const formatAmount = (\n value: string | number | bigint | BigNumber,\n { denomination = AE_AMOUNT_FORMATS.AETTOS, targetDenomination = AE_AMOUNT_FORMATS.AETTOS }:\n { denomination?: AE_AMOUNT_FORMATS; targetDenomination?: AE_AMOUNT_FORMATS },\n): string => {\n if (!isBigNumber(value)) throw new ArgumentError('value', 'a number', value);\n\n return new BigNumber(typeof value === 'bigint' ? value.toString() : value)\n .shiftedBy(DENOMINATION_MAGNITUDE[denomination] - DENOMINATION_MAGNITUDE[targetDenomination])\n .toFixed();\n};\n\n/**\n * Convert amount to AE\n * @param value - amount to convert\n * @param options - options\n * @param options.denomination - denomination of amount, can be ['ae', 'aettos']\n */\nexport const toAe = (\n value: string | number | BigNumber,\n { denomination = AE_AMOUNT_FORMATS.AETTOS }: { denomination?: AE_AMOUNT_FORMATS } = {},\n): string => formatAmount(value, { denomination, targetDenomination: AE_AMOUNT_FORMATS.AE });\n\n/**\n * Convert amount to aettos\n * @param value - amount to convert\n * @param options - options\n * @param options.denomination - denomination of amount, can be ['ae', 'aettos']\n */\nexport const toAettos = (\n value: string | number | BigNumber,\n { denomination = AE_AMOUNT_FORMATS.AE }: { denomination?: AE_AMOUNT_FORMATS } = {},\n): string => formatAmount(value, { denomination });\n\ninterface Prefix {\n name: string;\n magnitude: number;\n}\n\nconst prefixes: Prefix[] = [\n { name: 'exa', magnitude: 18 },\n { name: 'giga', magnitude: 9 },\n { name: '', magnitude: 0 },\n { name: 'pico', magnitude: -12 },\n];\n\nconst getNearestPrefix = (exponent: number): Prefix => prefixes.reduce((p, n) => (\n Math.abs(n.magnitude - exponent) < Math.abs(p.magnitude - exponent) ? n : p));\n\nconst getLowerBoundPrefix = (exponent: number): Prefix => prefixes\n .find((p) => p.magnitude <= exponent) ?? prefixes[prefixes.length - 1];\n\nexport const prefixedAmount = (rawValue: string | number | BigNumber): string => {\n const value: BigNumber = new BigNumber(rawValue);\n\n const exp = value.e ?? 0;\n const { name, magnitude } = (exp < 0 ? getNearestPrefix : getLowerBoundPrefix)(exp);\n const v = value\n .shiftedBy(-magnitude)\n .precision(9 + Math.min(exp - magnitude, 0))\n .toFixed();\n return `${v}${name !== '' ? ' ' : ''}${name}`;\n};\n","import { RestError } from '@azure/core-rest-pipeline';\n\nexport const pause = async (duration: number): Promise<void> => new Promise((resolve) => {\n setTimeout(resolve, duration);\n});\n\nexport const mapObject = <InputV, OutputV>(\n object: { [k: string]: InputV },\n fn: (\n value: [string, InputV], index: number, array: Array<[string, InputV]>\n ) => [number | string, OutputV],\n): { [k: string]: OutputV } => Object.fromEntries(Object.entries(object).map(fn));\n\n// remove after dropping webpack4 support\nconst isWebpack4Buffer = (() => {\n try {\n Buffer.concat([Uint8Array.from([])]);\n return false;\n } catch (error) {\n return true;\n }\n})();\n\nexport const concatBuffers = isWebpack4Buffer\n ? (list: readonly Uint8Array[], totalLength?: number): Buffer => (\n Buffer.concat(list.map((el) => Buffer.from(el)), totalLength)\n )\n : Buffer.concat;\n\n/**\n * Object key type guard\n * @param key - Maybe object key\n * @param object - Object\n */\nexport function isKeyOfObject<T extends object>(\n key: string | number | symbol,\n object: T,\n): key is keyof T {\n return key in object;\n}\n\n/**\n * Array item type guard\n * @param item - Maybe array item\n * @param array - Array\n */\nexport function isItemOfArray<T>(item: any, array: readonly T[]): item is T {\n return array.includes(item);\n}\n\nexport function isAccountNotFoundError(error: Error): boolean {\n return error instanceof RestError && error.statusCode === 404\n && error.message.includes('Account not found');\n}\n\n// based on https://stackoverflow.com/a/50375286/6176994\nexport type UnionToIntersection<Union> =\n (Union extends any ? (k: Union) => void : never) extends ((k: infer Intersection) => void)\n ? Intersection : never;\n\nexport function ensureError(error: unknown): asserts error is Error {\n if (error instanceof Error) return;\n throw error;\n}\n","import { ArgumentError } from './errors';\n\nexport function wrapWithProxy<Value extends object | undefined>(\n valueCb: () => Value,\n): NonNullable<Value> {\n return new Proxy(\n {},\n Object.fromEntries(([\n 'apply', 'construct', 'defineProperty', 'deleteProperty', 'getOwnPropertyDescriptor',\n 'getPrototypeOf', 'isExtensible', 'ownKeys', 'preventExtensions', 'set', 'setPrototypeOf',\n 'get', 'has',\n ] as const).map((name) => [name, (t: {}, ...args: unknown[]) => {\n const target = valueCb();\n if (target == null) throw new ArgumentError('wrapped value', 'defined', target);\n if (name === 'get' && args[0] === '_wrappedValue') return target;\n const res = (Reflect[name] as any)(target, ...args);\n return typeof res === 'function' && name === 'get' ? res.bind(target) : res;\n }])),\n ) as NonNullable<Value>;\n}\n\nexport function unwrapProxy<Value extends object>(value: Value): Value {\n return (value as { _wrappedValue?: Value })._wrappedValue ?? value;\n}\n","/**\n * @category transaction builder\n * @see {@link https://github.com/aeternity/protocol/blob/master/node/api/api_encoding.md}\n * @see {@link https://github.com/aeternity/aeserialization/blob/eb68fe331bd476910394966b7f5ede7a74d37e35/src/aeser_api_encoder.erl#L205-L230}\n */\nexport enum Encoding {\n KeyBlockHash = 'kh',\n MicroBlockHash = 'mh',\n BlockPofHash = 'bf',\n BlockTxHash = 'bx',\n BlockStateHash = 'bs',\n Channel = 'ch',\n ContractAddress = 'ct',\n ContractBytearray = 'cb',\n ContractStoreKey = 'ck',\n ContractStoreValue = 'cv',\n Transaction = 'tx',\n TxHash = 'th',\n OracleAddress = 'ok',\n OracleQuery = 'ov',\n OracleQueryId = 'oq',\n OracleResponse = 'or',\n AccountAddress = 'ak',\n Signature = 'sg',\n Commitment = 'cm',\n PeerPubkey = 'pp',\n Name = 'nm',\n State = 'st',\n Poi = 'pi',\n StateTrees = 'ss',\n CallStateTree = 'cs',\n Bytearray = 'ba',\n}\n\nexport type KeyBlockHash = `${Encoding.KeyBlockHash}_${string}`;\nexport type MicroBlockHash = `${Encoding.MicroBlockHash}_${string}`;\nexport type BlockPofHash = `${Encoding.BlockPofHash}_${string}`;\nexport type BlockTxHash = `${Encoding.BlockTxHash}_${string}`;\nexport type BlockStateHash = `${Encoding.BlockStateHash}_${string}`;\nexport type Channel = `${Encoding.Channel}_${string}`;\nexport type ContractAddress = `${Encoding.ContractAddress}_${string}`;\nexport type ContractBytearray = `${Encoding.ContractBytearray}_${string}`;\nexport type ContractStoreKey = `${Encoding.ContractStoreKey}_${string}`;\nexport type ContractStoreValue = `${Encoding.ContractStoreValue}_${string}`;\nexport type Transaction = `${Encoding.Transaction}_${string}`;\nexport type TxHash = `${Encoding.TxHash}_${string}`;\nexport type OracleAddress = `${Encoding.OracleAddress}_${string}`;\nexport type OracleQuery = `${Encoding.OracleQuery}_${string}`;\nexport type OracleQueryId = `${Encoding.OracleQueryId}_${string}`;\nexport type OracleResponse = `${Encoding.OracleResponse}_${string}`;\nexport type AccountAddress = `${Encoding.AccountAddress}_${string}`;\nexport type Signature = `${Encoding.Signature}_${string}`;\nexport type Commitment = `${Encoding.Commitment}_${string}`;\nexport type PeerPubkey = `${Encoding.PeerPubkey}_${string}`;\nexport type Name = `${Encoding.Name}_${string}`;\nexport type State = `${Encoding.State}_${string}`;\nexport type Poi = `${Encoding.Poi}_${string}`;\nexport type StateTrees = `${Encoding.StateTrees}_${string}`;\nexport type CallStateTree = `${Encoding.CallStateTree}_${string}`;\nexport type Bytearray = `${Encoding.Bytearray}_${string}`;\n\nexport type Generic<Type extends Encoding> = `${Type}_${string}`;\nexport type Any = `${Encoding}_${string}`;\n","import { encode as bs58Encode, decode as bs58Decode } from 'bs58';\n// js extension is required for mjs build, not importing the whole package to reduce bundle size\n// eslint-disable-next-line import/extensions\nimport Sha256 from 'sha.js/sha256.js';\nimport {\n DecodeError,\n ArgumentError,\n InvalidChecksumError,\n PayloadLengthError,\n} from './errors';\nimport { concatBuffers, isKeyOfObject } from './other';\nimport * as Encoded from './encoder-types';\nimport { Encoding } from './encoder-types';\n\nexport { Encoded, Encoding };\n\n/**\n * Calculate SHA256 hash of `input`\n * @param input - Data to hash\n * @returns Hash\n */\nexport function sha256hash(input: Uint8Array | string): Buffer {\n return new Sha256().update(input).digest();\n}\n\n/**\n * @see {@link https://github.com/aeternity/aeserialization/blob/eb68fe331bd476910394966b7f5ede7a74d37e35/src/aeser_api_encoder.erl#L177-L202}\n */\nconst base64Types = [\n Encoding.ContractBytearray,\n Encoding.ContractStoreKey,\n Encoding.ContractStoreValue,\n Encoding.Transaction,\n Encoding.OracleQuery,\n Encoding.OracleResponse,\n Encoding.State,\n Encoding.Poi,\n Encoding.StateTrees,\n Encoding.CallStateTree,\n Encoding.Bytearray,\n] as const;\nconst base58Types = [\n Encoding.KeyBlockHash,\n Encoding.MicroBlockHash,\n Encoding.BlockPofHash,\n Encoding.BlockTxHash,\n Encoding.BlockStateHash,\n Encoding.Channel,\n Encoding.ContractAddress,\n Encoding.TxHash,\n Encoding.OracleAddress,\n Encoding.OracleQueryId,\n Encoding.AccountAddress,\n Encoding.Signature,\n Encoding.Commitment,\n Encoding.PeerPubkey,\n Encoding.Name,\n] as const;\n\n/**\n * @see {@link https://github.com/aeternity/aeserialization/blob/eb68fe331bd476910394966b7f5ede7a74d37e35/src/aeser_api_encoder.erl#L261-L286}\n */\nconst byteSizeForType = {\n [Encoding.KeyBlockHash]: 32,\n [Encoding.MicroBlockHash]: 32,\n [Encoding.BlockPofHash]: 32,\n [Encoding.BlockTxHash]: 32,\n [Encoding.BlockStateHash]: 32,\n [Encoding.Channel]: 32,\n [Encoding.ContractAddress]: 32,\n [Encoding.TxHash]: 32,\n [Encoding.OracleAddress]: 32,\n [Encoding.OracleQueryId]: 32,\n [Encoding.AccountAddress]: 32,\n [Encoding.Signature]: 64,\n [Encoding.Commitment]: 32,\n [Encoding.PeerPubkey]: 32,\n [Encoding.State]: 32,\n} as const;\n\nfunction ensureValidLength(data: Uint8Array, type: Encoding): void {\n if (!isKeyOfObject(type, byteSizeForType)) return;\n const reqLen = byteSizeForType[type];\n if (reqLen == null || data.length === reqLen) return;\n throw new PayloadLengthError(`Payload should be ${reqLen} bytes, got ${data.length} instead`);\n}\n\nconst getChecksum = (payload: Uint8Array): Buffer => sha256hash(sha256hash(payload)).slice(0, 4);\n\nconst addChecksum = (payload: Uint8Array): Buffer => concatBuffers([payload, getChecksum(payload)]);\n\nfunction getPayload(buffer: Buffer): Buffer {\n const payload = buffer.slice(0, -4);\n if (!getChecksum(payload).equals(buffer.slice(-4))) throw new InvalidChecksumError();\n return payload;\n}\n\nconst base64 = {\n encode: (buffer: Uint8Array) => addChecksum(buffer).toString('base64'),\n decode: (string: string) => getPayload(Buffer.from(string, 'base64')),\n};\n\nconst base58 = {\n encode: (buffer: Uint8Array) => bs58Encode(addChecksum(buffer)),\n decode: (string: string) => getPayload(Buffer.from(bs58Decode(string))),\n};\n\nconst parseType = (maybeType: unknown): [Encoding, typeof base64] => {\n const base64Type = base64Types.find((t) => t === maybeType);\n if (base64Type != null) return [base64Type, base64];\n const base58Type = base58Types.find((t) => t === maybeType);\n if (base58Type != null) return [base58Type, base58];\n throw new ArgumentError('prefix', `one of ${[...base58Types, ...base64Types].join(', ')}`, maybeType);\n};\n\n/**\n * Decode data using the default encoding/decoding algorithm\n * @param data - An Base58/64check encoded and prefixed string\n * (ex tx_..., sg_..., ak_....)\n * @returns Decoded data\n */\nexport function decode(data: Encoded.Any): Buffer {\n const [prefix, encodedPayload, extra] = data.split('_');\n if (encodedPayload == null) throw new DecodeError(`Encoded string missing payload: ${data}`);\n if (extra != null) throw new DecodeError(`Encoded string have extra parts: ${data}`);\n const [type, encoder] = parseType(prefix);\n const payload = encoder.decode(encodedPayload);\n ensureValidLength(payload, type);\n return payload;\n}\n\n/**\n * Encode data using the default encoding/decoding algorithm\n * @param data - An decoded data\n * @param type - Prefix of Transaction\n * @returns Encoded string Base58check or Base64check data\n */\nexport function encode<Type extends Encoding>(\n data: Uint8Array,\n type: Type,\n): Encoded.Generic<Type> {\n const [, encoder] = parseType(type);\n ensureValidLength(data, type);\n return `${type}_${encoder.encode(data)}`;\n}\n","import nacl, { SignKeyPair } from 'tweetnacl';\n// js extension is required for mjs build, not importing the whole package to reduce bundle size\n// eslint-disable-next-line import/extensions\nimport { blake2b } from 'blakejs/blake2b.js';\nimport { encode as varuintEncode } from 'varuint-bitcoin';\n\nimport { concatBuffers, isItemOfArray } from './other';\nimport {\n decode, encode, Encoded, Encoding,\n} from './encoder';\nimport { ArgumentError } from './errors';\n\n/**\n * Generate address from secret key\n * @param secret - Private key as hex string\n * @returns Public key encoded as address\n */\nexport function getAddressFromPriv(secret: string | Uint8Array): Encoded.AccountAddress {\n const secretBuffer = typeof secret === 'string' ? Buffer.from(secret, 'hex') : secret;\n const keys = nacl.sign.keyPair.fromSecretKey(secretBuffer);\n return encode(keys.publicKey, Encoding.AccountAddress);\n}\n\n/**\n * Check if address is valid\n * @param maybeAddress - Address to check\n */\nexport function isAddressValid(maybeAddress: string): maybeAddress is Encoded.AccountAddress;\n/**\n * Check if data is encoded in one of provided encodings\n * @param maybeEncoded - Data to check\n * @param encodings - Rest parameters with encodings to check against\n */\nexport function isAddressValid<E extends Encoding>(\n maybeEncoded: string,\n ...encodings: E[]\n): maybeEncoded is Encoded.Generic<E>;\nexport function isAddressValid(maybeEncoded: string, ...encodings: Encoding[]): boolean {\n if (encodings.length === 0) encodings = [Encoding.AccountAddress];\n try {\n decode(maybeEncoded as Encoded.Any);\n const encoding = maybeEncoded.split('_')[0];\n if (!isItemOfArray(encoding, encodings)) {\n throw new ArgumentError(\n 'Encoded string type',\n encodings.length > 1 ? `one of ${encodings.join(', ')}` : encodings[0],\n encoding,\n );\n }\n return true;\n } catch (error) {\n return false;\n }\n}\n\n/**\n * Generate a random salt (positive integer)\n * @returns random salt\n */\nexport function genSalt(): number {\n const [random] = new BigUint64Array(nacl.randomBytes(8).buffer);\n return Number(random % BigInt(Number.MAX_SAFE_INTEGER));\n}\n\n/**\n * Converts a positive integer to the smallest possible\n * representation in a binary digit representation\n * @param value - Value to encode\n * @returns Encoded number\n */\nexport function encodeUnsigned(value: number): Buffer {\n const binary = Buffer.allocUnsafe(4);\n binary.writeUInt32BE(value);\n return binary.slice(binary.findIndex((i) => i !== 0));\n}\n\n/**\n * Calculate 256bits Blake2b hash of `input`\n * @param input - Data to hash\n * @returns Hash\n */\nexport function hash(input: string | Uint8Array): Buffer {\n return Buffer.from(blake2b(input, undefined, 32)); // 256 bits\n}\n\n// Todo Duplicated in tx builder. remove\n/**\n * Compute contract address\n * @category contract\n * @param owner - Address of contract owner\n * @param nonce - Round when contract was created\n * @returns Contract address\n */\nexport function encodeContractAddress(\n owner: Encoded.AccountAddress,\n nonce: number,\n): Encoded.ContractAddress {\n const publicKey = decode(owner);\n const binary = concatBuffers([publicKey, encodeUnsigned(nonce)]);\n return encode(hash(binary), Encoding.ContractAddress);\n}\n\n// KEY-PAIR HELPERS\n\n/**\n * Generate keyPair from secret key\n * @param secret - secret key\n * @returns Object with Private(privateKey) and Public(publicKey) keys\n */\nexport function generateKeyPairFromSecret(secret: Uint8Array): SignKeyPair {\n return nacl.sign.keyPair.fromSecretKey(secret);\n}\n\n/**\n * Generate a random ED25519 keypair\n * @param raw - Whether to return raw (binary) keys\n * @returns Key pair\n */\nexport function generateKeyPair(raw: true): { publicKey: Buffer; secretKey: Buffer };\nexport function generateKeyPair(raw?: false): {\n publicKey: Encoded.AccountAddress; secretKey: string;\n};\nexport function generateKeyPair(raw = false): {\n publicKey: Encoded.AccountAddress | Buffer;\n secretKey: string | Buffer;\n} {\n const keyPair = nacl.sign.keyPair();\n const publicBuffer = Buffer.from(keyPair.publicKey);\n const secretBuffer = Buffer.from(keyPair.secretKey);\n\n if (raw) {\n return {\n publicKey: publicBuffer,\n secretKey: secretBuffer,\n };\n }\n return {\n publicKey: encode(publicBuffer, Encoding.AccountAddress),\n secretKey: secretBuffer.toString('hex'),\n };\n}\n\n// SIGNATURES\n\n/**\n * Generate signature\n * @param data - Data to sign\n * @param privateKey - Key to sign with\n * @returns Signature\n */\nexport function sign(data: string | Uint8Array, privateKey: string | Uint8Array): Uint8Array {\n return nacl.sign.detached(Buffer.from(data), Buffer.from(privateKey));\n}\n\n/**\n * Verify that signature was signed by public key\n * @param data - Data that was signed\n * @param signature - Signature of data\n * @param address - Address to verify against\n * @returns is data was signed by address\n */\nexport function verify(\n data: Uint8Array,\n signature: Uint8Array,\n address: Encoded.AccountAddress,\n): boolean {\n return nacl.sign.detached.verify(data, signature, decode(address));\n}\n\nconst messagePrefix = Buffer.from('aeternity Signed Message:\\n', 'utf8');\nexport const messagePrefixLength = varuintEncode(messagePrefix.length);\n\n// TODO: consider rename to hashMessage\nexport function messageToHash(message: string): Buffer {\n const msg = Buffer.from(message, 'utf8');\n return hash(concatBuffers([messagePrefixLength, messagePrefix, varuintEncode(msg.length), msg]));\n}\n\nexport function signMessage(message: string, privateKey: string | Buffer): Uint8Array {\n return sign(messageToHash(message), privateKey);\n}\n\n/**\n * Verify that message was signed by address\n * @param message - Message that was signed\n * @param signature - Signature of message\n * @param address - Address to verify against\n * @returns is data was signed by address\n */\n// TODO: deprecate in favour of `verify(messageToHash(message), ...`, also the name is confusing\n// it should contain \"signature\"\nexport function verifyMessage(\n message: string,\n signature: Uint8Array,\n address: Encoded.AccountAddress,\n): boolean {\n return verify(messageToHash(message), signature, address);\n}\n\n/**\n * Check key pair for validity\n *\n * Signs a message, and then verifies that signature\n * @param privateKey - Private key to verify\n * @param publicKey - Public key to verify as hex string\n * @returns Valid?\n */\nexport function isValidKeypair(\n privateKey: string | Uint8Array,\n publicKey: string | Uint8Array,\n): boolean {\n const message = Buffer.from('TheMessage');\n const signature = sign(message, privateKey);\n const publicKeyBuffer = typeof publicKey === 'string' ? Buffer.from(publicKey, 'hex') : publicKey;\n return verify(message, signature, encode(publicKeyBuffer, Encoding.AccountAddress));\n}\n","import BigNumber from 'bignumber.js';\nimport { NoSerializerFoundError, TypeError } from './errors';\n\n/**\n * Convert string, number, or BigNumber to byte array\n * @param val - value to convert\n * @param big - enables force conversion to BigNumber\n * @returns Buffer\n */\n// eslint-disable-next-line import/prefer-default-export\nexport function toBytes(val?: null | string | number | BigNumber, big = false): Buffer {\n // Encode a value to bytes.\n // If the value is an int it will be encoded as bytes big endian\n // Raises ValueError if the input is not an int or string\n\n if (val == null) return Buffer.from([]);\n if (Number.isInteger(val) || BigNumber.isBigNumber(val) || big) {\n if (!BigNumber.isBigNumber(val)) val = new BigNumber(val);\n if (!val.isInteger()) throw new TypeError(`Unexpected not integer value: ${val.toFixed()}`);\n let hexString = val.toString(16);\n if (hexString.length % 2 === 1) hexString = `0${hexString}`;\n return Buffer.from(hexString, 'hex');\n }\n if (typeof val === 'string') {\n return Buffer.from(val);\n }\n throw new NoSerializerFoundError();\n}\n","import BigNumber from 'bignumber.js';\nimport { mapObject } from '../../utils/other';\n\nexport const DRY_RUN_ACCOUNT = {\n pub: 'ak_11111111111111111111111111111111273Yts',\n amount: 100000000000000000000000000000000000n,\n} as const;\n\nexport const MAX_AUTH_FUN_GAS = 50000;\nexport type Int = number | string | BigNumber;\nexport type AensName = `${string}.chain`;\nexport const MIN_GAS_PRICE = 1e9; // TODO: don't use number for ae\n// # see https://github.com/aeternity/aeternity/blob/72e440b8731422e335f879a31ecbbee7ac23a1cf/apps/aecore/src/aec_governance.erl#L67\nexport const NAME_FEE_MULTIPLIER = 1e14; // 100000000000000\nexport const NAME_FEE_BID_INCREMENT = 0.05; // # the increment is in percentage\n// # see https://github.com/aeternity/aeternity/blob/72e440b8731422e335f879a31ecbbee7ac23a1cf/apps/aecore/src/aec_governance.erl#L272\nexport const NAME_BID_TIMEOUT_BLOCKS = 480; // # ~1 day\n// # this is the max length for a domain that requires a base fee to be paid\nexport const NAME_MAX_LENGTH_FEE = 31;\n// # https://github.com/aeternity/aeternity/blob/72e440b8731422e335f879a31ecbbee7ac23a1cf/apps/aecore/src/aec_governance.erl#L290\n// # https://github.com/aeternity/protocol/blob/master/AENS.md#protocol-fees-and-protection-times\n// # bid ranges:\nexport const NAME_BID_RANGES = mapObject({\n 31: 3,\n 30: 5,\n 29: 8,\n 28: 13,\n 27: 21,\n 26: 34,\n 25: 55,\n 24: 89,\n 23: 144,\n 22: 233,\n 21: 377,\n 20: 610,\n 19: 987,\n 18: 1597,\n 17: 2584,\n 16: 4181,\n 15: 6765,\n 14: 10946,\n 13: 17711,\n 12: 28657,\n 11: 46368,\n 10: 75025,\n 9: 121393,\n 8: 196418,\n 7: 317811,\n 6: 514229,\n 5: 832040,\n 4: 1346269,\n 3: 2178309,\n 2: 3524578,\n 1: 5702887,\n}, ([key, value]) => [key, new BigNumber(value).times(NAME_FEE_MULTIPLIER)]);\n\nexport enum ConsensusProtocolVersion {\n Iris = 5,\n Ceres = 6,\n}\n\n/**\n * @category transaction builder\n * @see {@link https://github.com/aeternity/protocol/blob/0f6dee3d9d1e8e2469816798f5c7587a6c918f94/contracts/contract_vms.md#virtual-machines-on-the-%C3%A6ternity-blockchain}\n */\nexport enum VmVersion {\n NoVm = 0,\n Sophia = 1,\n SophiaImprovementsMinerva = 3,\n SophiaImprovementsFortuna = 4,\n Fate = 5,\n SophiaImprovementsLima = 6,\n Fate2 = 7,\n Fate3 = 8,\n}\n\n/**\n * @category transaction builder\n * @see {@link https://github.com/aeternity/protocol/blob/0f6dee3d9d1e8e2469816798f5c7587a6c918f94/contracts/contract_vms.md#virtual-machines-on-the-%C3%A6ternity-blockchain}\n */\nexport enum AbiVersion {\n NoAbi = 0,\n Sophia = 1,\n Fate = 3,\n}\n\n/**\n * Enum with tag types\n * @category transaction builder\n * @see {@link https://github.com/aeternity/protocol/blob/0f6dee3d9d1e8e2469816798f5c7587a6c918f94/serializations.md#binary-serialization}\n * @see {@link https://github.com/aeternity/aeserialization/blob/eb68fe331bd476910394966b7f5ede7a74d37e35/src/aeser_chain_objects.erl#L39-L97}\n */\n// TODO: implement serialisation for commented-out tags\nexport enum Tag {\n Account = 10,\n SignedTx = 11,\n SpendTx = 12,\n Oracle = 20,\n // OracleQuery = 21,\n OracleRegisterTx = 22,\n OracleQueryTx = 23,\n OracleResponseTx = 24,\n OracleExtendTx = 25,\n Name = 30,\n // NameCommitment = 31,\n NameClaimTx = 32,\n NamePreclaimTx = 33,\n NameUpdateTx = 34,\n NameRevokeTx = 35,\n NameTransferTx = 36,\n // NameAuction = 37,\n Contract = 40,\n ContractCall = 41,\n ContractCreateTx = 42,\n ContractCallTx = 43,\n ChannelCreateTx = 50,\n // ChannelSetDelegatesTx = 501,\n ChannelDepositTx = 51,\n ChannelWithdrawTx = 52,\n ChannelForceProgressTx = 521,\n ChannelCloseMutualTx = 53,\n ChannelCloseSoloTx = 54,\n ChannelSlashTx = 55,\n ChannelSettleTx = 56,\n ChannelOffChainTx = 57,\n ChannelOffChainUpdateTransfer = 570,\n ChannelOffChainUpdateDeposit = 571,\n ChannelOffChainUpdateWithdraw = 572,\n ChannelOffChainUpdateCreateContract = 573,\n ChannelOffChainUpdateCallContract = 574,\n // ChannelOffChainUpdateMeta = 576,\n ChannelClientReconnectTx = 575,\n Channel = 58,\n ChannelSnapshotSoloTx = 59,\n TreesPoi = 60,\n // TreesDb = 61,\n StateTrees = 62,\n Mtree = 63,\n MtreeValue = 64,\n ContractsMtree = 621,\n CallsMtree = 622,\n ChannelsMtree = 623,\n NameserviceMtree = 624,\n OraclesMtree = 625,\n AccountsMtree = 626,\n // CompilerSophia = 70,\n GaAttachTx = 80,\n GaMetaTx = 81,\n PayingForTx = 82,\n GaMetaTxAuthData = 810,\n // KeyBlock = 100,\n // MicroBlock = 101,\n // LightMicroBlock = 102,\n // Pof = 200,\n}\n","import BigNumber from 'bignumber.js';\nimport { genSalt, hash } from '../../utils/crypto';\nimport {\n decode, encode, Encoded, Encoding,\n} from '../../utils/encoder';\nimport { toBytes } from '../../utils/bytes';\nimport { concatBuffers } from '../../utils/other';\nimport {\n AensName,\n NAME_BID_RANGES,\n NAME_BID_TIMEOUT_BLOCKS,\n NAME_FEE_BID_INCREMENT,\n NAME_MAX_LENGTH_FEE,\n} from './constants';\nimport { ceil } from '../../utils/bignumber';\nimport { ArgumentError, IllegalBidFeeError } from '../../utils/errors';\n\n/**\n * JavaScript-based Transaction builder helper function's\n */\n\n/**\n * Build a contract public key\n * @category contract\n * @param ownerId - The public key of the owner account\n * @param nonce - the nonce of the transaction\n * @returns Contract public key\n */\nexport function buildContractId(\n ownerId: Encoded.AccountAddress,\n nonce: number | BigNumber,\n): Encoded.ContractAddress {\n const ownerIdAndNonce = Buffer.from([...decode(ownerId), ...toBytes(nonce)]);\n const b2bHash = hash(ownerIdAndNonce);\n return encode(b2bHash, Encoding.ContractAddress);\n}\n\n/**\n * Build a oracle query id\n * @category oracle\n * @param senderId - The public key of the sender account\n * @param nonce - the nonce of the transaction\n * @param oracleId - The oracle public key\n * @returns Contract public key\n */\nexport function oracleQueryId(\n senderId: Encoded.AccountAddress,\n nonce: number | BigNumber | string,\n oracleId: Encoded.OracleAddress,\n): Encoded.OracleQueryId {\n function _int32(val: number | string | BigNumber): Buffer {\n const nonceBE = toBytes(val, true);\n return concatBuffers([Buffer.alloc(32 - nonceBE.length), nonceBE]);\n }\n\n const b2bHash = hash(\n Buffer.from([...decode(senderId), ..._int32(nonce), ...decode(oracleId)]),\n );\n return encode(b2bHash, Encoding.OracleQueryId);\n}\n\nconst AENS_SUFFIX = '.chain';\n\nexport function nameToPunycode(maybeName: string): AensName {\n const [name, suffix, ...other] = maybeName.split('.');\n if (other.length !== 0) throw new ArgumentError('aens name', 'including only one dot', maybeName);\n if (suffix !== AENS_SUFFIX.slice(1)) {\n throw new ArgumentError('aens name', `suffixed with ${AENS_SUFFIX}`, maybeName);\n }\n if (/\\p{Emoji_Presentation}/u.test(name)) {\n throw new ArgumentError('aens name', 'not containing emoji', maybeName);\n }\n let punycode;\n try {\n const u = new URL(`http://${name}.${suffix}`);\n if (u.username + u.password + u.port + u.search + u.hash !== '' || u.pathname !== '/') {\n throw new ArgumentError('aens name', 'valid', maybeName);\n }\n punycode = u.host;\n } catch (error) {\n if (error instanceof TypeError && error.message.includes('Invalid URL')) {\n throw new ArgumentError('aens name', 'valid', maybeName);\n }\n throw error;\n }\n if (!/^[a-z0-9.-]+$/i.test(punycode)) {\n throw new ArgumentError('aens name', 'without illegal chars', maybeName);\n }\n if (punycode.length > 63 + AENS_SUFFIX.length) {\n throw new ArgumentError('aens name', 'not too long', maybeName);\n }\n return punycode as AensName;\n}\n\n/**\n * Encode an AENS name\n * @category AENS\n * @param name - Name to encode\n * @returns `nm_` prefixed encoded AENS name\n */\nexport function produceNameId(name: AensName): Encoded.Name {\n return encode(hash(nameToPunycode(name)), Encoding.Name);\n}\n\n/**\n * Generate the commitment hash by hashing the salt and\n * name, base 58 encoding the result and prepending 'cm_'\n * @category transaction builder\n * @param name - Name to be registered\n * @param salt - Random number\n * @returns Commitment hash\n */\nexport function commitmentHash(\n name: AensName,\n salt: number = genSalt(),\n): Encoded.Commitment {\n return encode(\n hash(concatBuffers([\n Buffer.from(nameToPunycode(name)),\n Buffer.from(salt.toString(16).padStart(64, '0'), 'hex'),\n ])),\n Encoding.Commitment,\n );\n}\n\n/**\n * Utility function to convert bytes to int\n * @category transaction builder\n * @param buf - Value\n * @returns Buffer Buffer from number(BigEndian)\n */\nexport function readInt(buf: Buffer = Buffer.from([])): string {\n return new BigNumber(Buffer.from(buf).toString('hex'), 16).toString(10);\n}\n\n/**\n * Ensure that name is valid AENS name, would throw an exception otherwise\n * @category AENS\n * @param maybeName - AENS name\n */\nexport function ensureName(maybeName: string): asserts maybeName is AensName {\n nameToPunycode(maybeName);\n}\n\n/**\n * Is AENS name valid\n * @category AENS\n * @param maybeName - AENS name\n */\n// TODO: consider renaming to isName\nexport function isNameValid(maybeName: string): maybeName is AensName {\n try {\n ensureName(maybeName);\n return true;\n } catch (error) {\n return false;\n }\n}\n\nconst encodingToPointerKey = [\n [Encoding.AccountAddress, 'account_pubkey'],\n [Encoding.OracleAddress, 'oracle_pubkey'],\n [Encoding.ContractAddress, 'contract_pubkey'],\n [Encoding.Channel, 'channel'],\n] as const;\n\n/**\n * @category AENS\n * @param identifier - account/oracle/contract address, or channel\n * @returns default AENS pointer key\n */\nexport function getDefaultPointerKey(\n identifier: Encoded.Generic<typeof encodingToPointerKey[number][0]>,\n): typeof encodingToPointerKey[number][1] {\n decode(identifier);\n const encoding = identifier.substring(0, 2);\n const result = encodingToPointerKey.find(([e]) => e === encoding)?.[1];\n if (result != null) return result;\n throw new ArgumentError(\n 'identifier',\n `prefixed with one of ${encodingToPointerKey.map(([e]) => `${e}_`).join(', ')}`,\n identifier,\n );\n}\n\n/**\n * Get the minimum AENS name fee\n * @category AENS\n * @param name - the AENS name to get the fee for\n * @returns the minimum fee for the AENS name auction\n */\nexport function getMinimumNameFee(name: AensName): BigNumber {\n const nameLength = nameToPunycode(name).length - AENS_SUFFIX.length;\n return NAME_BID_RANGES[Math.min(nameLength, NAME_MAX_LENGTH_FEE)];\n}\n\n/**\n * Compute bid fee for AENS auction\n * @category AENS\n * @param name - the AENS name to get the fee for\n * @param options - Options\n * @param options.startFee - Auction start fee\n * @param options.increment - Bid multiplier(In percentage, must be between 0 and 1)\n * @returns Bid fee\n */\nexport function computeBidFee(\n name: AensName,\n { startFee, increment = NAME_FEE_BID_INCREMENT }:\n { startFee?: number | string | BigNumber; increment?: number } = {},\n): BigNumber {\n if (!(Number(increment) === increment && increment % 1 !== 0)) throw new IllegalBidFeeError(`Increment must be float. Current increment ${increment}`);\n if (increment < NAME_FEE_BID_INCREMENT) throw new IllegalBidFeeError(`minimum increment percentage is ${NAME_FEE_BID_INCREMENT}`);\n // FIXME: increment should be used somehow here\n return ceil(\n new BigNumber(startFee ?? getMinimumNameFee(name))\n .times(new BigNumber(NAME_FEE_BID_INCREMENT).plus(1)),\n );\n}\n\n/**\n * Compute auction end height\n * @category AENS\n * @param name - Name to compute auction end for\n * @param claimHeight - Auction starting height\n * @see {@link https://github.com/aeternity/aeternity/blob/72e440b8731422e335f879a31ecbbee7ac23a1cf/apps/aecore/src/aec_governance.erl#L273}\n * @returns Auction end height\n */\nexport function computeAuctionEndBlock(name: AensName, claimHeight: number): number {\n const length = nameToPunycode(name).length - AENS_SUFFIX.length;\n const h = (length <= 4 ? 62 * NAME_BID_TIMEOUT_BLOCKS : null)\n ?? (length <= 8 ? 31 * NAME_BID_TIMEOUT_BLOCKS : null)\n ?? (length <= 12 ? NAME_BID_TIMEOUT_BLOCKS : null)\n ?? 0;\n return h + claimHeight;\n}\n\n/**\n * Is name accept going to auction\n * @category AENS\n */\nexport function isAuctionName(name: AensName): boolean {\n return nameToPunycode(name).length < 13 + AENS_SUFFIX.length;\n}\n","import { AE_AMOUNT_FORMATS, formatAmount } from './utils/amount-formatter';\nimport { isAccountNotFoundError, pause } from './utils/other';\nimport { unwrapProxy } from './utils/wrap-proxy';\nimport { isNameValid, produceNameId } from './tx/builder/helpers';\nimport { AensName, DRY_RUN_ACCOUNT } from './tx/builder/constants';\nimport {\n AensPointerContextError, DryRunError, InvalidAensNameError,\n TxTimedOutError, TxNotInChainError, InternalError,\n} from './utils/errors';\nimport Node, { TransformNodeType } from './Node';\nimport {\n Account as AccountNode, ByteCode, ContractObject, DryRunResult, DryRunResults,\n Generation, KeyBlock, MicroBlockHeader, NameEntry, SignedTx,\n} from './apis/node';\nimport {\n decode, encode, Encoded, Encoding,\n} from './utils/encoder';\n\n/**\n * @category chain\n * @param type - Type\n * @param options - Options\n */\nexport async function _getPollInterval(\n type: 'key-block' | 'micro-block',\n { _expectedMineRate, _microBlockCycle, onNode }:\n { _expectedMineRate?: number; _microBlockCycle?: number; onNode: Node },\n): Promise<number> {\n const getVal = async (\n t: string,\n val: number | undefined,\n devModeDef: number,\n def: number,\n ): Promise<number | null> => {\n if (t !== type) return null;\n if (val != null) return val;\n return await onNode?.getNetworkId() === 'ae_dev' ? devModeDef : def;\n };\n\n const base = await getVal('key-block', _expectedMineRate, 0, 180000)\n ?? await getVal('micro-block', _microBlockCycle, 0, 3000)\n ?? (() => { throw new InternalError(`Unknown type: ${type}`); })();\n return Math.floor(base / 3);\n}\n\nconst heightCache: WeakMap<Node, { time: number; height: number }> = new WeakMap();\n\n/**\n * Obtain current height of the chain\n * @category chain\n * @param options - Options\n * @param options.cached - Get height from the cache. The lag behind the actual height shouldn't\n * be more than 1 block. Use if needed to reduce requests count, and approximate value can be used.\n * For example, for timeout check in transaction status polling.\n * @returns Current chain height\n */\nexport async function getHeight(\n { cached = false, ...options }: {\n onNode: Node;\n cached?: boolean;\n } & Parameters<typeof _getPollInterval>[1],\n): Promise<number> {\n const onNode = unwrapProxy(options.onNode);\n if (cached) {\n const cache = heightCache.get(onNode);\n if (cache != null && cache.time > Date.now() - await _getPollInterval('key-block', options)) {\n return cache.height;\n }\n }\n const { height } = await onNode.getCurrentKeyBlockHeight();\n heightCache.set(onNode, { height, time: Date.now() });\n return height;\n}\n\n/**\n * Return transaction details if it is mined, fail otherwise.\n * If the transaction has ttl specified then would wait till it leaves the mempool.\n * Otherwise would fail if a specified amount of blocks were mined.\n * @category chain\n * @param th - The hash of transaction to poll\n * @param options - Options\n * @param options.interval - Interval (in ms) at which to poll the chain\n * @param options.blocks - Number of blocks mined after which to fail if transaction ttl is not set\n * @param options.onNode - Node to use\n * @returns The transaction as it was mined\n */\nexport async function poll(\n th: Encoded.TxHash,\n {\n blocks = 5, interval, ...options\n }:\n { blocks?: number; interval?: number; onNode: Node } & Parameters<typeof _getPollInterval>[1],\n): Promise<TransformNodeType<SignedTx>> {\n interval ??= await _getPollInterval('micro-block', options);\n let max;\n do {\n const tx = await options.onNode.getTransactionByHash(th);\n if (tx.blockHeight !== -1) return tx;\n if (max == null) {\n max = tx.tx.ttl !== 0 ? -1\n : await getHeight({ ...options, cached: true }) + blocks;\n }\n await pause(interval);\n } while (max === -1 ? true : await getHeight({ ...options, cached: true }) < max);\n throw new TxTimedOutError(blocks, th);\n}\n\n/**\n * Wait for the chain to reach a specific height\n * @category chain\n * @param height - Height to wait for\n * @param options - Options\n * @param options.interval - Interval (in ms) at which to poll the chain\n * @param options.onNode - Node to use\n * @returns Current chain height\n */\nexport async function awaitHeight(\n height: number,\n { interval, ...options }:\n { interval?: number; onNode: Node } & Parameters<typeof _getPollInterval>[1],\n): Promise<number> {\n interval ??= Math.min(await _getPollInterval('key-block', options), 5000);\n let currentHeight;\n do {\n if (currentHeight != null) await pause(interval);\n currentHeight = await getHeight(options);\n } while (currentHeight < height);\n return currentHeight;\n}\n\n/**\n * Wait for transaction confirmation\n * @category chain\n * @param txHash - Transaction hash\n * @param options - Options\n * @param options.confirm - Number of micro blocks to wait for transaction confirmation\n * @param options.onNode - Node to use\n * @returns Current Height\n */\nexport async function waitForTxConfirm(\n txHash: Encoded.TxHash,\n { confirm = 3, onNode, ...options }:\n { confirm?: number; onNode: Node } & Parameters<typeof awaitHeight>[1],\n): Promise<number> {\n const { blockHeight } = await onNode.getTransactionByHash(txHash);\n const height = await awaitHeight(blockHeight + confirm, { onNode, ...options });\n const { blockHeight: newBlockHeight } = await onNode.getTransactionByHash(txHash);\n switch (newBlockHeight) {\n case -1:\n throw new TxNotInChainError(txHash);\n case blockHeight:\n return height;\n default:\n return waitForTxConfirm(txHash, { onNode, confirm, ...options });\n }\n}\n\n/**\n * Get account by account public key\n * @category chain\n * @param address - Account address (public key)\n * @param options - Options\n * @param options.height - Get account on specific block by block height\n * @param options.hash - Get account on specific block by micro block hash or key block hash\n * @param options.onNode - Node to use\n */\nexport async function getAccount(\n address: Encoded.AccountAddress | Encoded.ContractAddress,\n { height, hash, onNode }:\n { height?: number; hash?: Encoded.KeyBlockHash | Encoded.MicroBlockHash; onNode: Node },\n): Promise<TransformNodeType<AccountNode>> {\n if (height != null) return onNode.getAccountByPubkeyAndHeight(address, height);\n if (hash != null) return onNode.getAccountByPubkeyAndHash(address, hash);\n return onNode.getAccountByPubkey(address);\n}\n\n/**\n * Request the balance of specified account\n * @category chain\n * @param address - The public account address to obtain the balance for\n * @param options - Options\n * @param options.format\n * @param options.height - The chain height at which to obtain the balance for\n * (default: top of chain)\n * @param options.hash - The block hash on which to obtain the balance for (default: top of chain)\n */\nexport async function getBalance(\n address: Encoded.AccountAddress | Encoded.ContractAddress | Encoded.OracleAddress,\n { format = AE_AMOUNT_FORMATS.AETTOS, ...options }:\n { format?: AE_AMOUNT_FORMATS } & Parameters<typeof getAccount>[1],\n): Promise<string> {\n const addr = address.startsWith('ok_')\n ? encode(decode(address), Encoding.AccountAddress)\n : address as Encoded.AccountAddress | Encoded.ContractAddress;\n\n const { balance } = await getAccount(addr, options).catch((error) => {\n if (!isAccountNotFoundError(error)) throw error;\n return { balance: 0n };\n });\n\n return formatAmount(balance, { targetDenomination: format });\n}\n\n/**\n * Obtain current generation\n * @category chain\n * @param options - Options\n * @param options.onNode - Node to use\n * @returns Current Generation\n */\nexport async function getCurrentGeneration(\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<Generation>> {\n return onNode.getCurrentGeneration();\n}\n\n/**\n * Get generation by hash or height\n * @category chain\n * @param hashOrHeight - Generation hash or height\n * @param options - Options\n * @param options.onNode - Node to use\n * @returns Generation\n */\nexport async function getGeneration(\n hashOrHeight: Encoded.KeyBlockHash | number,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<Generation>> {\n if (typeof hashOrHeight === 'number') return onNode.getGenerationByHeight(hashOrHeight);\n return onNode.getGenerationByHash(hashOrHeight);\n}\n\n/**\n * Get micro block transactions\n * @category chain\n * @param hash - Micro block hash\n * @param options - Options\n * @param options.onNode - Node to use\n * @returns Transactions\n */\nexport async function getMicroBlockTransactions(\n hash: Encoded.MicroBlockHash,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<SignedTx[]>> {\n return (await onNode.getMicroBlockTransactionsByHash(hash)).transactions;\n}\n\n/**\n * Get key block\n * @category chain\n * @param hashOrHeight - Key block hash or height\n * @param options - Options\n * @param options.onNode - Node to use\n * @returns Key Block\n */\nexport async function getKeyBlock(\n hashOrHeight: Encoded.KeyBlockHash | number,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<KeyBlock>> {\n if (typeof hashOrHeight === 'number') return onNode.getKeyBlockByHeight(hashOrHeight);\n return onNode.getKeyBlockByHash(hashOrHeight);\n}\n\n/**\n * Get micro block header\n * @category chain\n * @param hash - Micro block hash\n * @param options - Options\n * @param options.onNode - Node to use\n * @returns Micro block header\n */\nexport async function getMicroBlockHeader(\n hash: Encoded.MicroBlockHash,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<MicroBlockHeader>> {\n return onNode.getMicroBlockHeaderByHash(hash);\n}\n\ninterface TxDryRunArguments {\n tx: Encoded.Transaction;\n accountAddress: Encoded.AccountAddress;\n top?: number | Encoded.KeyBlockHash | Encoded.MicroBlockHash;\n txEvents?: any;\n resolve: Function;\n reject: Function;\n}\nconst txDryRunRequests: Map<string, TxDryRunArguments[] & { timeout?: NodeJS.Timeout }> = new Map();\n\nasync function txDryRunHandler(key: string, onNode: Node): Promise<void> {\n const rs = txDryRunRequests.get(key);\n txDryRunRequests.delete(key);\n if (rs == null) throw new InternalError('Can\\'t get dry-run request');\n\n let dryRunRes;\n try {\n const top = typeof rs[0].top === 'number'\n ? (await getKeyBlock(rs[0].top, { onNode })).hash : rs[0].top;\n dryRunRes = await onNode.protectedDryRunTxs({\n top,\n txEvents: rs[0].txEvents,\n txs: rs.map((req) => ({ tx: req.tx })),\n accounts: Array.from(new Set(rs.map((req) => req.accountAddress)))\n .map((pubKey) => ({ pubKey, amount: DRY_RUN_ACCOUNT.amount })),\n });\n } catch (error) {\n rs.forEach(({ reject }) => reject(error));\n return;\n }\n\n const { results, txEvents } = dryRunRes;\n results.forEach(({ result, reason, ...resultPayload }, idx) => {\n const {\n resolve, reject, tx, accountAddress,\n } = rs[idx];\n if (result === 'ok') resolve({ ...resultPayload, txEvents });\n else reject(Object.assign(new DryRunError(reason as string), { tx, accountAddress }));\n });\n}\n\n/**\n * Transaction dry-run\n * @category chain\n * @param tx - transaction to execute\n * @param accountAddress - address that will be used to execute transaction\n * @param options - Options\n * @param options.top - hash of block on which to make dry-run\n * @param options.txEvents - collect and return on-chain tx events that would result from the call\n * @param options.combine - Enables combining of similar requests to a single dry-run call\n * @param options.onNode - Node to use\n */\nexport async function txDryRun(\n tx: Encoded.Transaction,\n accountAddress: Encoded.AccountAddress,\n {\n top, txEvents, combine, onNode,\n }:\n { top?: TxDryRunArguments['top']; txEvents?: boolean; combine?: boolean; onNode: Node },\n): Promise<{\n txEvents?: TransformNodeType<DryRunResults['txEvents']>;\n } & TransformNodeType<DryRunResult>> {\n const key = combine === true ? [top, txEvents].join() : 'immediate';\n const requests = txDryRunRequests.get(key) ?? [];\n txDryRunRequests.set(key, requests);\n return new Promise((resolve, reject) => {\n requests.push({\n tx, accountAddress, top, txEvents, resolve, reject,\n });\n if (combine !== true) {\n void txDryRunHandler(key, onNode);\n return;\n }\n requests.timeout ??= setTimeout(() => { void txDryRunHandler(key, onNode); });\n });\n}\n\n/**\n * Get contract byte code\n * @category contract\n * @param contractId - Contract address\n * @param options - Options\n * @param options.onNode - Node to use\n */\nexport async function getContractByteCode(\n contractId: Encoded.ContractAddress,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<ByteCode>> {\n return onNode.getContractCode(contractId);\n}\n\n/**\n * Get contract entry\n * @category contract\n * @param contractId - Contract address\n * @param options - Options\n * @param options.onNode - Node to use\n */\nexport async function getContract(\n contractId: Encoded.ContractAddress,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<ContractObject>> {\n return onNode.getContract(contractId);\n}\n\n/**\n * Get name entry\n * @category AENS\n * @param name - AENS name\n * @param options - Options\n * @param options.onNode - Node to use\n */\nexport async function getName(\n name: AensName,\n { onNode }: { onNode: Node },\n): Promise<TransformNodeType<NameEntry>> {\n return onNode.getNameEntryByName(name);\n}\n\n/**\n * Resolve AENS name and return name hash\n * @category AENS\n * @param nameOrId - AENS name or address\n * @param key - in AENS pointers record\n * @param options - Options\n * @param options.verify - To ensure that name exist and have a corresponding pointer\n * // TODO: avoid that to don't trust to current api gateway\n * @param options.resolveByNode - Enables pointer resolving using node\n * @param options.onNode - Node to use\n * @returns Address or AENS name hash\n */\nexport async function resolveName <\n Type extends Encoding.AccountAddress | Encoding.ContractAddress,\n>(\n nameOrId: AensName | Encoded.Generic<Type>,\n key: string,\n { verify = true, resolveByNode = false, onNode }:\n { verify?: boolean; resolveByNode?: boolean; onNode: Node },\n): Promise<Encoded.Generic<Type | Encoding.Name>> {\n if (isNameValid(nameOrId)) {\n if (verify || resolveByNode) {\n const name = await onNode.getNameEntryByName(nameOrId);\n const pointer = name.pointers.find((p) => p.key === key);\n if (pointer == null) throw new AensPointerContextError(nameOrId, key);\n if (resolveByNode) return pointer.id as Encoded.Generic<Type>;\n }\n return produceNameId(nameOrId);\n }\n try {\n decode(nameOrId);\n return nameOrId;\n } catch (error) {\n throw new InvalidAensNameError(`Invalid name or address: ${nameOrId}`);\n }\n}\n","import { ConsensusProtocolVersion, VmVersion, AbiVersion } from '../constants';\nimport Node from '../../../Node';\n\n/*\n * First abi/vm by default\n * @see {@link https://github.com/aeternity/protocol/blob/71cf111/contracts/contract_vms.md#virtual-machines-on-the-æternity-blockchain}\n */\nexport const ProtocolToVmAbi = {\n [ConsensusProtocolVersion.Iris]: {\n 'contract-create': {\n vmVersion: [VmVersion.Fate2], abiVersion: [AbiVersion.Fate],\n },\n 'contract-call': {\n vmVersion: [], abiVersion: [AbiVersion.Fate, AbiVersion.Sophia],\n },\n 'oracle-call': {\n vmVersion: [], abiVersion: [AbiVersion.NoAbi, AbiVersion.Fate],\n },\n },\n [ConsensusProtocolVersion.Ceres]: {\n 'contract-create': {\n vmVersion: [VmVersion.Fate3], abiVersion: [AbiVersion.Fate],\n },\n 'contract-call': {\n vmVersion: [], abiVersion: [AbiVersion.Fate],\n },\n 'oracle-call': {\n vmVersion: [], abiVersion: [AbiVersion.NoAbi, AbiVersion.Fate],\n },\n },\n} as const;\n\nexport interface CtVersion {\n vmVersion: VmVersion;\n abiVersion: AbiVersion;\n}\n\nexport function getProtocolDetails(\n protocolVersion: ConsensusProtocolVersion,\n type: 'contract-create' | 'contract-call' | 'oracle-call',\n): CtVersion {\n const protocol = ProtocolToVmAbi[protocolVersion][type];\n return {\n vmVersion: protocol.vmVersion[0] ?? VmVersion.Fate2,\n abiVersion: protocol.abiVersion[0],\n };\n}\n\nexport default {\n serialize(\n value: CtVersion | undefined,\n params: {},\n { consensusProtocolVersion = ConsensusProtocolVersion.Iris }:\n { consensusProtocolVersion?: ConsensusProtocolVersion },\n ): Buffer {\n value ??= getProtocolDetails(consensusProtocolVersion, 'contract-create');\n\n return Buffer.from([value.vmVersion, 0, value.abiVersion]);\n },\n\n async prepare(\n value: CtVersion | undefined,\n params: {},\n // TODO: { consensusProtocolVersion: ConsensusProtocolVersion } | { onNode: Node } | {}\n options: { consensusProtocolVersion?: ConsensusProtocolVersion; onNode?: Node },\n ): Promise<CtVersion | undefined> {\n if (value != null) return value;\n if (options.consensusProtocolVersion != null) return undefined;\n if (Object.keys(ConsensusProtocolVersion).length === 2) return undefined;\n if (options.onNode != null) {\n return getProtocolDetails(\n (await options.onNode.getNodeInfo()).consensusProtocolVersion,\n 'contract-create',\n );\n }\n return undefined;\n },\n\n deserialize(buffer: Buffer): CtVersion {\n const [vm, , abi] = buffer;\n return { vmVersion: +vm, abiVersion: +abi };\n },\n};\n","import {\n decode, encode, Encoded, Encoding,\n} from '../../../utils/encoder';\nimport { Tag } from '../constants';\nimport type { unpackTx as unpackTxType, buildTx as buildTxType } from '../index';\n\nexport default function genEntryField<T extends Tag = Tag>(tag?: T): {\n serialize: (\n // TODO: replace with `TxParams & { tag: T }`,\n // but fix TS2502 value is referenced directly or indirectly in its own type annotation\n value: any,\n options: { buildTx: typeof buildTxType },\n ) => Buffer;\n deserialize: (\n value: Buffer, options: { unpackTx: typeof unpackTxType },\n // TODO: replace with `TxUnpacked & { tag: T }`,\n // TS2577 Return type annotation circularly references itself\n ) => any;\n} {\n return {\n serialize(txParams, { buildTx }) {\n if (ArrayBuffer.isView(txParams)) return Buffer.from(txParams as any);\n if (typeof txParams === 'string' && txParams.startsWith('tx_')) {\n return decode(txParams as Encoded.Transaction);\n }\n return decode(buildTx({ ...txParams, ...tag != null && { tag } }));\n },\n\n deserialize(buf, { unpackTx }) {\n return unpackTx(encode(buf, Encoding.Transaction), tag);\n },\n };\n}\n","export default function genArrayField<Input, Output, Binary>(\n itemHandler: {\n serialize: (value: Input, params: unknown) => Binary;\n deserialize: (value: Binary, params: unknown) => Output;\n },\n): {\n serialize: (value: readonly Input[], params: unknown) => Binary[];\n deserialize: (value: Binary[], params: unknown) => Output[];\n } {\n return {\n serialize(items, params) {\n return items.map((item) => itemHandler.serialize(item, params));\n },\n\n deserialize(buffers, params) {\n return buffers.map((buffer) => itemHandler.deserialize(buffer, params));\n },\n };\n}\n","import { Tag } from '../constants';\nimport {\n encode, Encoding, Encoded, decode,\n} from '../../../utils/encoder';\nimport type { unpackTx as unpackTxType, buildTx as buildTxType } from '../index';\n\nexport default function genMapField<E extends Encoding, T extends Tag>(encoding: E, tag: T): {\n serialize: (\n // TODO: replace with `TxParams & { tag: T }`,\n // but fix TS2502 value is referenced directly or indirectly in its own type annotation\n value: Record<Encoded.Generic<E>, any>, options: { buildTx: typeof buildTxType }\n ) => Buffer;\n deserialize: (\n value: Buffer, options: { unpackTx: typeof unpackTxType },\n // TODO: replace with `TxUnpacked & { tag: T }`,\n // TS2577 Return type annotation circularly references itself\n ) => Record<Encoded.Generic<E>, any>;\n recursiveType: true;\n} {\n return {\n serialize(object, { buildTx }) {\n return decode(buildTx({\n tag: Tag.Mtree,\n values: Object.entries(object).map(([key, value]) => ({\n tag: Tag.MtreeValue,\n key: decode(key as Encoded.Generic<E>),\n value: decode(buildTx({ ...value as any, tag })),\n })),\n }));\n },\n\n deserialize(buffer, { unpackTx }) {\n const { values } = unpackTx(encode(buffer, Encoding.Transaction), Tag.Mtree);\n return Object.fromEntries(values\n // TODO: remove after resolving https://github.com/aeternity/aeternity/issues/4066\n .filter(({ key }) => encoding !== Encoding.ContractAddress || key.length === 32)\n .map(({ key, value }) => [\n encode(key, encoding),\n unpackTx(encode(value, Encoding.Transaction), tag),\n ])) as Record<Encoded.Generic<E>, any>;\n },\n\n recursiveType: true,\n };\n}\n","export default function withDefault<Input, Output, Binary>(\n defaultValue: Input,\n field: {\n serialize: (value: Input, params: unknown) => Binary;\n deserialize: (value: Binary, params: unknown) => Output;\n },\n): {\n serialize: (value: Input | undefined, params: unknown) => Binary;\n deserialize: (value: Binary, params: unknown) => Output;\n } {\n return {\n ...field,\n\n serialize(value, params) {\n return field.serialize(value ?? defaultValue, params);\n },\n };\n}\n","import { readInt } from '../helpers';\nimport { Int } from '../constants';\nimport { ArgumentError } from '../../../utils/errors';\nimport { toBytes } from '../../../utils/bytes';\n\nexport default {\n serialize(value: Int): Buffer {\n if (Number(value) < 0) throw new ArgumentError('value', 'greater or equal to 0', value);\n return toBytes(value, true);\n },\n\n deserialize(value: Buffer): string {\n return readInt(value);\n },\n};\n","import uInt from './u-int';\n\nexport default {\n serialize(value: number): Buffer {\n return uInt.serialize(value);\n },\n\n deserialize(value: Buffer): number {\n return +uInt.deserialize(value);\n },\n};\n","export default function withFormatting<Input, Output, Binary, Params, Options>(\n format: (v: Input | undefined) => Input,\n field: {\n serialize: (value: Input, params: Params, options: Options) => Binary;\n deserialize: (value: Binary) => Output;\n },\n): {\n serialize: (value: Input | undefined, params: Params, options: Options) => Binary;\n deserialize: (value: Binary) => Output;\n } {\n return {\n ...field,\n\n serialize(value, params, options) {\n return field.serialize(format(value), params, options);\n },\n };\n}\n","import { ArgumentError } from '../../../utils/errors';\nimport shortUInt from './short-u-int';\n\nexport default function genShortUIntConstField<\n Value extends number, Optional extends boolean = false,\n>(constValue: Value, optional?: Optional): {\n serialize: Optional extends true ? (value?: Value) => Buffer : (value: Value) => Buffer;\n deserialize: (value: Buffer) => Value;\n constValue: Value;\n constValueOptional: boolean;\n} {\n return {\n serialize(value?: Value) {\n if ((optional !== true || value != null) && value !== constValue) {\n throw new ArgumentError('ShortUIntConst', constValue, value);\n }\n return shortUInt.serialize(constValue);\n },\n\n deserialize(buf) {\n const value = shortUInt.deserialize(buf);\n if (value !== constValue) throw new ArgumentError('ShortUIntConst', constValue, value);\n return constValue;\n },\n\n constValue,\n\n constValueOptional: optional === true,\n };\n}\n","import { ArgumentError, PrefixNotFoundError, TagNotFoundError } from '../../../utils/errors';\nimport { toBytes } from '../../../utils/bytes';\nimport {\n decode, encode, Encoded, Encoding,\n} from '../../../utils/encoder';\nimport { isItemOfArray } from '../../../utils/other';\n\n/**\n * Map of prefix to ID tag constant\n * @see {@link https://github.com/aeternity/protocol/blob/master/serializations.md#the-id-type}\n * @see {@link https://github.com/aeternity/aeserialization/blob/eb68fe331bd476910394966b7f5ede7a74d37e35/src/aeser_id.erl#L97-L102}\n * @see {@link https://github.com/aeternity/aeserialization/blob/eb68fe331bd476910394966b7f5ede7a74d37e35/src/aeser_api_encoder.erl#L163-L168}\n */\nexport const idTagToEncoding = [\n Encoding.AccountAddress,\n Encoding.Name,\n Encoding.Commitment,\n Encoding.OracleAddress,\n Encoding.ContractAddress,\n Encoding.Channel,\n] as const;\n\nexport type AddressEncodings = typeof idTagToEncoding[number];\n\nexport default function genAddressField<Encoding extends AddressEncodings>(\n ...encodings: Encoding[]\n): {\n serialize: (value: Encoded.Generic<Encoding>) => Buffer;\n deserialize: (value: Buffer) => Encoded.Generic<Encoding>;\n } {\n return {\n /**\n * Utility function to create and _id type\n * @param hashId - Encoded hash\n * @returns Buffer Buffer with ID tag and decoded HASh\n */\n serialize(hashId) {\n const enc = hashId.slice(0, 2);\n if (!isItemOfArray(enc, idTagToEncoding)) throw new TagNotFoundError(enc);\n if (!isItemOfArray(enc, encodings)) {\n throw new ArgumentError('Address encoding', encodings.join(', '), enc);\n }\n const idTag = idTagToEncoding.indexOf(enc) + 1;\n return Buffer.from([...toBytes(idTag), ...decode(hashId)]);\n },\n\n /**\n * Utility function to read and _id type\n * @param buf - Data\n * @returns Encoded hash string with prefix\n */\n deserialize(buf) {\n const idTag = Buffer.from(buf).readUIntBE(0, 1);\n const enc = idTagToEncoding[idTag - 1];\n if (enc == null) throw new PrefixNotFoundError(idTag);\n if (!isItemOfArray(enc, encodings)) {\n throw new ArgumentError('Address encoding', encodings.join(', '), enc);\n }\n return encode(buf.subarray(1), enc) as Encoded.Generic<Encoding>;\n },\n };\n}\n","import {\n decode, encode, Encoded, Encoding,\n} from '../../../utils/encoder';\nimport { ArgumentError } from '../../../utils/errors';\n\nexport default function genEncodedField<E extends Encoding, Optional extends boolean = false>(\n encoding: E,\n optional?: Optional,\n): {\n serialize: Optional extends true\n ? (value?: Encoded.Generic<E>) => Buffer : (value: Encoded.Generic<E>) => Buffer;\n deserialize: (value: Buffer) => Encoded.Generic<E>;\n } {\n return {\n serialize(encodedData?: Encoded.Generic<E>) {\n if (encodedData == null) {\n if (optional === true) return Buffer.from([]);\n throw new ArgumentError('Encoded data', 'provided', encodedData);\n }\n return decode(encodedData);\n },\n\n deserialize(buffer) {\n return encode(buffer, encoding);\n },\n };\n}\n","export default {\n serialize(buffer: Uint8Array): Buffer {\n return Buffer.from(buffer);\n },\n\n deserialize(buffer: Buffer): Buffer {\n return buffer;\n },\n};\n","import uInt from './u-int';\nimport { Int } from '../constants';\nimport { AE_AMOUNT_FORMATS, formatAmount } from '../../../utils/amount-formatter';\n\nexport default {\n ...uInt,\n\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n serializeAettos(value: string | undefined, params: {}, options: {}): string {\n return value ?? '0';\n },\n\n serialize(\n value: Int | undefined,\n params: {},\n { denomination = AE_AMOUNT_FORMATS.AETTOS, ...options }: { denomination?: AE_AMOUNT_FORMATS },\n ): Buffer {\n return uInt.serialize(\n this.serializeAettos(\n value != null ? formatAmount(value, { denomination }) : value,\n params,\n options,\n ),\n );\n },\n};\n","function verCmp(a: string, b: string): number {\n const getComponents = (v: string): number[] => v\n .split(/[-+]/)[0].split('.').map((i) => +i);\n\n const aComponents = getComponents(a);\n const bComponents = getComponents(b);\n\n const base = Math.max(...aComponents, ...bComponents) + 1;\n const componentsToNumber = (components: number[]): number => components.reverse()\n .reduce((acc, n, idx) => acc + n * base ** idx, 0);\n\n return componentsToNumber(aComponents) - componentsToNumber(bComponents);\n}\n\nexport default function semverSatisfies(\n version: string,\n geVersion: string,\n ltVersion?: string,\n): boolean {\n return verCmp(version, geVersion) >= 0\n && (ltVersion == null || verCmp(version, ltVersion) < 0);\n}\n","import BigNumber from 'bignumber.js';\nimport coinAmount from './coin-amount';\nimport { ArgumentError, IllegalArgumentError } from '../../../utils/errors';\nimport { Int, MIN_GAS_PRICE } from '../constants';\nimport Node from '../../../Node';\nimport { AE_AMOUNT_FORMATS, formatAmount } from '../../../utils/amount-formatter';\nimport semverSatisfies from '../../../utils/semver-satisfies';\n\nconst gasPriceCache: WeakMap<Node, { time: number; gasPrice: bigint }> = new WeakMap();\n\nexport async function getCachedIncreasedGasPrice(node: Node): Promise<bigint> {\n const cache = gasPriceCache.get(node);\n if (cache != null && cache.time > Date.now() - 20 * 1000) {\n return cache.gasPrice;\n }\n\n // TODO: remove after requiring node@6.13.0\n const { nodeVersion } = await node._getCachedStatus();\n if (!semverSatisfies(nodeVersion, '6.13.0')) return 0n;\n\n const { minGasPrice, utilization } = (await node.getRecentGasPrices())[0];\n let gasPrice = utilization < 70 ? 0n : BigInt(\n new BigNumber(minGasPrice.toString()).times(1.01).integerValue().toFixed(),\n );\n\n const maxSafeGasPrice = BigInt(MIN_GAS_PRICE) * 100000n; // max microblock fee is 600ae or 35usd\n if (gasPrice > maxSafeGasPrice) {\n console.warn([\n `Estimated gas price ${gasPrice} exceeds the maximum safe value for unknown reason.`,\n `It will be limited to ${maxSafeGasPrice}.`,\n 'To overcome this restriction provide `gasPrice`/`fee` in options.',\n ].join(' '));\n gasPrice = maxSafeGasPrice;\n }\n\n gasPriceCache.set(node, { gasPrice, time: Date.now() });\n return gasPrice;\n}\n\n// TODO: use withFormatting after using a single type for coins representation\nexport default {\n ...coinAmount,\n\n async prepare(\n value: Int | undefined,\n params: {},\n { onNode, denomination }: {\n onNode?: Node;\n denomination?: AE_AMOUNT_FORMATS;\n },\n ): Promise<Int | undefined> {\n if (value != null) return value;\n if (onNode == null) {\n throw new ArgumentError('onNode', 'provided (or provide `gasPrice` instead)', onNode);\n }\n const gasPrice = await getCachedIncreasedGasPrice(onNode);\n if (gasPrice === 0n) return undefined;\n return formatAmount(gasPrice, { targetDenomination: denomination });\n },\n\n serializeAettos(value: string | undefined = MIN_GAS_PRICE.toString()): string {\n if (+value < MIN_GAS_PRICE) {\n throw new IllegalArgumentError(`Gas price ${value.toString()} must be bigger than ${MIN_GAS_PRICE}`);\n }\n return value;\n },\n};\n","import BigNumber from 'bignumber.js';\nimport { ArgumentError, IllegalArgumentError } from '../../../utils/errors';\nimport { Int, MIN_GAS_PRICE, Tag } from '../constants';\nimport uInt from './u-int';\nimport coinAmount from './coin-amount';\nimport { getCachedIncreasedGasPrice } from './gas-price';\nimport { isKeyOfObject } from '../../../utils/other';\nimport { decode, Encoded } from '../../../utils/encoder';\nimport type { unpackTx as unpackTxType, buildTx as buildTxType } from '../index';\nimport Node from '../../../Node';\n\nconst BASE_GAS = 15000;\nconst GAS_PER_BYTE = 20;\nconst KEY_BLOCK_INTERVAL = 3;\n\n/**\n * Calculate the base gas\n * @see {@link https://github.com/aeternity/protocol/blob/master/consensus/README.md#gas}\n * @param txType - The transaction type\n * @returns The base gas\n * @example\n * ```js\n * TX_BASE_GAS(Tag.ChannelForceProgressTx) => 30 * 15000\n * ```\n */\nconst TX_BASE_GAS = (txType: Tag): number => {\n const feeFactors = {\n [Tag.ChannelForceProgressTx]: 30,\n [Tag.ChannelOffChainTx]: 0,\n [Tag.ContractCreateTx]: 5,\n [Tag.ContractCallTx]: 12,\n [Tag.GaAttachTx]: 5,\n [Tag.GaMetaTx]: 5,\n [Tag.PayingForTx]: 1 / 5,\n } as const;\n const factor = feeFactors[txType as keyof typeof feeFactors] ?? 1;\n return factor * BASE_GAS;\n};\n\n/**\n * Calculate gas for other types of transactions\n * @see {@link https://github.com/aeternity/protocol/blob/master/consensus/README.md#gas}\n * @param txType - The transaction type\n * @param txSize - The transaction size\n * @returns parameters - The transaction parameters\n * @returns parameters.relativeTtl - The relative ttl\n * @returns parameters.innerTxSize - The size of the inner transaction\n * @returns The other gas\n * @example\n * ```js\n * TX_OTHER_GAS(Tag.OracleResponseTx, 10, { relativeTtl: 12, innerTxSize: 0 })\n * => 10 * 20 + Math.ceil(32000 * 12 / Math.floor(60 * 24 * 365 / 3))\n * ```\n */\nconst TX_OTHER_GAS = (\n txType: Tag,\n txSize: number,\n { relativeTtl, innerTxSize }: { relativeTtl: number; innerTxSize: number },\n): number => {\n switch (txType) {\n case Tag.OracleRegisterTx:\n case Tag.OracleExtendTx:\n case Tag.OracleQueryTx:\n case Tag.OracleResponseTx:\n return txSize * GAS_PER_BYTE\n + Math.ceil((32000 * relativeTtl) / Math.floor((60 * 24 * 365) / KEY_BLOCK_INTERVAL));\n case Tag.GaMetaTx:\n case Tag.PayingForTx:\n return (txSize - innerTxSize) * GAS_PER_BYTE;\n default:\n return txSize * GAS_PER_BYTE;\n }\n};\n\nfunction getOracleRelativeTtl(params: any): number {\n const ttlKeys = {\n [Tag.OracleRegisterTx]: 'oracleTtlValue',\n [Tag.OracleExtendTx]: 'oracleTtlValue',\n [Tag.OracleQueryTx]: 'queryTtlValue',\n [Tag.OracleResponseTx]: 'responseTtlValue',\n } as const;\n\n const { tag } = params;\n if (!isKeyOfObject(tag, ttlKeys)) return 1;\n return params[ttlKeys[tag]];\n}\n\n/**\n * Calculate gas based on tx type and params\n */\nexport function buildGas(\n builtTx: Encoded.Transaction,\n unpackTx: typeof unpackTxType,\n buildTx: typeof buildTxType,\n): number {\n const { length } = decode(builtTx);\n const txObject = unpackTx(builtTx);\n\n let innerTxSize = 0;\n if (txObject.tag === Tag.GaMetaTx || txObject.tag === Tag.PayingForTx) {\n innerTxSize = decode(buildTx(txObject.tx.encodedTx)).length;\n }\n\n return TX_BASE_GAS(txObject.tag)\n + TX_OTHER_GAS(txObject.tag, length, {\n relativeTtl: getOracleRelativeTtl(txObject), innerTxSize,\n });\n}\n\n/**\n * Calculate min fee\n * @category transaction builder\n * @param rebuildTx - Callback to get built transaction with specific fee\n */\nfunction calculateMinFee(\n rebuildTx: (value: BigNumber) => Encoded.Transaction,\n unpackTx: typeof unpackTxType,\n buildTx: typeof buildTxType,\n): BigNumber {\n let fee = new BigNumber(0);\n let previousFee;\n do {\n previousFee = fee;\n fee = new BigNumber(MIN_GAS_PRICE).times(buildGas(rebuildTx(fee), unpackTx, buildTx));\n } while (!fee.eq(previousFee));\n return fee;\n}\n\n// TODO: Get rid of this workaround. Transaction builder can't accept/return gas price instead of\n// fee because it may get a decimal gas price. So, it should accept the optional `gasPrice` even\n// if it is not a contract-related transaction. And use this `gasPrice` to calculate `fee`.\nconst gasPricePrefix = '_gas-price:';\n\nexport interface SerializeAettosParams {\n rebuildTx: (params: any) => Encoded.Transaction;\n unpackTx: typeof unpackTxType;\n buildTx: typeof buildTxType;\n _computingMinFee?: BigNumber;\n}\n\nexport default {\n ...coinAmount,\n\n async prepare(\n value: Int | undefined,\n params: {},\n { onNode }: { onNode?: Node },\n ): Promise<Int | undefined> {\n if (value != null) return value;\n if (onNode == null) {\n throw new ArgumentError('onNode', 'provided (or provide `fee` instead)', onNode);\n }\n const gasPrice = await getCachedIncreasedGasPrice(onNode);\n if (gasPrice === 0n) return undefined;\n return gasPricePrefix + gasPrice;\n },\n\n serializeAettos(\n _value: string | undefined,\n {\n rebuildTx, unpackTx, buildTx, _computingMinFee,\n }: SerializeAettosParams,\n { _canIncreaseFee }: { _canIncreaseFee?: boolean },\n ): string {\n if (_computingMinFee != null) return _computingMinFee.toFixed();\n const minFee = calculateMinFee(\n (fee) => rebuildTx({ _computingMinFee: fee }),\n unpackTx,\n buildTx,\n );\n const value = _value?.startsWith(gasPricePrefix) === true\n ? minFee.dividedBy(MIN_GAS_PRICE).times(_value.replace(gasPricePrefix, ''))\n : new BigNumber(_value ?? minFee);\n if (minFee.gt(value)) {\n if (_canIncreaseFee === true) return minFee.toFixed();\n throw new IllegalArgumentError(`Fee ${value.toString()} must be bigger than ${minFee}`);\n }\n return value.toFixed();\n },\n\n serialize(\n value: Parameters<typeof coinAmount.serialize>[0],\n params: Parameters<typeof coinAmount.serialize>[1] & SerializeAettosParams,\n options: { _canIncreaseFee?: boolean } & Parameters<typeof coinAmount.serialize>[2],\n ): Buffer {\n if (typeof value === 'string' && value.startsWith(gasPricePrefix)) {\n return uInt.serialize(this.serializeAettos(value, params, options));\n }\n return coinAmount.serialize.call(this, value, params, options);\n },\n};\n","import shortUInt from './short-u-int';\nimport Node from '../../../Node';\nimport { ArgumentError } from '../../../utils/errors';\nimport { _getPollInterval, getHeight } from '../../../chain';\n\n/**\n * Time to leave\n */\nexport default {\n ...shortUInt,\n\n serialize(value: number | undefined): Buffer {\n return shortUInt.serialize(value ?? 0);\n },\n\n async prepare(\n value: number | undefined,\n params: {},\n // TODO: { absoluteTtl: true } | { absoluteTtl: false, onNode: Node }\n {\n onNode, absoluteTtl, _isInternalBuild, ...options\n }: {\n onNode?: Node;\n absoluteTtl?: boolean;\n _isInternalBuild?: boolean;\n } & Omit<Parameters<typeof _getPollInterval>[1], 'onNode'>,\n ) {\n if (absoluteTtl !== true && value !== 0 && (value != null || _isInternalBuild === true)) {\n if (onNode == null) throw new ArgumentError('onNode', 'provided', onNode);\n value = (value ?? 3) + await getHeight({ ...options, onNode, cached: true });\n }\n return value;\n },\n};\n","import { isAccountNotFoundError } from '../../../utils/other';\nimport shortUInt from './short-u-int';\nimport Node from '../../../Node';\nimport { ArgumentError } from '../../../utils/errors';\nimport { NextNonceStrategy } from '../../../apis/node';\n\nexport default function genNonceField<SenderKey extends string>(senderKey: SenderKey): {\n serialize: (value: number) => Buffer;\n // TODO: (value: number) => Promise<number> | (value: undefined, ...) => Promise<number>\n prepare: (\n value: number | undefined,\n params: {},\n // TODO: replace `string` with AddressEncodings\n options: { [key in SenderKey]: string } & {\n strategy?: NextNonceStrategy;\n onNode?: Node;\n _isInternalBuild?: boolean;\n },\n ) => Promise<number>;\n deserialize: (value: Buffer) => number;\n senderKey: string;\n} {\n return {\n ...shortUInt,\n\n async prepare(value, params, options) {\n if (value != null) return value;\n // TODO: uncomment the below line\n // if (options._isInternalBuild === true) return 0;\n const { onNode, strategy } = options;\n const senderId = options[senderKey];\n const requirement = 'provided (or provide `nonce` instead)';\n if (onNode == null) throw new ArgumentError('onNode', requirement, onNode);\n if (senderId == null) throw new ArgumentError('senderId', requirement, senderId);\n return (\n await onNode.getAccountNextNonce(senderId.replace(/^ok_/, 'ak_'), { strategy })\n .catch((error) => {\n if (!isAccountNotFoundError(error)) throw error;\n return { nextNonce: 1 };\n })\n ).nextNonce;\n },\n\n senderKey,\n };\n}\n","import { NamePointer as NamePointerString } from '../../../apis/node';\nimport { toBytes } from '../../../utils/bytes';\nimport { Encoded } from '../../../utils/encoder';\nimport { IllegalArgumentError } from '../../../utils/errors';\nimport address, { AddressEncodings, idTagToEncoding } from './address';\n\nconst addressAny = address(...idTagToEncoding);\n\n// TODO: remove after fixing node types\ntype NamePointer = NamePointerString & {\n id: Encoded.Generic<AddressEncodings>;\n};\n\nexport default {\n /**\n * Helper function to build pointers for name update TX\n * @param pointers - Array of pointers\n * `([ { key: 'account_pubkey', id: 'ak_32klj5j23k23j5423l434l2j3423'} ])`\n * @returns Serialized pointers array\n */\n serialize(pointers: NamePointer[]): Buffer[][] {\n if (pointers.length > 32) {\n throw new IllegalArgumentError(`Expected 32 pointers or less, got ${pointers.length} instead`);\n }\n\n return pointers.map(\n (pointer) => [toBytes(pointer.key), addressAny.serialize(pointer.id)],\n );\n },\n\n /**\n * Helper function to read pointers from name update TX\n * @param pointers - Array of pointers\n * @returns Deserialize pointer array\n */\n deserialize(pointers: Array<[key: Buffer, id: Buffer]>): NamePointer[] {\n return pointers.map(\n ([key, id]) => ({ key: key.toString(), id: addressAny.deserialize(id) }),\n );\n },\n};\n","export default {\n serialize(value: string): Buffer {\n return Buffer.from(value);\n },\n\n deserialize(value: Buffer): string {\n return value.toString();\n },\n};\n","import field from './field';\nimport { AensName } from '../constants';\n\nexport default {\n /**\n * @param value - AENS name\n */\n serialize(value: AensName): Buffer {\n return field.serialize(value);\n },\n\n /**\n * @param value - AENS name\n */\n deserialize(value: Buffer): AensName {\n return field.deserialize(value) as AensName;\n },\n};\n","import BigNumber from 'bignumber.js';\nimport { getMinimumNameFee } from '../helpers';\nimport { InsufficientNameFeeError } from '../../../utils/errors';\nimport coinAmount from './coin-amount';\nimport { AensName, Int } from '../constants';\n\nexport default {\n ...coinAmount,\n\n serializeAettos(\n _value: string | undefined,\n txFields: { name: AensName },\n ): string {\n const minNameFee = getMinimumNameFee(txFields.name);\n const value = new BigNumber(_value ?? minNameFee);\n if (minNameFee.gt(value)) throw new InsufficientNameFeeError(value, minNameFee);\n return value.toFixed();\n },\n\n /**\n * @param value - AENS name fee\n * @param txFields - Transaction fields\n * @param txFields.name - AENS Name in transaction\n */\n serialize(\n value: Int | undefined,\n txFields: { name: AensName } & Parameters<typeof coinAmount['serialize']>[1],\n parameters: Parameters<typeof coinAmount['serialize']>[2],\n ): Buffer {\n return coinAmount.serialize.call(this, value, txFields, parameters);\n },\n};\n","import { AensName } from '../constants';\nimport { produceNameId, isNameValid } from '../helpers';\nimport address from './address';\nimport { Encoded, Encoding } from '../../../utils/encoder';\n\nconst addressName = address(Encoding.Name);\n\nexport default {\n ...addressName,\n\n /**\n * @param value - AENS name ID\n */\n serialize(value: AensName | Encoded.Name): Buffer {\n return addressName.serialize(isNameValid(value) ? produceNameId(value) : value);\n },\n};\n","import { NamePointer as NamePointerString } from '../../../apis/node';\nimport { toBytes } from '../../../utils/bytes';\nimport {\n Encoded, Encoding, decode, encode,\n} from '../../../utils/encoder';\nimport { isAddressValid } from '../../../utils/crypto';\nimport { IllegalArgumentError, DecodeError, ArgumentError } from '../../../utils/errors';\nimport address, { AddressEncodings, idTagToEncoding } from './address';\n\nconst ID_TAG = Buffer.from([1]);\nconst DATA_TAG = Buffer.from([2]);\nconst DATA_LENGTH_MAX = 1024;\nconst addressAny = address(...idTagToEncoding);\n\n// TODO: remove after fixing node types\ntype NamePointer = NamePointerString & {\n id: Encoded.Generic<AddressEncodings | Encoding.Bytearray>;\n};\n\nexport default {\n /**\n * Helper function to build pointers for name update TX\n * @param pointers - Array of pointers\n * `([ { key: 'account_pubkey', id: 'ak_32klj5j23k23j5423l434l2j3423'} ])`\n * @returns Serialized pointers array\n */\n serialize(pointers: NamePointer[]): Buffer[][] {\n if (pointers.length > 32) {\n throw new IllegalArgumentError(`Expected 32 pointers or less, got ${pointers.length} instead`);\n }\n return pointers.map(({ key, id }) => {\n let payload;\n if (isAddressValid(id, ...idTagToEncoding)) payload = [ID_TAG, addressAny.serialize(id)];\n if (isAddressValid(id, Encoding.Bytearray)) {\n const data = decode(id);\n if (data.length > DATA_LENGTH_MAX) {\n throw new ArgumentError('Raw pointer', `shorter than ${DATA_LENGTH_MAX + 1} bytes`, `${data.length} bytes`);\n }\n payload = [DATA_TAG, data];\n }\n if (payload == null) throw new DecodeError(`Unknown AENS pointer value: ${id}`);\n return [toBytes(key), Buffer.concat(payload)];\n });\n },\n\n /**\n * Helper function to read pointers from name update TX\n * @param pointers - Array of pointers\n * @returns Deserialize pointer array\n */\n deserialize(pointers: Array<[key: Buffer, id: Buffer]>): NamePointer[] {\n return pointers.map(([bKey, bId]) => {\n const tag = bId.subarray(0, 1);\n const payload = bId.subarray(1);\n let id;\n if (tag.equals(ID_TAG)) id = addressAny.deserialize(payload);\n if (tag.equals(DATA_TAG)) id = encode(payload, Encoding.Bytearray);\n if (id == null) throw new DecodeError(`Unknown AENS pointer tag: ${tag}`);\n return { key: bKey.toString(), id };\n });\n },\n};\n","export default {\n serialize(value: boolean): Buffer {\n return Buffer.from([value ? 1 : 0]);\n },\n\n deserialize(buffer: Buffer): boolean {\n return buffer[0] === 1;\n },\n};\n","import { IllegalArgumentError } from '../../../utils/errors';\nimport { Tag, MAX_AUTH_FUN_GAS } from '../constants';\nimport shortUInt from './short-u-int';\nimport { buildGas } from './fee';\nimport type { unpackTx as unpackTxType, buildTx as buildTxType } from '../index';\n\nfunction calculateGasLimitMax(\n gasMax: number,\n rebuildTx: (value: number) => any,\n unpackTx: typeof unpackTxType,\n buildTx: typeof buildTxType,\n): number {\n return gasMax - +buildGas(rebuildTx(gasMax), unpackTx, buildTx);\n}\n\nexport default {\n ...shortUInt,\n\n serialize(\n _value: number | undefined,\n {\n tag, rebuildTx, unpackTx, buildTx, _computingGasLimit,\n }: {\n tag: Tag;\n rebuildTx: (params: any) => any;\n unpackTx: typeof unpackTxType;\n buildTx: typeof buildTxType;\n _computingGasLimit?: number;\n },\n { gasMax = 6e6 }: { gasMax?: number },\n ): Buffer {\n if (_computingGasLimit != null) return shortUInt.serialize(_computingGasLimit);\n\n const gasLimitMax = tag === Tag.GaMetaTx ? MAX_AUTH_FUN_GAS : calculateGasLimitMax(\n gasMax,\n (gasLimit) => rebuildTx({ _computingGasLimit: gasLimit, _canIncreaseFee: true }),\n unpackTx,\n buildTx,\n );\n const value = _value ?? gasLimitMax;\n if (value > gasLimitMax) {\n throw new IllegalArgumentError(`Gas limit ${value} must be less or equal to ${gasLimitMax}`);\n }\n return shortUInt.serialize(value);\n },\n};\n","import { Tag, ConsensusProtocolVersion, AbiVersion } from '../constants';\nimport { getProtocolDetails } from './ct-version';\nimport Node from '../../../Node';\n\nexport default {\n _getProtocolDetails(c: ConsensusProtocolVersion, tag: Tag): AbiVersion {\n const kind = Tag.ContractCallTx === tag || Tag.GaMetaTx === tag\n ? 'contract-call' : 'oracle-call';\n return getProtocolDetails(c, kind).abiVersion;\n },\n\n serialize(\n value: AbiVersion | undefined,\n { tag }: { tag: Tag },\n { consensusProtocolVersion = ConsensusProtocolVersion.Iris }:\n { consensusProtocolVersion?: ConsensusProtocolVersion },\n ): Buffer {\n const result = value ?? this._getProtocolDetails(consensusProtocolVersion, tag);\n\n return Buffer.from([result]);\n },\n\n async prepare(\n value: AbiVersion | undefined,\n { tag }: { tag: Tag },\n // TODO: { consensusProtocolVersion: ConsensusProtocolVersion } | { onNode: Node } | {}\n options: { consensusProtocolVersion?: ConsensusProtocolVersion; onNode?: Node },\n ): Promise<AbiVersion | undefined> {\n if (value != null) return value;\n if (options.consensusProtocolVersion != null) return undefined;\n if (Object.keys(ConsensusProtocolVersion).length === 2) return undefined;\n if (options.onNode != null) {\n return this._getProtocolDetails(\n (await options.onNode.getNodeInfo()).consensusProtocolVersion,\n tag,\n );\n }\n return undefined;\n },\n\n deserialize(buffer: Buffer): AbiVersion {\n return buffer[0];\n },\n};\n","import { ArgumentError } from '../../../utils/errors';\nimport { isItemOfArray } from '../../../utils/other';\n\nexport default function genEnumerationField<\n Enum extends { [key: string]: number | string },\n>(enm: Enum): {\n serialize: (value: Enum[keyof Enum]) => Buffer;\n deserialize: (value: Buffer) => Enum[keyof Enum];\n} {\n const values = Object.values(enm).filter((v) => typeof v === 'number');\n return {\n serialize(value) {\n if (typeof value !== 'number') throw new ArgumentError('value', 'to be a number', value);\n if (value > 0xff) throw new ArgumentError('value', 'to be less than 256', value);\n if (!isItemOfArray(value, values)) {\n throw new ArgumentError('value', 'to be a value of Enum', value);\n }\n return Buffer.from([value]);\n },\n\n deserialize(buffer) {\n if (buffer.length !== 1) {\n throw new ArgumentError('buffer', 'to have single element', buffer.length);\n }\n const value = buffer[0];\n if (!isItemOfArray(value, values)) {\n throw new ArgumentError('value', 'to be a value of Enum', value);\n }\n return value as Enum[keyof Enum];\n },\n };\n}\n","import { toBytes } from '../../../utils/bytes';\n\nexport default {\n serialize(string: string): Buffer {\n return toBytes(string);\n },\n\n deserialize(buffer: Buffer): string {\n return buffer.toString();\n },\n};\n","import coinAmount from './coin-amount';\nimport { Int } from '../constants';\nimport Node from '../../../Node';\nimport { Encoded } from '../../../utils/encoder';\nimport { ArgumentError } from '../../../utils/errors';\n\n/**\n * Oracle query fee\n */\nexport default {\n ...coinAmount,\n\n async prepare(\n value: Int | undefined,\n params: {},\n options: { oracleId?: Encoded.OracleAddress; onNode?: Node },\n ) {\n if (value != null) return value;\n const { onNode, oracleId } = options;\n const requirement = 'provided (or provide `queryFee` instead)';\n if (onNode == null) throw new ArgumentError('onNode', requirement, onNode);\n if (oracleId == null) throw new ArgumentError('oracleId', requirement, oracleId);\n return (await onNode.getOracleByPubkey(oracleId)).queryFee.toString();\n },\n};\n","import assertClassBrand from \"./assertClassBrand.js\";\nexport default function _classPrivateFieldGet2(s, a) {\n return s.get(assertClassBrand(s, a));\n}","export default function _assertClassBrand(e, t, n) {\n if (\"function\" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n;\n throw new TypeError(\"Private element is not present on this object\");\n}","import classApplyDescriptorSet from \"./classApplyDescriptorSet.js\";\nimport classPrivateFieldGet2 from \"./classPrivateFieldGet2.js\";\nexport default function _classPrivateFieldSet(receiver, privateMap, value) {\n var descriptor = classPrivateFieldGet2(privateMap, receiver);\n classApplyDescriptorSet(receiver, descriptor, value);\n return value;\n}","export default function _classApplyDescriptorSet(receiver, descriptor, value) {\n if (descriptor.set) {\n descriptor.set.call(receiver, value);\n } else {\n if (!descriptor.writable) {\n throw new TypeError(\"attempted to set read only private field\");\n }\n descriptor.value = value;\n }\n}","import classApplyDescriptorGet from \"./classApplyDescriptorGet.js\";\nimport classPrivateFieldGet2 from \"./classPrivateFieldGet2.js\";\nexport default function _classPrivateFieldGet(receiver, privateMap) {\n var descriptor = classPrivateFieldGet2(privateMap, receiver);\n return classApplyDescriptorGet(receiver, descriptor);\n}","export default function _classApplyDescriptorGet(receiver, descriptor) {\n if (descriptor.get) {\n return descriptor.get.call(receiver);\n }\n return descriptor.value;\n}","import { encode as rlpEncode, Input } from 'rlp';\nimport { Tag } from '../constants';\nimport { hash } from '../../../utils/crypto';\nimport {\n MerkleTreeHashMismatchError,\n MissingNodeInTreeError,\n UnknownPathNibbleError,\n UnexpectedTsError,\n UnknownNodeLengthError,\n InternalError,\n} from '../../../utils/errors';\nimport {\n decode, encode, Encoded, Encoding,\n} from '../../../utils/encoder';\nimport type { unpackTx } from '..';\nimport type { TxUnpacked } from '../schema.generated';\n\nenum NodeType {\n Branch,\n Extension,\n Leaf,\n}\n\ntype MPTreeBinary = [Buffer, Array<[Buffer, Buffer[]]>];\n\nclass MPTree<E extends Encoding, T extends Tag> {\n readonly #rootHash: string;\n\n #isComplete = true;\n\n get isComplete(): boolean {\n return this.#isComplete;\n }\n\n readonly #nodes: { [key: string]: Buffer[] };\n\n readonly #encoding: E;\n\n readonly #tag: T;\n\n readonly #unpackTx: typeof unpackTx;\n\n static #nodeHash(node: Input): string {\n return Buffer.from(hash(rlpEncode(node))).toString('hex');\n }\n\n /**\n * Deserialize Merkle Patricia Tree\n * @param binary - Binary\n * @param tag - Tag to use to decode value\n * @param unpTx - Implementation of unpackTx use to decode values\n * @returns Merkle Patricia Tree\n */\n constructor(binary: MPTreeBinary, encoding: E, tag: T, unpTx: typeof unpackTx) {\n this.#encoding = encoding;\n this.#tag = tag;\n this.#unpackTx = unpTx;\n this.#rootHash = binary[0].toString('hex');\n this.#nodes = Object.fromEntries(\n binary[1].map((node) => [node[0].toString('hex'), node[1]]),\n );\n\n if (this.#nodes[this.#rootHash] == null) {\n if (Object.keys(this.#nodes).length !== 0) {\n throw new MissingNodeInTreeError('Can\\'t find a node by root hash');\n }\n this.#isComplete = false;\n return;\n }\n Object.entries(this.#nodes).forEach(([key, node]) => {\n if (MPTree.#nodeHash(node) !== key) throw new MerkleTreeHashMismatchError();\n const { type } = MPTree.#parseNode(node);\n switch (type) {\n case NodeType.Branch:\n node\n .slice(0, 16)\n .filter((n) => n.length)\n .forEach((n) => {\n // TODO: enable after resolving https://github.com/aeternity/aeternity/issues/4066\n // if (n.length !== 32) {\n // throw new ArgumentError('MPTree branch item length', 32, n.length);\n // }\n if (this.#nodes[n.toString('hex')] == null) this.#isComplete = false;\n });\n break;\n case NodeType.Extension:\n if (this.#nodes[node[1].toString('hex')] == null) {\n throw new MissingNodeInTreeError('Can\\'t find a node by hash in extension node');\n }\n break;\n case NodeType.Leaf:\n break;\n default:\n throw new InternalError(`Unknown MPTree node type: ${type}`);\n }\n });\n }\n\n isEqual(tree: MPTree<E, T>): boolean {\n return this.#rootHash === tree.#rootHash;\n }\n\n static #parseNode(node: Buffer[]): { type: NodeType; value?: Buffer; path?: string } {\n switch (node.length) {\n case 17:\n return {\n type: NodeType.Branch,\n ...node[16].length !== 0 && { value: node[16] },\n };\n case 2: {\n const nibble = node[0][0] >> 4; // eslint-disable-line no-bitwise\n if (nibble > 3) throw new UnknownPathNibbleError(nibble);\n const type = nibble <= 1 ? NodeType.Extension : NodeType.Leaf;\n const slice = [0, 2].includes(nibble) ? 2 : 1;\n return {\n type,\n ...type === NodeType.Leaf && { value: node[1] },\n path: node[0].toString('hex').slice(slice),\n };\n }\n default:\n throw new UnknownNodeLengthError(node.length);\n }\n }\n\n /**\n * Serialize Merkle Patricia Tree\n * @returns Binary\n */\n serialize(): MPTreeBinary {\n return [\n Buffer.from(this.#rootHash, 'hex'),\n Object.entries(this.#nodes).map(([mptHash, value]) => ([\n Buffer.from(mptHash, 'hex'),\n value,\n ])),\n ];\n }\n\n /**\n * Retrieve value from Merkle Patricia Tree\n * @param _key - The key of the element to retrieve\n * @returns Value associated to the specified key\n */\n #getRaw(_key: string): Buffer | undefined {\n let searchFrom = this.#rootHash;\n let key = _key;\n while (true) { // eslint-disable-line no-constant-condition\n const node = this.#nodes[searchFrom];\n if (node == null) {\n if (!this.isComplete) return undefined;\n throw new InternalError('Can\\'t find node in complete tree');\n }\n const { type, value, path } = MPTree.#parseNode(node);\n switch (type) {\n case NodeType.Branch:\n if (key.length === 0) return value;\n searchFrom = node[+`0x${key[0]}`].toString('hex');\n key = key.substring(1);\n break;\n case NodeType.Extension:\n if (key.substring(0, path?.length) !== path) return undefined;\n searchFrom = node[1].toString('hex');\n key = key.substring(path.length);\n break;\n case NodeType.Leaf:\n if (path !== key) return undefined;\n return value;\n default:\n throw new InternalError(`Unknown MPTree node type: ${type}`);\n }\n }\n }\n\n /**\n * Retrieve value from Merkle Patricia Tree\n * @param key - The key of the element to retrieve\n * @returns Value associated to the specified key\n */\n get(key: Encoded.Generic<E>): TxUnpacked & { tag: T } | undefined {\n const d = this.#getRaw(decode(key).toString('hex'));\n if (d == null) return d;\n return this.#unpackTx(encode(d, Encoding.Transaction), this.#tag);\n }\n\n #entriesRaw(): Array<[string, Buffer]> {\n const entries: Array<[string, Buffer]> = [];\n const rec = (searchFrom: string, key: string): void => {\n const node = this.#nodes[searchFrom];\n if (node == null) {\n if (!this.isComplete) return;\n throw new InternalError('Can\\'t find node in complete tree');\n }\n const { type, value, path } = MPTree.#parseNode(node);\n switch (type) {\n case NodeType.Branch:\n node\n .slice(0, 16)\n .map((t, idx): [typeof t, number] => [t, idx])\n .filter(([t]) => t.length)\n .forEach(([t, idx]) => rec(t.toString('hex'), key + idx.toString(16)));\n if (value != null) entries.push([key, value]);\n break;\n case NodeType.Extension:\n rec(node[1].toString('hex'), key + path);\n break;\n case NodeType.Leaf:\n if (value == null) throw new UnexpectedTsError();\n entries.push([key + path, value]);\n break;\n default:\n throw new InternalError(`Unknown MPTree node type: ${type}`);\n }\n };\n rec(this.#rootHash, '');\n return entries;\n }\n\n toObject(): Record<Encoded.Generic<E>, TxUnpacked & { tag: T }> {\n return Object.fromEntries(this.#entriesRaw()\n // TODO: remove after resolving https://github.com/aeternity/aeternity/issues/4066\n .filter(([k]) => this.#encoding !== Encoding.ContractAddress || k.length !== 66)\n .map(([k, v]) => [\n encode(Buffer.from(k, 'hex'), this.#encoding),\n this.#unpackTx(encode(v, Encoding.Transaction), this.#tag),\n ])) as Record<Encoded.Generic<E>, TxUnpacked & { tag: T }>;\n }\n}\n\nexport default function genMPTreeField<E extends Encoding, T extends Tag>(encoding: E, tag: T): {\n serialize: (value: MPTree<E, T>) => MPTreeBinary;\n deserialize: (value: MPTreeBinary, o: { unpackTx: typeof unpackTx }) => MPTree<E, T>;\n} {\n return {\n serialize(value) {\n return value.serialize();\n },\n\n deserialize(value, { unpackTx }) {\n return new MPTree(value, encoding, tag, unpackTx);\n },\n };\n}\n","import { Tag } from '../constants';\nimport { encode, Encoding, decode } from '../../../utils/encoder';\nimport type { unpackTx as unpackTxType, buildTx as buildTxType } from '../index';\n\ntype TagWrapping = Tag.AccountsMtree | Tag.CallsMtree | Tag.ChannelsMtree | Tag.ContractsMtree\n| Tag.NameserviceMtree | Tag.OraclesMtree;\n\nexport default function genWrappedField<T extends TagWrapping>(tag: T): {\n serialize: (\n // TODO: replace with `(TxParams & { tag: T })['payload']`,\n // but fix TS2502 value is referenced directly or indirectly in its own type annotation\n value: any, options: { buildTx: typeof buildTxType }\n ) => Buffer;\n deserialize: (\n value: Buffer, options: { unpackTx: typeof unpackTxType },\n // TODO: replace with `(TxUnpacked & { tag: T })['payload']`,\n // TS2577 Return type annotation circularly references itself\n ) => any;\n recursiveType: true;\n} {\n return {\n serialize(payload, { buildTx }) {\n return decode(buildTx({ tag, payload }));\n },\n\n deserialize(buffer, { unpackTx }) {\n return unpackTx<TagWrapping>(encode(buffer, Encoding.Transaction), tag).payload;\n },\n\n recursiveType: true,\n };\n}\n","/**\n * Transaction Schema for TxBuilder\n */\n// # RLP version number\n// # https://github.com/aeternity/protocol/blob/master/serializations.md#binary-serialization\n\nimport { Tag } from './constants';\nimport SchemaTypes from './SchemaTypes';\nimport {\n uInt, shortUInt, coinAmount, name, nameId, nameFee, gasLimit, gasPrice, fee, address, pointers,\n pointers2, queryFee, entry, enumeration, mptree, shortUIntConst, string, encoded, raw,\n array, boolean, ctVersion, abiVersion, ttl, nonce, map, withDefault, withFormatting, wrapped,\n} from './field-types';\nimport { Encoded, Encoding } from '../../utils/encoder';\nimport { ArgumentError } from '../../utils/errors';\nimport { idTagToEncoding } from './field-types/address';\n\nexport enum ORACLE_TTL_TYPES {\n delta = 0,\n block = 1,\n}\n\nexport enum CallReturnType {\n Ok = 0,\n Error = 1,\n Revert = 2,\n}\n\n// TODO: figure out how to omit overriding types of recursive fields\ninterface EntryAny {\n serialize: (value: TxParams | Uint8Array | Encoded.Transaction) => Buffer;\n deserialize: (value: Buffer) => TxUnpacked;\n recursiveType: true;\n}\n\nconst entryAny = entry() as unknown as EntryAny;\n\ninterface EntrySignedTx {\n serialize: (value: TxParams & { tag: Tag.SignedTx } | Uint8Array | Encoded.Transaction) => Buffer;\n deserialize: (value: Buffer) => TxUnpacked & { tag: Tag.SignedTx };\n recursiveType: true;\n}\n\nconst entrySignedTx = entry(Tag.SignedTx) as unknown as EntrySignedTx;\n\ninterface EntryMtreeValueArray {\n serialize: (\n value: Array<TxParams & { tag: Tag.MtreeValue } | Uint8Array | Encoded.Transaction>,\n ) => Buffer[];\n deserialize: (value: Buffer[]) => Array<TxUnpacked & { tag: Tag.MtreeValue }>;\n recursiveType: true;\n}\n\nconst entryMtreeValueArray = array(entry(Tag.MtreeValue)) as unknown as EntryMtreeValueArray;\n\ninterface EntryTreesPoi {\n serialize: (value: TxParams & { tag: Tag.TreesPoi } | Uint8Array | Encoded.Transaction) => Buffer;\n deserialize: (value: Buffer) => TxUnpacked & { tag: Tag.TreesPoi };\n recursiveType: true;\n}\n\nconst entryTreesPoi = entry(Tag.TreesPoi) as unknown as EntryTreesPoi;\n\ninterface MapContracts {\n serialize: (\n value: Record<Encoded.ContractAddress, TxParams & { tag: Tag.Contract }>,\n ) => Buffer;\n deserialize: (\n value: Buffer,\n ) => Record<Encoded.ContractAddress, TxUnpacked & { tag: Tag.Contract }>;\n recursiveType: true;\n}\n\nconst mapContracts = map(Encoding.ContractAddress, Tag.Contract) as unknown as MapContracts;\n\ninterface MapAccounts {\n serialize: (\n value: Record<Encoded.AccountAddress, TxParams & { tag: Tag.Account }>,\n ) => Buffer;\n deserialize: (value: Buffer) => Record<Encoded.AccountAddress, TxUnpacked & { tag: Tag.Account }>;\n recursiveType: true;\n}\n\nconst mapAccounts = map(Encoding.AccountAddress, Tag.Account) as unknown as MapAccounts;\n\ninterface MapCalls {\n serialize: (\n value: Record<Encoded.Bytearray, TxParams & { tag: Tag.ContractCall }>,\n ) => Buffer;\n deserialize: (value: Buffer) => Record<Encoded.Bytearray, TxUnpacked & { tag: Tag.ContractCall }>;\n recursiveType: true;\n}\n\nconst mapCalls = map(Encoding.Bytearray, Tag.ContractCall) as unknown as MapCalls;\n\ninterface MapChannels {\n serialize: (\n value: Record<Encoded.Channel, TxParams & { tag: Tag.Channel }>,\n ) => Buffer;\n deserialize: (value: Buffer) => Record<Encoded.Channel, TxUnpacked & { tag: Tag.Channel }>;\n recursiveType: true;\n}\n\nconst mapChannels = map(Encoding.Channel, Tag.Channel) as unknown as MapChannels;\n\ninterface MapNames {\n serialize: (\n value: Record<Encoded.Name, TxParams & { tag: Tag.Name }>,\n ) => Buffer;\n deserialize: (value: Buffer) => Record<Encoded.Name, TxUnpacked & { tag: Tag.Name }>;\n recursiveType: true;\n}\n\nconst mapNames = map(Encoding.Name, Tag.Name) as unknown as MapNames;\n\ninterface MapOracles {\n serialize: (\n value: Record<Encoded.OracleAddress, TxParams & { tag: Tag.Oracle }>,\n ) => Buffer;\n deserialize: (value: Buffer) => Record<Encoded.OracleAddress, TxUnpacked & { tag: Tag.Oracle }>;\n recursiveType: true;\n}\n\nconst mapOracles = map(Encoding.OracleAddress, Tag.Oracle) as unknown as MapOracles;\n\n// TODO: inline after dropping Iris compatibility\nconst clientTtl = withDefault(60 * 60, shortUInt);\n// https://github.com/aeternity/protocol/blob/fd17982/AENS.md#update\nconst nameTtl = withFormatting(\n (value) => {\n const NAME_TTL = 180000;\n value ??= NAME_TTL;\n if (value >= 1 && value <= NAME_TTL) return value;\n throw new ArgumentError('nameTtl', `a number between 1 and ${NAME_TTL} blocks`, value);\n },\n shortUInt,\n);\n\n/**\n * @see {@link https://github.com/aeternity/protocol/blob/c007deeac4a01e401238412801ac7084ac72d60e/serializations.md#accounts-version-1-basic-accounts}\n */\nexport const txSchema = [{\n tag: shortUIntConst(Tag.Account),\n version: shortUIntConst(1),\n nonce: shortUInt,\n balance: uInt,\n}, {\n tag: shortUIntConst(Tag.Account),\n version: shortUIntConst(2, true),\n flags: uInt,\n nonce: shortUInt,\n balance: uInt,\n gaContract: address(Encoding.ContractAddress, Encoding.Name),\n gaAuthFun: encoded(Encoding.ContractBytearray),\n}, {\n tag: shortUIntConst(Tag.SignedTx),\n version: shortUIntConst(1, true),\n signatures: array(raw),\n encodedTx: entryAny,\n}, {\n tag: shortUIntConst(Tag.SpendTx),\n version: shortUIntConst(1, true),\n senderId: address(Encoding.AccountAddress),\n // TODO: accept also an AENS name\n recipientId: address(Encoding.AccountAddress, Encoding.ContractAddress, Encoding.Name),\n amount: coinAmount,\n fee,\n ttl,\n nonce: nonce('senderId'),\n payload: encoded(Encoding.Bytearray, true),\n}, {\n tag: shortUIntConst(Tag.Name),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n nameTtl: shortUInt,\n status: raw,\n clientTtl: shortUInt,\n pointers,\n}, {\n tag: shortUIntConst(Tag.NamePreclaimTx),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n commitmentId: address(Encoding.Commitment),\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.NameClaimTx),\n version: shortUIntConst(2, true),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n name,\n nameSalt: uInt,\n nameFee,\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.NameUpdateTx),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n nameId,\n nameTtl,\n pointers,\n clientTtl,\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.NameUpdateTx),\n version: shortUIntConst(2),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n nameId,\n nameTtl,\n pointers: pointers2,\n clientTtl,\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.NameTransferTx),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n nameId,\n // TODO: accept also an AENS name\n recipientId: address(Encoding.AccountAddress, Encoding.Name),\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.NameRevokeTx),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n nameId,\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.Contract),\n version: shortUIntConst(1, true),\n owner: address(Encoding.AccountAddress),\n ctVersion,\n code: encoded(Encoding.ContractBytearray),\n log: encoded(Encoding.ContractBytearray),\n active: boolean,\n referers: array(address(Encoding.AccountAddress)),\n deposit: coinAmount,\n}, {\n tag: shortUIntConst(Tag.ContractCreateTx),\n version: shortUIntConst(1, true),\n ownerId: address(Encoding.AccountAddress),\n nonce: nonce('ownerId'),\n code: encoded(Encoding.ContractBytearray),\n ctVersion,\n fee,\n ttl,\n deposit: withFormatting(\n (value = 0) => {\n if (+value === 0) return value;\n throw new ArgumentError('deposit', 'equal 0 (because is not refundable)', value);\n },\n coinAmount,\n ),\n amount: coinAmount,\n gasLimit,\n gasPrice,\n callData: encoded(Encoding.ContractBytearray),\n}, {\n tag: shortUIntConst(Tag.ContractCallTx),\n version: shortUIntConst(1, true),\n callerId: address(Encoding.AccountAddress),\n nonce: nonce('callerId'),\n // TODO: accept also an AENS name\n contractId: address(Encoding.ContractAddress, Encoding.Name),\n abiVersion,\n fee,\n ttl,\n amount: coinAmount,\n gasLimit,\n gasPrice,\n callData: encoded(Encoding.ContractBytearray),\n}, {\n tag: shortUIntConst(Tag.ContractCall),\n version: shortUIntConst(2, true),\n callerId: address(Encoding.AccountAddress),\n callerNonce: shortUInt,\n height: shortUInt,\n contractId: address(Encoding.ContractAddress),\n // TODO: rename after resolving https://github.com/aeternity/protocol/issues/506\n gasPrice: uInt,\n gasUsed: shortUInt,\n returnValue: encoded(Encoding.ContractBytearray),\n returnType: enumeration(CallReturnType),\n // TODO: add serialization for\n // <log> :: [ { <address> :: id, [ <topics> :: binary() }, <data> :: binary() } ]\n log: array(raw),\n}, {\n tag: shortUIntConst(Tag.Oracle),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n queryFormat: string,\n responseFormat: string,\n queryFee: coinAmount,\n oracleTtlValue: shortUInt,\n abiVersion,\n}, {\n tag: shortUIntConst(Tag.OracleRegisterTx),\n version: shortUIntConst(1, true),\n accountId: address(Encoding.AccountAddress),\n nonce: nonce('accountId'),\n queryFormat: string,\n responseFormat: string,\n queryFee: coinAmount,\n oracleTtlType: withDefault(ORACLE_TTL_TYPES.delta, enumeration(ORACLE_TTL_TYPES)),\n oracleTtlValue: withDefault(500, shortUInt),\n fee,\n ttl,\n abiVersion,\n}, {\n tag: shortUIntConst(Tag.OracleExtendTx),\n version: shortUIntConst(1, true),\n // TODO: accept also an AENS name\n oracleId: address(Encoding.OracleAddress, Encoding.Name),\n nonce: nonce('oracleId'),\n oracleTtlType: withDefault(ORACLE_TTL_TYPES.delta, enumeration(ORACLE_TTL_TYPES)),\n oracleTtlValue: withDefault(500, shortUInt),\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.OracleQueryTx),\n version: shortUIntConst(1, true),\n senderId: address(Encoding.AccountAddress),\n nonce: nonce('senderId'),\n // TODO: accept also an AENS name\n oracleId: address(Encoding.OracleAddress, Encoding.Name),\n query: string,\n queryFee,\n queryTtlType: withDefault(ORACLE_TTL_TYPES.delta, enumeration(ORACLE_TTL_TYPES)),\n queryTtlValue: withDefault(10, shortUInt),\n responseTtlType: withDefault(ORACLE_TTL_TYPES.delta, enumeration(ORACLE_TTL_TYPES)),\n responseTtlValue: withDefault(10, shortUInt),\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.OracleResponseTx),\n version: shortUIntConst(1, true),\n oracleId: address(Encoding.OracleAddress),\n nonce: nonce('oracleId'),\n queryId: encoded(Encoding.OracleQueryId),\n response: string,\n responseTtlType: withDefault(ORACLE_TTL_TYPES.delta, enumeration(ORACLE_TTL_TYPES)),\n responseTtlValue: withDefault(10, shortUInt),\n fee,\n ttl,\n}, {\n tag: shortUIntConst(Tag.ChannelCreateTx),\n version: shortUIntConst(2, true),\n initiator: address(Encoding.AccountAddress),\n initiatorAmount: uInt,\n responder: address(Encoding.AccountAddress),\n responderAmount: uInt,\n channelReserve: uInt,\n lockPeriod: uInt,\n ttl,\n fee,\n initiatorDelegateIds: array(address(...idTagToEncoding)),\n responderDelegateIds: array(address(...idTagToEncoding)),\n stateHash: encoded(Encoding.State),\n nonce: nonce('initiator'),\n}, {\n tag: shortUIntConst(Tag.ChannelCloseMutualTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n initiatorAmountFinal: uInt,\n responderAmountFinal: uInt,\n ttl,\n fee,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelCloseSoloTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n payload: encoded(Encoding.Transaction),\n poi: entryTreesPoi,\n ttl,\n fee,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelSlashTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n payload: encoded(Encoding.Transaction),\n poi: entryTreesPoi,\n ttl,\n fee,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelDepositTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n amount: uInt,\n ttl,\n fee,\n stateHash: encoded(Encoding.State),\n round: shortUInt,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelWithdrawTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n toId: address(Encoding.AccountAddress),\n amount: uInt,\n ttl,\n fee,\n stateHash: encoded(Encoding.State),\n round: shortUInt,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelSettleTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n initiatorAmountFinal: uInt,\n responderAmountFinal: uInt,\n ttl,\n fee,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelForceProgressTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n payload: encoded(Encoding.Transaction),\n round: shortUInt,\n update: encoded(Encoding.ContractBytearray),\n stateHash: encoded(Encoding.State),\n offChainTrees: encoded(Encoding.StateTrees),\n ttl,\n fee,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelOffChainTx),\n version: shortUIntConst(2, true),\n channelId: address(Encoding.Channel),\n round: shortUInt,\n stateHash: encoded(Encoding.State),\n}, {\n tag: shortUIntConst(Tag.Channel),\n version: shortUIntConst(3, true),\n initiator: address(Encoding.AccountAddress),\n responder: address(Encoding.AccountAddress),\n channelAmount: uInt,\n initiatorAmount: uInt,\n responderAmount: uInt,\n channelReserve: uInt,\n initiatorDelegateIds: array(address(...idTagToEncoding)),\n responderDelegateIds: array(address(...idTagToEncoding)),\n stateHash: encoded(Encoding.State),\n round: shortUInt,\n soloRound: uInt,\n lockPeriod: uInt,\n lockedUntil: uInt,\n initiatorAuth: encoded(Encoding.ContractBytearray),\n responderAuth: encoded(Encoding.ContractBytearray),\n}, {\n tag: shortUIntConst(Tag.ChannelSnapshotSoloTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n fromId: address(Encoding.AccountAddress),\n payload: encoded(Encoding.Transaction),\n ttl,\n fee,\n nonce: nonce('fromId'),\n}, {\n tag: shortUIntConst(Tag.ChannelOffChainUpdateTransfer),\n version: shortUIntConst(1, true),\n from: address(Encoding.AccountAddress),\n to: address(Encoding.AccountAddress),\n amount: uInt,\n}, {\n tag: shortUIntConst(Tag.ChannelOffChainUpdateDeposit),\n version: shortUIntConst(1, true),\n from: address(Encoding.AccountAddress),\n amount: uInt,\n}, {\n tag: shortUIntConst(Tag.ChannelOffChainUpdateWithdraw),\n version: shortUIntConst(1, true),\n from: address(Encoding.AccountAddress),\n amount: uInt,\n}, {\n tag: shortUIntConst(Tag.ChannelOffChainUpdateCreateContract),\n version: shortUIntConst(1, true),\n owner: address(Encoding.AccountAddress),\n ctVersion,\n code: encoded(Encoding.ContractBytearray),\n deposit: uInt,\n callData: encoded(Encoding.ContractBytearray),\n}, {\n tag: shortUIntConst(Tag.ChannelOffChainUpdateCallContract),\n version: shortUIntConst(1, true),\n caller: address(Encoding.AccountAddress),\n contract: address(Encoding.ContractAddress),\n abiVersion,\n amount: uInt,\n callData: encoded(Encoding.ContractBytearray),\n callStack: raw,\n gasPrice,\n gasLimit,\n}, {\n tag: shortUIntConst(Tag.ChannelClientReconnectTx),\n version: shortUIntConst(1, true),\n channelId: address(Encoding.Channel),\n round: shortUInt,\n role: string,\n pubkey: address(Encoding.AccountAddress),\n}, {\n tag: shortUIntConst(Tag.TreesPoi),\n version: shortUIntConst(1, true),\n // TODO: inline an extra wrapping array after resolving https://github.com/aeternity/protocol/issues/505\n accounts: array(mptree(Encoding.AccountAddress, Tag.Account)),\n calls: array(mptree(Encoding.Bytearray, Tag.ContractCall)),\n channels: array(mptree(Encoding.Channel, Tag.Channel)),\n contracts: array(mptree(Encoding.ContractAddress, Tag.Contract)),\n ns: array(mptree(Encoding.Name, Tag.Name)),\n oracles: array(mptree(Encoding.OracleAddress, Tag.Oracle)),\n}, {\n tag: shortUIntConst(Tag.StateTrees),\n version: shortUIntConst(0, true),\n contracts: wrapped(Tag.ContractsMtree) as unknown as MapContracts,\n calls: wrapped(Tag.CallsMtree) as unknown as MapCalls,\n channels: wrapped(Tag.ChannelsMtree) as unknown as MapChannels,\n ns: wrapped(Tag.NameserviceMtree) as unknown as MapNames,\n oracles: wrapped(Tag.OraclesMtree) as unknown as MapOracles,\n accounts: wrapped(Tag.AccountsMtree) as unknown as MapAccounts,\n}, {\n tag: shortUIntConst(Tag.Mtree),\n version: shortUIntConst(1, true),\n values: entryMtreeValueArray,\n}, {\n tag: shortUIntConst(Tag.MtreeValue),\n version: shortUIntConst(1, true),\n key: raw,\n value: raw,\n}, {\n tag: shortUIntConst(Tag.ContractsMtree),\n version: shortUIntConst(1, true),\n payload: mapContracts,\n}, {\n tag: shortUIntConst(Tag.CallsMtree),\n version: shortUIntConst(1, true),\n payload: mapCalls,\n}, {\n tag: shortUIntConst(Tag.ChannelsMtree),\n version: shortUIntConst(1, true),\n payload: mapChannels,\n}, {\n tag: shortUIntConst(Tag.NameserviceMtree),\n version: shortUIntConst(1, true),\n payload: mapNames,\n}, {\n tag: shortUIntConst(Tag.OraclesMtree),\n version: shortUIntConst(1, true),\n payload: mapOracles,\n}, {\n tag: shortUIntConst(Tag.AccountsMtree),\n version: shortUIntConst(1, true),\n payload: mapAccounts,\n}, {\n tag: shortUIntConst(Tag.GaAttachTx),\n version: shortUIntConst(1, true),\n ownerId: address(Encoding.AccountAddress),\n nonce: nonce('ownerId'),\n code: encoded(Encoding.ContractBytearray),\n authFun: raw,\n ctVersion,\n fee,\n ttl,\n gasLimit,\n gasPrice,\n callData: encoded(Encoding.ContractBytearray),\n}, {\n tag: shortUIntConst(Tag.GaMetaTx),\n version: shortUIntConst(2, true),\n gaId: address(Encoding.AccountAddress),\n authData: encoded(Encoding.ContractBytearray),\n abiVersion,\n fee,\n gasLimit,\n gasPrice,\n tx: entrySignedTx,\n}, {\n tag: shortUIntConst(Tag.PayingForTx),\n version: shortUIntConst(1, true),\n payerId: address(Encoding.AccountAddress),\n nonce: nonce('payerId'),\n fee,\n tx: entrySignedTx,\n}, {\n tag: shortUIntConst(Tag.GaMetaTxAuthData),\n version: shortUIntConst(1, true),\n fee: coinAmount,\n gasPrice,\n txHash: encoded(Encoding.TxHash),\n}] as const;\n\ntype TxSchema = SchemaTypes<typeof txSchema>;\nexport type TxParams = TxSchema['TxParams'];\nexport type TxParamsAsync = TxSchema['TxParamsAsync'];\nexport type TxUnpacked = TxSchema['TxUnpacked'];\n","import { decode as rlpDecode, encode as rlpEncode } from 'rlp';\nimport { Field, BinaryData } from './field-types';\nimport {\n ArgumentError, DecodeError, SchemaNotFoundError, InternalError,\n} from '../../utils/errors';\nimport {\n Encoding, Encoded, encode, decode,\n} from '../../utils/encoder';\nimport { readInt } from './helpers';\n\ntype Schemas = ReadonlyArray<{\n tag: { constValue: number } & Field;\n version: { constValue: number; constValueOptional: boolean } & Field;\n}>;\n\nexport function getSchema(\n schemas: Schemas,\n Tag: { [key: number]: string },\n tag: number,\n version: number | undefined,\n): Array<[string, Field]> {\n const subSchemas = schemas.filter((s) => s.tag.constValue === tag);\n if (subSchemas.length === 0) throw new SchemaNotFoundError(`${Tag[tag]} (${tag})`, 0);\n if (version == null) {\n const defaultSchema = subSchemas.find((schema) => schema.version.constValueOptional);\n if (defaultSchema == null) throw new InternalError(`Can't find default schema of ${Tag[tag]} (${tag})`);\n version = defaultSchema.version.constValue;\n }\n const schema = subSchemas.find((s) => s.version.constValue === version);\n if (schema == null) throw new SchemaNotFoundError(`${Tag[tag]} (${tag})`, version);\n return Object.entries(schema);\n}\n\nexport function packRecord<E extends Encoding>(\n schemas: Schemas,\n Tag: { [key: number]: string },\n params: {\n tag: number;\n version?: number;\n [k: string]: unknown;\n },\n extraParams: { [k: string]: unknown },\n encoding: E,\n): Encoded.Generic<E> {\n const schema = getSchema(schemas, Tag, params.tag, params.version);\n const binary = schema.map(([key, field]) => (\n field.serialize(params[key], { ...params, ...extraParams }, params)\n ));\n return encode(rlpEncode(binary), encoding);\n}\n\nexport function unpackRecord(\n schemas: Schemas,\n Tag: { [key: number]: string },\n encodedRecord: Encoded.Any,\n expectedTag: number | undefined,\n extraParams: { [k: string]: unknown },\n): unknown {\n const binary = rlpDecode(decode(encodedRecord));\n const tag = +readInt(binary[0] as Buffer);\n const version = +readInt(binary[1] as Buffer);\n const schema = getSchema(schemas, Tag, tag, version);\n if (expectedTag != null && expectedTag !== tag) {\n throw new DecodeError(`Expected ${Tag[expectedTag]} tag, got ${Tag[tag]} instead`);\n }\n if (binary.length !== schema.length) {\n throw new ArgumentError('RLP length', schema.length, binary.length);\n }\n return Object.fromEntries(\n schema.map(([name, field], index) => [\n name, field.deserialize(binary[index] as BinaryData, extraParams),\n ]),\n );\n}\n","import {\n decode, encode, Encoded, Encoding,\n} from '../../utils/encoder';\nimport { hash } from '../../utils/crypto';\nimport { Field } from './field-types';\nimport { txSchema } from './schema';\nimport { TxUnpacked, TxParams, TxParamsAsync } from './schema.generated';\nimport { Tag } from './constants';\nimport { buildContractId } from './helpers';\nimport { getSchema as getSchemaCommon, packRecord, unpackRecord } from './common';\nimport { ArgumentError } from '../../utils/errors';\n\n/**\n * JavaScript-based Transaction builder\n */\n\nexport function getSchema(tag: Tag, version?: number): Array<[string, Field]> {\n return getSchemaCommon(txSchema, Tag, tag, version);\n}\n\ntype TxEncoding = Encoding.Transaction | Encoding.Poi | Encoding.StateTrees\n| Encoding.CallStateTree;\n\n/**\n * Build transaction\n * @category transaction builder\n * @param params - Transaction params\n */\nexport function buildTx(params: TxParams): Encoded.Transaction;\n/**\n * Build node entry with a custom encoding\n * @param params - Entry params\n * @param options - Options\n * @param options.prefix - Output encoding\n */\nexport function buildTx<E extends TxEncoding>(\n params: TxParams,\n { prefix }: { prefix: E },\n): Encoded.Generic<E>;\nexport function buildTx(\n params: TxParams,\n { prefix }: { prefix?: TxEncoding } = {},\n): Encoded.Generic<TxEncoding> {\n return packRecord(txSchema, Tag, params, {\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n unpackTx,\n buildTx,\n rebuildTx: (overrideParams: any) => buildTx(\n { ...params, ...overrideParams },\n ),\n }, prefix ?? Encoding.Transaction);\n}\n\nexport type BuildTxOptions <TxType extends Tag, OmitFields extends string> =\n Omit<TxParamsAsync & { tag: TxType }, 'tag' | OmitFields>;\n\n// TODO: require onNode because it is the only reason this builder is async [breaking change]\n/**\n * Build transaction async (may request node for additional data)\n * @category transaction builder\n * @param params - Transaction params\n * @returns tx_-encoded transaction\n */\nexport async function buildTxAsync(params: TxParamsAsync): Promise<Encoded.Transaction> {\n await Promise.all(\n getSchema(params.tag, params.version)\n .map(async ([key, field]) => {\n if (field.prepare == null) return;\n // @ts-expect-error the type of `params[key]` can't be determined accurately\n params[key] = await field.prepare(params[key], params, params);\n }),\n );\n\n // @ts-expect-error after preparation properties should be compatible with sync tx builder\n return buildTx(params);\n}\n\n/**\n * Unpack transaction encoded as string\n * @category transaction builder\n * @param encodedTx - Encoded transaction\n * @param txType - Expected transaction type\n * @returns Transaction params\n */\nexport function unpackTx<TxType extends Tag>(\n encodedTx: Encoded.Generic<TxEncoding>,\n txType?: TxType,\n): TxUnpacked & { tag: TxType } {\n return unpackRecord(txSchema, Tag, encodedTx, txType, {\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n unpackTx,\n }) as any;\n}\n\n/**\n * Build a transaction hash\n * @category transaction builder\n * @param rawTx - base64 or rlp encoded transaction\n * @returns Transaction hash\n */\nexport function buildTxHash(rawTx: Encoded.Transaction | Uint8Array): Encoded.TxHash {\n const data = typeof rawTx === 'string' && rawTx.startsWith('tx_')\n ? decode(rawTx)\n : rawTx;\n return encode(hash(data), Encoding.TxHash);\n}\n\n/**\n * Build a contract public key by contractCreateTx, gaAttach or signedTx\n * @category contract\n * @param contractTx - Transaction\n * @returns Contract public key\n */\nexport function buildContractIdByContractTx(\n contractTx: Encoded.Transaction,\n): Encoded.ContractAddress {\n let params = unpackTx(contractTx);\n if (Tag.SignedTx === params.tag) params = params.encodedTx;\n if (Tag.ContractCreateTx !== params.tag && Tag.GaAttachTx !== params.tag) {\n throw new ArgumentError('contractTx', 'a contractCreateTx or gaAttach', params.tag);\n }\n return buildContractId(params.ownerId, params.nonce);\n}\n","import { RestError, PipelineResponse } from '@azure/core-rest-pipeline';\nimport { AdditionalPolicyConfig, FullOperationResponse, OperationOptions } from '@azure/core-client';\nimport { pause } from './other';\nimport semverSatisfies from './semver-satisfies';\nimport { UnsupportedVersionError } from './errors';\n\nexport const genRequestQueuesPolicy = (): AdditionalPolicyConfig => {\n const requestQueues = new Map<string, Promise<unknown>>();\n\n return {\n policy: {\n name: 'request-queues',\n async sendRequest(request, next) {\n const key = request.headers.get('__queue');\n request.headers.delete('__queue');\n const getResponse = async (): Promise<PipelineResponse> => next(request);\n if (key == null) return getResponse();\n const req = (requestQueues.get(key) ?? Promise.resolve()).then(getResponse);\n requestQueues.set(key, req.catch(() => {}));\n return req;\n },\n },\n position: 'perCall',\n };\n};\n\nexport const genCombineGetRequestsPolicy = (): AdditionalPolicyConfig => {\n const pendingGetRequests = new Map<string, Promise<PipelineResponse>>();\n\n return {\n policy: {\n name: 'combine-get-requests',\n async sendRequest(request, next) {\n if (request.method !== 'GET') return next(request);\n const key = JSON.stringify([request.url, request.body]);\n const response = pendingGetRequests.get(key) ?? next(request);\n pendingGetRequests.set(key, response);\n try {\n return await response;\n } finally {\n pendingGetRequests.delete(key);\n }\n },\n },\n position: 'perCall',\n };\n};\n\nexport const genAggressiveCacheGetResponsesPolicy = (): AdditionalPolicyConfig => {\n const getRequests = new Map<string, Promise<PipelineResponse>>();\n\n return {\n policy: {\n name: 'aggressive-cache-get-responses',\n async sendRequest(request, next) {\n if (request.method !== 'GET') return next(request);\n const key = JSON.stringify([request.url, request.body]);\n const response = getRequests.get(key) ?? next(request);\n getRequests.set(key, response);\n return response;\n },\n },\n position: 'perCall',\n };\n};\n\nexport const genErrorFormatterPolicy = (\n getMessage: (b: any) => string,\n): AdditionalPolicyConfig => ({\n policy: {\n name: 'error-formatter',\n async sendRequest(request, next) {\n try {\n return await next(request);\n } catch (error) {\n if (!(error instanceof RestError) || error.request == null) throw error;\n const prefix = `${new URL(error.request.url).pathname.slice(1)} error`;\n\n if (error.response?.bodyAsText == null) {\n if (error.message === '') error.message = `${prefix}: ${error.code}`;\n throw error;\n }\n\n const body = (error.response as FullOperationResponse).parsedBody;\n error.message = prefix;\n const message = body == null ? ` ${error.response.status} status code` : getMessage(body);\n if (message !== '') error.message += `:${message}`;\n throw error;\n }\n },\n },\n position: 'perCall',\n});\n\nexport const genVersionCheckPolicy = (\n name: string,\n versionCb: (options: OperationOptions) => Promise<string>,\n geVersion: string,\n ltVersion: string,\n): AdditionalPolicyConfig => ({\n policy: {\n name: 'version-check',\n async sendRequest(request, next) {\n if (request.headers.has('__version-check')) {\n request.headers.delete('__version-check');\n return next(request);\n }\n const options = { requestOptions: { customHeaders: { '__version-check': 'true' } } };\n const args = [await versionCb(options), geVersion, ltVersion] as const;\n if (!semverSatisfies(...args)) throw new UnsupportedVersionError(name, ...args);\n return next(request);\n },\n },\n position: 'perCall',\n});\n\nexport const genRetryOnFailurePolicy = (\n retryCount: number,\n retryOverallDelay: number,\n): AdditionalPolicyConfig => ({\n policy: {\n name: 'retry-on-failure',\n async sendRequest(request, next) {\n const retryCode = request.headers.get('__retry-code') ?? NaN;\n request.headers.delete('__retry-code');\n const statusesToNotRetry = [200, 400, 403, 410, 500].filter((c) => c !== +retryCode);\n\n const intervals = new Array(retryCount).fill(0)\n .map((_, idx) => ((idx + 1) / retryCount) ** 2);\n const intervalSum = intervals.reduce((a, b) => a + b, 0);\n const intervalsInMs = intervals.map((e) => Math.floor((e / intervalSum) * retryOverallDelay));\n\n let error = new RestError('Not expected to be thrown');\n for (let attempt = 0; attempt <= retryCount; attempt += 1) {\n if (attempt !== 0) {\n await pause(intervalsInMs[attempt - 1]);\n const urlParsed = new URL(request.url);\n urlParsed.searchParams.set('__sdk-retry', attempt.toString());\n request.url = urlParsed.toString();\n }\n try {\n return await next(request);\n } catch (e) {\n if (!(e instanceof RestError)) throw e;\n if (statusesToNotRetry.includes(e.response?.status ?? 0)) throw e;\n error = e;\n }\n }\n throw error;\n },\n },\n position: 'perCall',\n});\n","import * as coreClient from \"@azure/core-client\";\n\nexport const Header: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Header\",\n modelProperties: {\n hash: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n prevHash: {\n serializedName: \"prev_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n prevKeyHash: {\n serializedName: \"prev_key_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n miner: {\n serializedName: \"miner\",\n type: {\n name: \"String\",\n },\n },\n beneficiary: {\n serializedName: \"beneficiary\",\n type: {\n name: \"String\",\n },\n },\n target: {\n serializedName: \"target\",\n type: {\n name: \"String\",\n },\n },\n pow: {\n constraints: {\n MinItems: 42,\n MaxItems: 42,\n },\n serializedName: \"pow\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n time: {\n serializedName: \"time\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n version: {\n serializedName: \"version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n info: {\n serializedName: \"info\",\n type: {\n name: \"String\",\n },\n },\n pofHash: {\n serializedName: \"pof_hash\",\n type: {\n name: \"String\",\n },\n },\n txsHash: {\n serializedName: \"txs_hash\",\n type: {\n name: \"String\",\n },\n },\n signature: {\n serializedName: \"signature\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ErrorModel: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ErrorModel\",\n modelProperties: {\n reason: {\n serializedName: \"reason\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n errorCode: {\n serializedName: \"error_code\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const KeyBlock: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"KeyBlock\",\n modelProperties: {\n hash: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n prevHash: {\n serializedName: \"prev_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n prevKeyHash: {\n serializedName: \"prev_key_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n miner: {\n serializedName: \"miner\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n beneficiary: {\n serializedName: \"beneficiary\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n target: {\n serializedName: \"target\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n pow: {\n constraints: {\n MinItems: 42,\n MaxItems: 42,\n },\n serializedName: \"pow\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n time: {\n serializedName: \"time\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n version: {\n serializedName: \"version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n info: {\n serializedName: \"info\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const HashResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"HashResponse\",\n modelProperties: {\n hash: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const HeightResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"HeightResponse\",\n modelProperties: {\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const MicroBlockHeader: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"MicroBlockHeader\",\n modelProperties: {\n hash: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n pofHash: {\n serializedName: \"pof_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n prevHash: {\n serializedName: \"prev_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n prevKeyHash: {\n serializedName: \"prev_key_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n txsHash: {\n serializedName: \"txs_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n signature: {\n serializedName: \"signature\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n time: {\n serializedName: \"time\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n version: {\n serializedName: \"version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const SignedTxs: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SignedTxs\",\n modelProperties: {\n transactions: {\n serializedName: \"transactions\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"SignedTx\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const SignedTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SignedTx\",\n modelProperties: {\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Composite\",\n className: \"Tx\",\n },\n },\n blockHeight: {\n serializedName: \"block_height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n hash: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n encodedTx: {\n serializedName: \"encoded_tx\",\n type: {\n name: \"String\",\n },\n },\n signatures: {\n serializedName: \"signatures\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const Tx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Tx\",\n modelProperties: {\n recipientId: {\n serializedName: \"recipient_id\",\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n type: {\n name: \"String\",\n },\n },\n initiatorId: {\n serializedName: \"initiator_id\",\n type: {\n name: \"String\",\n },\n },\n initiatorAmount: {\n serializedName: \"initiator_amount\",\n type: {\n name: \"String\",\n },\n },\n responderId: {\n serializedName: \"responder_id\",\n type: {\n name: \"String\",\n },\n },\n responderAmount: {\n serializedName: \"responder_amount\",\n type: {\n name: \"String\",\n },\n },\n channelReserve: {\n serializedName: \"channel_reserve\",\n type: {\n name: \"String\",\n },\n },\n lockPeriod: {\n serializedName: \"lock_period\",\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n type: {\n name: \"String\",\n },\n },\n delegateIds: {\n serializedName: \"delegate_ids\",\n type: {\n name: \"Composite\",\n className: \"Delegates\",\n },\n },\n channelId: {\n serializedName: \"channel_id\",\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n type: {\n name: \"String\",\n },\n },\n round: {\n serializedName: \"round\",\n type: {\n name: \"String\",\n },\n },\n toId: {\n serializedName: \"to_id\",\n type: {\n name: \"String\",\n },\n },\n update: {\n serializedName: \"update\",\n type: {\n name: \"Composite\",\n className: \"OffChainUpdate\",\n },\n },\n offchainTrees: {\n serializedName: \"offchain_trees\",\n type: {\n name: \"String\",\n },\n },\n initiatorAmountFinal: {\n serializedName: \"initiator_amount_final\",\n type: {\n name: \"String\",\n },\n },\n responderAmountFinal: {\n serializedName: \"responder_amount_final\",\n type: {\n name: \"String\",\n },\n },\n poi: {\n serializedName: \"poi\",\n type: {\n name: \"String\",\n },\n },\n initiatorDelegateIds: {\n serializedName: \"initiator_delegate_ids\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n responderDelegateIds: {\n serializedName: \"responder_delegate_ids\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n queryFormat: {\n serializedName: \"query_format\",\n type: {\n name: \"String\",\n },\n },\n responseFormat: {\n serializedName: \"response_format\",\n type: {\n name: \"String\",\n },\n },\n queryFee: {\n serializedName: \"query_fee\",\n type: {\n name: \"String\",\n },\n },\n oracleTtl: {\n serializedName: \"oracle_ttl\",\n type: {\n name: \"Composite\",\n className: \"RelativeTTL\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n type: {\n name: \"String\",\n },\n },\n oracleId: {\n serializedName: \"oracle_id\",\n type: {\n name: \"String\",\n },\n },\n query: {\n serializedName: \"query\",\n type: {\n name: \"String\",\n },\n },\n queryTtl: {\n serializedName: \"query_ttl\",\n type: {\n name: \"Composite\",\n className: \"Ttl\",\n },\n },\n responseTtl: {\n serializedName: \"response_ttl\",\n type: {\n name: \"Composite\",\n className: \"RelativeTTL\",\n },\n },\n queryId: {\n serializedName: \"query_id\",\n type: {\n name: \"String\",\n },\n },\n response: {\n serializedName: \"response\",\n type: {\n name: \"String\",\n },\n },\n commitmentId: {\n serializedName: \"commitment_id\",\n type: {\n name: \"String\",\n },\n },\n name: {\n serializedName: \"name\",\n type: {\n name: \"String\",\n },\n },\n nameSalt: {\n serializedName: \"name_salt\",\n type: {\n name: \"String\",\n },\n },\n nameFee: {\n serializedName: \"name_fee\",\n type: {\n name: \"String\",\n },\n },\n nameId: {\n serializedName: \"name_id\",\n type: {\n name: \"String\",\n },\n },\n nameTtl: {\n serializedName: \"name_ttl\",\n type: {\n name: \"String\",\n },\n },\n pointers: {\n serializedName: \"pointers\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"NamePointer\",\n },\n },\n },\n },\n clientTtl: {\n serializedName: \"client_ttl\",\n type: {\n name: \"String\",\n },\n },\n ownerId: {\n serializedName: \"owner_id\",\n type: {\n name: \"String\",\n },\n },\n code: {\n serializedName: \"code\",\n type: {\n name: \"String\",\n },\n },\n vmVersion: {\n serializedName: \"vm_version\",\n type: {\n name: \"String\",\n },\n },\n deposit: {\n serializedName: \"deposit\",\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n type: {\n name: \"String\",\n },\n },\n callData: {\n serializedName: \"call_data\",\n type: {\n name: \"String\",\n },\n },\n callerId: {\n serializedName: \"caller_id\",\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n authFun: {\n constraints: {\n Pattern: new RegExp(\"^(0x|0X)?[a-fA-F0-9]+$\"),\n },\n serializedName: \"auth_fun\",\n type: {\n name: \"String\",\n },\n },\n gaId: {\n serializedName: \"ga_id\",\n type: {\n name: \"String\",\n },\n },\n authData: {\n serializedName: \"auth_data\",\n type: {\n name: \"String\",\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Composite\",\n className: \"SignedTx\",\n },\n },\n payerId: {\n serializedName: \"payer_id\",\n type: {\n name: \"String\",\n },\n },\n version: {\n serializedName: \"version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n type: {\n serializedName: \"type\",\n required: true,\n type: {\n name: \"Enum\",\n allowedValues: [\n \"SpendTx\",\n \"ChannelCreateTx\",\n \"ChannelDepositTx\",\n \"ChannelWithdrawTx\",\n \"ChannelForceProgressTx\",\n \"ChannelCloseMutualTx\",\n \"ChannelCloseSoloTx\",\n \"ChannelSlashTx\",\n \"ChannelSettleTx\",\n \"ChannelSnapshotSoloTx\",\n \"ChannelSetDelegatesTx\",\n \"OracleRegisterTx\",\n \"OracleExtendTx\",\n \"OracleQueryTx\",\n \"OracleRespondTx\",\n \"NamePreclaimTx\",\n \"NameClaimTx\",\n \"NameUpdateTx\",\n \"NameTransferTx\",\n \"NameRevokeTx\",\n \"ContractCreateTx\",\n \"ContractCallTx\",\n \"GAAttachTx\",\n \"GAMetaTx\",\n \"PayingForTx\",\n ],\n },\n },\n },\n },\n};\n\nexport const Delegates: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Delegates\",\n modelProperties: {\n initiator: {\n serializedName: \"initiator\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n responder: {\n serializedName: \"responder\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const OffChainUpdate: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OffChainUpdate\",\n uberParent: \"OffChainUpdate\",\n polymorphicDiscriminator: {\n serializedName: \"op\",\n clientName: \"op\",\n },\n modelProperties: {\n op: {\n serializedName: \"op\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const RelativeTTL: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"RelativeTTL\",\n modelProperties: {\n type: {\n defaultValue: \"delta\",\n isConstant: true,\n serializedName: \"type\",\n type: {\n name: \"String\",\n },\n },\n value: {\n serializedName: \"value\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Ttl: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Ttl\",\n modelProperties: {\n type: {\n serializedName: \"type\",\n required: true,\n type: {\n name: \"Enum\",\n allowedValues: [\"delta\", \"block\"],\n },\n },\n value: {\n serializedName: \"value\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NamePointer: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NamePointer\",\n modelProperties: {\n key: {\n serializedName: \"key\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const CountResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CountResponse\",\n modelProperties: {\n count: {\n serializedName: \"count\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Generation: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Generation\",\n modelProperties: {\n keyBlock: {\n serializedName: \"key_block\",\n type: {\n name: \"Composite\",\n className: \"KeyBlock\",\n },\n },\n microBlocks: {\n serializedName: \"micro_blocks\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const Account: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Account\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n balance: {\n serializedName: \"balance\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n payable: {\n serializedName: \"payable\",\n type: {\n name: \"Boolean\",\n },\n },\n kind: {\n serializedName: \"kind\",\n type: {\n name: \"Enum\",\n allowedValues: [\"basic\", \"generalized\"],\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n authFun: {\n serializedName: \"auth_fun\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NextNonceResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NextNonceResponse\",\n modelProperties: {\n nextNonce: {\n serializedName: \"next_nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const DryRunInput: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunInput\",\n modelProperties: {\n top: {\n serializedName: \"top\",\n type: {\n name: \"String\",\n },\n },\n accounts: {\n serializedName: \"accounts\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"DryRunAccount\",\n },\n },\n },\n },\n txs: {\n serializedName: \"txs\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"DryRunInputItem\",\n },\n },\n },\n },\n txEvents: {\n defaultValue: false,\n serializedName: \"tx_events\",\n type: {\n name: \"Boolean\",\n },\n },\n },\n },\n};\n\nexport const DryRunAccount: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunAccount\",\n modelProperties: {\n pubKey: {\n serializedName: \"pub_key\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const DryRunInputItem: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunInputItem\",\n modelProperties: {\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"String\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n type: {\n name: \"String\",\n },\n },\n callReq: {\n serializedName: \"call_req\",\n type: {\n name: \"Composite\",\n className: \"DryRunCallReq\",\n },\n },\n },\n },\n};\n\nexport const DryRunCallReq: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunCallReq\",\n modelProperties: {\n calldata: {\n serializedName: \"calldata\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contract: {\n serializedName: \"contract\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n type: {\n name: \"String\",\n },\n },\n caller: {\n serializedName: \"caller\",\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n type: {\n name: \"String\",\n },\n },\n context: {\n serializedName: \"context\",\n type: {\n name: \"Composite\",\n className: \"DryRunCallContext\",\n },\n },\n },\n },\n};\n\nexport const DryRunCallContext: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunCallContext\",\n modelProperties: {\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"String\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n type: {\n name: \"String\",\n },\n },\n stateful: {\n serializedName: \"stateful\",\n type: {\n name: \"Boolean\",\n },\n },\n },\n },\n};\n\nexport const DryRunResults: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunResults\",\n modelProperties: {\n results: {\n serializedName: \"results\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"DryRunResult\",\n },\n },\n },\n },\n txEvents: {\n serializedName: \"tx_events\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n },\n },\n};\n\nexport const DryRunResult: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DryRunResult\",\n modelProperties: {\n type: {\n serializedName: \"type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n result: {\n serializedName: \"result\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n reason: {\n serializedName: \"reason\",\n type: {\n name: \"String\",\n },\n },\n callObj: {\n serializedName: \"call_obj\",\n type: {\n name: \"Composite\",\n className: \"ContractCallObject\",\n },\n },\n },\n },\n};\n\nexport const ContractCallObject: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ContractCallObject\",\n modelProperties: {\n callerId: {\n serializedName: \"caller_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callerNonce: {\n serializedName: \"caller_nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasUsed: {\n serializedName: \"gas_used\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n log: {\n serializedName: \"log\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Event\",\n },\n },\n },\n },\n returnValue: {\n serializedName: \"return_value\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n returnType: {\n serializedName: \"return_type\",\n required: true,\n type: {\n name: \"Enum\",\n allowedValues: [\"ok\", \"error\", \"revert\"],\n },\n },\n },\n },\n};\n\nexport const Event: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Event\",\n modelProperties: {\n address: {\n serializedName: \"address\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n topics: {\n serializedName: \"topics\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n data: {\n serializedName: \"data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const TxInfoObject: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"TxInfoObject\",\n modelProperties: {\n callInfo: {\n serializedName: \"call_info\",\n type: {\n name: \"Composite\",\n className: \"ContractCallObject\",\n },\n },\n gaInfo: {\n serializedName: \"ga_info\",\n type: {\n name: \"Composite\",\n className: \"GAObject\",\n },\n },\n txInfo: {\n serializedName: \"tx_info\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const GAObject: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"GAObject\",\n modelProperties: {\n callerId: {\n serializedName: \"caller_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasUsed: {\n serializedName: \"gas_used\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n returnValue: {\n serializedName: \"return_value\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n returnType: {\n serializedName: \"return_type\",\n required: true,\n type: {\n name: \"Enum\",\n allowedValues: [\"ok\", \"error\"],\n },\n },\n innerObject: {\n serializedName: \"inner_object\",\n type: {\n name: \"Composite\",\n className: \"TxInfoObject\",\n },\n },\n },\n },\n};\n\nexport const EncodedTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"EncodedTx\",\n modelProperties: {\n tx: {\n serializedName: \"tx\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PostTxResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PostTxResponse\",\n modelProperties: {\n txHash: {\n serializedName: \"tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ContractObject: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ContractObject\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ownerId: {\n serializedName: \"owner_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n vmVersion: {\n serializedName: \"vm_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n active: {\n serializedName: \"active\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n referrerIds: {\n serializedName: \"referrer_ids\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n deposit: {\n serializedName: \"deposit\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ByteCode: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ByteCode\",\n modelProperties: {\n bytecode: {\n serializedName: \"bytecode\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PoI: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PoI\",\n modelProperties: {\n poi: {\n serializedName: \"poi\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const RegisteredOracle: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"RegisteredOracle\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryFormat: {\n serializedName: \"query_format\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responseFormat: {\n serializedName: \"response_format\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryFee: {\n serializedName: \"query_fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OracleQueries: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleQueries\",\n modelProperties: {\n oracleQueries: {\n serializedName: \"oracle_queries\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"OracleQuery\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const OracleQuery: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleQuery\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n senderNonce: {\n serializedName: \"sender_nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n oracleId: {\n serializedName: \"oracle_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n query: {\n serializedName: \"query\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n response: {\n serializedName: \"response\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responseTtl: {\n serializedName: \"response_ttl\",\n type: {\n name: \"Composite\",\n className: \"Ttl\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const AuctionEntry: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"AuctionEntry\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n startedAt: {\n serializedName: \"started_at\",\n type: {\n name: \"String\",\n },\n },\n endsAt: {\n serializedName: \"ends_at\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n highestBidder: {\n serializedName: \"highest_bidder\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n highestBid: {\n serializedName: \"highest_bid\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameEntry: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameEntry\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n owner: {\n serializedName: \"owner\",\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n pointers: {\n serializedName: \"pointers\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"NamePointer\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const Channel: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Channel\",\n modelProperties: {\n id: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n initiatorId: {\n serializedName: \"initiator_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responderId: {\n serializedName: \"responder_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n channelAmount: {\n serializedName: \"channel_amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n initiatorAmount: {\n serializedName: \"initiator_amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responderAmount: {\n serializedName: \"responder_amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n channelReserve: {\n serializedName: \"channel_reserve\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n delegateIds: {\n serializedName: \"delegate_ids\",\n type: {\n name: \"Composite\",\n className: \"Delegates\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n round: {\n serializedName: \"round\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n soloRound: {\n serializedName: \"solo_round\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n lockPeriod: {\n serializedName: \"lock_period\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n lockedUntil: {\n serializedName: \"locked_until\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PeerPubKey: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PeerPubKey\",\n modelProperties: {\n pubkey: {\n serializedName: \"pubkey\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const SyncStatus: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SyncStatus\",\n modelProperties: {\n progress: {\n serializedName: \"progress\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n target: {\n serializedName: \"target\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n speed: {\n serializedName: \"speed\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n estimate: {\n serializedName: \"estimate\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Status: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Status\",\n modelProperties: {\n genesisKeyBlockHash: {\n serializedName: \"genesis_key_block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n solutions: {\n serializedName: \"solutions\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n difficulty: {\n serializedName: \"difficulty\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n hashrate: {\n serializedName: \"hashrate\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n syncing: {\n serializedName: \"syncing\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n syncProgress: {\n constraints: {\n InclusiveMaximum: 100,\n InclusiveMinimum: 0,\n },\n serializedName: \"sync_progress\",\n type: {\n name: \"Number\",\n },\n },\n uptime: {\n serializedName: \"uptime\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n listening: {\n serializedName: \"listening\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n protocols: {\n serializedName: \"protocols\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Protocol\",\n },\n },\n },\n },\n nodeVersion: {\n serializedName: \"node_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nodeRevision: {\n serializedName: \"node_revision\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n peerCount: {\n serializedName: \"peer_count\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n peerConnections: {\n serializedName: \"peer_connections\",\n type: {\n name: \"Composite\",\n className: \"PeerConnections\",\n },\n },\n pendingTransactionsCount: {\n serializedName: \"pending_transactions_count\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n networkId: {\n serializedName: \"network_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n peerPubkey: {\n serializedName: \"peer_pubkey\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n topKeyBlockHash: {\n serializedName: \"top_key_block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n topBlockHeight: {\n serializedName: \"top_block_height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Protocol: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Protocol\",\n modelProperties: {\n version: {\n serializedName: \"version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n effectiveAtHeight: {\n serializedName: \"effective_at_height\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PeerConnections: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PeerConnections\",\n modelProperties: {\n inbound: {\n serializedName: \"inbound\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n outbound: {\n serializedName: \"outbound\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Currency: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Currency\",\n modelProperties: {\n name: {\n serializedName: \"name\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n symbol: {\n serializedName: \"symbol\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n subunit: {\n serializedName: \"subunit\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n subunitsPerUnit: {\n serializedName: \"subunits_per_unit\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fiatConverstionUrl: {\n serializedName: \"fiat_converstion_url\",\n type: {\n name: \"String\",\n },\n },\n logo: {\n serializedName: \"logo\",\n type: {\n name: \"Composite\",\n className: \"Image\",\n },\n },\n primaryColour: {\n serializedName: \"primary_colour\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n secondaryColour: {\n serializedName: \"secondary_colour\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n networkName: {\n serializedName: \"network_name\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Image: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Image\",\n modelProperties: {\n type: {\n serializedName: \"type\",\n type: {\n name: \"String\",\n },\n },\n data: {\n serializedName: \"data\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const GasPricesItem: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"GasPricesItem\",\n modelProperties: {\n minGasPrice: {\n serializedName: \"min_gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n utilization: {\n serializedName: \"utilization\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n minutes: {\n serializedName: \"minutes\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const SpendTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SpendTx\",\n modelProperties: {\n recipientId: {\n serializedName: \"recipient_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OracleRegisterTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleRegisterTx\",\n modelProperties: {\n queryFormat: {\n serializedName: \"query_format\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responseFormat: {\n serializedName: \"response_format\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryFee: {\n serializedName: \"query_fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n oracleTtl: {\n serializedName: \"oracle_ttl\",\n type: {\n name: \"Composite\",\n className: \"Ttl\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OracleExtendTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleExtendTx\",\n modelProperties: {\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n oracleTtl: {\n serializedName: \"oracle_ttl\",\n type: {\n name: \"Composite\",\n className: \"RelativeTTL\",\n },\n },\n oracleId: {\n serializedName: \"oracle_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OracleQueryTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleQueryTx\",\n modelProperties: {\n oracleId: {\n serializedName: \"oracle_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n query: {\n serializedName: \"query\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryFee: {\n serializedName: \"query_fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryTtl: {\n serializedName: \"query_ttl\",\n type: {\n name: \"Composite\",\n className: \"Ttl\",\n },\n },\n responseTtl: {\n serializedName: \"response_ttl\",\n type: {\n name: \"Composite\",\n className: \"RelativeTTL\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OracleRespondTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleRespondTx\",\n modelProperties: {\n queryId: {\n serializedName: \"query_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n response: {\n serializedName: \"response\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responseTtl: {\n serializedName: \"response_ttl\",\n type: {\n name: \"Composite\",\n className: \"RelativeTTL\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n oracleId: {\n serializedName: \"oracle_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NamePreclaimTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NamePreclaimTx\",\n modelProperties: {\n commitmentId: {\n serializedName: \"commitment_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameClaimTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameClaimTx\",\n modelProperties: {\n name: {\n serializedName: \"name\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nameSalt: {\n serializedName: \"name_salt\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nameFee: {\n serializedName: \"name_fee\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameUpdateTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameUpdateTx\",\n modelProperties: {\n nameId: {\n serializedName: \"name_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nameTtl: {\n serializedName: \"name_ttl\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n pointers: {\n serializedName: \"pointers\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"NamePointer\",\n },\n },\n },\n },\n clientTtl: {\n serializedName: \"client_ttl\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameTransferTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameTransferTx\",\n modelProperties: {\n nameId: {\n serializedName: \"name_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n recipientId: {\n serializedName: \"recipient_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameRevokeTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameRevokeTx\",\n modelProperties: {\n nameId: {\n serializedName: \"name_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const CommitmentId: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CommitmentId\",\n modelProperties: {\n commitmentId: {\n serializedName: \"commitment_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameHash: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameHash\",\n modelProperties: {\n nameId: {\n serializedName: \"name_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelCreateTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelCreateTx\",\n modelProperties: {\n initiatorId: {\n serializedName: \"initiator_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n initiatorAmount: {\n serializedName: \"initiator_amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responderId: {\n serializedName: \"responder_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responderAmount: {\n serializedName: \"responder_amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n channelReserve: {\n serializedName: \"channel_reserve\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n lockPeriod: {\n serializedName: \"lock_period\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n delegateIds: {\n serializedName: \"delegate_ids\",\n type: {\n name: \"Composite\",\n className: \"Delegates\",\n },\n },\n },\n },\n};\n\nexport const ChannelDepositTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelDepositTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n round: {\n serializedName: \"round\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelWithdrawTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelWithdrawTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n toId: {\n serializedName: \"to_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n round: {\n serializedName: \"round\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelForceProgressTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelForceProgressTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n round: {\n serializedName: \"round\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n update: {\n serializedName: \"update\",\n type: {\n name: \"Composite\",\n className: \"OffChainUpdate\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n offchainTrees: {\n serializedName: \"offchain_trees\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelCloseMutualTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelCloseMutualTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n initiatorAmountFinal: {\n serializedName: \"initiator_amount_final\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responderAmountFinal: {\n serializedName: \"responder_amount_final\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelCloseSoloTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelCloseSoloTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n poi: {\n serializedName: \"poi\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelSlashTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelSlashTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n poi: {\n serializedName: \"poi\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelSettleTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelSettleTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n initiatorAmountFinal: {\n serializedName: \"initiator_amount_final\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responderAmountFinal: {\n serializedName: \"responder_amount_final\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelSnapshotSoloTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelSnapshotSoloTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ChannelSetDelegatesTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ChannelSetDelegatesTx\",\n modelProperties: {\n channelId: {\n serializedName: \"channel_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fromId: {\n serializedName: \"from_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n initiatorDelegateIds: {\n serializedName: \"initiator_delegate_ids\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n responderDelegateIds: {\n serializedName: \"responder_delegate_ids\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n round: {\n serializedName: \"round\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PubKey: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PubKey\",\n modelProperties: {\n pubKey: {\n serializedName: \"pub_key\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PeerDetails: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PeerDetails\",\n modelProperties: {\n host: {\n serializedName: \"host\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n port: {\n serializedName: \"port\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n firstSeen: {\n serializedName: \"first_seen\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n lastSeen: {\n serializedName: \"last_seen\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n genesisHash: {\n serializedName: \"genesis_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n topHash: {\n serializedName: \"top_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n topDifficulty: {\n serializedName: \"top_difficulty\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n networkId: {\n serializedName: \"network_id\",\n type: {\n name: \"String\",\n },\n },\n nodeVersion: {\n serializedName: \"node_version\",\n type: {\n name: \"String\",\n },\n },\n nodeRevision: {\n serializedName: \"node_revision\",\n type: {\n name: \"String\",\n },\n },\n nodeVendor: {\n serializedName: \"node_vendor\",\n type: {\n name: \"String\",\n },\n },\n nodeOs: {\n serializedName: \"node_os\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Peers: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Peers\",\n modelProperties: {\n peers: {\n serializedName: \"peers\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n blocked: {\n serializedName: \"blocked\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const PeerCount: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PeerCount\",\n modelProperties: {\n connected: {\n serializedName: \"connected\",\n type: {\n name: \"Composite\",\n className: \"PeerCountConnected\",\n },\n },\n available: {\n serializedName: \"available\",\n type: {\n name: \"Composite\",\n className: \"PeerCountAvailable\",\n },\n },\n blocked: {\n serializedName: \"blocked\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PeerCountConnected: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PeerCountConnected\",\n modelProperties: {\n inbound: {\n serializedName: \"inbound\",\n type: {\n name: \"String\",\n },\n },\n outbound: {\n serializedName: \"outbound\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PeerCountAvailable: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PeerCountAvailable\",\n modelProperties: {\n verified: {\n serializedName: \"verified\",\n type: {\n name: \"String\",\n },\n },\n unverified: {\n serializedName: \"unverified\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ContractCreateTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ContractCreateTx\",\n modelProperties: {\n ownerId: {\n serializedName: \"owner_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n code: {\n serializedName: \"code\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n vmVersion: {\n serializedName: \"vm_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n deposit: {\n serializedName: \"deposit\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n callData: {\n serializedName: \"call_data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ContractCallTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ContractCallTx\",\n modelProperties: {\n callerId: {\n serializedName: \"caller_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callData: {\n serializedName: \"call_data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const UnsignedTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"UnsignedTx\",\n modelProperties: {\n tx: {\n serializedName: \"tx\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const TokenSupply: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"TokenSupply\",\n modelProperties: {\n accounts: {\n serializedName: \"accounts\",\n type: {\n name: \"String\",\n },\n },\n contracts: {\n serializedName: \"contracts\",\n type: {\n name: \"String\",\n },\n },\n contractOracles: {\n serializedName: \"contract_oracles\",\n type: {\n name: \"String\",\n },\n },\n locked: {\n serializedName: \"locked\",\n type: {\n name: \"String\",\n },\n },\n oracles: {\n serializedName: \"oracles\",\n type: {\n name: \"String\",\n },\n },\n oracleQueries: {\n serializedName: \"oracle_queries\",\n type: {\n name: \"String\",\n },\n },\n pendingRewards: {\n serializedName: \"pending_rewards\",\n type: {\n name: \"String\",\n },\n },\n total: {\n serializedName: \"total\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const GAAttachTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"GAAttachTx\",\n modelProperties: {\n ownerId: {\n serializedName: \"owner_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n code: {\n serializedName: \"code\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n vmVersion: {\n serializedName: \"vm_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n callData: {\n serializedName: \"call_data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n authFun: {\n constraints: {\n Pattern: new RegExp(\"^(0x|0X)?[a-fA-F0-9]+$\"),\n },\n serializedName: \"auth_fun\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const GAMetaTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"GAMetaTx\",\n modelProperties: {\n gaId: {\n serializedName: \"ga_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n type: {\n name: \"String\",\n },\n },\n authData: {\n serializedName: \"auth_data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Composite\",\n className: \"SignedTx\",\n },\n },\n },\n },\n};\n\nexport const PayingForTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PayingForTx\",\n modelProperties: {\n payerId: {\n serializedName: \"payer_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Composite\",\n className: \"SignedTx\",\n },\n },\n },\n },\n};\n\nexport const CheckTxInPoolResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CheckTxInPoolResponse\",\n modelProperties: {\n status: {\n serializedName: \"status\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OffChainTransfer: coreClient.CompositeMapper = {\n serializedName: \"OffChainTransfer\",\n type: {\n name: \"Composite\",\n className: \"OffChainTransfer\",\n uberParent: \"OffChainUpdate\",\n polymorphicDiscriminator: OffChainUpdate.type.polymorphicDiscriminator,\n modelProperties: {\n ...OffChainUpdate.type.modelProperties,\n from: {\n serializedName: \"from\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n to: {\n serializedName: \"to\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OffChainWithdrawal: coreClient.CompositeMapper = {\n serializedName: \"OffChainWithdrawal\",\n type: {\n name: \"Composite\",\n className: \"OffChainWithdrawal\",\n uberParent: \"OffChainUpdate\",\n polymorphicDiscriminator: OffChainUpdate.type.polymorphicDiscriminator,\n modelProperties: {\n ...OffChainUpdate.type.modelProperties,\n to: {\n serializedName: \"to\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OffChainDeposit: coreClient.CompositeMapper = {\n serializedName: \"OffChainDeposit\",\n type: {\n name: \"Composite\",\n className: \"OffChainDeposit\",\n uberParent: \"OffChainUpdate\",\n polymorphicDiscriminator: OffChainUpdate.type.polymorphicDiscriminator,\n modelProperties: {\n ...OffChainUpdate.type.modelProperties,\n from: {\n serializedName: \"from\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OffChainNewContract: coreClient.CompositeMapper = {\n serializedName: \"OffChainNewContract\",\n type: {\n name: \"Composite\",\n className: \"OffChainNewContract\",\n uberParent: \"OffChainUpdate\",\n polymorphicDiscriminator: OffChainUpdate.type.polymorphicDiscriminator,\n modelProperties: {\n ...OffChainUpdate.type.modelProperties,\n owner: {\n serializedName: \"owner\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n vmVersion: {\n serializedName: \"vm_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n code: {\n serializedName: \"code\",\n type: {\n name: \"Composite\",\n className: \"ByteCode\",\n },\n },\n deposit: {\n serializedName: \"deposit\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callData: {\n serializedName: \"call_data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const OffChainCallContract: coreClient.CompositeMapper = {\n serializedName: \"OffChainCallContract\",\n type: {\n name: \"Composite\",\n className: \"OffChainCallContract\",\n uberParent: \"OffChainUpdate\",\n polymorphicDiscriminator: OffChainUpdate.type.polymorphicDiscriminator,\n modelProperties: {\n ...OffChainUpdate.type.modelProperties,\n caller: {\n serializedName: \"caller\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contract: {\n serializedName: \"contract\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n abiVersion: {\n serializedName: \"abi_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gas: {\n serializedName: \"gas\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n gasPrice: {\n serializedName: \"gas_price\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callData: {\n serializedName: \"call_data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const CreateContractUnsignedTx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CreateContractUnsignedTx\",\n modelProperties: {\n ...UnsignedTx.type.modelProperties,\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport let discriminators = {\n OffChainUpdate: OffChainUpdate,\n \"OffChainUpdate.OffChainTransfer\": OffChainTransfer,\n \"OffChainUpdate.OffChainWithdrawal\": OffChainWithdrawal,\n \"OffChainUpdate.OffChainDeposit\": OffChainDeposit,\n \"OffChainUpdate.OffChainNewContract\": OffChainNewContract,\n \"OffChainUpdate.OffChainCallContract\": OffChainCallContract,\n};\n","import {\n OperationParameter,\n OperationURLParameter,\n OperationQueryParameter,\n} from \"@azure/core-client\";\nimport {\n DryRunInput as DryRunInputMapper,\n EncodedTx as EncodedTxMapper,\n} from \"../models/mappers\";\n\nexport const accept: OperationParameter = {\n parameterPath: \"accept\",\n mapper: {\n defaultValue: \"application/json\",\n isConstant: true,\n serializedName: \"Accept\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const $host: OperationURLParameter = {\n parameterPath: \"$host\",\n mapper: {\n serializedName: \"$host\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n skipEncoding: true,\n};\n\nexport const intAsString: OperationQueryParameter = {\n parameterPath: \"intAsString\",\n mapper: {\n defaultValue: false,\n serializedName: \"int-as-string\",\n type: {\n name: \"Boolean\",\n },\n },\n};\n\nexport const hash: OperationURLParameter = {\n parameterPath: \"hash\",\n mapper: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const height: OperationURLParameter = {\n parameterPath: \"height\",\n mapper: {\n constraints: {\n InclusiveMaximum: 18446744073709552000,\n InclusiveMinimum: 0,\n },\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const index: OperationURLParameter = {\n parameterPath: \"index\",\n mapper: {\n constraints: {\n InclusiveMinimum: 1,\n },\n serializedName: \"index\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const pubkey: OperationURLParameter = {\n parameterPath: \"pubkey\",\n mapper: {\n serializedName: \"pubkey\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const strategy: OperationQueryParameter = {\n parameterPath: [\"options\", \"strategy\"],\n mapper: {\n defaultValue: \"max\",\n serializedName: \"strategy\",\n type: {\n name: \"Enum\",\n allowedValues: [\"max\", \"continuity\"],\n },\n },\n};\n\nexport const contentType: OperationParameter = {\n parameterPath: [\"options\", \"contentType\"],\n mapper: {\n defaultValue: \"application/json\",\n isConstant: true,\n serializedName: \"Content-Type\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const body: OperationParameter = {\n parameterPath: \"body\",\n mapper: DryRunInputMapper,\n};\n\nexport const body1: OperationParameter = {\n parameterPath: \"body\",\n mapper: EncodedTxMapper,\n};\n\nexport const fromParam: OperationQueryParameter = {\n parameterPath: [\"options\", \"from\"],\n mapper: {\n serializedName: \"from\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const limit: OperationQueryParameter = {\n parameterPath: [\"options\", \"limit\"],\n mapper: {\n defaultValue: 20,\n constraints: {\n InclusiveMaximum: 1000,\n InclusiveMinimum: 1,\n },\n serializedName: \"limit\",\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const typeParam: OperationQueryParameter = {\n parameterPath: [\"options\", \"type\"],\n mapper: {\n defaultValue: \"all\",\n serializedName: \"type\",\n type: {\n name: \"Enum\",\n allowedValues: [\"open\", \"closed\", \"all\"],\n },\n },\n};\n\nexport const queryId: OperationURLParameter = {\n parameterPath: \"queryId\",\n mapper: {\n serializedName: \"query-id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const name: OperationURLParameter = {\n parameterPath: \"name\",\n mapper: {\n serializedName: \"name\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n","import * as coreClient from \"@azure/core-client\";\nimport * as Parameters from \"./models/parameters\";\nimport * as Mappers from \"./models/mappers\";\nimport {\n NodeOptionalParams,\n GetTopHeaderOptionalParams,\n GetTopHeaderResponse,\n GetCurrentKeyBlockOptionalParams,\n GetCurrentKeyBlockResponse,\n GetCurrentKeyBlockHashOptionalParams,\n GetCurrentKeyBlockHashResponse,\n GetCurrentKeyBlockHeightOptionalParams,\n GetCurrentKeyBlockHeightResponse,\n GetPendingKeyBlockOptionalParams,\n GetPendingKeyBlockResponse,\n GetKeyBlockByHashOptionalParams,\n GetKeyBlockByHashResponse,\n GetKeyBlockByHeightOptionalParams,\n GetKeyBlockByHeightResponse,\n GetMicroBlockHeaderByHashOptionalParams,\n GetMicroBlockHeaderByHashResponse,\n GetMicroBlockTransactionsByHashOptionalParams,\n GetMicroBlockTransactionsByHashResponse,\n GetMicroBlockTransactionByHashAndIndexOptionalParams,\n GetMicroBlockTransactionByHashAndIndexResponse,\n GetMicroBlockTransactionsCountByHashOptionalParams,\n GetMicroBlockTransactionsCountByHashResponse,\n GetCurrentGenerationOptionalParams,\n GetCurrentGenerationResponse,\n GetGenerationByHashOptionalParams,\n GetGenerationByHashResponse,\n GetGenerationByHeightOptionalParams,\n GetGenerationByHeightResponse,\n GetAccountByPubkeyOptionalParams,\n GetAccountByPubkeyResponse,\n GetAccountByPubkeyAndHeightOptionalParams,\n GetAccountByPubkeyAndHeightResponse,\n GetAccountByPubkeyAndHashOptionalParams,\n GetAccountByPubkeyAndHashResponse,\n GetPendingAccountTransactionsByPubkeyOptionalParams,\n GetPendingAccountTransactionsByPubkeyResponse,\n GetAccountNextNonceOptionalParams,\n GetAccountNextNonceResponse,\n DryRunInput,\n ProtectedDryRunTxsOptionalParams,\n ProtectedDryRunTxsResponse,\n GetTransactionByHashOptionalParams,\n GetTransactionByHashResponse,\n GetTransactionInfoByHashOptionalParams,\n GetTransactionInfoByHashResponse,\n EncodedTx,\n PostTransactionOptionalParams,\n PostTransactionResponse,\n GetContractOptionalParams,\n GetContractResponse,\n GetContractCodeOptionalParams,\n GetContractCodeResponse,\n GetContractPoIOptionalParams,\n GetContractPoIResponse,\n GetOracleByPubkeyOptionalParams,\n GetOracleByPubkeyResponse,\n GetOracleQueriesByPubkeyOptionalParams,\n GetOracleQueriesByPubkeyResponse,\n GetOracleQueryByPubkeyAndQueryIdOptionalParams,\n GetOracleQueryByPubkeyAndQueryIdResponse,\n GetAuctionEntryByNameOptionalParams,\n GetAuctionEntryByNameResponse,\n GetNameEntryByNameOptionalParams,\n GetNameEntryByNameResponse,\n GetChannelByPubkeyOptionalParams,\n GetChannelByPubkeyResponse,\n GetPeerPubkeyOptionalParams,\n GetPeerPubkeyResponse,\n GetSyncStatusOptionalParams,\n GetSyncStatusResponse,\n GetStatusOptionalParams,\n GetStatusResponse,\n GetChainEndsOptionalParams,\n GetChainEndsResponse,\n GetCurrencyOptionalParams,\n GetCurrencyResponse,\n GetRecentGasPricesOptionalParams,\n GetRecentGasPricesResponse,\n} from \"./models\";\n\nexport class Node extends coreClient.ServiceClient {\n $host: string;\n intAsString?: boolean;\n\n /**\n * Initializes a new instance of the Node class.\n * @param $host server parameter\n * @param options The parameter options\n */\n constructor($host: string, options?: NodeOptionalParams) {\n if ($host === undefined) {\n throw new Error(\"'$host' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: NodeOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\",\n };\n\n const packageDetails = `azsdk-js-node/1.0.0-beta.1`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix,\n },\n endpoint: options.endpoint ?? options.baseUri ?? \"{$host}\",\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.$host = $host;\n }\n\n /**\n * Get the top header (either key or micro block)\n * @param options The options parameters.\n */\n getTopHeader(\n options?: GetTopHeaderOptionalParams,\n ): Promise<GetTopHeaderResponse> {\n return this.sendOperationRequest({ options }, getTopHeaderOperationSpec);\n }\n\n /**\n * Get the current key block\n * @param options The options parameters.\n */\n getCurrentKeyBlock(\n options?: GetCurrentKeyBlockOptionalParams,\n ): Promise<GetCurrentKeyBlockResponse> {\n return this.sendOperationRequest(\n { options },\n getCurrentKeyBlockOperationSpec,\n );\n }\n\n /**\n * Get the hash of the current key block\n * @param options The options parameters.\n */\n getCurrentKeyBlockHash(\n options?: GetCurrentKeyBlockHashOptionalParams,\n ): Promise<GetCurrentKeyBlockHashResponse> {\n return this.sendOperationRequest(\n { options },\n getCurrentKeyBlockHashOperationSpec,\n );\n }\n\n /**\n * Get the height of the current key block\n * @param options The options parameters.\n */\n getCurrentKeyBlockHeight(\n options?: GetCurrentKeyBlockHeightOptionalParams,\n ): Promise<GetCurrentKeyBlockHeightResponse> {\n return this.sendOperationRequest(\n { options },\n getCurrentKeyBlockHeightOperationSpec,\n );\n }\n\n /**\n * Get the pending key block\n * @param options The options parameters.\n */\n getPendingKeyBlock(\n options?: GetPendingKeyBlockOptionalParams,\n ): Promise<GetPendingKeyBlockResponse> {\n return this.sendOperationRequest(\n { options },\n getPendingKeyBlockOperationSpec,\n );\n }\n\n /**\n * Get a key block by hash\n * @param hash The hash of the block - either a keyblock or a microblock\n * @param options The options parameters.\n */\n getKeyBlockByHash(\n hash: string,\n options?: GetKeyBlockByHashOptionalParams,\n ): Promise<GetKeyBlockByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getKeyBlockByHashOperationSpec,\n );\n }\n\n /**\n * Get a key block by height\n * @param height The height\n * @param options The options parameters.\n */\n getKeyBlockByHeight(\n height: number,\n options?: GetKeyBlockByHeightOptionalParams,\n ): Promise<GetKeyBlockByHeightResponse> {\n return this.sendOperationRequest(\n { height, options },\n getKeyBlockByHeightOperationSpec,\n );\n }\n\n /**\n * Get a micro block header by hash\n * @param hash The hash of the block - either a keyblock or a microblock\n * @param options The options parameters.\n */\n getMicroBlockHeaderByHash(\n hash: string,\n options?: GetMicroBlockHeaderByHashOptionalParams,\n ): Promise<GetMicroBlockHeaderByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getMicroBlockHeaderByHashOperationSpec,\n );\n }\n\n /**\n * Get micro block transactions by hash\n * @param hash The hash of the micro block\n * @param options The options parameters.\n */\n getMicroBlockTransactionsByHash(\n hash: string,\n options?: GetMicroBlockTransactionsByHashOptionalParams,\n ): Promise<GetMicroBlockTransactionsByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getMicroBlockTransactionsByHashOperationSpec,\n );\n }\n\n /**\n * Get a micro block transaction by hash and index\n * @param hash The hash of the micro block\n * @param index The index of the transaction in a block\n * @param options The options parameters.\n */\n getMicroBlockTransactionByHashAndIndex(\n hash: string,\n index: number,\n options?: GetMicroBlockTransactionByHashAndIndexOptionalParams,\n ): Promise<GetMicroBlockTransactionByHashAndIndexResponse> {\n return this.sendOperationRequest(\n { hash, index, options },\n getMicroBlockTransactionByHashAndIndexOperationSpec,\n );\n }\n\n /**\n * Get micro block transaction count by hash\n * @param hash The hash of the micro block\n * @param options The options parameters.\n */\n getMicroBlockTransactionsCountByHash(\n hash: string,\n options?: GetMicroBlockTransactionsCountByHashOptionalParams,\n ): Promise<GetMicroBlockTransactionsCountByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getMicroBlockTransactionsCountByHashOperationSpec,\n );\n }\n\n /**\n * Get the current generation\n * @param options The options parameters.\n */\n getCurrentGeneration(\n options?: GetCurrentGenerationOptionalParams,\n ): Promise<GetCurrentGenerationResponse> {\n return this.sendOperationRequest(\n { options },\n getCurrentGenerationOperationSpec,\n );\n }\n\n /**\n * Get a generation by hash\n * @param hash The hash of the key block\n * @param options The options parameters.\n */\n getGenerationByHash(\n hash: string,\n options?: GetGenerationByHashOptionalParams,\n ): Promise<GetGenerationByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getGenerationByHashOperationSpec,\n );\n }\n\n /**\n * Get a generation by height\n * @param height The height\n * @param options The options parameters.\n */\n getGenerationByHeight(\n height: number,\n options?: GetGenerationByHeightOptionalParams,\n ): Promise<GetGenerationByHeightResponse> {\n return this.sendOperationRequest(\n { height, options },\n getGenerationByHeightOperationSpec,\n );\n }\n\n /**\n * Get an account by public key\n * @param pubkey The public key of the account\n * @param options The options parameters.\n */\n getAccountByPubkey(\n pubkey: string,\n options?: GetAccountByPubkeyOptionalParams,\n ): Promise<GetAccountByPubkeyResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getAccountByPubkeyOperationSpec,\n );\n }\n\n /**\n * Get an account by public key after the opening key block of the generation at height\n * @param pubkey The public key of the account\n * @param height The height\n * @param options The options parameters.\n */\n getAccountByPubkeyAndHeight(\n pubkey: string,\n height: number,\n options?: GetAccountByPubkeyAndHeightOptionalParams,\n ): Promise<GetAccountByPubkeyAndHeightResponse> {\n return this.sendOperationRequest(\n { pubkey, height, options },\n getAccountByPubkeyAndHeightOperationSpec,\n );\n }\n\n /**\n * Get an account by public key after the block indicated by hash. Can be either a micro block or a\n * keyblock hash\n * @param pubkey The public key of the account\n * @param hash The hash of the block - either a keyblock or a microblock\n * @param options The options parameters.\n */\n getAccountByPubkeyAndHash(\n pubkey: string,\n hash: string,\n options?: GetAccountByPubkeyAndHashOptionalParams,\n ): Promise<GetAccountByPubkeyAndHashResponse> {\n return this.sendOperationRequest(\n { pubkey, hash, options },\n getAccountByPubkeyAndHashOperationSpec,\n );\n }\n\n /**\n * Get pending account transactions by public key\n * @param pubkey The public key of the account\n * @param options The options parameters.\n */\n getPendingAccountTransactionsByPubkey(\n pubkey: string,\n options?: GetPendingAccountTransactionsByPubkeyOptionalParams,\n ): Promise<GetPendingAccountTransactionsByPubkeyResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getPendingAccountTransactionsByPubkeyOperationSpec,\n );\n }\n\n /**\n * Get an account's next nonce; This is computed according to whatever is the current account nonce and\n * what transactions are currently present in the transaction pool\n * @param pubkey The public key of the account\n * @param options The options parameters.\n */\n getAccountNextNonce(\n pubkey: string,\n options?: GetAccountNextNonceOptionalParams,\n ): Promise<GetAccountNextNonceResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getAccountNextNonceOperationSpec,\n );\n }\n\n /**\n * Dry-run unsigned transactions on top of a given block. Supports all TXs except GAMetaTx, PayingForTx\n * and OffchainTx. The maximum gas limit of all calls is capped. The maximum gas limit per request is a\n * global node setting. Since DryRunCallReq object do not have a mandatory gas field, if not set a\n * default value of 1000000 is being used instead.\n * @param body transactions\n * @param options The options parameters.\n */\n protectedDryRunTxs(\n body: DryRunInput,\n options?: ProtectedDryRunTxsOptionalParams,\n ): Promise<ProtectedDryRunTxsResponse> {\n return this.sendOperationRequest(\n { body, options },\n protectedDryRunTxsOperationSpec,\n );\n }\n\n /**\n * Get a transaction by hash\n * @param hash The hash of the transaction\n * @param options The options parameters.\n */\n getTransactionByHash(\n hash: string,\n options?: GetTransactionByHashOptionalParams,\n ): Promise<GetTransactionByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getTransactionByHashOperationSpec,\n );\n }\n\n /**\n * @param hash The hash of the transaction\n * @param options The options parameters.\n */\n getTransactionInfoByHash(\n hash: string,\n options?: GetTransactionInfoByHashOptionalParams,\n ): Promise<GetTransactionInfoByHashResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getTransactionInfoByHashOperationSpec,\n );\n }\n\n /**\n * Post a new transaction\n * @param body The new transaction\n * @param options The options parameters.\n */\n postTransaction(\n body: EncodedTx,\n options?: PostTransactionOptionalParams,\n ): Promise<PostTransactionResponse> {\n return this.sendOperationRequest(\n { body, options },\n postTransactionOperationSpec,\n );\n }\n\n /**\n * Get a contract by pubkey\n * @param pubkey Contract pubkey to get proof for\n * @param options The options parameters.\n */\n getContract(\n pubkey: string,\n options?: GetContractOptionalParams,\n ): Promise<GetContractResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getContractOperationSpec,\n );\n }\n\n /**\n * Get contract code by pubkey\n * @param pubkey Contract pubkey to get proof for\n * @param options The options parameters.\n */\n getContractCode(\n pubkey: string,\n options?: GetContractCodeOptionalParams,\n ): Promise<GetContractCodeResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getContractCodeOperationSpec,\n );\n }\n\n /**\n * Get a proof of inclusion for a contract\n * @param pubkey Contract pubkey to get proof for\n * @param options The options parameters.\n */\n getContractPoI(\n pubkey: string,\n options?: GetContractPoIOptionalParams,\n ): Promise<GetContractPoIResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getContractPoIOperationSpec,\n );\n }\n\n /**\n * Get an oracle by public key\n * @param pubkey The public key of the oracle\n * @param options The options parameters.\n */\n getOracleByPubkey(\n pubkey: string,\n options?: GetOracleByPubkeyOptionalParams,\n ): Promise<GetOracleByPubkeyResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getOracleByPubkeyOperationSpec,\n );\n }\n\n /**\n * Get oracle queries by public key\n * @param pubkey The public key of the oracle\n * @param options The options parameters.\n */\n getOracleQueriesByPubkey(\n pubkey: string,\n options?: GetOracleQueriesByPubkeyOptionalParams,\n ): Promise<GetOracleQueriesByPubkeyResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getOracleQueriesByPubkeyOperationSpec,\n );\n }\n\n /**\n * Get an oracle query by public key and query ID\n * @param pubkey The public key of the oracle\n * @param queryId The ID of the query\n * @param options The options parameters.\n */\n getOracleQueryByPubkeyAndQueryId(\n pubkey: string,\n queryId: string,\n options?: GetOracleQueryByPubkeyAndQueryIdOptionalParams,\n ): Promise<GetOracleQueryByPubkeyAndQueryIdResponse> {\n return this.sendOperationRequest(\n { pubkey, queryId, options },\n getOracleQueryByPubkeyAndQueryIdOperationSpec,\n );\n }\n\n /**\n * Get auction entry from naming system\n * @param name The name key of the name entry\n * @param options The options parameters.\n */\n getAuctionEntryByName(\n name: string,\n options?: GetAuctionEntryByNameOptionalParams,\n ): Promise<GetAuctionEntryByNameResponse> {\n return this.sendOperationRequest(\n { name, options },\n getAuctionEntryByNameOperationSpec,\n );\n }\n\n /**\n * Get name entry from naming system\n * @param name The name key of the name entry\n * @param options The options parameters.\n */\n getNameEntryByName(\n name: string,\n options?: GetNameEntryByNameOptionalParams,\n ): Promise<GetNameEntryByNameResponse> {\n return this.sendOperationRequest(\n { name, options },\n getNameEntryByNameOperationSpec,\n );\n }\n\n /**\n * Get channel by public key\n * @param pubkey The pubkey of the channel\n * @param options The options parameters.\n */\n getChannelByPubkey(\n pubkey: string,\n options?: GetChannelByPubkeyOptionalParams,\n ): Promise<GetChannelByPubkeyResponse> {\n return this.sendOperationRequest(\n { pubkey, options },\n getChannelByPubkeyOperationSpec,\n );\n }\n\n /**\n * Get peer public key\n * @param options The options parameters.\n */\n getPeerPubkey(\n options?: GetPeerPubkeyOptionalParams,\n ): Promise<GetPeerPubkeyResponse> {\n return this.sendOperationRequest({ options }, getPeerPubkeyOperationSpec);\n }\n\n /**\n * Get the sync status of a node\n * @param options The options parameters.\n */\n getSyncStatus(\n options?: GetSyncStatusOptionalParams,\n ): Promise<GetSyncStatusResponse> {\n return this.sendOperationRequest({ options }, getSyncStatusOperationSpec);\n }\n\n /**\n * Get the status of a node\n * @param options The options parameters.\n */\n getStatus(options?: GetStatusOptionalParams): Promise<GetStatusResponse> {\n return this.sendOperationRequest({ options }, getStatusOperationSpec);\n }\n\n /**\n * Get oldest keyblock hashes counting from genesis including orphans\n * @param options The options parameters.\n */\n getChainEnds(\n options?: GetChainEndsOptionalParams,\n ): Promise<GetChainEndsResponse> {\n return this.sendOperationRequest({ options }, getChainEndsOperationSpec);\n }\n\n /**\n * Get the currency metadata of a node\n * @param options The options parameters.\n */\n getCurrency(\n options?: GetCurrencyOptionalParams,\n ): Promise<GetCurrencyResponse> {\n return this.sendOperationRequest({ options }, getCurrencyOperationSpec);\n }\n\n /**\n * Get minimum gas prices in recent blocks\n * @param options The options parameters.\n */\n getRecentGasPrices(\n options?: GetRecentGasPricesOptionalParams,\n ): Promise<GetRecentGasPricesResponse> {\n return this.sendOperationRequest(\n { options },\n getRecentGasPricesOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst getTopHeaderOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/headers/top\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Header,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getCurrentKeyBlockOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/key-blocks/current\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.KeyBlock,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getCurrentKeyBlockHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/key-blocks/current/hash\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.HashResponse,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getCurrentKeyBlockHeightOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/key-blocks/current/height\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.HeightResponse,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getPendingKeyBlockOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/key-blocks/pending\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.KeyBlock,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getKeyBlockByHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/key-blocks/hash/{hash}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.KeyBlock,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getKeyBlockByHeightOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/key-blocks/height/{height}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.KeyBlock,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.height],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getMicroBlockHeaderByHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/micro-blocks/hash/{hash}/header\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.MicroBlockHeader,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getMicroBlockTransactionsByHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/micro-blocks/hash/{hash}/transactions\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SignedTxs,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getMicroBlockTransactionByHashAndIndexOperationSpec: coreClient.OperationSpec =\n {\n path: \"/v3/micro-blocks/hash/{hash}/transactions/index/{index}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SignedTx,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash, Parameters.index],\n headerParameters: [Parameters.accept],\n serializer,\n };\nconst getMicroBlockTransactionsCountByHashOperationSpec: coreClient.OperationSpec =\n {\n path: \"/v3/micro-blocks/hash/{hash}/transactions/count\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.CountResponse,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n };\nconst getCurrentGenerationOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/generations/current\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Generation,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getGenerationByHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/generations/hash/{hash}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Generation,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getGenerationByHeightOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/generations/height/{height}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Generation,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.height],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAccountByPubkeyOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/accounts/{pubkey}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Account,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAccountByPubkeyAndHeightOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/accounts/{pubkey}/height/{height}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Account,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 410: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.height, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAccountByPubkeyAndHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/accounts/{pubkey}/hash/{hash}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Account,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getPendingAccountTransactionsByPubkeyOperationSpec: coreClient.OperationSpec =\n {\n path: \"/v3/accounts/{pubkey}/transactions/pending\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SignedTxs,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n };\nconst getAccountNextNonceOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/accounts/{pubkey}/next-nonce\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.NextNonceResponse,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString, Parameters.strategy],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst protectedDryRunTxsOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/dry-run\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.DryRunResults,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 403: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n requestBody: Parameters.body,\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept, Parameters.contentType],\n mediaType: \"json\",\n serializer,\n};\nconst getTransactionByHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/transactions/{hash}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SignedTx,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTransactionInfoByHashOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/transactions/{hash}/info\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.TxInfoObject,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 410: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.hash],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst postTransactionOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/transactions\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.PostTxResponse,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n requestBody: Parameters.body1,\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept, Parameters.contentType],\n mediaType: \"json\",\n serializer,\n};\nconst getContractOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/contracts/{pubkey}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.ContractObject,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getContractCodeOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/contracts/{pubkey}/code\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.ByteCode,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getContractPoIOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/contracts/{pubkey}/poi\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PoI,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOracleByPubkeyOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/oracles/{pubkey}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.RegisteredOracle,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOracleQueriesByPubkeyOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/oracles/{pubkey}/queries\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.OracleQueries,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.intAsString,\n Parameters.fromParam,\n Parameters.limit,\n Parameters.typeParam,\n ],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOracleQueryByPubkeyAndQueryIdOperationSpec: coreClient.OperationSpec =\n {\n path: \"/v3/oracles/{pubkey}/queries/{query-id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.OracleQuery,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey, Parameters.queryId],\n headerParameters: [Parameters.accept],\n serializer,\n };\nconst getAuctionEntryByNameOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/auctions/{name}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.AuctionEntry,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.name],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNameEntryByNameOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/names/{name}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.NameEntry,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.name],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getChannelByPubkeyOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/channels/{pubkey}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Channel,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host, Parameters.pubkey],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getPeerPubkeyOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/peers/pubkey\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.PeerPubKey,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getSyncStatusOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/sync-status\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.SyncStatus,\n },\n 404: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getStatusOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/status\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Status,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getChainEndsOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/status/chain-ends\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: {\n type: { name: \"Sequence\", element: { type: { name: \"String\" } } },\n },\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getCurrencyOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/currency\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Currency,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getRecentGasPricesOperationSpec: coreClient.OperationSpec = {\n path: \"/v3/recent-gas-prices\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"GasPricesItem\" } },\n },\n },\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n queryParameters: [Parameters.intAsString],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\n","// eslint-disable-next-line max-classes-per-file\nimport BigNumber from 'bignumber.js';\nimport { OperationArguments, OperationOptions, OperationSpec } from '@azure/core-client';\nimport { userAgentPolicyName, setClientRequestIdPolicyName } from '@azure/core-rest-pipeline';\nimport {\n genRequestQueuesPolicy, genCombineGetRequestsPolicy, genErrorFormatterPolicy,\n genVersionCheckPolicy, genRetryOnFailurePolicy,\n} from './utils/autorest';\nimport { Node as NodeApi, NodeOptionalParams, ErrorModel } from './apis/node';\nimport { mapObject } from './utils/other';\nimport { UnsupportedVersionError } from './utils/errors';\nimport { Encoded } from './utils/encoder';\nimport { ConsensusProtocolVersion } from './tx/builder/constants';\n\nconst bigIntPropertyNames = [\n 'balance', 'queryFee', 'fee', 'amount', 'nameFee', 'channelAmount',\n 'initiatorAmount', 'responderAmount', 'channelReserve', 'initiatorAmountFinal',\n 'responderAmountFinal', 'gasPrice', 'minGasPrice', 'deposit',\n] as const;\n\nconst numberPropertyNames = [\n 'time', 'gas', 'gasUsed', 'nameSalt',\n 'nonce', 'nextNonce', 'height', 'blockHeight', 'topBlockHeight',\n 'ttl', 'nameTtl', 'clientTtl',\n 'inbound', 'outbound', 'peerCount', 'pendingTransactionsCount', 'effectiveAtHeight',\n 'version', 'solutions', 'round', 'minutes', 'utilization', 'difficulty', 'hashrate',\n] as const;\n\nclass NodeTransformed extends NodeApi {\n override async sendOperationRequest(\n operationArguments: OperationArguments,\n operationSpec: OperationSpec,\n ): Promise<any> {\n const args = mapObject(\n operationArguments,\n ([key, value]) => [key, this.#encodeArg(value)],\n ) as OperationArguments;\n return this.#decodeRes(await super.sendOperationRequest(args, operationSpec));\n }\n\n #mapData(data: any, transform: {\n bigInt: (v: any) => any;\n number: (v: any) => any;\n }): unknown {\n if (Array.isArray(data)) return data.map((d) => this.#mapData(d, transform));\n if (data != null && typeof data === 'object') {\n return mapObject(data, ([key, value]) => {\n if (value == null) return [key, value];\n if (bigIntPropertyNames.some((k) => k === key)) return [key, transform.bigInt(value)];\n if (numberPropertyNames.some((k) => k === key)) return [key, transform.number(value)];\n return [key, this.#mapData(value, transform)];\n });\n }\n return data;\n }\n\n #encodeArg(data: any): any {\n return this.#mapData(data, {\n bigInt: (value) => {\n if (value instanceof BigNumber) return value.toFixed();\n return value.toString();\n },\n number: (value) => value.toString(),\n });\n }\n\n #decodeRes(data: any): any {\n return this.#mapData(data, {\n bigInt: (value) => BigInt(value),\n number: (value) => +value,\n });\n }\n}\n\ntype BigIntPropertyNames = typeof bigIntPropertyNames[number];\ntype NumberPropertyNames = typeof numberPropertyNames[number];\ntype PreserveOptional<NewType, OrigType> =\n OrigType extends undefined ? NewType | undefined : NewType;\nexport type TransformNodeType<Type> =\n Type extends (...args: infer Args) => infer Ret\n ? (...args: TransformNodeType<Args>) => TransformNodeType<Ret>\n : Type extends [infer Item, ...infer Rest]\n ? [TransformNodeType<Item>, ...TransformNodeType<Rest>]\n : Type extends Array<infer Item>\n ? Array<TransformNodeType<Item>>\n : Type extends Promise<infer T>\n ? Promise<TransformNodeType<T>>\n : Type extends { [P in any]: any }\n ? {\n [Property in keyof Type]:\n Property extends BigIntPropertyNames\n ? PreserveOptional<bigint, Type[Property]>\n : Property extends NumberPropertyNames\n ? PreserveOptional<number, Type[Property]>\n : Property extends 'txHash'\n ? PreserveOptional<Encoded.TxHash, Type[Property]>\n : Property extends 'bytecode'\n ? PreserveOptional<Encoded.ContractBytearray, Type[Property]>\n : TransformNodeType<Type[Property]>\n }\n : Type;\ntype NodeTransformedApi = new (...args: ConstructorParameters<typeof NodeApi>) => {\n [Name in keyof InstanceType<typeof NodeApi>]:\n Name extends 'pipeline' | 'sendRequest' | 'sendOperationRequest'\n ? NodeApi[Name] : TransformNodeType<NodeApi[Name]>\n};\n\ninterface NodeInfo {\n url: string;\n nodeNetworkId: string;\n version: string;\n consensusProtocolVersion: ConsensusProtocolVersion;\n}\n\nexport default class Node extends (NodeTransformed as unknown as NodeTransformedApi) {\n /**\n * @param url - Url for node API\n * @param options - Options\n * @param options.ignoreVersion - Don't ensure that the node is supported\n * @param options.retryCount - Amount of extra requests to do in case of failure\n * @param options.retryOverallDelay - Time in ms to wait between all retries\n */\n constructor(\n url: string,\n {\n ignoreVersion = false, retryCount = 3, retryOverallDelay = 800, ...options\n }: NodeOptionalParams & {\n ignoreVersion?: boolean;\n retryCount?: number;\n retryOverallDelay?: number;\n } = {},\n ) {\n const getVersion = async (opts: OperationOptions): Promise<string> => (\n (await this._getCachedStatus(opts)).nodeVersion\n );\n // eslint-disable-next-line constructor-super\n super(url, {\n allowInsecureConnection: true,\n additionalPolicies: [\n ...ignoreVersion ? [] : [genVersionCheckPolicy('node', getVersion, '6.2.0', '8.0.0')],\n genRequestQueuesPolicy(),\n genCombineGetRequestsPolicy(),\n genRetryOnFailurePolicy(retryCount, retryOverallDelay),\n genErrorFormatterPolicy((body: ErrorModel) => [\n ' ', body.reason, body.errorCode == null ? '' : ` (${body.errorCode})`,\n ].join('')),\n ],\n ...options,\n });\n this.pipeline.removePolicy({ name: userAgentPolicyName });\n this.pipeline.removePolicy({ name: setClientRequestIdPolicyName });\n // TODO: use instead our retry policy\n this.pipeline.removePolicy({ name: 'defaultRetryPolicy' });\n this.intAsString = true;\n }\n\n #cachedStatusPromise?: ReturnType<Node['getStatus']>;\n\n async _getCachedStatus(options?: OperationOptions): ReturnType<Node['getStatus']> {\n if (this.#cachedStatusPromise != null) return this.#cachedStatusPromise;\n return this.getStatus(options);\n }\n\n // eslint-disable-next-line rulesdir/tsdoc-syntax\n /** @ts-expect-error use code generation to create node class? */\n override async getStatus(\n ...args: Parameters<InstanceType<NodeTransformedApi>['getStatus']>\n ): ReturnType<InstanceType<NodeTransformedApi>['getStatus']> {\n const promise = super.getStatus(...args);\n promise.then(() => { this.#cachedStatusPromise = promise; }, () => {});\n return promise;\n }\n\n /**\n * Returns network ID provided by node.\n * This method won't do extra requests on subsequent calls.\n */\n async getNetworkId(): Promise<string> {\n return (await this._getCachedStatus()).networkId;\n }\n\n async getNodeInfo(): Promise<NodeInfo> {\n const {\n nodeVersion,\n networkId: nodeNetworkId,\n protocols,\n topBlockHeight,\n } = await this.getStatus();\n\n const consensusProtocolVersion = protocols\n .filter(({ effectiveAtHeight }) => topBlockHeight >= effectiveAtHeight)\n .reduce(\n (acc, p) => (p.effectiveAtHeight > acc.effectiveAtHeight ? p : acc),\n { effectiveAtHeight: -1, version: 0 },\n )\n .version;\n if (ConsensusProtocolVersion[consensusProtocolVersion] == null) {\n const version = consensusProtocolVersion.toString();\n const versions = Object.values(ConsensusProtocolVersion)\n .filter((el) => typeof el === 'number').map((el) => +el);\n const geVersion = Math.min(...versions).toString();\n const ltVersion = (Math.max(...versions) + 1).toString();\n throw new UnsupportedVersionError('consensus protocol', version, geVersion, ltVersion);\n }\n\n return {\n url: this.$host,\n nodeNetworkId,\n version: nodeVersion,\n consensusProtocolVersion,\n };\n }\n}\n","import { Encoded } from '../utils/encoder';\nimport { buildTx, getSchema, unpackTx } from './builder';\nimport { Tag } from './builder/constants';\nimport { TransactionError, UnexpectedTsError } from '../utils/errors';\n\n/**\n * Returns account address that signed a transaction\n * @param transaction - transaction to get a signer of\n */\nexport default function getTransactionSignerAddress(\n transaction: Encoded.Transaction,\n): Encoded.AccountAddress {\n const params = unpackTx(transaction);\n switch (params.tag) {\n case Tag.SignedTx:\n return getTransactionSignerAddress(buildTx(params.encodedTx));\n case Tag.GaMetaTx:\n return params.gaId;\n default:\n }\n\n const nonce = getSchema(params.tag, params.version).find(([name]) => name === 'nonce')?.[1];\n if (nonce == null) throw new TransactionError(`Transaction doesn't have nonce: ${Tag[params.tag]}`);\n if (!('senderKey' in nonce)) throw new UnexpectedTsError();\n const address = params[nonce.senderKey as keyof typeof params] as unknown as string;\n return address.replace(/^ok_/, 'ak_') as Encoded.AccountAddress;\n}\n","import { Encoded } from '../utils/encoder';\nimport Node from '../Node';\nimport CompilerBase from '../contract/compiler/Base';\nimport { AensName, ConsensusProtocolVersion, Int } from '../tx/builder/constants';\nimport { AciValue, Domain } from '../utils/typed-data';\nimport { NotImplementedError } from '../utils/errors';\n\ninterface AuthData {\n fee?: Int;\n gasLimit?: number;\n gasPrice?: Int;\n callData?: Encoded.ContractBytearray;\n sourceCode?: string;\n args?: any[];\n}\n\n/**\n * Account is one of the three basic building blocks of an\n * {@link AeSdk} and provides access to a signing key pair.\n */\nexport default abstract class AccountBase {\n /**\n * Sign encoded transaction\n * @param tx - Transaction to sign\n * @param options - Options\n * @param options.innerTx - Sign as inner transaction for PayingFor\n * @param options.authData - Object with gaMeta params\n * @returns Signed transaction\n */\n abstract signTransaction(\n tx: Encoded.Transaction,\n options: {\n innerTx?: boolean;\n networkId?: string;\n authData?: AuthData | ((tx: Encoded.Transaction) => Promise<AuthData>);\n onNode?: Node;\n onCompiler?: CompilerBase;\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n ): Promise<Encoded.Transaction>;\n\n /**\n * Sign message\n * @param message - Message to sign\n * @param options - Options\n * @returns Signature\n */\n abstract signMessage(\n message: string,\n options?: {\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n ): Promise<Uint8Array>;\n\n /**\n * Sign typed data\n * @param data - Encoded data to sign\n * @param aci - Type of data to sign\n * @param options - Options\n * @returns Signature\n */\n // TODO: make abstract in the next major release\n // eslint-disable-next-line class-methods-use-this\n async signTypedData(\n /* eslint-disable @typescript-eslint/no-unused-vars */\n data: Encoded.ContractBytearray,\n aci: AciValue,\n options?: Domain & {\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ): Promise<Encoded.Signature> {\n throw new NotImplementedError('signTypedData method');\n }\n\n /**\n * Sign delegation of AENS, oracle operations to a contract\n * @param contractAddress - Address of a contract to delegate permissions to\n * @param options - Options\n * @param options.isOracle - Use to generate an oracle delegation signature in Ceres, otherwise an\n * AENS preclaim delegation signature would be generated\n * @returns Signature\n * @deprecated use AccountBase:signDelegation in Ceres\n */\n // TODO: make abstract in the next major release\n // eslint-disable-next-line class-methods-use-this\n async signDelegationToContract(\n /* eslint-disable @typescript-eslint/no-unused-vars */\n contractAddress: Encoded.ContractAddress,\n options?: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n isOracle?: boolean;\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ): Promise<Encoded.Signature> {\n throw new NotImplementedError('signDelegationToContract method');\n }\n\n /**\n * Sign delegation of an AENS name to a contract\n * @param contractAddress - Address of a contract to delegate permissions to\n * @param name - AENS name to manage by a contract\n * @param options - Options\n * @returns Signature\n * @deprecated use AccountBase:signDelegation in Ceres\n */\n // TODO: make abstract in the next major release\n // eslint-disable-next-line class-methods-use-this\n async signNameDelegationToContract(\n /* eslint-disable @typescript-eslint/no-unused-vars */\n contractAddress: Encoded.ContractAddress,\n name: AensName,\n options?: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ): Promise<Encoded.Signature> {\n throw new NotImplementedError('signNameDelegationToContract method');\n }\n\n /**\n * Sign delegation of all AENS names to a contract (not available in Iris)\n * @param contractAddress - Address of a contract to delegate permissions to\n * @param options - Options\n * @returns Signature\n * @deprecated use AccountBase:signDelegation in Ceres\n */\n // TODO: make abstract in the next major release\n // eslint-disable-next-line class-methods-use-this\n async signAllNamesDelegationToContract(\n /* eslint-disable @typescript-eslint/no-unused-vars */\n contractAddress: Encoded.ContractAddress,\n options?: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ): Promise<Encoded.Signature> {\n throw new NotImplementedError('signAllNamesDelegationToContract method');\n }\n\n /**\n * Sign delegation of oracle query to a contract\n *\n * Warning! Implementations needs to ensure that decoded oracle query id is not equal to decoded\n * current account address unless https://github.com/aeternity/aesophia/issues/475 is fixed.\n *\n * Warning! Implementations needs to ensure that oracle query and contract exists unless\n * https://github.com/aeternity/aesophia/issues/474 is fixed.\n *\n * @param contractAddress - Address of a contract to delegate permissions to\n * @param oracleQueryId - Oracle query ID to reply by a contract\n * @param options - Options\n * @returns Signature\n * @deprecated use AccountBase:signDelegation in Ceres\n */\n // TODO: make abstract in the next major release\n // eslint-disable-next-line class-methods-use-this\n async signOracleQueryDelegationToContract(\n /* eslint-disable @typescript-eslint/no-unused-vars */\n contractAddress: Encoded.ContractAddress,\n oracleQueryId: Encoded.OracleQueryId,\n options?: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ): Promise<Encoded.Signature> {\n throw new NotImplementedError('signOracleQueryDelegationToContract method');\n }\n\n /**\n * Sign data blob\n * @param data - Data blob to sign\n * @param options - Options\n * @returns Signature\n */\n abstract sign(\n data: string | Uint8Array,\n options?: {\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n ): Promise<Uint8Array>;\n\n /**\n * Account address\n */\n readonly address!: Encoded.AccountAddress;\n\n /**\n * Sign delegation, works only in Ceres\n * @param delegation - Delegation to sign\n * @param options - Options\n * @returns Signature\n */\n // TODO: make abstract in the next major release\n // eslint-disable-next-line class-methods-use-this\n async signDelegation(\n /* eslint-disable @typescript-eslint/no-unused-vars */\n delegation: Encoded.Bytearray,\n options?: {\n networkId?: string;\n aeppOrigin?: string;\n aeppRpcClientId?: string;\n },\n /* eslint-enable @typescript-eslint/no-unused-vars */\n ): Promise<Encoded.Signature> {\n throw new NotImplementedError('signDelegation method');\n }\n}\n","import { TypeResolver, ContractByteArrayEncoder } from '@aeternity/aepp-calldata';\nimport canonicalize from 'canonicalize';\nimport { Encoded, decode } from './encoder';\nimport { hash, messagePrefixLength } from './crypto';\nimport { concatBuffers } from './other';\n\n/**\n * Hashes arbitrary object, can be used to inline the aci hash to contract source code\n */\nexport function hashJson(data: unknown): Buffer {\n return hash(canonicalize(data) ?? '');\n}\n\n// TODO: move this type to calldata library https://github.com/aeternity/aepp-calldata-js/issues/215\n// based on https://github.com/aeternity/aepp-calldata-js/blob/82b5a98f9b308482627da8d7484d213e9cf87151/src/AciTypeResolver.js#L129\nexport type AciValue = 'void' | 'unit' | 'int' | 'bool' | 'string' | 'bits' | 'hash' | 'signature'\n| 'address' | 'contract_pubkey' | 'Chain.ttl' | 'Chain.ga_meta_tx' | 'Chain.paying_for_tx'\n| 'Chain.base_tx' | 'AENS.pointee' | 'AENS.name' | 'MCL_BLS12_381.fr' | 'MCL_BLS12_381.fp'\n| { 'Set.set': readonly [AciValue] }\n| { bytes: number }\n| { list: readonly [AciValue] }\n| { map: readonly [AciValue, AciValue] }\n| { tuple: readonly AciValue[] }\n| { record: ReadonlyArray<{ name: string; type: AciValue }> }\n| { variant: ReadonlyArray<{ [key: string]: readonly AciValue[] }> }\n| { option: readonly [AciValue] }\n| { oracle: readonly [AciValue, AciValue] }\n| { oracle_query: readonly [AciValue, AciValue] };\n\nexport interface Domain {\n name?: string;\n version?: number;\n networkId?: string;\n contractAddress?: Encoded.ContractAddress;\n}\n\n/**\n * Hashes domain object, can be used to inline domain hash to contract source code\n */\nexport function hashDomain(domain: Domain): Buffer {\n const domainAci = {\n record: [{\n name: 'name',\n type: { option: ['string'] },\n }, {\n name: 'version',\n type: { option: ['int'] },\n }, {\n name: 'networkId',\n type: { option: ['string'] },\n }, {\n name: 'contractAddress',\n type: { option: ['contract_pubkey'] },\n }],\n } as const;\n const domainType = new TypeResolver().resolveType(domainAci, {});\n const fateValue = new ContractByteArrayEncoder().encodeWithType(domain, domainType);\n return hash(decode(fateValue));\n}\n\nexport function hashTypedData(\n data: Encoded.ContractBytearray,\n aci: AciValue,\n domain: Domain,\n): Buffer {\n return hash(concatBuffers([\n messagePrefixLength, new Uint8Array([0]), hashDomain(domain), hashJson(aci), hash(decode(data)),\n ]));\n}\n","import SchemaTypes from '../SchemaTypes';\nimport { address, nameId, shortUIntConst } from '../field-types';\nimport {\n Encoded, Encoding, decode, encode,\n} from '../../../utils/encoder';\n\n/**\n * @category delegation signature\n */\nexport enum DelegationTag {\n AensWildcard = 1,\n AensName = 2,\n AensPreclaim = 3,\n Oracle = 4,\n OracleResponse = 5,\n}\n\nconst oracleAddressField = address(Encoding.OracleAddress);\nconst queryIdField = {\n serialize(value: Encoded.OracleQueryId): Buffer {\n return oracleAddressField.serialize(encode(decode(value), Encoding.OracleAddress));\n },\n deserialize(value: Buffer): Encoded.OracleQueryId {\n return encode(decode(oracleAddressField.deserialize(value)), Encoding.OracleQueryId);\n },\n} as const;\n\n/**\n * @see {@link https://github.com/aeternity/protocol/blob/8a9d1d1206174627f6aaef86159dc9c643080653/contracts/fate.md#from-ceres-serialized-signature-data}\n */\nexport const schemas = [{\n tag: shortUIntConst(DelegationTag.AensWildcard),\n version: shortUIntConst(1, true),\n accountAddress: address(Encoding.AccountAddress),\n contractAddress: address(Encoding.ContractAddress),\n}, {\n tag: shortUIntConst(DelegationTag.AensName),\n version: shortUIntConst(1, true),\n accountAddress: address(Encoding.AccountAddress),\n nameId,\n contractAddress: address(Encoding.ContractAddress),\n}, {\n tag: shortUIntConst(DelegationTag.AensPreclaim),\n version: shortUIntConst(1, true),\n accountAddress: address(Encoding.AccountAddress),\n contractAddress: address(Encoding.ContractAddress),\n}, {\n tag: shortUIntConst(DelegationTag.Oracle),\n version: shortUIntConst(1, true),\n accountAddress: address(Encoding.AccountAddress),\n contractAddress: address(Encoding.ContractAddress),\n}, {\n tag: shortUIntConst(DelegationTag.OracleResponse),\n version: shortUIntConst(1, true),\n queryId: queryIdField,\n contractAddress: address(Encoding.ContractAddress),\n}] as const;\n\ntype Schemas = SchemaTypes<typeof schemas>;\nexport type DlgParams = Schemas['TxParams'];\nexport type DlgUnpacked = Schemas['TxUnpacked'];\n","import { Encoded, Encoding } from '../../../utils/encoder';\nimport { packRecord, unpackRecord } from '../common';\nimport { DelegationTag, schemas } from './schema';\nimport { DlgParams, DlgUnpacked } from './schema.generated';\n\n/**\n * Pack delegation\n * @category delegation signature\n * @param params - Params of delegation\n * @returns Encoded delegation\n */\nexport function packDelegation(params: DlgParams): Encoded.Bytearray {\n return packRecord(schemas, DelegationTag, params, {}, Encoding.Bytearray);\n}\n\n/**\n * Unpack delegation\n * @category delegation signature\n * @param encoded - Encoded delegation\n * @param expectedTag - Expected delegation signature type\n * @returns Params of delegation\n */\nexport function unpackDelegation<T extends DelegationTag>(\n encoded: Encoded.Bytearray,\n expectedTag?: T,\n): DlgUnpacked & { tag: T } {\n return unpackRecord(schemas, DelegationTag, encoded, expectedTag, {}) as any;\n}\n","import AccountBase from './Base';\nimport {\n generateKeyPairFromSecret, sign, generateKeyPair, hash, messageToHash, messagePrefixLength,\n} from '../utils/crypto';\nimport { ArgumentError, UnexpectedTsError } from '../utils/errors';\nimport {\n decode, encode, Encoded, Encoding,\n} from '../utils/encoder';\nimport { concatBuffers } from '../utils/other';\nimport { hashTypedData, AciValue } from '../utils/typed-data';\nimport { buildTx } from '../tx/builder';\nimport { Tag, AensName, ConsensusProtocolVersion } from '../tx/builder/constants';\nimport { produceNameId } from '../tx/builder/helpers';\nimport { DelegationTag } from '../tx/builder/delegation/schema';\nimport { packDelegation } from '../tx/builder/delegation';\n\nconst secretKeys = new WeakMap<AccountMemory, Uint8Array>();\n\nexport function getBufferToSign(\n transaction: Encoded.Transaction,\n networkId: string,\n innerTx: boolean,\n): Uint8Array {\n const prefixes = [networkId];\n if (innerTx) prefixes.push('inner_tx');\n const rlpBinaryTx = decode(transaction);\n return concatBuffers([Buffer.from(prefixes.join('-')), hash(rlpBinaryTx)]);\n}\n\n/**\n * In-memory account class\n */\nexport default class AccountMemory extends AccountBase {\n override readonly address: Encoded.AccountAddress;\n\n /**\n * @param secretKey - Secret key\n */\n constructor(secretKey: string | Uint8Array) {\n super();\n secretKey = typeof secretKey === 'string' ? Buffer.from(secretKey, 'hex') : secretKey;\n if (secretKey.length !== 64) {\n throw new ArgumentError('secretKey', '64 bytes', secretKey.length);\n }\n secretKeys.set(this, secretKey);\n this.address = encode(\n generateKeyPairFromSecret(secretKey).publicKey,\n Encoding.AccountAddress,\n );\n }\n\n /**\n * Generates a new AccountMemory using a random secret key\n */\n static generate(): AccountMemory {\n return new AccountMemory(generateKeyPair().secretKey);\n }\n\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n override async sign(data: string | Uint8Array, options?: any): Promise<Uint8Array> {\n const secretKey = secretKeys.get(this);\n if (secretKey == null) throw new UnexpectedTsError();\n return sign(data, secretKey);\n }\n\n override async signTransaction(\n transaction: Encoded.Transaction,\n { innerTx, networkId, ...options }: { innerTx?: boolean; networkId?: string } = {},\n ): Promise<Encoded.Transaction> {\n if (networkId == null) {\n throw new ArgumentError('networkId', 'provided', networkId);\n }\n const rlpBinaryTx = decode(transaction);\n const txWithNetworkId = getBufferToSign(transaction, networkId, innerTx === true);\n\n const signatures = [await this.sign(txWithNetworkId, options)];\n return buildTx({ tag: Tag.SignedTx, encodedTx: rlpBinaryTx, signatures });\n }\n\n override async signMessage(message: string, options?: any): Promise<Uint8Array> {\n return this.sign(messageToHash(message), options);\n }\n\n override async signTypedData(\n data: Encoded.ContractBytearray,\n aci: AciValue,\n {\n name, version, networkId, contractAddress, ...options\n }: Parameters<AccountBase['signTypedData']>[2] = {},\n ): Promise<Encoded.Signature> {\n const dHash = hashTypedData(data, aci, {\n name, version, networkId, contractAddress,\n });\n const signature = await this.sign(dHash, options);\n return encode(signature, Encoding.Signature);\n }\n\n override async signDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n { networkId, consensusProtocolVersion, isOracle }: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n isOracle?: boolean;\n } = {},\n ): Promise<Encoded.Signature> {\n if (isOracle == null) {\n const protocol = (consensusProtocolVersion != null) ? ConsensusProtocolVersion[consensusProtocolVersion] : 'unknown';\n console.warn(`AccountMemory:signDelegationToContract: isOracle is not set. By default, sdk would generate an AENS preclaim delegation signature, but it won't be the same as the oracle delegation signature in Ceres (current protocol is ${protocol}).`);\n }\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: isOracle === true ? DelegationTag.Oracle : DelegationTag.AensPreclaim,\n accountAddress: this.address,\n contractAddress,\n });\n return this.signDelegation(delegation, { networkId });\n }\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n const payload = concatBuffers([\n Buffer.from(networkId),\n decode(this.address),\n decode(contractAddress),\n ]);\n const signature = await this.sign(payload);\n return encode(signature, Encoding.Signature);\n }\n\n override async signNameDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n name: AensName,\n { networkId, consensusProtocolVersion }: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n } = {},\n ): Promise<Encoded.Signature> {\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: DelegationTag.AensName, accountAddress: this.address, contractAddress, nameId: name,\n });\n return this.signDelegation(delegation, { networkId });\n }\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n const payload = concatBuffers([\n Buffer.from(networkId),\n decode(this.address),\n decode(produceNameId(name)),\n decode(contractAddress),\n ]);\n const signature = await this.sign(payload);\n return encode(signature, Encoding.Signature);\n }\n\n override async signAllNamesDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n { networkId, consensusProtocolVersion }: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n } = {},\n ): Promise<Encoded.Signature> {\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: DelegationTag.AensWildcard, accountAddress: this.address, contractAddress,\n });\n return this.signDelegation(delegation, { networkId });\n }\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n const payload = concatBuffers([\n Buffer.from(networkId),\n decode(this.address),\n Buffer.from('AENS'),\n decode(contractAddress),\n ]);\n const signature = await this.sign(payload);\n return encode(signature, Encoding.Signature);\n }\n\n override async signOracleQueryDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n oracleQueryId: Encoded.OracleQueryId,\n { networkId, consensusProtocolVersion }: {\n networkId?: string;\n consensusProtocolVersion?: ConsensusProtocolVersion;\n } = {},\n ): Promise<Encoded.Signature> {\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: DelegationTag.OracleResponse, queryId: oracleQueryId, contractAddress,\n });\n return this.signDelegation(delegation, { networkId });\n }\n const oracleQueryIdDecoded = decode(oracleQueryId);\n const addressDecoded = decode(this.address);\n // TODO: remove after fixing https://github.com/aeternity/aesophia/issues/475\n if (oracleQueryIdDecoded.compare(addressDecoded) === 0) {\n throw new ArgumentError('oracleQueryId', 'not equal to account address', oracleQueryId);\n }\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n const payload = concatBuffers([\n Buffer.from(networkId),\n oracleQueryIdDecoded,\n decode(contractAddress),\n ]);\n const signature = await this.sign(payload);\n return encode(signature, Encoding.Signature);\n }\n\n override async signDelegation(\n delegation: Encoded.Bytearray,\n { networkId }: { networkId?: string } = {},\n ): Promise<Encoded.Signature> {\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n const payload = concatBuffers([\n messagePrefixLength, new Uint8Array([1]), Buffer.from(networkId), decode(delegation),\n ]);\n const signature = await this.sign(payload);\n return encode(signature, Encoding.Signature);\n }\n}\n","import { Encoded } from '../utils/encoder';\nimport { buildTx, buildTxHash, unpackTx } from './builder';\nimport { Tag } from './builder/constants';\nimport { verify } from '../utils/crypto';\nimport { getBufferToSign } from '../account/Memory';\nimport { IllegalArgumentError, InternalError, TransactionError } from '../utils/errors';\nimport Node from '../Node';\nimport getTransactionSignerAddress from './transaction-signer';\n\n/**\n * Calculates the cost of transaction execution\n * Provides an upper cost of contract-call-related transactions because of `gasLimit`.\n * Also assumes that oracle query fee is 0 unless it is provided in options.\n *\n * The idea is that if you need to show transaction details with some accuracy you can define\n * expense fields that you want to show separately. And to show `getExecutionCost` result as a fee,\n * subtracting all fields shown separately.\n *\n * @example\n * ```vue\n * <template>\n * Amount: {{ txUnpacked.amount }}\n * Name fee: {{ txUnpacked.nameFee }}\n * Other fees: {{ getExecutionCost(txEncoded) - txUnpacked.amount - txUnpacked.nameFee }}\n * </template>\n * ```\n *\n * Doing this way you won't worry to show wrong fee for a transaction you may not support. Because\n * the SDK calculates the overall price of any transaction on its side.\n *\n * @param transaction - Transaction to calculate the cost of\n * @param options - Options\n * @param options.innerTx - Should be provided if transaction wrapped with Tag.PayingForTx\n * @param options.gasUsed - Amount of gas actually used to make calculation more accurate\n * @param options.queryFee - Oracle query fee\n * @param options.isInitiator - Is transaction signer an initiator of state channel\n */\nexport function getExecutionCost(\n transaction: Encoded.Transaction,\n {\n innerTx, gasUsed, queryFee, isInitiator,\n }: {\n innerTx?: 'fee-payer' | 'freeloader';\n gasUsed?: number;\n queryFee?: string;\n isInitiator?: boolean;\n } = {},\n): bigint {\n const params = unpackTx(transaction);\n if (params.tag === Tag.SignedTx) {\n throw new IllegalArgumentError('Transaction shouldn\\'t be a SignedTx, use `getExecutionCostBySignedTx` instead');\n }\n\n let res = 0n;\n if ('fee' in params && innerTx !== 'freeloader') {\n res += BigInt(params.fee);\n }\n if (params.tag === Tag.NameClaimTx) {\n res += BigInt(params.nameFee);\n }\n if (params.tag === Tag.OracleQueryTx) {\n res += BigInt(params.queryFee);\n }\n if (params.tag === Tag.OracleResponseTx) {\n res -= BigInt(queryFee ?? 0);\n }\n if (params.tag === Tag.ChannelSettleTx) {\n if (isInitiator === true) res -= BigInt(params.initiatorAmountFinal);\n if (isInitiator === false) res -= BigInt(params.responderAmountFinal);\n }\n if (\n ((params.tag === Tag.SpendTx && params.senderId !== params.recipientId)\n || params.tag === Tag.ContractCreateTx || params.tag === Tag.ContractCallTx\n || params.tag === Tag.ChannelDepositTx) && innerTx !== 'fee-payer'\n ) {\n res += BigInt(params.amount);\n }\n if (params.tag === Tag.ContractCreateTx) res += BigInt(params.deposit);\n if (\n (params.tag === Tag.ContractCreateTx || params.tag === Tag.ContractCallTx\n || params.tag === Tag.GaAttachTx || params.tag === Tag.GaMetaTx)\n && innerTx !== 'freeloader'\n ) {\n res += BigInt(params.gasPrice) * BigInt(gasUsed ?? params.gasLimit);\n }\n if (params.tag === Tag.GaMetaTx || params.tag === Tag.PayingForTx) {\n res += getExecutionCost(\n buildTx(params.tx.encodedTx),\n params.tag === Tag.PayingForTx ? { innerTx: 'fee-payer' } : {},\n );\n }\n return res;\n}\n\n/**\n * Calculates the cost of signed transaction execution\n * @param transaction - Transaction to calculate the cost of\n * @param networkId - Network id used to sign the transaction\n * @param options - Options\n */\nexport function getExecutionCostBySignedTx(\n transaction: Encoded.Transaction,\n networkId: string,\n options?: Omit<Parameters<typeof getExecutionCost>[1], 'innerTx'>,\n): bigint {\n const params = unpackTx(transaction, Tag.SignedTx);\n if (params.encodedTx.tag === Tag.GaMetaTx) {\n return getExecutionCost(buildTx(params.encodedTx), options);\n }\n\n const tx = buildTx(params.encodedTx);\n const address = getTransactionSignerAddress(tx);\n const [isInnerTx, isNotInnerTx] = [true, false]\n .map((f) => verify(getBufferToSign(tx, networkId, f), params.signatures[0], address));\n if (!isInnerTx && !isNotInnerTx) throw new TransactionError('Can\\'t verify signature');\n return getExecutionCost(\n buildTx(params.encodedTx),\n { ...isInnerTx && { innerTx: 'freeloader' }, ...options },\n );\n}\n\n/**\n * Calculates the cost of signed and not signed transaction execution using node\n * @param transaction - Transaction to calculate the cost of\n * @param node - Node to use\n * @param options - Options\n * @param options.isMined - Is transaction already mined or not\n */\nexport async function getExecutionCostUsingNode(\n transaction: Encoded.Transaction,\n node: Node,\n { isMined, ...options }: { isMined?: boolean } & Parameters<typeof getExecutionCost>[1] = {},\n): Promise<bigint> {\n let params = unpackTx(transaction);\n const isSignedTx = params.tag === Tag.SignedTx;\n const txHash = isSignedTx && isMined === true && buildTxHash(transaction);\n if (params.tag === Tag.SignedTx) params = params.encodedTx;\n\n // TODO: set gasUsed for PayingForTx after solving https://github.com/aeternity/aeternity/issues/4087\n if (\n options.gasUsed == null && txHash !== false\n && [Tag.ContractCreateTx, Tag.ContractCallTx, Tag.GaAttachTx, Tag.GaMetaTx].includes(params.tag)\n ) {\n const { callInfo, gaInfo } = await node.getTransactionInfoByHash(txHash);\n const combinedInfo = callInfo ?? gaInfo;\n if (combinedInfo == null) {\n throw new InternalError(`callInfo and gaInfo is not available for transaction ${txHash}`);\n }\n options.gasUsed = combinedInfo.gasUsed;\n }\n\n if (options.queryFee == null && Tag.OracleResponseTx === params.tag) {\n options.queryFee = (await node.getOracleByPubkey(params.oracleId)).queryFee.toString();\n }\n\n if (options.isInitiator == null && Tag.ChannelSettleTx === params.tag && isMined !== true) {\n const { initiatorId } = await node.getChannelByPubkey(params.channelId);\n options.isInitiator = params.fromId === initiatorId;\n }\n\n return isSignedTx\n ? getExecutionCostBySignedTx(transaction, await node.getNetworkId(), options)\n : getExecutionCost(transaction, options);\n}\n","import { RestError } from '@azure/core-rest-pipeline';\nimport { hash, isAddressValid, verify } from '../utils/crypto';\nimport { TxUnpacked } from './builder/schema.generated';\nimport { CtVersion, ProtocolToVmAbi } from './builder/field-types/ct-version';\nimport { Tag, ConsensusProtocolVersion } from './builder/constants';\nimport { buildTx, unpackTx } from './builder';\nimport { concatBuffers, isAccountNotFoundError } from '../utils/other';\nimport { Encoded, Encoding, decode } from '../utils/encoder';\nimport Node, { TransformNodeType } from '../Node';\nimport { Account } from '../apis/node';\nimport { genAggressiveCacheGetResponsesPolicy } from '../utils/autorest';\nimport { UnexpectedTsError } from '../utils/errors';\nimport getTransactionSignerAddress from './transaction-signer';\nimport { getExecutionCostUsingNode } from './execution-cost';\n\nexport interface ValidatorResult {\n message: string;\n key: string;\n checkedKeys: string[];\n}\n\ntype Validator = (\n tx: TxUnpacked,\n options: {\n // TODO: remove after fixing node types\n account: TransformNodeType<Account> & { id: Encoded.AccountAddress };\n nodeNetworkId: string;\n parentTxTypes: Tag[];\n node: Node;\n height: number;\n consensusProtocolVersion: ConsensusProtocolVersion;\n }\n) => ValidatorResult[] | Promise<ValidatorResult[]>;\n\nconst validators: Validator[] = [];\n\nasync function verifyTransactionInternal(\n tx: TxUnpacked,\n node: Node,\n parentTxTypes: Tag[],\n): Promise<ValidatorResult[]> {\n const address = getTransactionSignerAddress(buildTx(tx));\n const [account, { height }, { consensusProtocolVersion, nodeNetworkId }] = await Promise.all([\n node.getAccountByPubkey(address)\n .catch((error) => {\n if (!isAccountNotFoundError(error)) throw error;\n return { id: address, balance: 0n, nonce: 0 };\n })\n // TODO: remove after fixing https://github.com/aeternity/aepp-sdk-js/issues/1537\n .then((acc) => ({ ...acc, id: acc.id as Encoded.AccountAddress })),\n node.getCurrentKeyBlockHeight(), // TODO: don't request height on each validation, use caching\n node.getNodeInfo(),\n ]);\n\n return (await Promise.all(\n validators.map(async (v) => v(\n tx,\n {\n node, account, height, consensusProtocolVersion, nodeNetworkId, parentTxTypes,\n },\n )),\n )).flat();\n}\n\n/**\n * Transaction Validator\n * This function validates some transaction properties,\n * to make sure it can be posted it to the chain\n * @category transaction builder\n * @param transaction - Base64Check-encoded transaction\n * @param nodeNotCached - Node to validate transaction against\n * @returns Array with verification errors\n * @example const errors = await verifyTransaction(transaction, node)\n */\nexport default async function verifyTransaction(\n transaction: Parameters<typeof unpackTx>[0],\n nodeNotCached: Node,\n): Promise<ValidatorResult[]> {\n const node = new Node(nodeNotCached.$host, {\n ignoreVersion: true,\n pipeline: nodeNotCached.pipeline.clone(),\n additionalPolicies: [genAggressiveCacheGetResponsesPolicy()],\n });\n return verifyTransactionInternal(unpackTx(transaction), node, []);\n}\n\nvalidators.push(\n (tx, { account, nodeNetworkId, parentTxTypes }) => {\n if (tx.tag !== Tag.SignedTx) return [];\n const { encodedTx, signatures } = tx;\n if ((encodedTx ?? signatures) == null) return [];\n if (signatures.length !== 1) return []; // TODO: Support multisignature like in state channels\n const prefix = Buffer.from([\n nodeNetworkId,\n ...parentTxTypes.includes(Tag.PayingForTx) ? ['inner_tx'] : [],\n ].join('-'));\n const txBinary = decode(buildTx(encodedTx));\n const txWithNetworkId = concatBuffers([prefix, txBinary]);\n const txHashWithNetworkId = concatBuffers([prefix, hash(txBinary)]);\n if (verify(txWithNetworkId, signatures[0], account.id)\n || verify(txHashWithNetworkId, signatures[0], account.id)) return [];\n return [{\n message: 'Signature cannot be verified, please ensure that you transaction have'\n + ' the correct prefix and the correct private key for the sender address',\n key: 'InvalidSignature',\n checkedKeys: ['encodedTx', 'signatures'],\n }];\n },\n async (tx, { node, parentTxTypes }) => {\n let nestedTx;\n if ('encodedTx' in tx) nestedTx = tx.encodedTx;\n if ('tx' in tx) nestedTx = tx.tx;\n if (nestedTx == null) return [];\n return verifyTransactionInternal(nestedTx, node, [...parentTxTypes, tx.tag]);\n },\n (tx, { height }) => {\n if (!('ttl' in tx)) return [];\n if (tx.ttl === 0 || tx.ttl > height) return [];\n return [{\n message: `TTL ${tx.ttl} is already expired, current height is ${height}`,\n key: 'ExpiredTTL',\n checkedKeys: ['ttl'],\n }];\n },\n async (tx, { account, parentTxTypes, node }) => {\n if (parentTxTypes.length !== 0) return [];\n const cost = await getExecutionCostUsingNode(buildTx(tx), node).catch(() => 0n);\n if (cost <= account.balance) return [];\n return [{\n message: `Account balance ${account.balance} is not enough to execute the transaction that costs ${cost}`,\n key: 'InsufficientBalance',\n checkedKeys: ['amount', 'fee', 'nameFee', 'gasLimit', 'gasPrice'],\n }];\n },\n async (tx, { node }) => {\n if (tx.tag !== Tag.SpendTx || isAddressValid(tx.recipientId, Encoding.Name)) return [];\n const recipient = await node.getAccountByPubkey(tx.recipientId).catch((error) => {\n if (!isAccountNotFoundError(error)) throw error;\n return null;\n });\n if (recipient == null || recipient.payable === true) return [];\n return [{\n message: 'Recipient account is not payable',\n key: 'RecipientAccountNotPayable',\n checkedKeys: ['recipientId'],\n }];\n },\n (tx, { account }) => {\n let message;\n if (tx.tag === Tag.SignedTx && account.kind === 'generalized' && tx.signatures.length !== 0) {\n message = 'Generalized account can\\'t be used to generate SignedTx with signatures';\n }\n if (tx.tag === Tag.GaMetaTx && account.kind === 'basic') {\n message = 'Basic account can\\'t be used to generate GaMetaTx';\n }\n if (message == null) return [];\n return [{ message, key: 'InvalidAccountType', checkedKeys: ['tag'] }];\n },\n // TODO: revert nonce check\n // TODO: ensure nonce valid when paying for own tx\n (tx, { consensusProtocolVersion }) => {\n const oracleCall = Tag.OracleRegisterTx === tx.tag;\n const contractCreate = Tag.ContractCreateTx === tx.tag || Tag.GaAttachTx === tx.tag;\n const contractCall = Tag.ContractCallTx === tx.tag || Tag.GaMetaTx === tx.tag;\n const type = (oracleCall ? 'oracle-call' : null)\n ?? (contractCreate ? 'contract-create' : null)\n ?? (contractCall ? 'contract-call' : null);\n if (type == null) return [];\n const protocol = ProtocolToVmAbi[consensusProtocolVersion][type] as {\n abiVersion: readonly any[];\n vmVersion: readonly any[];\n };\n\n let ctVersion: Partial<CtVersion> | undefined;\n if ('abiVersion' in tx) ctVersion = { abiVersion: tx.abiVersion };\n if ('ctVersion' in tx) ctVersion = tx.ctVersion;\n if (ctVersion == null) throw new UnexpectedTsError();\n if (\n !protocol.abiVersion.includes(ctVersion.abiVersion)\n || (contractCreate && !protocol.vmVersion.includes(ctVersion.vmVersion))\n ) {\n return [{\n message: `ABI/VM version ${JSON.stringify(ctVersion)} is wrong, supported is: ${JSON.stringify(protocol)}`,\n key: 'VmAndAbiVersionMismatch',\n checkedKeys: ['ctVersion', 'abiVersion'],\n }];\n }\n return [];\n },\n async (tx, { node }) => {\n if (Tag.ContractCallTx !== tx.tag) return [];\n // TODO: remove after solving https://github.com/aeternity/aeternity/issues/3669\n if (tx.contractId.startsWith('nm_')) return [];\n try {\n const { active } = await node.getContract(tx.contractId);\n if (active) return [];\n return [{\n message: `Contract ${tx.contractId} is not active`,\n key: 'ContractNotActive',\n checkedKeys: ['contractId'],\n }];\n } catch (error) {\n if (!(error instanceof RestError) || error.response?.bodyAsText == null) throw error;\n return [{\n message: JSON.parse(error.response.bodyAsText).reason, // TODO: use parsedBody instead\n key: 'ContractNotFound',\n checkedKeys: ['contractId'],\n }];\n }\n },\n // TODO: move to fee field of tx builder after dropping Iris\n (tx, { consensusProtocolVersion }) => ((\n Tag.GaAttachTx === tx.tag\n && ConsensusProtocolVersion.Ceres === consensusProtocolVersion\n && tx.nonce !== 1\n ) ? [{\n message: `Account ${tx.ownerId} can't become generalized because it is already used`,\n key: 'AccountUsed',\n checkedKeys: ['nonce'],\n }]\n : []),\n);\n","import verifyTransaction, { ValidatorResult } from './tx/validator';\nimport { ensureError } from './utils/other';\nimport { TransactionError } from './utils/errors';\nimport Node, { TransformNodeType } from './Node';\nimport { SignedTx } from './apis/node';\nimport { Encoded } from './utils/encoder';\nimport AccountBase from './account/Base';\nimport { buildTxHash } from './tx/builder';\nimport { poll, waitForTxConfirm } from './chain';\n\n/**\n * @category exception\n */\nexport class InvalidTxError extends TransactionError {\n validation: ValidatorResult[];\n\n transaction: Encoded.Transaction;\n\n constructor(\n message: string,\n validation: ValidatorResult[],\n transaction: Encoded.Transaction,\n ) {\n super(message);\n this.name = 'InvalidTxError';\n this.validation = validation;\n this.transaction = transaction;\n }\n}\n\n/**\n * Signs and submits transaction for mining\n * @category chain\n * @param txUnsigned - Transaction to sign and submit\n * @param options - Options\n * @returns Transaction details\n */\nexport async function sendTransaction(\n txUnsigned: Encoded.Transaction,\n {\n onNode, onAccount, verify = true, waitMined = true, confirm, innerTx, ...options\n }:\n SendTransactionOptions,\n): Promise<SendTransactionReturnType> {\n const tx = await onAccount.signTransaction(txUnsigned, {\n ...options,\n onNode,\n innerTx,\n networkId: await onNode.getNetworkId(),\n });\n\n if (innerTx === true) return { hash: buildTxHash(tx), rawTx: tx };\n\n if (verify) {\n const validation = await verifyTransaction(tx, onNode);\n if (validation.length > 0) {\n const message = `Transaction verification errors: ${\n validation.map((v: { message: string }) => v.message).join(', ')}`;\n throw new InvalidTxError(message, validation, tx);\n }\n }\n\n try {\n let __queue;\n try {\n __queue = onAccount != null ? `tx-${onAccount.address}` : null;\n } catch (error) {\n __queue = null;\n }\n const { txHash } = await onNode.postTransaction({ tx }, {\n requestOptions: {\n customHeaders: {\n // TODO: remove __retry-code after fixing https://github.com/aeternity/aeternity/issues/3803\n '__retry-code': '400',\n ...__queue != null ? { __queue } : {},\n },\n },\n });\n\n if (waitMined) {\n const pollResult = await poll(txHash, { onNode, ...options });\n const txData = {\n ...pollResult,\n hash: pollResult.hash as Encoded.TxHash,\n rawTx: tx,\n };\n // wait for transaction confirmation\n if (confirm != null && +confirm > 0) {\n const c = typeof confirm === 'boolean' ? undefined : confirm;\n return {\n ...txData,\n confirmationHeight: await waitForTxConfirm(txHash, { onNode, confirm: c, ...options }),\n };\n }\n return txData;\n }\n return { hash: txHash, rawTx: tx };\n } catch (error) {\n ensureError(error);\n throw Object.assign(error, {\n rawTx: tx,\n verifyTx: async () => verifyTransaction(tx, onNode),\n });\n }\n}\n\ntype SendTransactionOptionsType = {\n /**\n * Node to use\n */\n onNode: Node;\n /**\n * Account to use\n */\n onAccount: AccountBase;\n /**\n * Verify transaction before broadcast, throw error if not\n */\n verify?: boolean;\n /**\n * Ensure that transaction get into block\n */\n waitMined?: boolean;\n /**\n * Number of micro blocks that should be mined after tx get included\n */\n confirm?: boolean | number;\n} & Parameters<typeof poll>[1] & Omit<Parameters<typeof waitForTxConfirm>[1], 'confirm'>\n& Parameters<AccountBase['signTransaction']>[1];\nexport interface SendTransactionOptions extends SendTransactionOptionsType {}\ninterface SendTransactionReturnType extends Partial<TransformNodeType<SignedTx>> {\n hash: Encoded.TxHash;\n // TODO: use `SignedTx.encodedTx` instead\n rawTx: Encoded.Transaction;\n confirmationHeight?: number;\n}\n","import canonicalize from 'canonicalize';\nimport AccountBase from '../account/Base';\nimport {\n Encoded, Encoding, decode, encode,\n} from './encoder';\nimport { verify } from './crypto';\nimport { ArgumentError, InvalidSignatureError } from './errors';\n\n// TODO: use Buffer.from(data, 'base64url') after solving https://github.com/feross/buffer/issues/309\nconst toBase64Url = (data: Buffer | Uint8Array | string): string => Buffer\n .from(data)\n .toString('base64')\n .replaceAll('/', '_')\n .replaceAll('+', '-')\n .replace(/=+$/, '');\n\nconst fromBase64Url = (data: string): Buffer => Buffer\n .from(data.replaceAll('_', '/').replaceAll('-', '+'), 'base64');\n\nconst objectToBase64Url = (data: any): string => toBase64Url(canonicalize(data) ?? '');\n\nconst header = 'eyJhbGciOiJFZERTQSIsInR5cCI6IkpXVCJ9'; // objectToBase64Url({ alg: 'EdDSA', typ: 'JWT' })\n\n/**\n * JWT including specific header\n * @category JWT\n */\nexport type Jwt = `${typeof header}.${string}.${string}`;\n\n/**\n * Generate a signed JWT\n * Provide `\"sub_jwk\": undefined` in payload to omit signer public key added by default.\n * @param originalPayload - Payload to sign\n * @param account - Account to sign by\n * @category JWT\n */\nexport async function signJwt(originalPayload: any, account: AccountBase): Promise<Jwt> {\n const payload = { ...originalPayload };\n if (!('sub_jwk' in payload)) {\n payload.sub_jwk = {\n kty: 'OKP',\n crv: 'Ed25519',\n x: toBase64Url(decode(account.address)),\n };\n }\n if (payload.sub_jwk === undefined) delete payload.sub_jwk;\n const body = `${header}.${objectToBase64Url(payload)}` as const;\n const signature = await account.sign(body);\n return `${body}.${toBase64Url(signature)}`;\n}\n\n/**\n * Unpack JWT. It will check signature if address or \"sub_jwk\" provided.\n * @param jwt - JWT to unpack\n * @param address - Address to check signature\n * @category JWT\n */\nexport function unpackJwt(jwt: Jwt, address?: Encoded.AccountAddress): {\n /**\n * JWT payload as object\n */\n payload: any;\n /**\n * Undefined returned in case signature is not checked\n */\n signer: Encoded.AccountAddress | undefined;\n} {\n const components = jwt.split('.');\n if (components.length !== 3) throw new ArgumentError('JWT components count', 3, components.length);\n const [h, payloadEncoded, signature] = components;\n if (h !== header) throw new ArgumentError('JWT header', header, h);\n const payload = JSON.parse(fromBase64Url(payloadEncoded).toString());\n const jwk = payload.sub_jwk ?? {};\n const signer = jwk.x == null || jwk.kty !== 'OKP' || jwk.crv !== 'Ed25519'\n ? address\n : encode(fromBase64Url(jwk.x), Encoding.AccountAddress);\n if (address != null && signer !== address) {\n throw new ArgumentError('address', `${signer} (\"sub_jwk\")`, address);\n }\n if (\n signer != null\n && !verify(Buffer.from(`${h}.${payloadEncoded}`), fromBase64Url(signature), signer)\n ) {\n throw new InvalidSignatureError(`JWT is not signed by ${signer}`);\n }\n return { payload, signer };\n}\n\n/**\n * Check is string a JWT or not. Use to validate the user input.\n * @param maybeJwt - A string to check\n * @returns True if argument is a JWT\n * @category JWT\n */\nexport function isJwt(maybeJwt: string): maybeJwt is Jwt {\n try {\n unpackJwt(maybeJwt as Jwt);\n return true;\n } catch (error) {\n return false;\n }\n}\n\n/**\n * Throws an error if argument is not JWT. Use to ensure that a value is JWT.\n * @param maybeJwt - A string to check\n * @category JWT\n */\nexport function ensureJwt(maybeJwt: string): asserts maybeJwt is Jwt {\n unpackJwt(maybeJwt as Jwt);\n}\n\n/**\n * Check is JWT signed by address from arguments or \"sub_jwk\"\n * @param jwt - JWT to check\n * @param address - Address to check signature\n * @category JWT\n */\nexport function verifyJwt(jwt: Jwt, address?: Encoded.AccountAddress): boolean {\n try {\n const { signer } = unpackJwt(jwt, address);\n return signer != null;\n } catch (error) {\n return false;\n }\n}\n","import nacl from 'tweetnacl';\nimport { v4 as uuid } from '@aeternity/uuid';\nimport { hash, argon2id } from '@aeternity/argon2';\nimport { getAddressFromPriv } from './crypto';\nimport { InvalidPasswordError } from './errors';\n\nconst DERIVED_KEY_FUNCTIONS = {\n async argon2id(\n pass: string | Uint8Array,\n salt: string | Uint8Array,\n params: Partial<Keystore['crypto']['kdf_params']>,\n ): Promise<Uint8Array> {\n const { memlimit_kib: memoryCost, opslimit: timeCost } = params;\n\n return hash(pass, {\n hashLength: 32,\n salt,\n timeCost,\n memoryCost,\n type: argon2id,\n });\n },\n};\n\nconst CRYPTO_FUNCTIONS = {\n 'xsalsa20-poly1305': {\n encrypt: nacl.secretbox,\n decrypt(...args: Parameters<typeof nacl.secretbox.open>): Uint8Array {\n const res = nacl.secretbox.open(...args);\n if (res == null) throw new InvalidPasswordError();\n return res;\n },\n },\n};\n\nexport interface Keystore {\n name: string;\n version: 1;\n public_key: string;\n id: string;\n crypto: {\n secret_type: 'ed25519';\n symmetric_alg: keyof typeof CRYPTO_FUNCTIONS;\n ciphertext: string;\n cipher_params: {\n nonce: string;\n };\n /**\n * Key derivation function name.\n */\n kdf: keyof typeof DERIVED_KEY_FUNCTIONS;\n /**\n * Key derivation function parameters.\n */\n kdf_params: {\n memlimit_kib: number;\n opslimit: number;\n parallelism: number;\n salt: string;\n };\n };\n}\n\nconst CRYPTO_DEFAULTS = {\n secret_type: 'ed25519',\n symmetric_alg: 'xsalsa20-poly1305',\n kdf: 'argon2id',\n kdf_params: {\n memlimit_kib: 65536,\n opslimit: 3,\n parallelism: 1,\n },\n} as const;\n\n/**\n * Symmetric private key encryption using secret (derived) key.\n * @category keystore\n * @param plaintext - Data to be encrypted.\n * @param key - Secret key.\n * @param nonce - Randomly generated nonce.\n * @param algo - Encryption algorithm.\n * @returns Encrypted data.\n */\nfunction encrypt(\n plaintext: Uint8Array,\n key: Uint8Array,\n nonce: Uint8Array,\n algo: keyof typeof CRYPTO_FUNCTIONS = CRYPTO_DEFAULTS.symmetric_alg,\n): Uint8Array {\n return CRYPTO_FUNCTIONS[algo].encrypt(plaintext, nonce, key);\n}\n\n/**\n * Symmetric private key decryption using secret (derived) key.\n * @category keystore\n * @param ciphertext - Data to be decrypted.\n * @param key - Secret key.\n * @param nonce - Nonce from key-object.\n * @param algo - Encryption algorithm.\n * @returns Decrypted data.\n */\nfunction decrypt(\n ciphertext: Uint8Array,\n key: Uint8Array,\n nonce: Uint8Array,\n algo: keyof typeof CRYPTO_FUNCTIONS = CRYPTO_DEFAULTS.symmetric_alg,\n): Uint8Array {\n return CRYPTO_FUNCTIONS[algo].decrypt(ciphertext, nonce, key);\n}\n\n/**\n * Derive secret key from password with key derivation function.\n * @category keystore\n * @param password - User-supplied password.\n * @param nonce - Randomly generated nonce.\n * @param kdf - Key derivation function.\n * @param kdfParams - KDF parameters.\n * @returns Secret key derived from password.\n */\nasync function deriveKey(\n password: string | Uint8Array,\n nonce: string | Uint8Array,\n kdf: Keystore['crypto']['kdf'],\n kdfParams: Omit<Keystore['crypto']['kdf_params'], 'salt'>,\n): Promise<Uint8Array> {\n return DERIVED_KEY_FUNCTIONS[kdf](password, nonce, kdfParams);\n}\n\n/**\n * Recover plaintext private key from secret-storage key object.\n * @category keystore\n * @param password - Keystore object password.\n * @param keystore - Keystore object.\n * @returns Plaintext private key.\n */\nexport async function recover(\n password: string | Uint8Array,\n { crypto }: Keystore,\n): Promise<string> {\n const salt = Buffer.from(crypto.kdf_params.salt, 'hex');\n return Buffer.from(decrypt(\n Buffer.from(crypto.ciphertext, 'hex'),\n await deriveKey(password, salt, crypto.kdf, crypto.kdf_params),\n Buffer.from(crypto.cipher_params.nonce, 'hex'),\n crypto.symmetric_alg,\n )).toString('hex');\n}\n\n/**\n * Export private key to keystore secret-storage format.\n * @category keystore\n * @param name - Key name.\n * @param password - User-supplied password.\n * @param privateKey - Private key as hex-string or a Buffer.\n * @param nonce - Randomly generated 24byte nonce.\n * @param salt - Randomly generated 16byte salt.\n * @param options - Encryption parameters.\n */\nexport async function dump(\n name: string,\n password: string | Uint8Array,\n privateKey: string | Uint8Array,\n nonce: Uint8Array = nacl.randomBytes(24),\n salt: Uint8Array = nacl.randomBytes(16),\n options?: Partial<Keystore['crypto']>,\n): Promise<Keystore> {\n const opt = { ...CRYPTO_DEFAULTS, ...options };\n const derivedKey = await deriveKey(password, salt, opt.kdf, opt.kdf_params);\n const payload = typeof privateKey === 'string' ? Buffer.from(privateKey, 'hex') : privateKey;\n return {\n name,\n version: 1,\n public_key: getAddressFromPriv(payload),\n id: uuid(),\n crypto: {\n secret_type: opt.secret_type,\n symmetric_alg: opt.symmetric_alg,\n ciphertext: Buffer.from(\n encrypt(payload, derivedKey, nonce, opt.symmetric_alg),\n ).toString('hex'),\n cipher_params: { nonce: Buffer.from(nonce).toString('hex') },\n kdf: opt.kdf,\n kdf_params: {\n ...opt.kdf_params,\n salt: Buffer.from(salt).toString('hex'),\n },\n },\n };\n}\n","import nacl from 'tweetnacl';\nimport { full as hmac } from 'tweetnacl-auth';\nimport { fromString } from 'bip32-path';\nimport aesjs from 'aes-js';\nimport { sha256hash, encode, Encoding } from './encoder';\nimport { CryptographyError } from './errors';\nimport { concatBuffers } from './other';\n\nconst Ecb = aesjs.ModeOfOperation.ecb;\n\n// TODO: use mnemonic encryption instead of AES\n/**\n * Encrypt given data using `password`\n * @param password - Password to encrypt with\n * @param binaryData - Data to encrypt\n * @returns Encrypted data\n */\nfunction encryptKey(password: string, binaryData: Uint8Array): Uint8Array {\n const hashedPasswordBytes = sha256hash(password);\n const aesEcb = new Ecb(hashedPasswordBytes);\n return aesEcb.encrypt(binaryData);\n}\n\n/**\n * Decrypt given data using `password`\n * @param password - Password to decrypt with\n * @param encrypted - Data to decrypt\n * @returns Decrypted data\n */\nfunction decryptKey(password: string, encrypted: Uint8Array): Uint8Array {\n const encryptedBytes = Buffer.from(encrypted);\n const hashedPasswordBytes = sha256hash(password);\n const aesEcb = new Ecb(hashedPasswordBytes);\n return aesEcb.decrypt(encryptedBytes);\n}\n\n/**\n * @category exception\n */\nexport class DerivationError extends CryptographyError {\n constructor(message: string) {\n super(message);\n this.name = 'DerivationError';\n }\n}\n\nconst ED25519_CURVE = Buffer.from('ed25519 seed');\nconst HARDENED_OFFSET = 0x80000000;\n\ninterface KeyTreeNode {\n secretKey: Uint8Array;\n chainCode: Uint8Array;\n}\n\ninterface HDWallet {\n secretKey: string;\n chainCode: string;\n}\n\ninterface Account {\n secretKey: string;\n publicKey: string;\n}\n\ntype Dec<N extends number> = [-1, 0, 1, 2, 3, 4][N];\ntype Bip32PathT<MaxLen extends number, H extends 'H' | 'h' | '\\''> = MaxLen extends -1\n ? `${number}${H}`\n : Bip32PathT<Dec<MaxLen>, H> | `${Bip32PathT<Dec<MaxLen>, H>}/${number}${H}`;\ntype Bip32Path<MaxLen extends number> =\n '' | Bip32PathT<MaxLen, 'H'> | Bip32PathT<MaxLen, 'h'> | Bip32PathT<MaxLen, '\\''>;\n\n/**\n * @category hd-wallet\n * @param keyTreeNode - A node of key tree\n * @param index - index of child node to derive\n */\nexport function deriveChild({ secretKey, chainCode }: KeyTreeNode, index: number): KeyTreeNode {\n if (index < HARDENED_OFFSET) {\n throw new DerivationError(`Segment ${index} is not hardened`);\n }\n const indexBuffer = Buffer.allocUnsafe(4);\n indexBuffer.writeUInt32BE(index, 0);\n\n const data = concatBuffers([Buffer.alloc(1, 0), secretKey, indexBuffer]);\n\n const I = hmac(data, chainCode);\n const IL = I.slice(0, 32);\n const IR = I.slice(32);\n return {\n secretKey: IL,\n chainCode: IR,\n };\n}\n\n/**\n * @category hd-wallet\n */\nexport function derivePathFromKey(path: Bip32Path<5>, key: KeyTreeNode): KeyTreeNode {\n const segments = path === '' ? [] : fromString(path).toPathArray();\n segments.forEach((segment, i) => {\n if (segment < HARDENED_OFFSET) {\n throw new DerivationError(`Segment #${i + 1} is not hardened`);\n }\n });\n\n return segments.reduce((parentKey, segment) => deriveChild(parentKey, segment), key);\n}\n\n/**\n * @category hd-wallet\n */\nexport function getMasterKeyFromSeed(seed: Uint8Array): KeyTreeNode {\n const I = hmac(seed, ED25519_CURVE);\n const IL = I.slice(0, 32);\n const IR = I.slice(32);\n return {\n secretKey: IL,\n chainCode: IR,\n };\n}\n\n/**\n * @category hd-wallet\n */\nexport function derivePathFromSeed(path: 'm' | `m/${Bip32Path<5>}`, seed: Uint8Array): KeyTreeNode {\n if (!['m', 'm/'].includes(path.slice(0, 2))) {\n throw new DerivationError('Root element is required');\n }\n const masterKey = getMasterKeyFromSeed(seed);\n return derivePathFromKey(path.slice(2) as Bip32Path<5>, masterKey);\n}\n\nfunction formatAccount(keys: nacl.SignKeyPair): Account {\n const { secretKey, publicKey } = keys;\n return {\n secretKey: Buffer.from(secretKey).toString('hex'),\n publicKey: encode(publicKey, Encoding.AccountAddress),\n };\n}\n\n/**\n * @category hd-wallet\n */\nexport function getKeyPair(secretKey: Uint8Array): nacl.SignKeyPair {\n return nacl.sign.keyPair.fromSeed(secretKey);\n}\n\n/**\n * @category hd-wallet\n */\nexport function generateSaveHDWalletFromSeed(seed: Uint8Array, password: string): HDWallet {\n const walletKey = derivePathFromSeed('m/44h/457h', seed);\n return {\n secretKey: Buffer.from(encryptKey(password, walletKey.secretKey)).toString('hex'),\n chainCode: Buffer.from(encryptKey(password, walletKey.chainCode)).toString('hex'),\n };\n}\n\n/**\n * @category hd-wallet\n */\nexport function getSaveHDWalletAccounts(\n saveHDWallet: HDWallet,\n password: string,\n accountCount: number,\n): Account[] {\n const walletKey = {\n secretKey: decryptKey(password, Buffer.from(saveHDWallet.secretKey, 'hex')),\n chainCode: decryptKey(password, Buffer.from(saveHDWallet.chainCode, 'hex')),\n };\n return (new Array(accountCount)).fill(undefined)\n .map((_, idx) => formatAccount(getKeyPair(derivePathFromKey(`${idx}h/0h/0h`, walletKey).secretKey)));\n}\n\n/**\n * @category hd-wallet\n */\nexport const getHdWalletAccountFromSeed = (\n seed: Uint8Array,\n accountIdx: number,\n): Account & { idx: number } => {\n const walletKey = derivePathFromSeed('m/44h/457h', seed);\n const derived = derivePathFromKey(`${accountIdx}h/0h/0h`, walletKey);\n const keyPair = getKeyPair(derived.secretKey);\n return {\n ...formatAccount(keyPair),\n idx: accountIdx,\n };\n};\n","/**\n * Aens methods - routines to interact with the æternity naming system\n *\n * The high-level description of the naming system is\n * https://github.com/aeternity/protocol/blob/master/AENS.md in the protocol\n * repository.\n */\n\nimport BigNumber from 'bignumber.js';\nimport { genSalt, isAddressValid } from './utils/crypto';\nimport { commitmentHash, isAuctionName } from './tx/builder/helpers';\nimport { Tag, AensName, ConsensusProtocolVersion } from './tx/builder/constants';\nimport { Encoded, Encoding } from './utils/encoder';\nimport { UnsupportedProtocolError } from './utils/errors';\nimport { getName } from './chain';\nimport { sendTransaction, SendTransactionOptions } from './send-transaction';\nimport { buildTxAsync, BuildTxOptions } from './tx/builder';\nimport { TransformNodeType } from './Node';\nimport { NameEntry, NamePointer } from './apis/node';\nimport AccountBase from './account/Base';\nimport { AddressEncodings } from './tx/builder/field-types/address';\n\ninterface KeyPointers {\n [key: string]: Encoded.Generic<AddressEncodings | Encoding.Bytearray>;\n}\n\n/**\n * Revoke a name\n * @category AENS\n * @param name - Name hash\n * @param options - Options\n * @returns Transaction result\n * @example\n * ```js\n * const name = 'test.chain'\n * const nameObject = await sdkInstance.aensQuery(name)\n *\n * await sdkInstance.aensRevoke(name, { fee, ttl , nonce })\n * // or\n * await nameObject.revoke({ fee, ttl, nonce })\n * ```\n */\nexport async function aensRevoke(\n name: AensName,\n options: AensRevokeOptions,\n): ReturnType<typeof sendTransaction> {\n const nameRevokeTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.NameRevokeTx,\n nameId: name,\n accountId: options.onAccount.address,\n });\n return sendTransaction(nameRevokeTx, options);\n}\n\ninterface AensRevokeOptions extends\n BuildTxOptions<Tag.NameRevokeTx, 'nameId' | 'accountId' | 'onNode'>,\n SendTransactionOptions {}\n\n/**\n * Update a name\n * @category AENS\n * @param name - AENS name\n * @param pointers - Map of pointer keys to corresponding addresses\n * @param options - Options\n * @throws Invalid pointer array error\n * @example\n * ```js\n * const name = 'test.chain'\n * const pointersArray = ['ak_asd23dasdas...,' 'ct_asdf34fasdasd...']\n * const nameObject = await sdkInstance.aensQuery(name)\n *\n * await sdkInstance.aensUpdate(name, pointersArray, { nameTtl, ttl, fee, nonce, clientTtl })\n * // or\n * await nameObject.update(pointers, { nameTtl, ttl, fee, nonce, clientTtl })\n * ```\n */\nexport async function aensUpdate(\n name: AensName,\n pointers: KeyPointers,\n { extendPointers, ...options }: AensUpdateOptions,\n): ReturnType<typeof sendTransaction> {\n const allPointers = {\n ...extendPointers === true && Object.fromEntries(\n (await getName(name, options)).pointers.map(({ key, id }) => [key, id]),\n ),\n ...pointers,\n };\n\n const hasRawPointers = Object.values(allPointers)\n .some((v) => isAddressValid(v, Encoding.Bytearray));\n const isIris = (await options.onNode.getNodeInfo())\n .consensusProtocolVersion === ConsensusProtocolVersion.Iris;\n if (hasRawPointers && isIris) {\n throw new UnsupportedProtocolError('Raw pointers are available only in Ceres, the current protocol is Iris');\n }\n\n const nameUpdateTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.NameUpdateTx,\n version: hasRawPointers ? 2 : 1,\n nameId: name,\n accountId: options.onAccount.address,\n pointers: Object.entries(allPointers)\n .map(([key, id]: [string, Encoded.Generic<AddressEncodings>]) => ({ key, id })),\n });\n\n return sendTransaction(nameUpdateTx, options);\n}\n\ninterface AensUpdateOptions extends\n BuildTxOptions<Tag.NameUpdateTx, 'nameId' | 'accountId' | 'pointers' | 'clientTtl' | 'nameTtl' | 'onNode'>,\n SendTransactionOptions {\n /**\n * Get the pointers from the node and merge with provided ones. Pointers with the same key will be\n * overwritten.\n */\n extendPointers?: boolean;\n /**\n * a suggestion as to how long any clients should cache this information\n */\n clientTtl?: number;\n /**\n * Name ttl represented in number of blocks (Max value is 50000 blocks)\n */\n nameTtl?: number;\n}\n\n/**\n * Transfer a domain to another account\n * @category AENS\n * @param name - AENS name\n * @param account - Recipient account publick key\n * @param options - Options\n * @returns Transaction result\n * @example\n * ```js\n * const name = 'test.chain'\n * const recipientPub = 'ak_asd23dasdas...'\n * const nameObject = await sdkInstance.aensQuery(name)\n *\n * await sdkInstance.aensTransfer(name, recipientPub, { ttl, fee, nonce })\n * // or\n * await nameObject.transfer(recipientPub, { ttl, fee, nonce })\n * ```\n */\nexport async function aensTransfer(\n name: AensName,\n account: Encoded.AccountAddress,\n options: AensTransferOptions,\n): ReturnType<typeof sendTransaction> {\n const nameTransferTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.NameTransferTx,\n nameId: name,\n accountId: options.onAccount.address,\n recipientId: account,\n });\n\n return sendTransaction(nameTransferTx, options);\n}\n\ninterface AensTransferOptions extends\n BuildTxOptions<Tag.NameTransferTx, 'nameId' | 'accountId' | 'recipientId' | 'onNode'>,\n SendTransactionOptions {}\n\n/**\n * Query the AENS name info from the node\n * and return the object with info and predefined functions for manipulating name\n * @category AENS\n * @param name - AENS name\n * @param opt - Options\n * @example\n * ```js\n * const nameObject = sdkInstance.aensQuery('test.chain')\n * console.log(nameObject)\n * {\n * id, // name hash\n * pointers, // array of pointers\n * update, // Update name function\n * extendTtl, // Extend Ttl name function\n * transfer, // Transfer name function\n * revoke // Revoke name function\n * }\n * ```\n */\nexport async function aensQuery(\n name: AensName,\n opt: Parameters<typeof getName>[1] & Parameters<typeof aensUpdate>[2]\n & Parameters<typeof aensTransfer>[2],\n): Promise<Readonly<\n TransformNodeType<NameEntry> & {\n id: Encoded.Name;\n owner: Encoded.AccountAddress;\n pointers: KeyPointers | NamePointer[];\n ttl: number;\n update: (\n pointers: KeyPointers,\n options?: Omit<Parameters<typeof aensQuery>[1], 'onNode' | 'onCompiler' | 'onAccount'> & {\n onAccount?: AccountBase;\n }\n ) => ReturnType<typeof aensUpdate> & ReturnType<typeof aensQuery>;\n transfer: (\n account: Encoded.AccountAddress,\n options?: Parameters<typeof aensQuery>[1]\n ) => ReturnType<typeof aensUpdate> & ReturnType<typeof aensQuery>;\n revoke: (options?: Omit<Parameters<typeof aensRevoke>[1], 'onNode' | 'onCompiler' | 'onAccount'> & {\n onAccount?: AccountBase;\n }\n ) => ReturnType<typeof aensRevoke>;\n extendTtl: (\n nameTtl?: number,\n options?: Omit<Parameters<typeof aensQuery>[1], 'onNode' | 'onCompiler' | 'onAccount'>\n ) => ReturnType<typeof aensUpdate> & ReturnType<typeof aensQuery>;\n }\n >> {\n const nameEntry = await getName(name, opt);\n return Object.freeze({\n ...nameEntry,\n id: nameEntry.id as Encoded.Name,\n owner: nameEntry.owner as Encoded.AccountAddress,\n async update(pointers, options) {\n return {\n ...await aensUpdate(name, pointers, { ...opt, ...options }),\n ...await aensQuery(name, { ...opt, ...options }),\n };\n },\n async transfer(account, options) {\n return {\n ...await aensTransfer(name, account, { ...opt, ...options }),\n ...await aensQuery(name, { ...opt, ...options }),\n };\n },\n async revoke(options) {\n return aensRevoke(name, { ...opt, ...options });\n },\n async extendTtl(nameTtl, options = {}) {\n return {\n ...await aensUpdate(name, {}, {\n ...opt, ...options, nameTtl, extendPointers: true,\n }),\n ...await aensQuery(name, { ...opt, ...options }),\n };\n },\n });\n}\n\n/**\n * Claim a previously preclaimed registration. This can only be done after the\n * preclaim step\n * @category AENS\n * @param name - AENS name\n * @param salt - Salt from pre-claim, or 0 if it's a bid or claiming without preclaim (in Ceres)\n * @param options - options\n * @returns Transaction result\n * @example\n * ```js\n * const name = 'test.chain'\n * const salt = preclaimResult.salt // salt from pre-claim transaction\n *\n * await sdkInstance.aensClaim(name, salt, { ttl, fee, nonce, nameFee })\n * ```\n */\nexport async function aensClaim(\n name: AensName,\n salt: number,\n options: AensClaimOptions,\n): Promise<AensClaimReturnType> {\n const claimTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.NameClaimTx,\n accountId: options.onAccount.address,\n nameSalt: salt,\n name,\n });\n\n const result = await sendTransaction(claimTx, options);\n if (!isAuctionName(name)) {\n const nameInter = result.blockHeight != null && result.blockHeight > 0\n ? await aensQuery(name, options)\n : {};\n return Object.assign(result, nameInter);\n }\n return result;\n}\n\ntype AensClaimOptionsType = BuildTxOptions<Tag.NameClaimTx, 'accountId' | 'nameSalt' | 'name'>\n& SendTransactionOptions & Parameters<typeof aensQuery>[1];\ninterface AensClaimOptions extends AensClaimOptionsType {}\ninterface AensClaimReturnType extends\n Awaited<ReturnType<typeof sendTransaction>>,\n Partial<Awaited<ReturnType<typeof aensQuery>>> {}\n\n/**\n * Preclaim a name. Sends a hash of the name and a random salt to the node\n * @category AENS\n * @param name - AENS name\n * @param options - Options\n * @example\n * ```js\n * const name = 'test.chain'\n * const salt = preclaimResult.salt // salt from pre-claim transaction\n *\n * await sdkInstance.aensPreclaim(name, { ttl, fee, nonce })\n * {\n * ...transactionResult,\n * claim, // Claim function (options={}) => claimTransactionResult\n * salt,\n * commitmentId\n * }\n * ```\n */\nexport async function aensPreclaim(name: AensName, options: AensPreclaimOptions): Promise<Readonly<\nAwaited<ReturnType<typeof sendTransaction>> & {\n salt: number;\n commitmentId: string;\n claim: (opts?: Parameters<typeof aensClaim>[2]) => ReturnType<typeof aensClaim>;\n}\n>> {\n const salt = genSalt();\n const commitmentId = commitmentHash(name, salt);\n\n const preclaimTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.NamePreclaimTx,\n accountId: options.onAccount.address,\n commitmentId,\n });\n\n return Object.freeze({\n ...await sendTransaction(preclaimTx, options),\n salt,\n commitmentId,\n async claim(opts?: Parameters<typeof aensClaim>[2]) {\n const { version, ...otherOptions } = options;\n return aensClaim(name, salt, { ...otherOptions, ...opts });\n },\n });\n}\n\ninterface AensPreclaimOptions extends\n BuildTxOptions<Tag.NamePreclaimTx, 'accountId' | 'commitmentId' | 'onNode'>,\n SendTransactionOptions,\n Omit<AensClaimOptions, 'version'> {}\n\n/**\n * Bid to name auction\n * @category AENS\n * @param name - Domain name\n * @param nameFee - Name fee (bid fee)\n * @param options - Options\n * @returns Transaction result\n * @example\n * ```js\n * const name = 'test.chain'\n * const bidFee = computeBidFee(name, { startFee, increment: 0.42 })\n *\n * await sdkInstance.aensBid(name, 213109412839123, { ttl, fee, nonce })\n * ```\n */\nexport async function aensBid(\n name: AensName,\n nameFee: number | string | BigNumber,\n options: Omit<Parameters<typeof aensClaim>[2], 'nameFee'>,\n): ReturnType<typeof aensClaim> {\n return aensClaim(name, 0, { ...options, nameFee });\n}\n","/**\n * Contract module - routines to interact with the æternity contract\n *\n * High level documentation of the contracts are available at\n * https://github.com/aeternity/protocol/tree/master/contracts and\n */\n\nimport { Encoder as Calldata } from '@aeternity/aepp-calldata';\nimport {\n Tag, AensName, ConsensusProtocolVersion, DRY_RUN_ACCOUNT,\n} from '../tx/builder/constants';\nimport {\n buildContractIdByContractTx, unpackTx, buildTxAsync, BuildTxOptions, buildTxHash,\n} from '../tx/builder';\nimport { decode, Encoded } from '../utils/encoder';\nimport {\n MissingContractDefError,\n MissingContractAddressError,\n InactiveContractError,\n BytecodeMismatchError,\n DuplicateContractError,\n MissingFunctionNameError,\n InvalidMethodInvocationError,\n NotPayableFunctionError,\n TypeError,\n NodeInvocationError,\n IllegalArgumentError,\n NoSuchContractFunctionError,\n MissingEventDefinitionError,\n AmbiguousEventDefinitionError,\n UnexpectedTsError,\n InternalError,\n NoWalletConnectedError,\n ContractError,\n} from '../utils/errors';\nimport { hash as calcHash } from '../utils/crypto';\nimport {\n ContractCallObject as NodeContractCallObject, Event as NodeEvent,\n} from '../apis/node';\nimport CompilerBase, { Aci } from './compiler/Base';\nimport Node, { TransformNodeType } from '../Node';\nimport {\n getAccount, getContract, getContractByteCode, resolveName, txDryRun,\n} from '../chain';\nimport { sendTransaction, SendTransactionOptions } from '../send-transaction';\nimport AccountBase from '../account/Base';\nimport { TxUnpacked } from '../tx/builder/schema.generated';\nimport { isAccountNotFoundError } from '../utils/other';\nimport { isNameValid, produceNameId } from '../tx/builder/helpers';\n\ntype ContractAci = NonNullable<Aci[0]['contract']>;\ntype FunctionAci = ContractAci['functions'][0];\n\ninterface Event extends NodeEvent {\n address: Encoded.ContractAddress;\n data: Encoded.ContractBytearray;\n}\n\nexport interface ContractCallObject extends TransformNodeType<NodeContractCallObject> {\n returnValue: Encoded.ContractBytearray;\n log: Event[];\n}\n\ninterface DecodedEvent {\n name: string;\n args: unknown[];\n contract: {\n name: string;\n address: Encoded.ContractAddress;\n };\n}\n\ntype TxData = Awaited<ReturnType<typeof sendTransaction>>;\n\ninterface SendAndProcessReturnType {\n result?: ContractCallObject;\n hash: TxData['hash'];\n tx: TxUnpacked & { tag: Tag.SignedTx | Tag.ContractCallTx | Tag.ContractCreateTx };\n txData: TxData;\n rawTx: Encoded.Transaction;\n}\n\nexport interface ContractMethodsBase { [key: string]: (...args: any[]) => any }\n\ntype MethodsToContractApi<M extends ContractMethodsBase> = {\n [Name in keyof M]:\n M[Name] extends (...args: infer Args) => any\n ? (...args: [\n ...Args,\n ...[] | [Name extends 'init'\n ? Parameters<Contract<M>['$deploy']>[1] : Parameters<Contract<M>['$call']>[2]],\n ]) => ReturnType<Contract<M>['$call']>\n : never\n};\n\ntype ContractWithMethods<M extends ContractMethodsBase> = Contract<M> & MethodsToContractApi<M>;\n\ntype MethodNames<M extends ContractMethodsBase> = keyof M & string | 'init';\n\ntype MethodParameters<M extends ContractMethodsBase, Fn extends MethodNames<M>> =\n Fn extends 'init'\n ? M extends { init: any } ? Parameters<M['init']> : []\n : Parameters<M[Fn]>;\n\ninterface GetContractNameByEventOptions {\n contractAddressToName?: { [key: Encoded.ContractAddress]: string };\n}\n\ninterface GetCallResultByHashReturnType<M extends ContractMethodsBase, Fn extends MethodNames<M>> {\n decodedResult: ReturnType<M[Fn]>;\n decodedEvents?: ReturnType<Contract<M>['$decodeEvents']>;\n}\n\n/**\n * Generate contract ACI object with predefined js methods for contract usage - can be used for\n * creating a reference to already deployed contracts\n * @category contract\n * @param options - Options object\n * @returns JS Contract API\n * @example\n * ```js\n * const contractIns = await aeSdk.initializeContract({ sourceCode })\n * await contractIns.$deploy([321]) or await contractIns.init(321)\n * const callResult = await contractIns.$call('setState', [123])\n * const staticCallResult = await contractIns.$call('setState', [123], { callStatic: true })\n * ```\n * Also you can call contract like: `await contractIns.setState(123, options)`\n * Then sdk decide to make on-chain or static call (dry-run API) transaction based on function is\n * stateful or not\n */\nclass Contract<M extends ContractMethodsBase> {\n /**\n * Compile contract\n * @returns bytecode\n */\n async $compile(): Promise<Encoded.ContractBytearray> {\n if (this.$options.bytecode != null) return this.$options.bytecode;\n if (this.$options.onCompiler == null) throw new IllegalArgumentError('Can\\'t compile without compiler');\n if (this.$options.sourceCode != null) {\n const { bytecode } = await this.$options.onCompiler\n .compileBySourceCode(this.$options.sourceCode, this.$options.fileSystem);\n this.$options.bytecode = bytecode;\n }\n if (this.$options.sourceCodePath != null) {\n const { bytecode } = await this.$options.onCompiler.compile(this.$options.sourceCodePath);\n this.$options.bytecode = bytecode;\n }\n if (this.$options.bytecode == null) {\n throw new IllegalArgumentError('Can\\'t compile without sourceCode and sourceCodePath');\n }\n return this.$options.bytecode;\n }\n\n #getCallResult<Fn extends MethodNames<M>>(\n { returnType, returnValue, log }: ContractCallObject,\n fnName: Fn,\n transaction: Encoded.Transaction | undefined,\n options: Parameters<Contract<M>['$decodeEvents']>[1],\n ): GetCallResultByHashReturnType<M, Fn> {\n let message: string;\n switch (returnType) {\n case 'ok': {\n const fnAci = this.#getFunctionAci(fnName);\n return {\n decodedResult: this._calldata.decode(this._name, fnAci.name, returnValue),\n decodedEvents: this.$decodeEvents(log, options),\n };\n }\n case 'revert':\n message = this._calldata.decodeFateString(returnValue);\n break;\n case 'error':\n message = decode(returnValue).toString();\n if (/Expected \\d+ arguments, got \\d+/.test(message)) {\n throw new ContractError(`ACI doesn't match called contract. Error provided by node: ${message}`);\n }\n break;\n default:\n throw new InternalError(`Unknown return type: ${returnType}`);\n }\n throw new NodeInvocationError(message, transaction);\n }\n\n async #sendAndProcess<Fn extends MethodNames<M>>(\n tx: Encoded.Transaction,\n fnName: Fn,\n options: SendTransactionOptions & Parameters<Contract<M>['$getCallResultByTxHash']>[2],\n ): Promise<SendAndProcessReturnType & Partial<GetCallResultByHashReturnType<M, Fn>>> {\n const txData = await sendTransaction(tx, { ...this.$options, ...options });\n return {\n hash: txData.hash,\n tx: unpackTx<Tag.ContractCallTx | Tag.ContractCreateTx>(txData.rawTx),\n txData,\n rawTx: txData.rawTx,\n ...txData.blockHeight != null && (\n await this.$getCallResultByTxHash(txData.hash, fnName, options)\n ),\n };\n }\n\n async $getCallResultByTxHash<Fn extends MethodNames<M>>(\n hash: Encoded.TxHash,\n fnName: Fn,\n options?: Parameters<Contract<M>['$decodeEvents']>[1],\n ): Promise<GetCallResultByHashReturnType<M, Fn> & { result: ContractCallObject }> {\n const { callInfo } = await this.$options.onNode.getTransactionInfoByHash(hash);\n if (callInfo == null) {\n throw new ContractError(`callInfo is not available for transaction ${hash}`);\n }\n const callInfoTyped = callInfo as ContractCallObject;\n return {\n ...this.#getCallResult(callInfoTyped, fnName, undefined, options),\n result: callInfoTyped,\n };\n }\n\n async _estimateGas<Fn extends MethodNames<M>>(\n name: Fn,\n params: MethodParameters<M, Fn>,\n options: Omit<Parameters<Contract<M>['$call']>[2], 'callStatic'> = {},\n ): Promise<number> {\n const { result } = await this.$call(name, params, { ...options, callStatic: true });\n if (result == null) throw new UnexpectedTsError();\n const { gasUsed } = result;\n // taken from https://github.com/aeternity/aepp-sdk-js/issues/1286#issuecomment-977814771\n return Math.floor(gasUsed * 1.25);\n }\n\n /**\n * Deploy contract\n * @param params - Contract init function arguments array\n * @param options - Options\n * @returns deploy info\n */\n async $deploy(\n params: MethodParameters<M, 'init'>,\n options?: Parameters<Contract<M>['$call']>[2]\n & Partial<BuildTxOptions<Tag.ContractCreateTx, 'ownerId' | 'code' | 'callData'>>,\n ): Promise<Omit<SendAndProcessReturnType, 'hash'> & {\n transaction?: Encoded.TxHash;\n owner?: Encoded.AccountAddress;\n address?: Encoded.ContractAddress;\n decodedEvents?: ReturnType<Contract<M>['$decodeEvents']>;\n }> {\n const { callStatic, ...opt } = { ...this.$options, ...options };\n if (this.$options.bytecode == null) await this.$compile();\n if (callStatic === true) return this.$call('init', params, { ...opt, callStatic });\n if (this.$options.address != null) throw new DuplicateContractError();\n\n if (opt.onAccount == null) throw new IllegalArgumentError('Can\\'t deploy without account');\n const ownerId = opt.onAccount.address;\n if (this.$options.bytecode == null) throw new IllegalArgumentError('Can\\'t deploy without bytecode');\n const tx = await buildTxAsync({\n _isInternalBuild: true,\n ...opt,\n tag: Tag.ContractCreateTx,\n gasLimit: opt.gasLimit ?? await this._estimateGas('init', params, opt),\n callData: this._calldata.encode(this._name, 'init', params),\n code: this.$options.bytecode,\n ownerId,\n });\n const { hash, ...other } = await this.#sendAndProcess(\n tx,\n 'init',\n { ...opt, onAccount: opt.onAccount },\n );\n this.$options.address = buildContractIdByContractTx(other.rawTx);\n return {\n ...other,\n ...other.result?.log != null && {\n decodedEvents: this.$decodeEvents(other.result.log, opt),\n },\n owner: ownerId,\n transaction: hash,\n address: this.$options.address,\n };\n }\n\n /**\n * Get function schema from contract ACI object\n * @param name - Function name\n * @returns function ACI\n */\n #getFunctionAci(name: string): FunctionAci {\n const fn = this.#aciContract.functions.find(\n (f: { name: string }) => f.name === name,\n );\n if (fn != null) {\n return fn;\n }\n if (name === 'init') {\n return {\n arguments: [], name: 'init', payable: false, returns: 'unit', stateful: true,\n };\n }\n throw new NoSuchContractFunctionError(name);\n }\n\n /**\n * Call contract function\n * @param fn - Function name\n * @param params - Array of function arguments\n * @param options - Array of function arguments\n * @returns CallResult\n */\n async $call<Fn extends MethodNames<M>>(\n fn: Fn,\n params: MethodParameters<M, Fn>,\n options: Partial<BuildTxOptions<Tag.ContractCallTx, 'callerId' | 'contractId' | 'callData'>>\n & Parameters<Contract<M>['$decodeEvents']>[1]\n & Omit<SendTransactionOptions, 'onAccount' | 'onNode'>\n & Omit<Parameters<typeof txDryRun>[2], 'onNode'>\n & { onAccount?: AccountBase; onNode?: Node; callStatic?: boolean } = {},\n ): Promise<SendAndProcessReturnType & Partial<GetCallResultByHashReturnType<M, Fn>>> {\n const { callStatic, top, ...opt } = { ...this.$options, ...options };\n const fnAci = this.#getFunctionAci(fn);\n const { address, name } = this.$options;\n // TODO: call `produceNameId` on buildTx side\n const contractId = name != null ? produceNameId(name) : address;\n const { onNode } = opt;\n\n if (fn == null) throw new MissingFunctionNameError();\n if (fn === 'init' && callStatic !== true) throw new InvalidMethodInvocationError('\"init\" can be called only via dryRun');\n if (fn !== 'init' && opt.amount != null && Number(opt.amount) > 0 && !fnAci.payable) {\n throw new NotPayableFunctionError(opt.amount, fn);\n }\n\n let callerId;\n try {\n if (opt.onAccount == null) throw new InternalError('Use fallback account');\n callerId = opt.onAccount.address;\n } catch (error) {\n const useFallbackAccount = callStatic === true && (\n (error instanceof TypeError && error.message === 'Account should be an address (ak-prefixed string), or instance of AccountBase, got undefined instead')\n || (error instanceof NoWalletConnectedError)\n || (error instanceof InternalError && error.message === 'Use fallback account')\n );\n if (!useFallbackAccount) throw error;\n callerId = DRY_RUN_ACCOUNT.pub;\n }\n const callData = this._calldata.encode(this._name, fn, params);\n\n if (callStatic === true) {\n if (opt.nonce == null) {\n const topOption = top != null && { [typeof top === 'number' ? 'height' : 'hash']: top };\n const account = await getAccount(callerId, { ...topOption, onNode }).catch((error) => {\n if (!isAccountNotFoundError(error)) throw error;\n return { kind: 'basic', nonce: 0 };\n });\n opt.nonce = account.kind === 'generalized' ? 0 : account.nonce + 1;\n }\n\n const txOpt = { ...opt, onNode, callData };\n let tx;\n if (fn === 'init') {\n if (this.$options.bytecode == null) throw new IllegalArgumentError('Can\\'t dry-run \"init\" without bytecode');\n tx = await buildTxAsync({\n ...txOpt, tag: Tag.ContractCreateTx, code: this.$options.bytecode, ownerId: callerId,\n });\n } else {\n if (contractId == null) throw new MissingContractAddressError('Can\\'t dry-run contract without address');\n tx = await buildTxAsync({\n ...txOpt, tag: Tag.ContractCallTx, callerId, contractId,\n });\n }\n\n const { callObj, ...dryRunOther } = await txDryRun(tx, callerId, { ...opt, top });\n if (callObj == null) {\n throw new InternalError(`callObj is not available for transaction ${tx}`);\n }\n const callInfoTyped = callObj as ContractCallObject;\n return {\n ...dryRunOther,\n ...this.#getCallResult(callInfoTyped, fn, tx, opt),\n tx: unpackTx(tx),\n result: callInfoTyped,\n rawTx: tx,\n hash: buildTxHash(tx),\n txData: undefined as any,\n };\n }\n\n if (top != null) throw new IllegalArgumentError('Can\\'t handle `top` option in on-chain contract call');\n if (contractId == null) throw new MissingContractAddressError('Can\\'t call contract without address');\n const tx = await buildTxAsync({\n _isInternalBuild: true,\n ...opt,\n tag: Tag.ContractCallTx,\n gasLimit: opt.gasLimit ?? await this._estimateGas(fn, params, opt),\n callerId,\n contractId,\n callData,\n });\n if (opt.onAccount == null) throw new IllegalArgumentError('Can\\'t call contract on chain without account');\n return this.#sendAndProcess(tx, fn, { ...opt, onAccount: opt.onAccount });\n }\n\n /**\n * @param ctAddress - Contract address that emitted event\n * @param nameHash - Hash of emitted event name\n * @param options - Options\n * @returns Contract name\n * @throws {@link MissingEventDefinitionError}\n * @throws {@link AmbiguousEventDefinitionError}\n */\n #getContractNameByEvent(\n ctAddress: Encoded.ContractAddress,\n nameHash: BigInt,\n { contractAddressToName }: GetContractNameByEventOptions,\n ): string {\n const addressToName = { ...this.$options.contractAddressToName, ...contractAddressToName };\n if (addressToName[ctAddress] != null) return addressToName[ctAddress];\n\n // TODO: consider using a third-party library\n const isEqual = (a: any, b: any): boolean => JSON.stringify(a) === JSON.stringify(b);\n\n const contracts = this._aci\n .map(({ contract }) => contract)\n .filter((contract) => contract?.event) as ContractAci[];\n const matchedEvents = contracts\n .map((contract) => [contract.name, contract.event.variant])\n .map(([name, events]) => events.map((event: {}) => (\n [name, Object.keys(event)[0], Object.values(event)[0]]\n )))\n .flat()\n .filter(([, eventName]) => BigInt(`0x${calcHash(eventName).toString('hex')}`) === nameHash)\n .filter(([, , type], idx, arr) => !arr.slice(0, idx).some((el) => isEqual(el[2], type)));\n switch (matchedEvents.length) {\n case 0: throw new MissingEventDefinitionError(nameHash.toString(), ctAddress);\n case 1: return matchedEvents[0][0];\n default: throw new AmbiguousEventDefinitionError(ctAddress, matchedEvents);\n }\n }\n\n /**\n * Decode Events\n * @param events - Array of encoded events (callRes.result.log)\n * @param options - Options\n * @returns DecodedEvents\n */\n $decodeEvents(\n events: Event[],\n { omitUnknown, ...opt }: { omitUnknown?: boolean } & GetContractNameByEventOptions = {},\n ): DecodedEvent[] {\n return events\n .map((event) => {\n const topics = event.topics.map((t: string | number) => BigInt(t));\n let contractName;\n try {\n contractName = this.#getContractNameByEvent(event.address, topics[0], opt);\n } catch (error) {\n if ((omitUnknown ?? false) && error instanceof MissingEventDefinitionError) return null;\n throw error;\n }\n const decoded = this._calldata.decodeEvent(contractName, event.data, topics);\n const [name, args] = Object.entries(decoded)[0];\n return {\n name,\n args,\n contract: {\n name: contractName,\n address: event.address,\n },\n };\n }).filter((e: DecodedEvent | null): e is DecodedEvent => e != null);\n }\n\n static async initialize<M extends ContractMethodsBase>(\n {\n onCompiler,\n onNode,\n bytecode,\n aci,\n address,\n sourceCodePath,\n sourceCode,\n fileSystem,\n validateBytecode,\n ...otherOptions\n }: Omit<ConstructorParameters<typeof Contract>[0], 'aci' | 'address'> & {\n validateBytecode?: boolean;\n aci?: Aci;\n address?: Encoded.ContractAddress | AensName;\n },\n ): Promise<ContractWithMethods<M>> {\n if (aci == null && onCompiler != null) {\n let res;\n if (sourceCodePath != null) res = await onCompiler.compile(sourceCodePath);\n if (sourceCode != null) res = await onCompiler.compileBySourceCode(sourceCode, fileSystem);\n if (res != null) {\n aci = res.aci;\n bytecode ??= res.bytecode;\n }\n }\n if (aci == null) throw new MissingContractDefError();\n\n let name;\n if (address != null) {\n address = await resolveName(\n address,\n 'contract_pubkey',\n { resolveByNode: true, onNode },\n ) as Encoded.ContractAddress;\n const isIris = (await onNode.getNodeInfo())\n .consensusProtocolVersion === ConsensusProtocolVersion.Iris;\n if (!isIris && isNameValid(address)) name = address;\n }\n\n if (address == null && sourceCode == null && sourceCodePath == null && bytecode == null) {\n throw new MissingContractAddressError('Can\\'t create instance by ACI without address');\n }\n\n if (address != null) {\n const contract = await getContract(address, { onNode });\n if (contract.active == null) throw new InactiveContractError(address);\n }\n\n if (validateBytecode === true) {\n if (address == null) throw new MissingContractAddressError('Can\\'t validate bytecode without contract address');\n const onChanBytecode = (await getContractByteCode(address, { onNode })).bytecode;\n let isValid = false;\n if (bytecode != null) isValid = bytecode === onChanBytecode;\n else if (sourceCode != null) {\n if (onCompiler == null) throw new IllegalArgumentError('Can\\'t validate bytecode without compiler');\n isValid = await onCompiler.validateBySourceCode(onChanBytecode, sourceCode, fileSystem);\n } else if (sourceCodePath != null) {\n if (onCompiler == null) throw new IllegalArgumentError('Can\\'t validate bytecode without compiler');\n isValid = await onCompiler.validate(onChanBytecode, sourceCodePath);\n }\n if (!isValid) {\n throw new BytecodeMismatchError((sourceCode ?? sourceCodePath) != null ? 'source code' : 'bytecode');\n }\n }\n\n return new ContractWithMethods<M>({\n onCompiler,\n onNode,\n sourceCode,\n sourceCodePath,\n bytecode,\n aci,\n address,\n name,\n fileSystem,\n ...otherOptions,\n });\n }\n\n _aci: Aci;\n\n readonly #aciContract: ContractAci;\n\n _name: string;\n\n _calldata: Calldata;\n\n $options: Omit<ConstructorParameters<typeof Contract>[0], 'aci'>;\n\n /**\n * @param options - Options\n */\n constructor({ aci, ...otherOptions }: {\n onCompiler?: CompilerBase;\n onNode: Node;\n bytecode?: Encoded.ContractBytearray;\n aci: Aci;\n address?: Encoded.ContractAddress;\n /**\n * Supported only in Ceres\n */\n name?: AensName;\n sourceCodePath?: Parameters<CompilerBase['compile']>[0];\n sourceCode?: Parameters<CompilerBase['compileBySourceCode']>[0];\n fileSystem?: Parameters<CompilerBase['compileBySourceCode']>[1];\n } & Parameters<Contract<M>['$deploy']>[1]) {\n this._aci = aci;\n const aciLast = aci[aci.length - 1];\n if (aciLast.contract == null) {\n throw new IllegalArgumentError(`The last 'aci' item should have 'contract' key, got ${Object.keys(aciLast)} keys instead`);\n }\n this.#aciContract = aciLast.contract;\n this._name = this.#aciContract.name;\n this._calldata = new Calldata(aci);\n this.$options = otherOptions;\n\n /**\n * Generate proto function based on contract function using Contract ACI schema\n * All function can be called like:\n * ```js\n * await contract.testFunction()\n * ```\n * then sdk will decide to use dry-run or send tx\n * on-chain base on if function stateful or not.\n * Also, you can manually do that:\n * ```js\n * await contract.testFunction({ callStatic: true }) // use call-static (dry-run)\n * await contract.testFunction({ callStatic: false }) // send tx on-chain\n * ```\n */\n Object.assign(\n this,\n Object.fromEntries(this.#aciContract.functions\n .map(({ name, arguments: aciArgs, stateful }: FunctionAci) => {\n const callStatic = name !== 'init' && !stateful;\n return [\n name,\n async (...args: any) => {\n const options = args.length === aciArgs.length + 1 ? args.pop() : {};\n if (typeof options !== 'object') throw new TypeError(`Options should be an object: ${options}`);\n if (name === 'init') return this.$deploy(args, { callStatic, ...options });\n return this.$call(name, args, { callStatic, ...options });\n },\n ];\n })),\n );\n }\n}\n\ninterface ContractWithMethodsClass {\n new <M extends ContractMethodsBase>(\n options: ConstructorParameters<typeof Contract>[0],\n ): ContractWithMethods<M>;\n initialize: typeof Contract['initialize'];\n}\n\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nconst ContractWithMethods: ContractWithMethodsClass = Contract as any;\n\nexport default ContractWithMethods;\n","/**\n * Oracle methods - routines to interact with the æternity oracle system\n *\n * The high-level description of the oracle system is\n * https://github.com/aeternity/protocol/blob/master/ORACLE.md in the protocol\n * repository.\n */\n\nimport { mapObject, pause } from './utils/other';\nimport { oracleQueryId } from './tx/builder/helpers';\nimport { unpackTx, buildTxAsync, BuildTxOptions } from './tx/builder';\nimport { Tag } from './tx/builder/constants';\nimport { RequestTimedOutError } from './utils/errors';\nimport {\n decode, encode, Encoded, Encoding,\n} from './utils/encoder';\nimport { _getPollInterval, getHeight } from './chain';\nimport { sendTransaction, SendTransactionOptions } from './send-transaction';\nimport Node from './Node';\nimport AccountBase from './account/Base';\n\ntype OracleQueries = Awaited<ReturnType<Node['getOracleQueriesByPubkey']>>['oracleQueries'];\n\n/**\n * Poll for oracle queries\n * @category oracle\n * @param oracleId - Oracle public key\n * @param onQuery - OnQuery callback\n * @param options - Options object\n * @param options.interval - Poll interval(default: 5000)\n * @param options.onNode - Node to use\n * @returns Callback to stop polling function\n */\nexport function pollForQueries(\n oracleId: Encoded.OracleAddress,\n onQuery: (query: OracleQueries[number]) => void,\n { interval, ...options }: { interval?: number; onNode: Node }\n & Parameters<typeof _getPollInterval>[1],\n): () => void {\n const knownQueryIds = new Set();\n const checkNewQueries = async (): Promise<void> => {\n const queries = ((await options.onNode.getOracleQueriesByPubkey(oracleId)).oracleQueries ?? [])\n .filter(({ id }) => !knownQueryIds.has(id));\n queries.forEach((query) => {\n knownQueryIds.add(query.id);\n onQuery(query);\n });\n };\n\n let stopped = false;\n\n // eslint-disable-next-line @typescript-eslint/no-floating-promises\n (async () => {\n interval ??= await _getPollInterval('micro-block', options);\n while (!stopped) { // eslint-disable-line no-unmodified-loop-condition\n // TODO: allow to handle this error somehow\n await checkNewQueries().catch(console.error);\n await pause(interval);\n }\n })();\n return () => { stopped = true; };\n}\n\n/**\n * Poll for oracle query response\n * @category oracle\n * @param oracleId - Oracle public key\n * @param queryId - Oracle Query id\n * @param options - Options object\n * @param options.interval - Poll interval\n * @param options.onNode - Node to use\n * @returns OracleQuery object\n */\nexport async function pollForQueryResponse(\n oracleId: Encoded.OracleAddress,\n queryId: Encoded.OracleQueryId,\n { interval, ...options }:\n { interval?: number; onNode: Node } & Parameters<typeof _getPollInterval>[1],\n): Promise<string> {\n interval ??= await _getPollInterval('micro-block', options);\n let height;\n let ttl;\n let response;\n do {\n ({ response, ttl } = await options.onNode.getOracleQueryByPubkeyAndQueryId(oracleId, queryId));\n const responseBuffer = decode(response as Encoded.OracleResponse);\n if (responseBuffer.length > 0) return responseBuffer.toString();\n await pause(interval);\n height = await getHeight({ ...options, cached: true });\n } while (ttl >= height);\n throw new RequestTimedOutError(height);\n}\n\n/**\n * Constructor for OracleQuery Object (helper object for using OracleQuery)\n * @category oracle\n * @param oracleId - Oracle public key\n * @param queryId - Oracle Query id\n * @param options - Options\n * @returns OracleQuery object\n */\nexport async function getQueryObject(\n oracleId: Encoded.OracleAddress,\n queryId: Encoded.OracleQueryId,\n options: RespondToQueryOptions & Parameters<typeof pollForQueryResponse>[2],\n): Promise<GetQueryObjectReturnType> {\n const record = await options.onNode.getOracleQueryByPubkeyAndQueryId(oracleId, queryId);\n return {\n ...record,\n decodedQuery: decode(record.query as Encoded.OracleQueryId).toString(),\n decodedResponse: decode(record.response as Encoded.OracleResponse).toString(),\n respond: async (response, opt) => (\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n respondToQuery(queryId, response, { ...options, ...opt })\n ),\n pollForResponse: async (opt) => pollForQueryResponse(oracleId, queryId, { ...options, ...opt }),\n };\n}\n\ninterface GetQueryObjectReturnType extends Awaited<ReturnType<Node['getOracleQueryByPubkeyAndQueryId']>> {\n decodedQuery: string;\n decodedResponse: string;\n respond: (response: string, options?: Parameters<typeof respondToQuery>[2]) =>\n ReturnType<typeof respondToQuery>;\n pollForResponse: (options?: Parameters<typeof pollForQueryResponse>[2]) =>\n ReturnType<typeof pollForQueryResponse>;\n}\n\n/**\n * Post query to oracle\n * @category oracle\n * @param oracleId - Oracle public key\n * @param query - Oracle query object\n * @param options - Options object\n * @returns Query object\n */\nexport async function postQueryToOracle(\n oracleId: Encoded.OracleAddress,\n query: string,\n options: PostQueryToOracleOptions,\n): Promise<\n Awaited<ReturnType<typeof sendTransaction>> & Awaited<ReturnType<typeof getQueryObject>>\n > {\n const senderId = options.onAccount.address;\n\n const oracleQueryTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.OracleQueryTx,\n oracleId,\n senderId,\n query,\n });\n const { nonce } = unpackTx(oracleQueryTx, Tag.OracleQueryTx);\n const queryId = oracleQueryId(senderId, nonce, oracleId);\n return {\n ...await sendTransaction(oracleQueryTx, options),\n ...await getQueryObject(oracleId, queryId, options),\n };\n}\n\ntype PostQueryToOracleOptionsType = Parameters<typeof sendTransaction>[1]\n& Parameters<typeof getQueryObject>[2]\n& BuildTxOptions<Tag.OracleQueryTx, 'oracleId' | 'senderId' | 'query'>;\ninterface PostQueryToOracleOptions extends PostQueryToOracleOptionsType {}\n\n/**\n * Extend oracle ttl\n * @category oracle\n * @param options - Options object\n * @returns Oracle object\n */\nexport async function extendOracleTtl(options: ExtendOracleTtlOptions): Promise<\nAwaited<ReturnType<typeof sendTransaction>> & Awaited<ReturnType<typeof getOracleObject>>\n> {\n const oracleId = encode(decode(options.onAccount.address), Encoding.OracleAddress);\n const oracleExtendTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.OracleExtendTx,\n oracleId,\n });\n return {\n ...await sendTransaction(oracleExtendTx, options),\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n ...await getOracleObject(oracleId, options),\n };\n}\n\ntype ExtendOracleTtlOptionsType = SendTransactionOptions & Parameters<typeof getOracleObject>[1]\n& BuildTxOptions<Tag.OracleExtendTx, 'callerId' | 'oracleId'>;\ninterface ExtendOracleTtlOptions extends ExtendOracleTtlOptionsType {}\n\n/**\n * Extend oracle ttl\n * @category oracle\n * @param queryId - Oracle query id\n * @param response - Oracle query response\n * @param options - Options object\n * @returns Oracle object\n */\nexport async function respondToQuery(\n queryId: Encoded.OracleQueryId,\n response: string,\n options: RespondToQueryOptions,\n): Promise<\n Awaited<ReturnType<typeof sendTransaction>> & Awaited<ReturnType<typeof getOracleObject>>\n > {\n const oracleId = encode(decode(options.onAccount.address), Encoding.OracleAddress);\n const oracleRespondTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.OracleResponseTx,\n oracleId,\n queryId,\n response,\n });\n return {\n ...await sendTransaction(oracleRespondTx, options),\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n ...await getOracleObject(oracleId, options),\n };\n}\n\ntype RespondToQueryOptionsType = SendTransactionOptions & Parameters<typeof getOracleObject>[1]\n& BuildTxOptions<Tag.OracleResponseTx, 'callerId' | 'oracleId' | 'queryId' | 'response'>;\ninterface RespondToQueryOptions extends RespondToQueryOptionsType {}\n\n/**\n * Constructor for Oracle Object (helper object for using Oracle)\n * @category oracle\n * @param oracleId - Oracle public key\n * @param options - Options\n * @returns Oracle object\n */\nexport async function getOracleObject(\n oracleId: Encoded.OracleAddress,\n options: { onNode: Node; onAccount: AccountBase },\n): Promise<GetOracleObjectReturnType> {\n return {\n ...await options.onNode.getOracleByPubkey(oracleId),\n queries: (await options.onNode.getOracleQueriesByPubkey(oracleId)).oracleQueries,\n ...mapObject<Function, Function>(\n {\n pollQueries: pollForQueries,\n postQuery: postQueryToOracle,\n respondToQuery,\n extendOracle: extendOracleTtl,\n getQuery: getQueryObject,\n },\n ([name, handler]) => [\n name,\n (...args: any) => {\n const lastArg = args[args.length - 1];\n if (lastArg != null && typeof lastArg === 'object' && lastArg.constructor === Object) {\n Object.assign(lastArg, { ...options, ...lastArg });\n } else args.push(options);\n return handler(\n ...['extendOracle', 'respondToQuery'].includes(name) ? [] : [oracleId],\n ...args,\n );\n },\n ],\n ),\n } as any;\n}\n\ninterface GetOracleObjectReturnType extends Awaited<ReturnType<Node['getOracleByPubkey']>> {\n id: Encoded.OracleAddress;\n queries: OracleQueries;\n // TODO: replace getOracleObject with a class\n pollQueries: (cb: Parameters<typeof pollForQueries>[1]) => ReturnType<typeof pollForQueries>;\n postQuery: Function;\n respondToQuery: Function;\n extendOracle: Function;\n getQuery: Function;\n}\n\n/**\n * Register oracle\n * @category oracle\n * @param queryFormat - Format of query\n * @param responseFormat - Format of query response\n * @param options - Options\n * @returns Oracle object\n */\nexport async function registerOracle(\n queryFormat: string,\n responseFormat: string,\n options: RegisterOracleOptions,\n): Promise<\n Awaited<ReturnType<typeof sendTransaction>> & Awaited<ReturnType<typeof getOracleObject>>\n > {\n const accountId = options.onAccount.address;\n const oracleRegisterTx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.OracleRegisterTx,\n accountId,\n queryFormat,\n responseFormat,\n });\n return {\n ...await sendTransaction(oracleRegisterTx, options),\n ...await getOracleObject(encode(decode(accountId), Encoding.OracleAddress), options),\n };\n}\n\ntype RegisterOracleOptionsType = SendTransactionOptions & Parameters<typeof getOracleObject>[1]\n& BuildTxOptions<Tag.OracleRegisterTx, 'accountId' | 'queryFormat' | 'responseFormat'>;\ninterface RegisterOracleOptions extends RegisterOracleOptionsType {}\n","import BigNumber from 'bignumber.js';\nimport { getBalance, resolveName } from './chain';\nimport { sendTransaction, SendTransactionOptions } from './send-transaction';\nimport { buildTxAsync, BuildTxOptions, unpackTx } from './tx/builder';\nimport { ArgumentError } from './utils/errors';\nimport { Encoded } from './utils/encoder';\nimport { Tag, AensName } from './tx/builder/constants';\nimport AccountBase from './account/Base';\n\n/**\n * Send coins to another account\n * @category chain\n * @param amount - Amount to spend\n * @param recipientIdOrName - Address or name of recipient account\n * @param options - Options\n * @returns Transaction\n */\nexport async function spend(\n amount: number | string,\n recipientIdOrName: Encoded.AccountAddress | Encoded.ContractAddress | AensName,\n options: SpendOptions,\n): ReturnType<typeof sendTransaction> {\n return sendTransaction(\n await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.SpendTx,\n senderId: options.onAccount.address,\n recipientId: await resolveName(\n recipientIdOrName,\n 'account_pubkey',\n options,\n ),\n amount,\n }),\n options,\n );\n}\n\ntype SpendOptionsType = BuildTxOptions<Tag.SpendTx, 'senderId' | 'recipientId' | 'amount'>\n& Parameters<typeof resolveName>[2] & { onAccount: AccountBase } & SendTransactionOptions;\ninterface SpendOptions extends SpendOptionsType {}\n\n// TODO: Rename to spendFraction\n/**\n * Spend a fraction of coin balance to another account. Useful if needed to drain account balance\n * completely, sending funds to another account (with fraction set to 1).\n * @category chain\n * @param fraction - Fraction of balance to spend (between 0 and 1)\n * @param recipientIdOrName - Address or name of recipient account\n * @param options - Options\n * @example\n * ```js\n * // `fraction` * 100 = % of AE to be transferred (e.g. `0.42` for 42% or `1` for 100%)\n * const { blockHeight } = await aeSdk.transferFunds(\n * 0.42,\n * 'ak_21A27UVVt3hDkBE5J7rhhqnH5YNb4Y1dqo4PnSybrH85pnWo7E',\n * );\n * console.log('Transaction mined at', blockHeight);\n * ```\n */\nexport async function transferFunds(\n fraction: number | string, // TODO: accept only number\n recipientIdOrName: AensName | Encoded.AccountAddress | Encoded.ContractAddress,\n options: TransferFundsOptions,\n): ReturnType<typeof sendTransaction> {\n if (+fraction < 0 || +fraction > 1) {\n throw new ArgumentError('fraction', 'a number between 0 and 1', fraction);\n }\n const recipientId = await resolveName(\n recipientIdOrName,\n 'account_pubkey',\n options,\n );\n const senderId = options.onAccount.address;\n const balance = new BigNumber(\n await getBalance.bind(options.onAccount)(senderId, options),\n );\n const desiredAmount = balance.times(fraction).integerValue(BigNumber.ROUND_HALF_UP);\n const { fee } = unpackTx(\n await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.SpendTx,\n senderId,\n recipientId,\n amount: desiredAmount,\n }),\n Tag.SpendTx,\n );\n // Reducing of the amount may reduce transaction fee, so this is not completely accurate\n const amount = desiredAmount.plus(fee).gt(balance) ? balance.minus(fee) : desiredAmount;\n return sendTransaction(\n await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.SpendTx,\n senderId,\n recipientId,\n amount,\n }),\n options,\n );\n}\n\ntype TransferFundsOptionsType = BuildTxOptions<Tag.SpendTx, 'senderId' | 'recipientId' | 'amount'>\n& Parameters<typeof resolveName>[2] & { onAccount: AccountBase } & SendTransactionOptions;\ninterface TransferFundsOptions extends TransferFundsOptionsType {}\n\n/**\n * Submit transaction of another account paying for it (fee and gas)\n * @category chain\n * @param transaction - tx_<base64>-encoded transaction\n * @param options - Options\n * @returns Object Transaction\n */\nexport async function payForTransaction(\n transaction: Encoded.Transaction,\n options: PayForTransactionOptions,\n): ReturnType<typeof sendTransaction> {\n return sendTransaction(\n await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.PayingForTx,\n payerId: options.onAccount.address,\n tx: transaction,\n }),\n options,\n );\n}\n\ninterface PayForTransactionOptions extends\n BuildTxOptions<Tag.PayingForTx, 'payerId' | 'tx' | 'onNode'>, SendTransactionOptions {\n onAccount: AccountBase;\n}\n","/**\n * Generalized Account module - routines to use generalized account\n */\n\nimport { ConsensusProtocolVersion, Int, Tag } from '../tx/builder/constants';\nimport {\n buildContractIdByContractTx, buildTx, buildTxAsync, BuildTxOptions, unpackTx,\n} from '../tx/builder';\nimport { hash } from '../utils/crypto';\nimport {\n decode, encode, Encoded, Encoding,\n} from '../utils/encoder';\nimport { ArgumentError, IllegalArgumentError } from '../utils/errors';\nimport { concatBuffers } from '../utils/other';\nimport AccountBase from '../account/Base';\nimport Contract from './Contract';\nimport Node from '../Node';\nimport { getAccount } from '../chain';\nimport { sendTransaction, SendTransactionOptions } from '../send-transaction';\nimport CompilerBase from './compiler/Base';\n\n/**\n * Convert current account to GA\n * @category contract\n * @param authFnName - Authorization function name\n * @param args - init arguments\n * @param options - Options\n * @returns General Account Object\n */\nexport async function createGeneralizedAccount(\n authFnName: string,\n args: any[],\n {\n onAccount, onCompiler, onNode, bytecode, aci, sourceCodePath, sourceCode, fileSystem, ...options\n }: CreateGeneralizedAccountOptions,\n): Promise<Readonly<{\n owner: Encoded.AccountAddress;\n transaction: Encoded.TxHash;\n rawTx: Encoded.Transaction;\n gaContractId: Encoded.ContractAddress;\n }>> {\n const ownerId = onAccount.address;\n if ((await getAccount(ownerId, { onNode })).kind === 'generalized') {\n throw new IllegalArgumentError(`Account ${ownerId} is already GA`);\n }\n\n const contract = await Contract.initialize<{ init: (...a: any[]) => void }>({\n onAccount, onCompiler, onNode, bytecode, aci, sourceCodePath, sourceCode, fileSystem,\n });\n\n const tx = await buildTxAsync({\n _isInternalBuild: true,\n ...options,\n tag: Tag.GaAttachTx,\n onNode,\n code: await contract.$compile(),\n gasLimit: options.gasLimit ?? await contract._estimateGas('init', args, options),\n ownerId,\n callData: contract._calldata.encode(contract._name, 'init', args),\n authFun: hash(authFnName),\n });\n const { hash: transaction, rawTx } = await sendTransaction(tx, {\n onNode, onAccount, onCompiler, ...options,\n });\n const contractId = buildContractIdByContractTx(rawTx);\n\n return Object.freeze({\n owner: ownerId,\n transaction,\n rawTx,\n gaContractId: contractId,\n });\n}\n\ninterface CreateGeneralizedAccountOptions extends\n BuildTxOptions<Tag.GaAttachTx, 'authFun' | 'callData' | 'code' | 'ownerId' | 'gasLimit'>,\n SendTransactionOptions,\n Pick<\n Parameters<typeof Contract.initialize>[0],\n 'bytecode' | 'aci' | 'sourceCodePath' | 'sourceCode' | 'fileSystem'\n > {\n onAccount: AccountBase;\n onCompiler: CompilerBase;\n onNode: Node;\n gasLimit?: number;\n}\n\n/**\n * Build a transaction hash the same as `Auth.tx_hash` by GaMetaTx payload\n * @category contract\n * @param transaction - tx-encoded transaction\n * @param options - Options\n * @param options.fee - GaMetaTx fee, required in Ceres\n * @param options.gasPrice - GaMetaTx gasPrice, required in Ceres\n * @param options.onNode - Node to use\n * @returns Transaction hash\n */\nexport async function buildAuthTxHash(\n transaction: Encoded.Transaction,\n { fee, gasPrice, onNode }: { fee?: Int; gasPrice?: Int; onNode: Node },\n): Promise<Buffer> {\n const { nodeNetworkId, consensusProtocolVersion } = await onNode.getNodeInfo();\n let payload = hash(concatBuffers([Buffer.from(nodeNetworkId), decode(transaction)]));\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n if (fee == null) throw new ArgumentError('fee', 'provided (in Ceres)', fee);\n if (gasPrice == null) throw new ArgumentError('gasPrice', 'provided (in Ceres)', gasPrice);\n payload = hash(decode(buildTx({\n tag: Tag.GaMetaTxAuthData,\n fee,\n gasPrice,\n txHash: encode(payload, Encoding.TxHash),\n })));\n }\n return payload;\n}\n\n/**\n * Build a transaction hash the same as `Auth.tx_hash` by GaMetaTx\n * @category contract\n * @param transaction - tx-encoded signed GaMeta transaction\n * @param options - Options\n * @param options.onNode - Node to use\n * @returns Transaction hash\n */\nexport async function buildAuthTxHashByGaMetaTx(\n transaction: Encoded.Transaction,\n { onNode }: { onNode: Node },\n): Promise<Buffer> {\n const txParams = unpackTx(transaction, Tag.SignedTx);\n if (txParams.encodedTx.tag !== Tag.GaMetaTx) {\n throw new ArgumentError('transaction', 'to include GaMetaTx', Tag[txParams.encodedTx.tag]);\n }\n return buildAuthTxHash(buildTx(txParams.encodedTx.tx.encodedTx), {\n fee: txParams.encodedTx.fee,\n gasPrice: txParams.encodedTx.gasPrice,\n onNode,\n });\n}\n","import _Symbol from \"core-js-pure/features/symbol/index.js\";\nimport _Symbol$iterator from \"core-js-pure/features/symbol/iterator.js\";\nexport default function _typeof(o) {\n \"@babel/helpers - typeof\";\n\n return _typeof = \"function\" == typeof _Symbol && \"symbol\" == typeof _Symbol$iterator ? function (o) {\n return typeof o;\n } : function (o) {\n return o && \"function\" == typeof _Symbol && o.constructor === _Symbol && o !== _Symbol.prototype ? \"symbol\" : typeof o;\n }, _typeof(o);\n}","import _Object$defineProperty from \"core-js-pure/features/object/define-property.js\";\nimport toPropertyKey from \"./toPropertyKey.js\";\nexport default function _defineProperty(obj, key, value) {\n key = toPropertyKey(key);\n if (key in obj) {\n _Object$defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n return obj;\n}","import _typeof from \"./typeof.js\";\nimport toPrimitive from \"./toPrimitive.js\";\nexport default function toPropertyKey(t) {\n var i = toPrimitive(t, \"string\");\n return \"symbol\" == _typeof(i) ? i : String(i);\n}","import _typeof from \"./typeof.js\";\nimport _Symbol$toPrimitive from \"core-js-pure/features/symbol/to-primitive.js\";\nexport default function toPrimitive(t, r) {\n if (\"object\" != _typeof(t) || !t) return t;\n var e = t[_Symbol$toPrimitive];\n if (void 0 !== e) {\n var i = e.call(t, r || \"default\");\n if (\"object\" != _typeof(i)) return i;\n throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n }\n return (\"string\" === r ? String : Number)(t);\n}","import * as chainMethods from './chain';\nimport { sendTransaction } from './send-transaction';\nimport * as aensMethods from './aens';\nimport * as spendMethods from './spend';\nimport * as oracleMethods from './oracle';\nimport Contract, { ContractMethodsBase } from './contract/Contract';\nimport createDelegationSignature from './contract/delegation-signature';\nimport * as contractGaMethods from './contract/ga';\nimport { buildTxAsync } from './tx/builder';\nimport { mapObject, UnionToIntersection } from './utils/other';\nimport { wrapWithProxy } from './utils/wrap-proxy';\nimport Node from './Node';\nimport { TxParamsAsync } from './tx/builder/schema.generated';\nimport AccountBase from './account/Base';\nimport { Encoded } from './utils/encoder';\nimport CompilerBase from './contract/compiler/Base';\n\nexport type OnAccount = Encoded.AccountAddress | AccountBase | undefined;\n\nconst methods = {\n ...chainMethods,\n sendTransaction,\n ...aensMethods,\n ...spendMethods,\n ...oracleMethods,\n createDelegationSignature,\n ...contractGaMethods,\n} as const;\n\ntype Decrement<Number extends number> = [-1, 0, 1, 2, 3, 4, 5][Number];\ntype GetMethodsOptions <Methods extends { [key: string]: Function }> =\n {\n [Name in keyof Methods]:\n Methods[Name] extends (...args: infer Args) => any\n ? Args[Decrement<Args['length']>] : never\n };\ntype MethodsOptions = GetMethodsOptions<typeof methods>;\nexport interface AeSdkMethodsOptions\n extends Partial<UnionToIntersection<MethodsOptions[keyof MethodsOptions]>> {\n}\n\nexport interface WrappedOptions {\n onAccount: AccountBase;\n onCompiler: CompilerBase;\n onNode: Node;\n}\n\n/**\n * AeSdkMethods is the composition of:\n * - chain methods\n * - tx methods\n * - aens methods\n * - spend methods\n * - oracle methods\n * - contract methods\n * - contract ga methods\n *\n * While these methods can be used separately, this class provides a handy way to store\n * their context (current account, network, and compiler to use).\n */\nclass AeSdkMethods {\n _options: AeSdkMethodsOptions = {};\n\n readonly #wrappedOptions: WrappedOptions;\n\n /**\n * @param options - Options\n */\n constructor(options: AeSdkMethodsOptions = {}) {\n Object.assign(this._options, options);\n this.#wrappedOptions = {\n onAccount: wrapWithProxy(() => this._options.onAccount),\n onNode: wrapWithProxy(() => this._options.onNode),\n onCompiler: wrapWithProxy(() => this._options.onCompiler),\n };\n }\n\n /**\n * Returns sdk instance options with references to current account, node, compiler.\n * Used to create an instance (Contract, Oracle) bound to AeSdk state.\n * @param mergeWith - Merge context with these extra options\n * @returns Context object\n */\n getContext(mergeWith: AeSdkMethodsOptions = {}): AeSdkMethodsOptions & WrappedOptions {\n return {\n ...this._options,\n ...this.#wrappedOptions,\n ...mergeWith,\n };\n }\n\n // TODO: omit onNode from options, because it is already in context\n async buildTx(options: TxParamsAsync): Promise<Encoded.Transaction> {\n return buildTxAsync({ ...this.getContext(), ...options });\n }\n\n async initializeContract<Methods extends ContractMethodsBase>(\n options?: Omit<Parameters<typeof Contract.initialize>[0], 'onNode'> & { onNode?: Node },\n ): Promise<Contract<Methods>> {\n return Contract.initialize<Methods>(this.getContext(options as AeSdkMethodsOptions));\n }\n}\n\ntype RequiredKeys<T> = {\n [K in keyof T]-?: {} extends Pick<T, K> ? never : K\n}[keyof T];\n\ntype OptionalIfNotRequired<T extends [any]> = RequiredKeys<T[0]> extends never ? T | [] : T;\n\ntype ReplaceOnAccount<Options> = Options extends { onAccount: any }\n ? Omit<Options, 'onAccount'> & {\n /**\n * Make operation on specific account by providing address (to use account from sdk) or instance\n * of AccountBase (like MemoryAccount)\n */\n onAccount: OnAccount;\n } : Options;\n\ntype MakeOptional<Options> = OptionalIfNotRequired<[\n Omit<Options, 'onNode' | 'onCompiler' | 'onAccount'> & Partial<ReplaceOnAccount<Options>>,\n]>;\n\ntype TransformMethods <Methods extends { [key: string]: Function }> =\n {\n [Name in keyof Methods]:\n Methods[Name] extends (...args: [...infer Args, infer Options]) => infer Ret\n ? (...args: [...Args, ...MakeOptional<Options>]) => Ret\n : never\n };\n\ninterface AeSdkMethodsTransformed extends TransformMethods<typeof methods> {}\n\nObject.assign(AeSdkMethods.prototype, mapObject<Function, Function>(\n methods,\n ([name, handler]) => [\n name,\n function methodWrapper(this: AeSdkMethods, ...args: any[]) {\n args.length = handler.length;\n const options = args[args.length - 1];\n args[args.length - 1] = this.getContext(options);\n return handler(...args);\n },\n ],\n));\n\ntype AeSdkMethodsTyped = AeSdkMethods & AeSdkMethodsTransformed;\n// eslint-disable-next-line @typescript-eslint/no-redeclare\nconst AeSdkMethodsTyped = AeSdkMethods as new (options?: AeSdkMethodsOptions) => AeSdkMethodsTyped;\nexport default AeSdkMethodsTyped;\n","import { decode, Encoded } from '../utils/encoder';\nimport { ArgumentError } from '../utils/errors';\nimport { AensName } from '../tx/builder/constants';\nimport AccountBase from '../account/Base';\nimport { isNameValid } from '../tx/builder/helpers';\nimport Node from '../Node';\n\nfunction ensureOracleQuery(oq: string): asserts oq is Encoded.OracleQueryId {\n if (!oq.startsWith('oq_')) throw new ArgumentError('oq', 'oracle query', oq);\n}\n\n/**\n * Helper to generate a signature to delegate\n * - pre-claim/claim/transfer/revoke of a name to a contract.\n * - register/extend/respond of an Oracle to a contract.\n * @category contract\n * @param contractAddress - Address of contract to delegate access\n * @param ids - The list of id's to prepend\n * @param options - Options\n * @param options.omitAddress - Prepend delegation signature with an account address\n * @param options.onAccount - Account to use\n * @param options.onNode - Node to use\n * @returns Signature\n * @deprecated use methods `sign*DelegationToContract` of Account instance instead\n * @example\n * ```js\n * const aeSdk = new AeSdk({ ... })\n * const contractAddress = 'ct_asd2ks...'\n * const aensName = 'example.chain'\n * const onAccount = new MemoryAccount(...) // Sign with a specific account\n * // Preclaim signature\n * const preclaimSig = await aeSdk.createDelegationSignature(contractAddress, [], { onAccount })\n * // Claim, transfer and revoke signature\n * const aensDelegationSig = await aeSdk\n * .createDelegationSignature(contractAddress, [aensName], { onAccount })\n *\n * const oracleQueryId = 'oq_...'\n * const onAccount = new MemoryAccount(...) // Sign with a specific account\n * // Oracle register and extend signature\n * const oracleDelegationSig = await aeSdk\n * .createDelegationSignature(contractAddress, [], { onAccount })\n * // Oracle respond signature\n * const respondSig = await aeSdk\n * .createDelegationSignature(contractAddress, [oracleQueryId], { onAccount, omitAddress: true })\n * ```\n */\nexport default async function createDelegationSignature(\n contractAddress: Encoded.ContractAddress,\n ids: Array<Encoded.Any | AensName>,\n {\n onAccount, omitAddress, isOracle, ...options\n }: {\n omitAddress?: boolean;\n onAccount: AccountBase;\n isOracle?: boolean;\n onNode: Node;\n },\n): Promise<Uint8Array> {\n if (ids.length > 1) throw new ArgumentError('ids', 'shorter than 2', ids);\n const { nodeNetworkId, consensusProtocolVersion } = await options.onNode.getNodeInfo();\n const signOpts = { networkId: nodeNetworkId, consensusProtocolVersion };\n if (ids.length === 0) {\n if (omitAddress === true) {\n throw new ArgumentError('omitAddress', 'equal false', omitAddress);\n }\n return decode(\n await onAccount.signDelegationToContract(contractAddress, { ...signOpts, isOracle }),\n );\n }\n\n const [payload] = ids;\n if (isNameValid(payload)) {\n if (omitAddress === true) {\n throw new ArgumentError('omitAddress', 'equal false', omitAddress);\n }\n return decode(\n await onAccount.signNameDelegationToContract(contractAddress, payload, signOpts),\n );\n }\n\n ensureOracleQuery(payload);\n if (omitAddress !== true) {\n throw new ArgumentError('omitAddress', 'equal true', omitAddress);\n }\n return decode(\n await onAccount.signOracleQueryDelegationToContract(contractAddress, payload, signOpts),\n );\n}\n","import Node from './Node';\nimport AccountBase from './account/Base';\nimport {\n CompilerError, DuplicateNodeError, NodeNotFoundError, NotImplementedError, TypeError,\n} from './utils/errors';\nimport { Encoded } from './utils/encoder';\nimport { wrapWithProxy } from './utils/wrap-proxy';\nimport CompilerBase from './contract/compiler/Base';\nimport AeSdkMethods, { OnAccount, AeSdkMethodsOptions, WrappedOptions } from './AeSdkMethods';\nimport { AensName } from './tx/builder/constants';\n\ntype NodeInfo = Awaited<ReturnType<Node['getNodeInfo']>> & { name: string };\n\n/**\n * Basic AeSdk class implements:\n * - node selector,\n * - integrated compiler support,\n * - wrappers of account methods mapped to the current account.\n */\nexport default class AeSdkBase extends AeSdkMethods {\n pool: Map<string, Node> = new Map();\n\n selectedNodeName?: string;\n\n readonly #wrappedOptions: WrappedOptions;\n\n /**\n * @param options - Options\n * @param options.nodes - Array of nodes\n */\n constructor(\n { nodes = [], ...options }: AeSdkMethodsOptions & {\n nodes?: Array<{ name: string; instance: Node }>;\n } = {},\n ) {\n super(options);\n\n nodes.forEach(({ name, instance }, i) => this.addNode(name, instance, i === 0));\n\n this.#wrappedOptions = {\n onNode: wrapWithProxy(() => this.api),\n onCompiler: wrapWithProxy(() => this.compilerApi),\n onAccount: wrapWithProxy(() => this._resolveAccount()),\n };\n }\n\n // TODO: consider dropping this getter, because:\n // compiler is not intended to be used separately any more (functionality limited to sdk needs)\n // and user creates its instance by himself\n get compilerApi(): CompilerBase {\n if (this._options.onCompiler == null) {\n throw new CompilerError('You can\\'t use Compiler API. Compiler is not ready!');\n }\n return this._options.onCompiler;\n }\n\n get api(): Node {\n this.ensureNodeConnected();\n return this.pool.get(this.selectedNodeName) as Node;\n }\n\n /**\n * Add Node\n * @param name - Node name\n * @param node - Node instance\n * @param select - Select this node as current\n * @example\n * ```js\n * // add and select new node with name 'testNode'\n * aeSdkBase.addNode('testNode', new Node({ url }), true)\n * ```\n */\n addNode(name: string, node: Node, select = false): void {\n if (this.pool.has(name)) throw new DuplicateNodeError(name);\n\n this.pool.set(name, node);\n if (select || this.selectedNodeName == null) {\n this.selectNode(name);\n }\n }\n\n /**\n * Select Node\n * @param name - Node name\n * @example\n * nodePool.selectNode('testNode')\n */\n selectNode(name: string): void {\n if (!this.pool.has(name)) throw new NodeNotFoundError(`Node with name ${name} not in pool`);\n this.selectedNodeName = name;\n }\n\n /**\n * Check if you have selected node\n * @example\n * nodePool.isNodeConnected()\n */\n isNodeConnected(): this is AeSdkBase & { selectedNodeName: string } {\n return this.selectedNodeName != null;\n }\n\n protected ensureNodeConnected(): asserts this is AeSdkBase & { selectedNodeName: string } {\n if (!this.isNodeConnected()) {\n throw new NodeNotFoundError('You can\\'t use Node API. Node is not connected or not defined!');\n }\n }\n\n /**\n * Get information about node\n * @example\n * ```js\n * nodePool.getNodeInfo() // { name, version, networkId, protocol, ... }\n * ```\n */\n async getNodeInfo(): Promise<NodeInfo> {\n this.ensureNodeConnected();\n return {\n name: this.selectedNodeName,\n ...await this.api.getNodeInfo(),\n };\n }\n\n /**\n * Get array of available nodes\n * @example\n * nodePool.getNodesInPool()\n */\n async getNodesInPool(): Promise<NodeInfo[]> {\n return Promise.all(\n Array.from(this.pool.entries()).map(async ([name, node]) => ({\n name,\n ...await node.getNodeInfo(),\n })),\n );\n }\n\n // eslint-disable-next-line class-methods-use-this\n addresses(): Encoded.AccountAddress[] {\n return [];\n }\n\n /**\n * Resolves an account\n * @param account - ak-address, instance of AccountBase, or keypair\n */\n _resolveAccount(account: OnAccount = this._options.onAccount): AccountBase {\n if (typeof account === 'string') throw new NotImplementedError('Address in AccountResolver');\n if (typeof account === 'object') return account;\n throw new TypeError(\n 'Account should be an address (ak-prefixed string), '\n + `or instance of AccountBase, got ${String(account)} instead`,\n );\n }\n\n get address(): Encoded.AccountAddress {\n return this._resolveAccount().address;\n }\n\n /**\n * Sign data blob\n * @param data - Data to sign\n * @param options - Options\n */\n async sign(\n data: string | Uint8Array,\n { onAccount, ...options }: { onAccount?: OnAccount } = {},\n ): Promise<Uint8Array> {\n return this._resolveAccount(onAccount).sign(data, options);\n }\n\n /**\n * Sign encoded transaction\n * @param tx - Transaction to sign\n * @param options - Options\n */\n async signTransaction(\n tx: Encoded.Transaction,\n { onAccount, ...options }: { onAccount?: OnAccount } & Parameters<AccountBase['signTransaction']>[1] = {},\n ): Promise<Encoded.Transaction> {\n const networkId = this.selectedNodeName !== null ? await this.api.getNetworkId() : undefined;\n return this._resolveAccount(onAccount).signTransaction(tx, { networkId, ...options });\n }\n\n /**\n * Sign message\n * @param message - Message to sign\n * @param options - Options\n */\n async signMessage(\n message: string,\n { onAccount, ...options }: { onAccount?: OnAccount } & Parameters<AccountBase['signMessage']>[1] = {},\n ): Promise<Uint8Array> {\n return this._resolveAccount(onAccount).signMessage(message, options);\n }\n\n /**\n * Sign typed data\n * @param data - Encoded data to sign\n * @param aci - Type of data to sign\n * @param options - Options\n */\n async signTypedData(\n data: Encoded.ContractBytearray,\n aci: Parameters<AccountBase['signTypedData']>[1],\n { onAccount, ...options }: { onAccount?: OnAccount } & Parameters<AccountBase['signTypedData']>[2] = {},\n ): Promise<Encoded.Signature> {\n return this._resolveAccount(onAccount).signTypedData(data, aci, options);\n }\n\n /**\n * @deprecated use AeSdkBase:signDelegation in Ceres\n * @param contractAddress - Contract address\n * @param options - Options\n */\n async signDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n { onAccount, ...options }: { onAccount?: OnAccount }\n & Parameters<AccountBase['signDelegationToContract']>[1] = {},\n ): Promise<Encoded.Signature> {\n options.networkId ??= this.selectedNodeName !== null\n ? await this.api.getNetworkId() : undefined;\n options.consensusProtocolVersion ??= this.selectedNodeName !== null\n ? (await this.api.getNodeInfo()).consensusProtocolVersion : undefined;\n return this._resolveAccount(onAccount)\n .signDelegationToContract(contractAddress, options);\n }\n\n /**\n * @deprecated use AeSdkBase:signDelegation in Ceres\n * @param contractAddress - Contract address\n * @param name - AENS name\n * @param options - Options\n */\n async signNameDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n name: AensName,\n { onAccount, ...options }: { onAccount?: OnAccount }\n & Parameters<AccountBase['signNameDelegationToContract']>[2] = {},\n ): Promise<Encoded.Signature> {\n options.networkId ??= this.selectedNodeName !== null\n ? await this.api.getNetworkId() : undefined;\n options.consensusProtocolVersion ??= this.selectedNodeName !== null\n ? (await this.api.getNodeInfo()).consensusProtocolVersion : undefined;\n return this._resolveAccount(onAccount)\n .signNameDelegationToContract(contractAddress, name, options);\n }\n\n /**\n * @deprecated use AeSdkBase:signDelegation in Ceres\n * @param contractAddress - Contract address\n * @param options - Options\n */\n async signAllNamesDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n { onAccount, ...options }: { onAccount?: OnAccount }\n & Parameters<AccountBase['signAllNamesDelegationToContract']>[1] = {},\n ): Promise<Encoded.Signature> {\n options.networkId ??= this.selectedNodeName !== null\n ? await this.api.getNetworkId() : undefined;\n options.consensusProtocolVersion ??= this.selectedNodeName !== null\n ? (await this.api.getNodeInfo()).consensusProtocolVersion : undefined;\n return this._resolveAccount(onAccount)\n .signAllNamesDelegationToContract(contractAddress, options);\n }\n\n /**\n * @deprecated use AeSdkBase:signDelegation in Ceres\n * @param contractAddress - Contract address\n * @param oracleQueryId - Oracle query id\n * @param options - Options\n */\n async signOracleQueryDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n oracleQueryId: Encoded.OracleQueryId,\n { onAccount, ...options }: { onAccount?: OnAccount }\n & Parameters<AccountBase['signOracleQueryDelegationToContract']>[2] = {},\n ): Promise<Encoded.Signature> {\n options.networkId ??= this.selectedNodeName !== null\n ? await this.api.getNetworkId() : undefined;\n options.consensusProtocolVersion ??= this.selectedNodeName !== null\n ? (await this.api.getNodeInfo()).consensusProtocolVersion : undefined;\n return this._resolveAccount(onAccount)\n .signOracleQueryDelegationToContract(contractAddress, oracleQueryId, options);\n }\n\n /**\n * Sign delegation, works only in Ceres\n * @param delegation - Delegation to sign\n * @param options - Options\n */\n async signDelegation(\n delegation: Encoded.Bytearray,\n { onAccount, ...options }: { onAccount?: OnAccount }\n & Parameters<AccountBase['signDelegation']>[1] = {},\n ): Promise<Encoded.Signature> {\n options.networkId ??= this.selectedNodeName !== null\n ? await this.api.getNetworkId() : undefined;\n return this._resolveAccount(onAccount).signDelegation(delegation, options);\n }\n\n /**\n * The same as AeSdkMethods:getContext, but it would resolve ak_-prefixed address in\n * `mergeWith.onAccount` to AccountBase.\n */\n override getContext(mergeWith: AeSdkMethodsOptions = {}): AeSdkMethodsOptions & WrappedOptions {\n return {\n ...this._options,\n ...this.#wrappedOptions,\n ...mergeWith,\n ...mergeWith.onAccount != null && {\n onAccount: this._resolveAccount(mergeWith.onAccount),\n },\n };\n }\n}\n","import AeSdkBase from './AeSdkBase';\nimport { OnAccount } from './AeSdkMethods';\nimport AccountBase from './account/Base';\nimport { decode, Encoded } from './utils/encoder';\nimport { UnavailableAccountError } from './utils/errors';\n\nexport default class AeSdk extends AeSdkBase {\n accounts: { [key: Encoded.AccountAddress]: AccountBase } = {};\n\n selectedAddress?: Encoded.AccountAddress;\n\n /**\n * @param options - Options\n */\n constructor(\n { accounts, ...options }: { accounts?: AccountBase[] }\n & ConstructorParameters<typeof AeSdkBase>[0] = {},\n ) {\n super(options);\n accounts?.forEach((account, idx) => this.addAccount(account, { select: idx === 0 }));\n }\n\n override _resolveAccount(account: OnAccount = this.selectedAddress): AccountBase {\n if (typeof account === 'string') {\n const address = account as Encoded.AccountAddress;\n decode(address);\n if (this.accounts[address] == null) throw new UnavailableAccountError(account);\n account = this.accounts[address];\n }\n return super._resolveAccount(account);\n }\n\n /**\n * Get accounts addresses\n * @example addresses()\n */\n override addresses(): Encoded.AccountAddress[] {\n return Object.keys(this.accounts) as Encoded.AccountAddress[];\n }\n\n /**\n * Add specific account\n * @param account - Account instance\n * @param options - Options\n * @param options.select - Select account\n * @example addAccount(account)\n */\n addAccount(account: AccountBase, { select }: { select?: boolean } = {}): void {\n const { address } = account;\n this.accounts[address] = account;\n if (select === true) this.selectAccount(address);\n }\n\n /**\n * Remove specific account\n * @param address - Address of account to remove\n * @example removeAccount(address)\n */\n removeAccount(address: Encoded.AccountAddress): void {\n if (this.accounts[address] == null) throw new UnavailableAccountError(address);\n delete this.accounts[address]; // eslint-disable-line @typescript-eslint/no-dynamic-delete\n if (this.selectedAddress === address) delete this.selectedAddress;\n }\n\n /**\n * Select specific account\n * @param address - Address of account to select\n * @example selectAccount('ak_xxxxxxxx')\n */\n selectAccount(address: Encoded.AccountAddress): void {\n decode(address);\n if (this.accounts[address] == null) throw new UnavailableAccountError(address);\n this.selectedAddress = address;\n }\n}\n","// eslint-disable-next-line max-classes-per-file\nimport { Encoded } from '../utils/encoder';\nimport { BaseError, InternalError } from '../utils/errors';\n\n/**\n * @category aepp wallet communication\n */\nexport const enum MESSAGE_DIRECTION {\n to_waellet = 'to_waellet',\n to_aepp = 'to_aepp',\n}\n\n/**\n * @category aepp wallet communication\n */\nexport const enum WALLET_TYPE {\n window = 'window',\n extension = 'extension',\n}\n\n/**\n * @category aepp wallet communication\n */\nexport const enum SUBSCRIPTION_TYPES {\n subscribe = 'subscribe',\n unsubscribe = 'unsubscribe',\n}\n\n/**\n * @category aepp wallet communication\n */\nexport const enum METHODS {\n readyToConnect = 'connection.announcePresence',\n updateAddress = 'address.update',\n address = 'address.get',\n connect = 'connection.open',\n unsafeSign = 'data.unsafeSign',\n sign = 'transaction.sign',\n signMessage = 'message.sign',\n signTypedData = 'typedData.sign',\n signDelegationToContract = 'delegationToContract.sign',\n signDelegation = 'delegation.sign',\n subscribeAddress = 'address.subscribe',\n updateNetwork = 'networkId.update',\n closeConnection = 'connection.close',\n}\n\n/**\n * @category aepp wallet communication\n */\nexport const enum RPC_STATUS {\n CONNECTED = 'CONNECTED',\n DISCONNECTED = 'DISCONNECTED',\n WAITING_FOR_CONNECTION_REQUEST = 'WAITING_FOR_CONNECTION_REQUEST',\n}\n\ninterface RpcErrorAsJson {\n code: number;\n message: string;\n data?: any;\n}\n\nconst rpcErrors: Array<(new (data?: any) => RpcError) & { code: number }> = [];\n\n/**\n * @category exception\n */\nexport abstract class RpcError extends BaseError {\n static code: number;\n\n code!: number;\n\n data?: any;\n\n toJSON(): RpcErrorAsJson {\n return {\n code: this.code,\n message: this.message,\n data: this.data,\n };\n }\n\n static deserialize(json: RpcErrorAsJson): RpcError {\n const RpcErr = rpcErrors.find((cl) => cl.code === json.code);\n if (RpcErr == null) throw new InternalError(`Can't find RpcError with code: ${json.code}`);\n return new RpcErr(json.data);\n }\n}\n\n/**\n * @category exception\n */\nexport class RpcInvalidTransactionError extends RpcError {\n static override code = 2;\n\n override code = 2;\n\n constructor(data?: any) {\n super('Invalid transaction');\n this.data = data;\n this.name = 'RpcInvalidTransactionError';\n }\n}\nrpcErrors.push(RpcInvalidTransactionError);\n\n/**\n * @category exception\n */\nexport class RpcRejectedByUserError extends RpcError {\n static override code = 4;\n\n override code = 4;\n\n constructor(data?: any) {\n super('Operation rejected by user');\n this.data = data;\n this.name = 'RpcRejectedByUserError';\n }\n}\nrpcErrors.push(RpcRejectedByUserError);\n\n/**\n * @category exception\n */\nexport class RpcUnsupportedProtocolError extends RpcError {\n static override code = 5;\n\n override code = 5;\n\n constructor() {\n super('Unsupported Protocol Version');\n this.name = 'RpcUnsupportedProtocolError';\n }\n}\nrpcErrors.push(RpcUnsupportedProtocolError);\n\n/**\n * @category exception\n */\nexport class RpcConnectionDenyError extends RpcError {\n static override code = 9;\n\n override code = 9;\n\n constructor(data?: any) {\n super('Wallet deny your connection request');\n this.data = data;\n this.name = 'RpcConnectionDenyError';\n }\n}\nrpcErrors.push(RpcConnectionDenyError);\n\n/**\n * @category exception\n */\nexport class RpcNotAuthorizeError extends RpcError {\n static override code = 10;\n\n override code = 10;\n\n constructor() {\n super('You are not connected to the wallet');\n this.name = 'RpcNotAuthorizeError';\n }\n}\nrpcErrors.push(RpcNotAuthorizeError);\n\n/**\n * @category exception\n */\nexport class RpcPermissionDenyError extends RpcError {\n static override code = 11;\n\n override code = 11;\n\n constructor(address: Encoded.AccountAddress) {\n super(`You are not subscribed for account ${address}`);\n this.data = address;\n this.name = 'RpcPermissionDenyError';\n }\n}\nrpcErrors.push(RpcPermissionDenyError);\n\n/**\n * @category exception\n */\nexport class RpcInternalError extends RpcError {\n static override code = 12;\n\n override code = 12;\n\n constructor() {\n super('The peer failed to execute your request due to unknown error');\n this.name = 'RpcInternalError';\n }\n}\nrpcErrors.push(RpcInternalError);\n\n/**\n * @category exception\n */\nexport class RpcMethodNotFoundError extends RpcError {\n static override code = -32601;\n\n override code = -32601;\n\n constructor() {\n super('Method not found');\n this.name = 'RpcMethodNotFoundError';\n }\n}\nrpcErrors.push(RpcMethodNotFoundError);\n","import AccountBase from './Base';\nimport { METHODS } from '../aepp-wallet-communication/schema';\nimport { ArgumentError, UnsupportedProtocolError } from '../utils/errors';\nimport {\n Encoded, Encoding, decode, encode,\n} from '../utils/encoder';\nimport RpcClient from '../aepp-wallet-communication/rpc/RpcClient';\nimport { AeppApi, WalletApi } from '../aepp-wallet-communication/rpc/types';\nimport { AensName, ConsensusProtocolVersion } from '../tx/builder/constants';\nimport { packDelegation } from '../tx/builder/delegation';\nimport { DelegationTag } from '../tx/builder/delegation/schema';\n\n/**\n * Account provided by wallet\n * @param params - Params\n * @param params.rpcClient - RpcClient instance\n * @param params.address - RPC account address\n * @returns AccountRpc instance\n */\nexport default class AccountRpc extends AccountBase {\n _rpcClient: RpcClient<WalletApi, AeppApi>;\n\n override readonly address: Encoded.AccountAddress;\n\n constructor(rpcClient: RpcClient<WalletApi, AeppApi>, address: Encoded.AccountAddress) {\n super();\n this._rpcClient = rpcClient;\n this.address = address;\n }\n\n async sign(dataRaw: string | Uint8Array): Promise<Uint8Array> {\n const data = encode(Buffer.from(dataRaw), Encoding.Bytearray);\n const { signature } = await this._rpcClient\n .request(METHODS.unsafeSign, { onAccount: this.address, data });\n return decode(signature);\n }\n\n override async signTransaction(\n tx: Encoded.Transaction,\n { innerTx, networkId }: Parameters<AccountBase['signTransaction']>[1] = {},\n ): Promise<Encoded.Transaction> {\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n const res = await this._rpcClient.request(METHODS.sign, {\n onAccount: this.address,\n tx,\n returnSigned: true,\n networkId,\n innerTx,\n });\n if (res.signedTransaction == null) {\n throw new UnsupportedProtocolError('signedTransaction is missed in wallet response');\n }\n return res.signedTransaction;\n }\n\n override async signMessage(message: string): Promise<Uint8Array> {\n const { signature } = await this._rpcClient\n .request(METHODS.signMessage, { onAccount: this.address, message });\n return Buffer.from(signature, 'hex');\n }\n\n override async signTypedData(\n data: Encoded.ContractBytearray,\n aci: Parameters<AccountBase['signTypedData']>[1],\n {\n name, version, contractAddress, networkId,\n }: Parameters<AccountBase['signTypedData']>[2] = {},\n ): Promise<Encoded.Signature> {\n const { signature } = await this._rpcClient.request(METHODS.signTypedData, {\n onAccount: this.address,\n domain: {\n name, version, networkId, contractAddress,\n },\n aci,\n data,\n });\n return signature;\n }\n\n override async signDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n { consensusProtocolVersion, isOracle }: {\n consensusProtocolVersion?: ConsensusProtocolVersion;\n isOracle?: boolean;\n } = {},\n ): Promise<Encoded.Signature> {\n if (isOracle == null) {\n const protocol = (consensusProtocolVersion != null) ? ConsensusProtocolVersion[consensusProtocolVersion] : 'unknown';\n console.warn(`AccountRpc:signDelegationToContract: isOracle is not set. By default, sdk would generate an AENS preclaim delegation signature, but it won't be the same as the oracle delegation signature in Ceres (current protocol is ${protocol}).`);\n }\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: isOracle === true ? DelegationTag.Oracle : DelegationTag.AensPreclaim,\n accountAddress: this.address,\n contractAddress,\n });\n return this.signDelegation(delegation);\n }\n const { signature } = await this._rpcClient.request(METHODS.signDelegationToContract, {\n onAccount: this.address,\n contractAddress,\n isOracle,\n });\n return signature;\n }\n\n override async signNameDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n name: AensName,\n { consensusProtocolVersion }: { consensusProtocolVersion?: ConsensusProtocolVersion } = {},\n ): Promise<Encoded.Signature> {\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: DelegationTag.AensName, accountAddress: this.address, contractAddress, nameId: name,\n });\n return this.signDelegation(delegation);\n }\n const { signature } = await this._rpcClient.request(METHODS.signDelegationToContract, {\n onAccount: this.address,\n contractAddress,\n name,\n });\n return signature;\n }\n\n override async signAllNamesDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n { consensusProtocolVersion }: { consensusProtocolVersion?: ConsensusProtocolVersion } = {},\n ): Promise<Encoded.Signature> {\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: DelegationTag.AensWildcard, accountAddress: this.address, contractAddress,\n });\n return this.signDelegation(delegation);\n }\n const { signature } = await this._rpcClient.request(METHODS.signDelegationToContract, {\n onAccount: this.address,\n contractAddress,\n allNames: true,\n });\n return signature;\n }\n\n override async signOracleQueryDelegationToContract(\n contractAddress: Encoded.ContractAddress,\n oracleQueryId: Encoded.OracleQueryId,\n { consensusProtocolVersion }: { consensusProtocolVersion?: ConsensusProtocolVersion } = {},\n ): Promise<Encoded.Signature> {\n if (consensusProtocolVersion === ConsensusProtocolVersion.Ceres) {\n const delegation = packDelegation({\n tag: DelegationTag.OracleResponse, queryId: oracleQueryId, contractAddress,\n });\n return this.signDelegation(delegation);\n }\n const { signature } = await this._rpcClient.request(METHODS.signDelegationToContract, {\n onAccount: this.address,\n contractAddress,\n oracleQueryId,\n });\n return signature;\n }\n\n override async signDelegation(delegation: Encoded.Bytearray): Promise<Encoded.Signature> {\n const { signature } = await this._rpcClient.request(\n METHODS.signDelegation,\n { delegation, onAccount: this.address },\n );\n return signature;\n }\n}\n","import { RpcError, RpcInternalError, RpcMethodNotFoundError } from '../schema';\nimport BrowserConnection from '../connection/Browser';\nimport { InvalidRpcMessageError, MissingCallbackError } from '../../utils/errors';\nimport { ensureError } from '../../utils/other';\n\ninterface JsonRpcRequest {\n jsonrpc: '2.0';\n id: number;\n method: string;\n params?: any;\n}\n\ninterface JsonRpcResponse {\n jsonrpc: '2.0';\n id: number;\n method: string;\n result?: any;\n error?: {\n code: number;\n message: string;\n data?: any;\n };\n}\n\ntype RpcApiHandler = (p?: any) => any | undefined;\ntype RpcApi<Api> = { [k in keyof Api]: RpcApiHandler };\ntype WithOrigin<Api extends RpcApi<Api>> = {\n [k in keyof Api]: (p: Parameters<Api[k]>[0], origin: string) => ReturnType<Api[k]>\n};\n\n/**\n * Contain functionality for using RPC conection\n * @category aepp wallet communication\n * @param connection - Connection object\n * @param onDisconnect - Disconnect callback\n * @param methods - Object containing handlers for each request by name\n */\nexport default class RpcClient <\n RemoteApi extends RpcApi<RemoteApi>, LocalApi extends RpcApi<LocalApi>,\n> {\n connection: BrowserConnection;\n\n readonly #callbacks = (\n new Map<number, { resolve: (v: any) => void; reject: (e: Error) => void }>()\n );\n\n #messageId = 0;\n\n readonly #methods: WithOrigin<LocalApi>;\n\n constructor(\n connection: BrowserConnection,\n onDisconnect: () => void,\n methods: WithOrigin<LocalApi>,\n ) {\n this.connection = connection;\n this.#methods = methods;\n connection.connect(this.#handleMessage.bind(this), onDisconnect);\n }\n\n async #handleMessage(msg: JsonRpcRequest | JsonRpcResponse, origin: string): Promise<void> {\n if (msg?.jsonrpc !== '2.0') throw new InvalidRpcMessageError(JSON.stringify(msg));\n if ('result' in msg || 'error' in msg) {\n this.#processResponse(msg);\n return;\n }\n\n const request = msg as JsonRpcRequest;\n let result;\n let error: Error | undefined;\n try {\n if (!(request.method in this.#methods)) throw new RpcMethodNotFoundError();\n const methodName = request.method as keyof LocalApi;\n result = await this.#methods[methodName](request.params, origin);\n } catch (e) {\n ensureError(e);\n error = e;\n }\n if (request.id != null) {\n this.#sendResponse(\n request.id,\n request.method as keyof LocalApi,\n result,\n error == null || error instanceof RpcError ? error : new RpcInternalError(),\n );\n }\n if (error != null && !(error instanceof RpcError)) throw error;\n }\n\n #sendRequest(\n id: number | undefined,\n method: keyof RemoteApi | keyof LocalApi,\n params?: any,\n ): void {\n this.connection.sendMessage({\n jsonrpc: '2.0',\n ...id != null ? { id } : {},\n method,\n ...params != null ? { params } : {},\n });\n }\n\n #sendResponse(\n id: number,\n method: keyof RemoteApi | keyof LocalApi, // TODO: remove as far it is not required in JSON RPC\n result?: any,\n error?: RpcError,\n ): void {\n this.connection.sendMessage({\n jsonrpc: '2.0',\n id,\n method,\n ...error != null ? { error: error.toJSON() } : { result },\n });\n }\n\n /**\n * Make a request\n * @param name - Method name\n * @param params - Method params\n * @returns Promise which will be resolved after receiving response message\n */\n async request<Name extends keyof RemoteApi>(\n name: Name,\n params: Parameters<RemoteApi[Name]>[0],\n ): Promise<ReturnType<RemoteApi[Name]>> {\n this.#sendRequest(this.#messageId += 1, name, params);\n return new Promise((resolve, reject) => {\n this.#callbacks.set(this.#messageId, { resolve, reject });\n });\n }\n\n /**\n * Make a notification\n * @param name - Method name\n * @param params - Method params\n */\n notify<Name extends keyof RemoteApi>(name: Name, params: Parameters<RemoteApi[Name]>[0]): void {\n this.#sendRequest(undefined, name, params);\n }\n\n /**\n * Process response message\n * @param msg - Message object\n */\n #processResponse({ id, error, result }: { id: number; error?: any; result?: any }): void {\n const callbacks = this.#callbacks.get(id);\n if (callbacks == null) throw new MissingCallbackError(id);\n if (error != null) callbacks.reject(RpcError.deserialize(error));\n else callbacks.resolve(result);\n this.#callbacks.delete(id);\n }\n}\n","import AeSdkBase from './AeSdkBase';\nimport { OnAccount } from './AeSdkMethods';\nimport AccountBase from './account/Base';\nimport AccountRpc from './account/Rpc';\nimport { decode, Encoded } from './utils/encoder';\nimport {\n Accounts, RPC_VERSION, WalletInfo, Network, WalletApi, AeppApi, Node as NodeRpc,\n} from './aepp-wallet-communication/rpc/types';\nimport RpcClient from './aepp-wallet-communication/rpc/RpcClient';\nimport { METHODS, SUBSCRIPTION_TYPES } from './aepp-wallet-communication/schema';\nimport {\n AlreadyConnectedError,\n NoWalletConnectedError,\n UnsubscribedAccountError,\n UnAuthorizedAccountError,\n RpcConnectionError,\n} from './utils/errors';\nimport Node from './Node';\nimport BrowserConnection from './aepp-wallet-communication/connection/Browser';\n\n/**\n * RPC handler for AEPP side\n * Contain functionality for wallet interaction and connect it to sdk\n * @category aepp wallet communication\n */\nexport default class AeSdkAepp extends AeSdkBase {\n name: string;\n\n onAddressChange: (a: Accounts) => void;\n\n onDisconnect: (p: any) => void;\n\n onNetworkChange: (a: Network) => void;\n\n rpcClient?: RpcClient<WalletApi, AeppApi>;\n\n _accounts?: Accounts;\n\n /**\n * @param options - Options\n * @param options.name - Aepp name\n * @param options.onAddressChange - Call-back function for update address event\n * @param options.onDisconnect - Call-back function for disconnect event\n * @param options.onNetworkChange - Call-back function for update network event\n */\n constructor({\n name,\n onAddressChange = () => {},\n onDisconnect = () => {},\n onNetworkChange = () => {},\n ...other\n }: {\n name: string;\n onAddressChange?: (a: Accounts) => void;\n onDisconnect?: (p: any) => void;\n onNetworkChange?: (a: Network) => void;\n } & ConstructorParameters<typeof AeSdkBase>[0]) {\n super(other);\n this.onAddressChange = onAddressChange;\n this.onDisconnect = onDisconnect;\n this.onNetworkChange = onNetworkChange;\n this.name = name;\n }\n\n override _resolveAccount(account: OnAccount = this.addresses()[0]): AccountBase {\n if (typeof account === 'string') {\n const address = account as Encoded.AccountAddress;\n decode(address);\n if (!this.addresses().includes(address)) throw new UnAuthorizedAccountError(address);\n this._ensureConnected();\n account = new AccountRpc(this.rpcClient, address);\n }\n if (account == null) this._ensureAccountAccess();\n return super._resolveAccount(account);\n }\n\n override addresses(): Encoded.AccountAddress[] {\n if (this._accounts == null) return [];\n const current = Object.keys(this._accounts.current)[0];\n return [\n ...current != null ? [current] : [], ...Object.keys(this._accounts.connected),\n ] as Encoded.AccountAddress[];\n }\n\n /**\n * Connect to wallet\n * @param connection - Wallet connection object\n * @param options - Options\n * @param options.connectNode - Request wallet to bind node\n * @param options.name - Node name\n */\n async connectToWallet(\n connection: BrowserConnection,\n { connectNode = false, name = 'wallet-node' }: { connectNode?: boolean; name?: string } = {},\n ): Promise<WalletInfo & { node?: NodeRpc }> {\n if (this.rpcClient != null) throw new AlreadyConnectedError('You are already connected to wallet');\n let disconnectParams: any;\n\n const updateNetwork = (params: Network): void => {\n if (connectNode) {\n if (params.node?.url == null) throw new RpcConnectionError('Missing URLs of the Node');\n this.pool.delete(name);\n this.addNode(name, new Node(params.node.url), true);\n }\n this.onNetworkChange(params);\n };\n\n const client = new RpcClient<WalletApi, AeppApi>(\n connection,\n () => {\n delete this.rpcClient;\n delete this._accounts;\n this.onDisconnect(disconnectParams);\n },\n {\n [METHODS.updateAddress]: (params) => {\n this._accounts = params;\n this.onAddressChange(params);\n },\n [METHODS.updateNetwork]: updateNetwork,\n [METHODS.closeConnection]: (params) => {\n disconnectParams = params;\n client.connection.disconnect();\n },\n [METHODS.readyToConnect]: () => {},\n },\n );\n const walletInfo = await client\n .request(METHODS.connect, { name: this.name, version: RPC_VERSION, connectNode });\n updateNetwork(walletInfo);\n this.rpcClient = client;\n return walletInfo;\n }\n\n /**\n * Disconnect from wallet\n */\n disconnectWallet(): void {\n this._ensureConnected();\n this.rpcClient.notify(METHODS.closeConnection, { reason: 'bye' });\n this.rpcClient.connection.disconnect();\n }\n\n /**\n * Ask addresses from wallet\n * @returns Addresses from wallet\n */\n async askAddresses(): Promise<Encoded.AccountAddress[]> {\n this._ensureAccountAccess();\n return this.rpcClient.request(METHODS.address, undefined);\n }\n\n /**\n * Subscribe for addresses from wallet\n * @param type - Subscription type\n * @param value - Should be one of 'current' (the selected account), 'connected' (all)\n * @returns Accounts from wallet\n */\n async subscribeAddress(\n type: SUBSCRIPTION_TYPES,\n value: 'current' | 'connected',\n ): Promise<ReturnType<WalletApi[METHODS.subscribeAddress]>> {\n this._ensureConnected();\n const result = await this.rpcClient.request(METHODS.subscribeAddress, { type, value });\n this._accounts = result.address;\n return result;\n }\n\n _ensureConnected(): asserts this is AeSdkAepp & { rpcClient: NonNullable<AeSdkAepp['rpcClient']> } {\n if (this.rpcClient != null) return;\n throw new NoWalletConnectedError('You are not connected to Wallet');\n }\n\n _ensureAccountAccess(): asserts this is AeSdkAepp & { rpcClient: NonNullable<AeSdkAepp['rpcClient']> } {\n this._ensureConnected();\n if (this.addresses().length !== 0) return;\n throw new UnsubscribedAccountError();\n }\n}\n","import { Encoded } from '../../utils/encoder';\nimport { Domain, AciValue } from '../../utils/typed-data';\nimport { METHODS, SUBSCRIPTION_TYPES, WALLET_TYPE } from '../schema';\nimport { TransformNodeType } from '../../Node';\nimport { SignedTx } from '../../apis/node';\nimport { AensName } from '../../tx/builder/constants';\n\nexport interface WalletInfo {\n id: string;\n name: string;\n networkId: string;\n origin: string; // TODO: origin needs to be provided by transport\n type: WALLET_TYPE;\n}\n\nexport interface Accounts {\n connected: { [pub: Encoded.AccountAddress]: {} };\n current: { [pub: Encoded.AccountAddress]: {} };\n}\n\nexport interface Node {\n // TODO: name is not used, can be removed\n name: string;\n url: string;\n}\n\nexport interface Network {\n networkId: string;\n node?: Node;\n}\n\ntype Icons = Array<{ src: string; sizes?: string; type?: string; purpose?: string }>;\n\nexport const RPC_VERSION = 1;\n\nexport interface WalletApi {\n [METHODS.connect]: (\n p: { name: string; icons?: Icons; version: typeof RPC_VERSION; connectNode: boolean }\n ) => Promise<WalletInfo & { node?: Node }>;\n\n [METHODS.closeConnection]: (p: any) => void;\n\n [METHODS.subscribeAddress]: (\n p: { type: SUBSCRIPTION_TYPES; value: 'connected' | 'current' }\n ) => Promise<{ subscription: Array<'connected' | 'current'>; address: Accounts }>;\n\n [METHODS.address]: () => Promise<Encoded.AccountAddress[]>;\n\n [METHODS.unsafeSign]: (\n p: { data: Encoded.Bytearray; onAccount: Encoded.AccountAddress }\n ) => Promise<{ signature: Encoded.Signature }>;\n\n [METHODS.sign]: ((\n p: {\n tx: Encoded.Transaction;\n onAccount: Encoded.AccountAddress;\n returnSigned: boolean;\n /**\n * @deprecated Wallet provided networkId will be used (current network)\n * required to maintain backward compatibility with wallets using SDK v11.0.1 and below\n * @see {@link https://github.com/aeternity/aepp-sdk-js/commit/153fd89a52c4eab39fcd659b356b36d32129c1ba}\n */\n networkId: string;\n innerTx?: boolean;\n }\n ) => Promise<{\n /**\n * @deprecated this is not a hash at all, will be removed later at the same time\n * as dropping ability to broadcast transaction by wallet\n */\n transactionHash?: Partial<TransformNodeType<SignedTx>> & {\n hash: Encoded.TxHash;\n rawTx: Encoded.Transaction;\n };\n signedTransaction?: Encoded.Transaction;\n }>);\n\n [METHODS.signMessage]: (\n p: { message: string; onAccount: Encoded.AccountAddress }\n ) => Promise<{ signature: string }>;\n\n [METHODS.signTypedData]: (\n p: {\n domain: Domain;\n aci: AciValue;\n data: Encoded.ContractBytearray;\n onAccount: Encoded.AccountAddress;\n },\n ) => Promise<{ signature: Encoded.Signature }>;\n\n [METHODS.signDelegationToContract]: (\n p: {\n contractAddress: Encoded.ContractAddress;\n name?: AensName;\n oracleQueryId?: Encoded.OracleQueryId;\n allNames?: boolean;\n isOracle?: boolean;\n onAccount: Encoded.AccountAddress;\n },\n ) => Promise<{ signature: Encoded.Signature }>;\n\n [METHODS.signDelegation]: (\n p: {\n delegation: Encoded.Bytearray;\n onAccount: Encoded.AccountAddress;\n },\n ) => Promise<{ signature: Encoded.Signature }>;\n}\n\nexport interface AeppApi {\n [METHODS.updateAddress]: (a: Accounts) => void;\n [METHODS.updateNetwork]: (a: Network) => void;\n [METHODS.readyToConnect]: (w: WalletInfo) => void;\n [METHODS.closeConnection]: (p: any) => void;\n}\n","import JsonBig from 'json-bigint';\nimport BigNumber from 'bignumber.js';\nimport { mapObject } from './other';\n\nconst jsonBig = JsonBig({ storeAsString: true });\n\nconst convertValuesToBigNumbers = (value: any): any => {\n if (typeof value === 'object' && value !== null && value.constructor === Object) {\n return mapObject(value, ([k, v]) => [k, convertValuesToBigNumbers(v)]);\n }\n if (Array.isArray(value)) {\n return value.map((item) => convertValuesToBigNumbers(item));\n }\n if (typeof value === 'string' && new BigNumber(value).toString(10) === value) {\n const bn = new BigNumber(value);\n bn.toJSON = () => bn.toString(10);\n return bn;\n }\n return value;\n};\n\nexport default {\n stringify: (...args: Parameters<typeof JsonBig['stringify']>): string => (\n jsonBig.stringify(convertValuesToBigNumbers(args[0]), ...args.slice(1))\n ),\n parse: jsonBig.parse,\n};\n","import { v4 as uuid } from '@aeternity/uuid';\nimport AeSdk from './AeSdk';\nimport verifyTransaction from './tx/validator';\nimport RpcClient from './aepp-wallet-communication/rpc/RpcClient';\nimport {\n METHODS, RPC_STATUS, SUBSCRIPTION_TYPES, WALLET_TYPE,\n RpcInvalidTransactionError,\n RpcNotAuthorizeError, RpcPermissionDenyError, RpcUnsupportedProtocolError,\n} from './aepp-wallet-communication/schema';\nimport { InternalError, UnknownRpcClientError } from './utils/errors';\nimport AccountBase from './account/Base';\nimport BrowserConnection from './aepp-wallet-communication/connection/Browser';\nimport {\n Accounts,\n AeppApi,\n Network,\n RPC_VERSION,\n WalletApi,\n WalletInfo,\n} from './aepp-wallet-communication/rpc/types';\nimport {\n Encoded, Encoding, encode, decode,\n} from './utils/encoder';\nimport jsonBig from './utils/json-big';\n\ntype RpcClientWallet = RpcClient<AeppApi, WalletApi>;\n\ntype OnConnection = (\n clientId: string, params: Omit<Parameters<WalletApi[METHODS.connect]>[0], 'version'>, origin: string\n) => void;\n\ntype OnSubscription = (\n clientId: string, params: Parameters<WalletApi[METHODS.subscribeAddress]>[0], origin: string\n) => void;\n\ntype OnDisconnect = (\n clientId: string, params: Parameters<WalletApi[METHODS.closeConnection]>[0]\n) => void;\n\ntype OnAskAccounts = (\n clientId: string, params: undefined, origin: string\n) => void;\n\ninterface RpcClientsInfo {\n id: string;\n status: RPC_STATUS;\n connectNode: boolean;\n addressSubscription: Set<'connected' | 'current'>;\n rpc: RpcClientWallet;\n}\n\n/**\n * Contain functionality for aepp interaction and managing multiple aepps\n * @category aepp wallet communication\n */\nexport default class AeSdkWallet extends AeSdk {\n id: string;\n\n _type: WALLET_TYPE;\n\n name: string;\n\n _clients = new Map<string, RpcClientsInfo>();\n\n onConnection: OnConnection;\n\n onSubscription: OnSubscription;\n\n onDisconnect: OnDisconnect;\n\n onAskAccounts: OnAskAccounts;\n\n /**\n * @param options - Options\n * @param options.name - Wallet name\n * @param options.id - Wallet id\n * @param options.type - Wallet type\n * @param options.onConnection - Call-back function for incoming AEPP connection\n * @param options.onSubscription - Call-back function for incoming AEPP account subscription\n * @param options.onAskAccounts - Call-back function for incoming AEPP get address request\n * @param options.onDisconnect - Call-back function for disconnect event\n */\n constructor({\n name,\n id,\n type,\n onConnection,\n onSubscription,\n onDisconnect,\n onAskAccounts,\n ...options\n }: {\n id: string;\n type: WALLET_TYPE;\n name: string;\n onConnection: OnConnection;\n onSubscription: OnSubscription;\n onDisconnect: OnDisconnect;\n onAskAccounts: OnAskAccounts;\n } & ConstructorParameters<typeof AeSdk>[0]) {\n super(options);\n this.onConnection = onConnection;\n this.onSubscription = onSubscription;\n this.onDisconnect = onDisconnect;\n this.onAskAccounts = onAskAccounts;\n this.name = name;\n this.id = id;\n this._type = type;\n }\n\n _getAccountsForClient({ addressSubscription }: RpcClientsInfo): Accounts {\n const { current, connected } = this.getAccounts();\n return {\n current: addressSubscription.has('current') || addressSubscription.has('connected')\n ? current : {},\n connected: addressSubscription.has('connected') ? connected : {},\n };\n }\n\n _pushAccountsToApps(): void {\n if (this._clients == null) return;\n Array.from(this._clients.keys())\n .filter((clientId) => this._isRpcClientConnected(clientId))\n .map((clientId) => this._getClient(clientId))\n .filter((client) => client.addressSubscription.size !== 0)\n .forEach((client) => client.rpc\n .notify(METHODS.updateAddress, this._getAccountsForClient(client)));\n }\n\n override selectAccount(address: Encoded.AccountAddress): void {\n super.selectAccount(address);\n this._pushAccountsToApps();\n }\n\n override addAccount(account: AccountBase, options?: Parameters<AeSdk['addAccount']>[1]): void {\n super.addAccount(account, options);\n this._pushAccountsToApps();\n }\n\n _getNode(): { node: Network['node'] } {\n this.ensureNodeConnected();\n return { node: { url: this.api.$host, name: this.selectedNodeName } };\n }\n\n override async selectNode(name: string): Promise<void> {\n super.selectNode(name);\n const networkId = await this.api.getNetworkId();\n Array.from(this._clients.keys())\n .filter((clientId) => this._isRpcClientConnected(clientId))\n .map((clientId) => this._getClient(clientId))\n .forEach((client) => {\n client.rpc.notify(METHODS.updateNetwork, {\n networkId,\n ...client.connectNode && this._getNode(),\n });\n });\n }\n\n _getClient(clientId: string): RpcClientsInfo {\n const client = this._clients.get(clientId);\n if (client == null) throw new UnknownRpcClientError(clientId);\n return client;\n }\n\n _isRpcClientConnected(clientId: string): boolean {\n return RPC_STATUS.CONNECTED === this._getClient(clientId).status\n && this._getClient(clientId).rpc.connection.isConnected();\n }\n\n _disconnectRpcClient(clientId: string): void {\n const client = this._getClient(clientId);\n client.rpc.connection.disconnect();\n client.status = RPC_STATUS.DISCONNECTED;\n client.addressSubscription = new Set();\n }\n\n /**\n * Remove specific RpcClient by ID\n * @param id - Client ID\n */\n removeRpcClient(id: string): void {\n this._disconnectRpcClient(id);\n this._clients.delete(id);\n }\n\n /**\n * Add new client by AEPP connection\n * @param clientConnection - AEPP connection object\n * @returns Client ID\n */\n addRpcClient(clientConnection: BrowserConnection): string {\n // @TODO detect if aepp has some history based on origin????\n // if yes use this instance for connection\n const id = uuid();\n let disconnectParams: any;\n const client: RpcClientsInfo = {\n id,\n status: RPC_STATUS.WAITING_FOR_CONNECTION_REQUEST,\n addressSubscription: new Set(),\n connectNode: false,\n rpc: new RpcClient<AeppApi, WalletApi>(\n clientConnection,\n () => {\n this._clients.delete(id);\n this.onDisconnect(id, disconnectParams); // also related info\n },\n {\n [METHODS.closeConnection]: (params) => {\n disconnectParams = params;\n this._disconnectRpcClient(id);\n },\n // Store client info and prepare two fn for each client `connect` and `denyConnection`\n // which automatically prepare and send response for that client\n [METHODS.connect]: async ({\n name, version, icons, connectNode,\n }, origin) => {\n if (version !== RPC_VERSION) throw new RpcUnsupportedProtocolError();\n\n await this.onConnection(id, { name, icons, connectNode }, origin);\n client.status = RPC_STATUS.CONNECTED;\n client.connectNode = connectNode;\n return {\n ...await this.getWalletInfo(),\n ...connectNode && this._getNode(),\n };\n },\n [METHODS.subscribeAddress]: async ({ type, value }, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n\n switch (type) {\n case SUBSCRIPTION_TYPES.subscribe:\n // TODO: remove `type` as it always subscribe\n await this.onSubscription(id, { type, value }, origin);\n client.addressSubscription.add(value);\n break;\n case SUBSCRIPTION_TYPES.unsubscribe:\n client.addressSubscription.delete(value);\n break;\n default:\n throw new InternalError(`Unknown subscription type: ${type}`);\n }\n\n return {\n subscription: Array.from(client.addressSubscription),\n address: this._getAccountsForClient(client),\n };\n },\n [METHODS.address]: async (params, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n await this.onAskAccounts(id, params, origin);\n return this.addresses();\n },\n [METHODS.sign]: async (\n {\n tx, onAccount = this.address, returnSigned, innerTx,\n },\n origin,\n ) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n if (!this.addresses().includes(onAccount)) {\n throw new RpcPermissionDenyError(onAccount);\n }\n\n const parameters = {\n onAccount, aeppOrigin: origin, aeppRpcClientId: id, innerTx,\n };\n if (returnSigned || innerTx === true) {\n return { signedTransaction: await this.signTransaction(tx, parameters) };\n }\n try {\n return jsonBig.parse(jsonBig.stringify({\n transactionHash: await this.sendTransaction(tx, { ...parameters, verify: false }),\n }));\n } catch (error) {\n const validation = await verifyTransaction(tx, this.api);\n if (validation.length > 0) throw new RpcInvalidTransactionError(validation);\n throw error;\n }\n },\n [METHODS.signMessage]: async ({ message, onAccount = this.address }, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n if (!this.addresses().includes(onAccount)) {\n throw new RpcPermissionDenyError(onAccount);\n }\n\n const parameters = { onAccount, aeppOrigin: origin, aeppRpcClientId: id };\n return {\n signature: Buffer.from(await this.signMessage(message, parameters)).toString('hex'),\n };\n },\n [METHODS.signTypedData]: async ({\n domain, aci, data, onAccount = this.address,\n }, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n if (!this.addresses().includes(onAccount)) {\n throw new RpcPermissionDenyError(onAccount);\n }\n\n const parameters = {\n ...domain, onAccount, aeppOrigin: origin, aeppRpcClientId: id,\n };\n return {\n signature: await this.signTypedData(data, aci, parameters),\n };\n },\n [METHODS.signDelegationToContract]: async ({\n contractAddress, name, oracleQueryId, allNames, onAccount = this.address, isOracle,\n }, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n if (!this.addresses().includes(onAccount)) {\n throw new RpcPermissionDenyError(onAccount);\n }\n\n isOracle ??= false;\n const parameters = { onAccount, aeppOrigin: origin, aeppRpcClientId: id };\n const signature = await (\n (name == null ? null : this\n .signNameDelegationToContract(contractAddress, name, parameters))\n ?? (oracleQueryId == null ? null : this\n .signOracleQueryDelegationToContract(contractAddress, oracleQueryId, parameters))\n ?? (allNames !== true ? null : this\n .signAllNamesDelegationToContract(contractAddress, parameters))\n ?? this.signDelegationToContract(contractAddress, { ...parameters, isOracle })\n );\n return { signature };\n },\n [METHODS.unsafeSign]: async ({ data, onAccount = this.address }, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n if (!this.addresses().includes(onAccount)) throw new RpcPermissionDenyError(onAccount);\n const parameters = { onAccount, aeppOrigin: origin, aeppRpcClientId: id };\n const signature = encode(await this.sign(decode(data), parameters), Encoding.Signature);\n return { signature };\n },\n [METHODS.signDelegation]: async ({ delegation, onAccount = this.address }, origin) => {\n if (!this._isRpcClientConnected(id)) throw new RpcNotAuthorizeError();\n if (!this.addresses().includes(onAccount)) throw new RpcPermissionDenyError(onAccount);\n const parameters = { onAccount, aeppOrigin: origin, aeppRpcClientId: id };\n const signature = await this.signDelegation(delegation, parameters);\n return { signature };\n },\n },\n ),\n };\n this._clients.set(id, client);\n return id;\n }\n\n /**\n * Send shareWalletInfo message to notify AEPP about wallet\n * @param clientId - ID of RPC client send message to\n */\n async shareWalletInfo(clientId: string): Promise<void> {\n this._getClient(clientId).rpc.notify(METHODS.readyToConnect, await this.getWalletInfo());\n }\n\n /**\n * Get Wallet info object\n * @returns Object with wallet information\n */\n async getWalletInfo(): Promise<WalletInfo> {\n return {\n id: this.id,\n name: this.name,\n networkId: await this.api.getNetworkId(),\n origin: window.location.origin,\n type: this._type,\n };\n }\n\n /**\n * Get Wallet accounts\n * @returns Object with accounts information (\\{ connected: Object, current: Object \\})\n */\n getAccounts(): Accounts {\n return {\n current: this.selectedAddress != null ? { [this.selectedAddress]: {} } : {},\n connected: this.addresses()\n .filter((a) => a !== this.selectedAddress)\n .reduce((acc, a) => ({ ...acc, [a]: {} }), {}),\n };\n }\n}\n","import AccountBase from './Base';\nimport {\n ArgumentError,\n InternalError,\n InvalidAuthDataError,\n NotImplementedError,\n} from '../utils/errors';\nimport { decode, Encoded } from '../utils/encoder';\nimport { getAccount } from '../chain';\nimport Contract from '../contract/Contract';\nimport { buildTxAsync, buildTx } from '../tx/builder';\nimport { Tag } from '../tx/builder/constants';\n\n/**\n * Generalized account class\n */\nexport default class AccountGeneralized extends AccountBase {\n override readonly address: Encoded.AccountAddress;\n\n #authFun?: string;\n\n /**\n * @param address - Address of generalized account\n */\n constructor(address: Encoded.AccountAddress) {\n super();\n decode(address);\n this.address = address;\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async sign(): Promise<Uint8Array> {\n throw new NotImplementedError('Can\\'t sign using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signMessage(): Promise<Uint8Array> {\n throw new NotImplementedError('Can\\'t sign using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signTypedData(): Promise<Encoded.Signature> {\n throw new NotImplementedError('Can\\'t sign using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signNameDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signAllNamesDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signOracleQueryDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using generalized account');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signDelegation(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation using generalized account');\n }\n\n override async signTransaction(\n tx: Encoded.Transaction,\n { authData, onCompiler, onNode }: Parameters<AccountBase['signTransaction']>[1],\n ): Promise<Encoded.Transaction> {\n if (authData == null || onCompiler == null || onNode == null) {\n throw new ArgumentError('authData, onCompiler, onNode', 'provided', null);\n }\n const {\n callData, sourceCode, args, fee, gasLimit, gasPrice,\n } = typeof authData === 'function' ? await authData(tx) : authData;\n\n const authCallData = callData ?? await (async () => {\n if (this.#authFun == null) {\n const account = await getAccount(this.address, { onNode });\n if (account.kind !== 'generalized') {\n throw new ArgumentError('account kind', 'generalized', account.kind);\n }\n this.#authFun = account.authFun;\n }\n if (this.#authFun == null) {\n throw new InternalError('Account in generalised, but authFun not provided');\n }\n\n if (sourceCode == null || args == null) {\n throw new InvalidAuthDataError('Auth data must contain sourceCode and args or callData.');\n }\n const contract = await Contract.initialize({ onCompiler, onNode, sourceCode });\n return contract._calldata.encode(contract._name, this.#authFun, args);\n })();\n\n const gaMetaTx = await buildTxAsync({\n tag: Tag.GaMetaTx,\n tx: { tag: Tag.SignedTx, encodedTx: decode(tx), signatures: [] },\n gaId: this.address,\n authData: authCallData,\n fee,\n gasLimit,\n gasPrice,\n onNode,\n });\n return buildTx({ tag: Tag.SignedTx, encodedTx: decode(gaMetaTx), signatures: [] });\n }\n}\n","import type Transport from '@ledgerhq/hw-transport';\nimport AccountBase from './Base';\nimport { ArgumentError, NotImplementedError } from '../utils/errors';\nimport { decode, Encoded } from '../utils/encoder';\nimport { buildTx } from '../tx/builder';\nimport { Tag } from '../tx/builder/constants';\n\nexport const CLA = 0xe0;\nexport const GET_ADDRESS = 0x02;\nexport const SIGN_TRANSACTION = 0x04;\nexport const GET_APP_CONFIGURATION = 0x06;\nexport const SIGN_PERSONAL_MESSAGE = 0x08;\n\n/**\n * Ledger wallet account class\n */\nexport default class AccountLedger extends AccountBase {\n readonly transport: Transport;\n\n override readonly address: Encoded.AccountAddress;\n\n readonly index: number;\n\n /**\n * @param transport - Connection to Ledger to use\n * @param index - Index of account\n * @param address - Address of account\n */\n constructor(transport: Transport, index: number, address: Encoded.AccountAddress) {\n super();\n this.transport = transport;\n this.index = index;\n this.address = address;\n const scrambleKey = 'w0w';\n transport.decorateAppAPIMethods(this, ['signTransaction', 'signMessage'], scrambleKey);\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async sign(): Promise<Uint8Array> {\n throw new NotImplementedError('RAW signing using Ledger HW');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signTypedData(): Promise<Encoded.Signature> {\n throw new NotImplementedError('Typed data signing using Ledger HW');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using Ledger HW');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signNameDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using Ledger HW');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signAllNamesDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using Ledger HW');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signOracleQueryDelegationToContract(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation to contract using Ledger HW');\n }\n\n // eslint-disable-next-line class-methods-use-this\n override async signDelegation(): Promise<Encoded.Signature> {\n throw new NotImplementedError('signing delegation using Ledger HW');\n }\n\n override async signTransaction(\n tx: Encoded.Transaction,\n { innerTx, networkId }: { innerTx?: boolean; networkId?: string } = {},\n ): Promise<Encoded.Transaction> {\n if (innerTx != null) throw new NotImplementedError('innerTx option in AccountLedger');\n if (networkId == null) throw new ArgumentError('networkId', 'provided', networkId);\n\n const rawTx = decode(tx);\n let offset = 0;\n const headerLength = 4 + 1 + 4;\n const networkIdBuffer = Buffer.from(networkId);\n const toSend = [];\n while (offset !== rawTx.length) {\n const maxChunkSize = offset === 0 ? 150 - headerLength - networkIdBuffer.length : 150;\n const chunkSize = offset + maxChunkSize > rawTx.length\n ? rawTx.length - offset : maxChunkSize;\n const buffer = Buffer.alloc(\n offset === 0 ? headerLength + networkIdBuffer.length + chunkSize : chunkSize,\n );\n if (offset === 0) {\n let bufferOffset = buffer.writeUInt32BE(this.index, 0);\n bufferOffset = buffer.writeUInt32BE(rawTx.length, bufferOffset);\n bufferOffset = buffer.writeUInt8(networkIdBuffer.length, bufferOffset);\n bufferOffset += networkIdBuffer.copy(\n buffer,\n bufferOffset,\n 0,\n networkIdBuffer.length,\n );\n rawTx.copy(buffer, bufferOffset, 0, 150 - bufferOffset);\n } else {\n rawTx.copy(buffer, 0, offset, offset + chunkSize);\n }\n toSend.push(buffer);\n offset += chunkSize;\n }\n const response = await toSend.reduce(\n async (previous, data, i) => {\n await previous;\n return this.transport.send(\n CLA,\n SIGN_TRANSACTION,\n i === 0 ? 0x00 : 0x80,\n 0x00,\n data,\n );\n },\n Promise.resolve(Buffer.alloc(0)),\n );\n const signatures = [response.subarray(0, 64)];\n\n return buildTx({ tag: Tag.SignedTx, encodedTx: rawTx, signatures });\n }\n\n override async signMessage(messageStr: string): Promise<Uint8Array> {\n let offset = 0;\n const message = Buffer.from(messageStr);\n const toSend = [];\n while (offset !== message.length) {\n const maxChunkSize = offset === 0 ? 150 - 4 - 4 : 150;\n const chunkSize = offset + maxChunkSize > message.length\n ? message.length - offset : maxChunkSize;\n const buffer = Buffer.alloc(offset === 0 ? 4 + 4 + chunkSize : chunkSize);\n if (offset === 0) {\n buffer.writeUInt32BE(this.index, 0);\n buffer.writeUInt32BE(message.length, 4);\n message.copy(buffer, 4 + 4, offset, offset + chunkSize);\n } else {\n message.copy(buffer, 0, offset, offset + chunkSize);\n }\n toSend.push(buffer);\n offset += chunkSize;\n }\n const response = await toSend.reduce(\n async (previous, data, i) => {\n await previous;\n return this.transport.send(\n CLA,\n SIGN_PERSONAL_MESSAGE,\n i === 0 ? 0x00 : 0x80,\n 0x00,\n data,\n );\n },\n Promise.resolve(Buffer.alloc(0)),\n );\n return response.subarray(0, 64);\n }\n}\n","import type Transport from '@ledgerhq/hw-transport';\nimport AccountLedger, { CLA, GET_ADDRESS, GET_APP_CONFIGURATION } from './Ledger';\nimport { UnsupportedVersionError } from '../utils/errors';\nimport { Encoded } from '../utils/encoder';\nimport semverSatisfies from '../utils/semver-satisfies';\nimport Node from '../Node';\n\n/**\n * A factory class that generates instances of AccountLedger based on provided transport.\n */\nexport default class AccountLedgerFactory {\n readonly transport: Transport;\n\n private readonly versionCheckPromise: Promise<void>;\n\n /**\n * @param transport - Connection to Ledger to use\n */\n constructor(transport: Transport) {\n this.transport = transport;\n this.versionCheckPromise = this.getAppConfiguration().then(({ version }) => {\n const args = [version, '0.4.4', '0.5.0'] as const;\n if (!semverSatisfies(...args)) throw new UnsupportedVersionError('app on ledger', ...args);\n });\n const scrambleKey = 'w0w';\n transport.decorateAppAPIMethods(this, ['getAddress', 'getAppConfiguration'], scrambleKey);\n }\n\n /**\n * @returns the version of app installed on Ledger wallet\n */\n async getAppConfiguration(): Promise<{ version: string }> {\n await this.versionCheckPromise;\n const response = await this.transport.send(CLA, GET_APP_CONFIGURATION, 0x00, 0x00);\n return {\n version: [response[1], response[2], response[3]].join('.'),\n };\n }\n\n /**\n * Get `ak_`-prefixed address for a given account index.\n * @param accountIndex - Index of account\n * @param verify - Ask user to confirm address by showing it on the device screen\n */\n async getAddress(accountIndex: number, verify = false): Promise<Encoded.AccountAddress> {\n await this.versionCheckPromise;\n const buffer = Buffer.alloc(4);\n buffer.writeUInt32BE(accountIndex, 0);\n const response = await this.transport.send(\n CLA,\n GET_ADDRESS,\n verify ? 0x01 : 0x00,\n 0x00,\n buffer,\n );\n const addressLength = response[0];\n return response.subarray(1, 1 + addressLength).toString('ascii') as Encoded.AccountAddress;\n }\n\n /**\n * Get an instance of AccountLedger for a given account index.\n * @param accountIndex - Index of account\n */\n async initialize(accountIndex: number): Promise<AccountLedger> {\n await this.versionCheckPromise;\n return new AccountLedger(this.transport, accountIndex, await this.getAddress(accountIndex));\n }\n\n /**\n * Discovers accounts on Ledger that already have been used (has any on-chain transactions).\n * It returns an empty array if none of accounts been used.\n * If a used account is preceded by an unused account then it would be ignored.\n * @param node - Instance of Node to get account information from\n */\n async discover(node: Node): Promise<AccountLedger[]> {\n let index = 0;\n const result = [];\n let account;\n do {\n if (account != null) result.push(account);\n account = await this.initialize(index);\n index += 1;\n } while (await node.getAccountByPubkey(account.address).then(() => true, () => false));\n return result;\n }\n}\n","import { Encoded } from '../../utils/encoder';\n\ninterface FunctionAci {\n arguments: any[];\n name: string;\n payable: boolean;\n returns: any;\n stateful: boolean;\n}\n\nexport type Aci = Array<{\n contract?: {\n name: string;\n event?: any;\n functions: FunctionAci[];\n kind: string; // known values: 'contract_main'\n payable: boolean;\n typedefs: any[];\n };\n}>;\n\nexport type CompileResult = Promise<{\n bytecode: Encoded.ContractBytearray;\n aci: Aci;\n warnings: Array<{\n message: string;\n pos: {\n file?: string;\n line: number;\n col: number;\n };\n }>;\n}>;\n\n/**\n * A base class for all compiler implementations\n */\nexport default abstract class CompilerBase {\n /**\n * Compile contract by contract's path\n * Available only in Node.js\n * @param path - Path to contract source code\n * @returns ACI and bytecode\n */\n abstract compile(path: string): CompileResult;\n\n /**\n * Compile contract by contract's source code\n * @param sourceCode - Contract source code as string\n * @param fileSystem - A map of contract filename to the corresponding contract source code to\n * include into the main contract\n * @example\n * ```js\n * {\n * 'library.aes': 'namespace TestLib =\\n function sum(x: int, y: int) : int = x + y'\n * }\n * ```\n * @returns ACI and bytecode\n */\n abstract compileBySourceCode(\n sourceCode: string,\n fileSystem?: Record<string, string>,\n ): CompileResult;\n\n /**\n * Generate contract's ACI by contract's path\n * Available only in Node.js\n * @param path - Path to contract source code\n * @returns ACI\n */\n abstract generateAci(path: string): Promise<Aci>;\n\n /**\n * Generate contract's ACI by contract's source code\n * @param sourceCode - Contract source code as string\n * @param fileSystem - A map of contract filename to the corresponding contract source code to\n * include into the main contract\n * @example\n * ```js\n * {\n * 'library.aes': 'namespace TestLib =\\n function sum(x: int, y: int) : int = x + y'\n * }\n * ```\n * @returns ACI\n */\n abstract generateAciBySourceCode(\n sourceCode: string,\n fileSystem?: Record<string, string>,\n ): Promise<Aci>;\n\n /**\n * Verify that a contract bytecode is the result of compiling the given source code\n * Available only in Node.js\n * @param bytecode - Contract bytecode to verify\n * @param path - Path to contract source code\n * @returns ACI and bytecode\n */\n abstract validate(bytecode: Encoded.ContractBytearray, path: string): Promise<boolean>;\n\n /**\n * Verify that a contract bytecode is the result of compiling the given source code\n * @param bytecode - Contract bytecode to verify\n * @param sourceCode - Contract source code as string\n * @param fileSystem - A map of contract filename to the corresponding contract source code to\n * include into the main contract\n * @example\n * ```js\n * {\n * 'library.aes': 'namespace TestLib =\\n function sum(x: int, y: int) : int = x + y'\n * }\n * ```\n */\n abstract validateBySourceCode(\n bytecode: Encoded.ContractBytearray,\n sourceCode: string,\n fileSystem?: Record<string, string>,\n ): Promise<boolean>;\n\n /**\n * @returns Compiler version\n */\n abstract version(): Promise<string>;\n}\n","import * as coreClient from \"@azure/core-client\";\n\nexport const Contract: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Contract\",\n modelProperties: {\n code: {\n serializedName: \"code\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n options: {\n serializedName: \"options\",\n type: {\n name: \"Composite\",\n className: \"CompileOpts\",\n },\n },\n },\n },\n};\n\nexport const CompileOpts: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CompileOpts\",\n modelProperties: {\n fileSystem: {\n serializedName: \"file_system\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n srcFile: {\n serializedName: \"src_file\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const CompilerError: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CompilerError\",\n modelProperties: {\n type: {\n serializedName: \"type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n pos: {\n serializedName: \"pos\",\n type: {\n name: \"Composite\",\n className: \"ErrorPos\",\n },\n },\n message: {\n serializedName: \"message\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n context: {\n serializedName: \"context\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ErrorPos: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ErrorPos\",\n modelProperties: {\n file: {\n serializedName: \"file\",\n type: {\n name: \"String\",\n },\n },\n line: {\n serializedName: \"line\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n col: {\n serializedName: \"col\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const CompileResult: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CompileResult\",\n modelProperties: {\n bytecode: {\n serializedName: \"bytecode\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n aci: {\n serializedName: \"aci\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n warnings: {\n serializedName: \"warnings\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"CompilerError\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const SophiaCallResultInput: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SophiaCallResultInput\",\n modelProperties: {\n source: {\n serializedName: \"source\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n options: {\n serializedName: \"options\",\n type: {\n name: \"Composite\",\n className: \"CompileOpts\",\n },\n },\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callResult: {\n serializedName: \"call-result\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callValue: {\n serializedName: \"call-value\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const BytecodeCallResultInput: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"BytecodeCallResultInput\",\n modelProperties: {\n bytecode: {\n serializedName: \"bytecode\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callResult: {\n serializedName: \"call-result\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callValue: {\n serializedName: \"call-value\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const DecodedCallresult: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DecodedCallresult\",\n modelProperties: {\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n result: {\n serializedName: \"result\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n\nexport const FunctionCallInput: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"FunctionCallInput\",\n modelProperties: {\n source: {\n serializedName: \"source\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n options: {\n serializedName: \"options\",\n type: {\n name: \"Composite\",\n className: \"CompileOpts\",\n },\n },\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n arguments: {\n serializedName: \"arguments\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n },\n },\n};\n\nexport const Calldata: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Calldata\",\n modelProperties: {\n calldata: {\n serializedName: \"calldata\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const DecodeCalldataBytecode: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DecodeCalldataBytecode\",\n modelProperties: {\n calldata: {\n serializedName: \"calldata\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n bytecode: {\n serializedName: \"bytecode\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const DecodedCalldata: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DecodedCalldata\",\n modelProperties: {\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n arguments: {\n serializedName: \"arguments\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n },\n },\n};\n\nexport const ErrorModel: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ErrorModel\",\n modelProperties: {\n reason: {\n serializedName: \"reason\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const DecodeCalldataSource: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DecodeCalldataSource\",\n modelProperties: {\n source: {\n serializedName: \"source\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n options: {\n serializedName: \"options\",\n type: {\n name: \"Composite\",\n className: \"CompileOpts\",\n },\n },\n calldata: {\n serializedName: \"calldata\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ByteCodeInput: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ByteCodeInput\",\n modelProperties: {\n bytecode: {\n serializedName: \"bytecode\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const FateAssembler: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"FateAssembler\",\n modelProperties: {\n fateAssembler: {\n serializedName: \"fate-assembler\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ValidateByteCodeInput: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ValidateByteCodeInput\",\n modelProperties: {\n bytecode: {\n serializedName: \"bytecode\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n source: {\n serializedName: \"source\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n options: {\n serializedName: \"options\",\n type: {\n name: \"Composite\",\n className: \"CompileOpts\",\n },\n },\n },\n },\n};\n\nexport const CompilerVersion: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"CompilerVersion\",\n modelProperties: {\n version: {\n serializedName: \"version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ApiVersion: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ApiVersion\",\n modelProperties: {\n apiVersion: {\n serializedName: \"api-version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const SophiaBinaryData: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SophiaBinaryData\",\n modelProperties: {\n sophiaType: {\n serializedName: \"sophia-type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n data: {\n serializedName: \"data\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const SophiaJsonData: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"SophiaJsonData\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n","import { OperationParameter, OperationURLParameter } from \"@azure/core-client\";\nimport {\n Contract as ContractMapper,\n SophiaCallResultInput as SophiaCallResultInputMapper,\n BytecodeCallResultInput as BytecodeCallResultInputMapper,\n FunctionCallInput as FunctionCallInputMapper,\n DecodeCalldataBytecode as DecodeCalldataBytecodeMapper,\n DecodeCalldataSource as DecodeCalldataSourceMapper,\n ByteCodeInput as ByteCodeInputMapper,\n ValidateByteCodeInput as ValidateByteCodeInputMapper,\n} from \"../models/mappers\";\n\nexport const contentType: OperationParameter = {\n parameterPath: [\"options\", \"contentType\"],\n mapper: {\n defaultValue: \"application/json\",\n isConstant: true,\n serializedName: \"Content-Type\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const body: OperationParameter = {\n parameterPath: \"body\",\n mapper: ContractMapper,\n};\n\nexport const accept: OperationParameter = {\n parameterPath: \"accept\",\n mapper: {\n defaultValue: \"application/json\",\n isConstant: true,\n serializedName: \"Accept\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const $host: OperationURLParameter = {\n parameterPath: \"$host\",\n mapper: {\n serializedName: \"$host\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n skipEncoding: true,\n};\n\nexport const body1: OperationParameter = {\n parameterPath: \"body\",\n mapper: SophiaCallResultInputMapper,\n};\n\nexport const body2: OperationParameter = {\n parameterPath: \"body\",\n mapper: BytecodeCallResultInputMapper,\n};\n\nexport const body3: OperationParameter = {\n parameterPath: \"body\",\n mapper: FunctionCallInputMapper,\n};\n\nexport const body4: OperationParameter = {\n parameterPath: \"body\",\n mapper: DecodeCalldataBytecodeMapper,\n};\n\nexport const body5: OperationParameter = {\n parameterPath: \"body\",\n mapper: DecodeCalldataSourceMapper,\n};\n\nexport const body6: OperationParameter = {\n parameterPath: \"body\",\n mapper: ByteCodeInputMapper,\n};\n\nexport const body7: OperationParameter = {\n parameterPath: \"body\",\n mapper: ValidateByteCodeInputMapper,\n};\n","import * as coreClient from \"@azure/core-client\";\nimport * as Parameters from \"./models/parameters\";\nimport * as Mappers from \"./models/mappers\";\nimport {\n CompilerOptionalParams,\n Contract,\n GenerateACIOptionalParams,\n GenerateACIResponse,\n CompileContractOptionalParams,\n CompileContractResponse,\n SophiaCallResultInput,\n DecodeCallResultOptionalParams,\n DecodeCallResultResponse,\n BytecodeCallResultInput,\n DecodeCallResultBytecodeOptionalParams,\n DecodeCallResultBytecodeResponse,\n FunctionCallInput,\n EncodeCalldataOptionalParams,\n EncodeCalldataResponse,\n DecodeCalldataBytecode,\n DecodeCalldataBytecodeOptionalParams,\n DecodeCalldataBytecodeResponse,\n DecodeCalldataSource,\n DecodeCalldataSourceOptionalParams,\n DecodeCalldataSourceResponse,\n ByteCodeInput,\n GetFateAssemblerCodeOptionalParams,\n GetFateAssemblerCodeResponse,\n ValidateByteCodeInput,\n ValidateByteCodeOptionalParams,\n GetCompilerVersionOptionalParams,\n GetCompilerVersionResponse,\n VersionOptionalParams,\n VersionResponse,\n ApiVersionOptionalParams,\n ApiVersionResponse,\n ApiOptionalParams,\n ApiResponse,\n} from \"./models\";\n\nexport class Compiler extends coreClient.ServiceClient {\n $host: string;\n\n /**\n * Initializes a new instance of the Compiler class.\n * @param $host server parameter\n * @param options The parameter options\n */\n constructor($host: string, options?: CompilerOptionalParams) {\n if ($host === undefined) {\n throw new Error(\"'$host' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: CompilerOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\",\n };\n\n const packageDetails = `azsdk-js-compiler/1.0.0-beta.1`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix,\n },\n endpoint: options.endpoint ?? options.baseUri ?? \"{$host}\",\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.$host = $host;\n }\n\n /**\n * Generate an Aeternity Contract Interface (ACI) for contract\n * @param body contract code\n * @param options The options parameters.\n */\n generateACI(\n body: Contract,\n options?: GenerateACIOptionalParams,\n ): Promise<GenerateACIResponse> {\n return this.sendOperationRequest(\n { body, options },\n generateACIOperationSpec,\n );\n }\n\n /**\n * Compile a sophia contract from source and return byte code and ACI\n * @param body contract code\n * @param options The options parameters.\n */\n compileContract(\n body: Contract,\n options?: CompileContractOptionalParams,\n ): Promise<CompileContractResponse> {\n return this.sendOperationRequest(\n { body, options },\n compileContractOperationSpec,\n );\n }\n\n /**\n * Decode the result of contract call\n * @param body Binary data in Sophia ABI format\n * @param options The options parameters.\n */\n decodeCallResult(\n body: SophiaCallResultInput,\n options?: DecodeCallResultOptionalParams,\n ): Promise<DecodeCallResultResponse> {\n return this.sendOperationRequest(\n { body, options },\n decodeCallResultOperationSpec,\n );\n }\n\n /**\n * Decode the result of contract call from Bytecode\n * @param body Call result + compiled contract\n * @param options The options parameters.\n */\n decodeCallResultBytecode(\n body: BytecodeCallResultInput,\n options?: DecodeCallResultBytecodeOptionalParams,\n ): Promise<DecodeCallResultBytecodeResponse> {\n return this.sendOperationRequest(\n { body, options },\n decodeCallResultBytecodeOperationSpec,\n );\n }\n\n /**\n * Encode Sophia function call according to sophia ABI.\n * @param body Sophia function call - contract code + function name + arguments\n * @param options The options parameters.\n */\n encodeCalldata(\n body: FunctionCallInput,\n options?: EncodeCalldataOptionalParams,\n ): Promise<EncodeCalldataResponse> {\n return this.sendOperationRequest(\n { body, options },\n encodeCalldataOperationSpec,\n );\n }\n\n /**\n * Identify function name and arguments in Calldata for a compiled contract\n * @param body Calldata + compiled contract\n * @param options The options parameters.\n */\n decodeCalldataBytecode(\n body: DecodeCalldataBytecode,\n options?: DecodeCalldataBytecodeOptionalParams,\n ): Promise<DecodeCalldataBytecodeResponse> {\n return this.sendOperationRequest(\n { body, options },\n decodeCalldataBytecodeOperationSpec,\n );\n }\n\n /**\n * Identify function name and arguments in Calldata for a (partial) contract\n * @param body Calldata + contract (stub) code\n * @param options The options parameters.\n */\n decodeCalldataSource(\n body: DecodeCalldataSource,\n options?: DecodeCalldataSourceOptionalParams,\n ): Promise<DecodeCalldataSourceResponse> {\n return this.sendOperationRequest(\n { body, options },\n decodeCalldataSourceOperationSpec,\n );\n }\n\n /**\n * Get FATE assembler code from bytecode\n * @param body contract byte array\n * @param options The options parameters.\n */\n getFateAssemblerCode(\n body: ByteCodeInput,\n options?: GetFateAssemblerCodeOptionalParams,\n ): Promise<GetFateAssemblerCodeResponse> {\n return this.sendOperationRequest(\n { body, options },\n getFateAssemblerCodeOperationSpec,\n );\n }\n\n /**\n * Verify that an encoded byte array is the result of compiling a given contract\n * @param body contract byte array and source code\n * @param options The options parameters.\n */\n validateByteCode(\n body: ValidateByteCodeInput,\n options?: ValidateByteCodeOptionalParams,\n ): Promise<void> {\n return this.sendOperationRequest(\n { body, options },\n validateByteCodeOperationSpec,\n );\n }\n\n /**\n * Extract compiler version from bytecode\n * @param body contract byte array\n * @param options The options parameters.\n */\n getCompilerVersion(\n body: ByteCodeInput,\n options?: GetCompilerVersionOptionalParams,\n ): Promise<GetCompilerVersionResponse> {\n return this.sendOperationRequest(\n { body, options },\n getCompilerVersionOperationSpec,\n );\n }\n\n /**\n * Get the version of the underlying Sophia compiler version\n * @param options The options parameters.\n */\n version(options?: VersionOptionalParams): Promise<VersionResponse> {\n return this.sendOperationRequest({ options }, versionOperationSpec);\n }\n\n /**\n * Get the version of the API\n * @param options The options parameters.\n */\n apiVersion(options?: ApiVersionOptionalParams): Promise<ApiVersionResponse> {\n return this.sendOperationRequest({ options }, apiVersionOperationSpec);\n }\n\n /**\n * Get the Api description\n * @param options The options parameters.\n */\n api(options?: ApiOptionalParams): Promise<ApiResponse> {\n return this.sendOperationRequest({ options }, apiOperationSpec);\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst generateACIOperationSpec: coreClient.OperationSpec = {\n path: \"/aci\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: {\n type: { name: \"Dictionary\", value: { type: { name: \"any\" } } },\n },\n },\n },\n },\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst compileContractOperationSpec: coreClient.OperationSpec = {\n path: \"/compile\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.CompileResult,\n },\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst decodeCallResultOperationSpec: coreClient.OperationSpec = {\n path: \"/decode-call-result\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: { type: { name: \"any\" } },\n },\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body1,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst decodeCallResultBytecodeOperationSpec: coreClient.OperationSpec = {\n path: \"/decode-call-result/bytecode\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.DecodedCallresult,\n },\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body2,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst encodeCalldataOperationSpec: coreClient.OperationSpec = {\n path: \"/encode-calldata\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.Calldata,\n },\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body3,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst decodeCalldataBytecodeOperationSpec: coreClient.OperationSpec = {\n path: \"/decode-calldata/bytecode\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.DecodedCalldata,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n requestBody: Parameters.body4,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst decodeCalldataSourceOperationSpec: coreClient.OperationSpec = {\n path: \"/decode-calldata/source\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.DecodedCalldata,\n },\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body5,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst getFateAssemblerCodeOperationSpec: coreClient.OperationSpec = {\n path: \"/fate-assembler\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.FateAssembler,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n requestBody: Parameters.body6,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst validateByteCodeOperationSpec: coreClient.OperationSpec = {\n path: \"/validate-byte-code\",\n httpMethod: \"POST\",\n responses: {\n 200: {},\n 400: {\n bodyMapper: {\n type: {\n name: \"Sequence\",\n element: { type: { name: \"Composite\", className: \"CompilerError\" } },\n },\n },\n isError: true,\n },\n },\n requestBody: Parameters.body7,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst getCompilerVersionOperationSpec: coreClient.OperationSpec = {\n path: \"/compiler-version\",\n httpMethod: \"POST\",\n responses: {\n 200: {\n bodyMapper: Mappers.CompilerVersion,\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n requestBody: Parameters.body6,\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.contentType, Parameters.accept],\n mediaType: \"json\",\n serializer,\n};\nconst versionOperationSpec: coreClient.OperationSpec = {\n path: \"/version\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.CompilerVersion,\n },\n 500: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst apiVersionOperationSpec: coreClient.OperationSpec = {\n path: \"/api-version\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.ApiVersion,\n },\n 500: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst apiOperationSpec: coreClient.OperationSpec = {\n path: \"/api\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: {\n type: { name: \"Dictionary\", value: { type: { name: \"any\" } } },\n },\n },\n 400: {\n bodyMapper: Mappers.ErrorModel,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\n","import {\n RestError, userAgentPolicyName, setClientRequestIdPolicyName,\n} from '@azure/core-rest-pipeline';\nimport { OperationOptions } from '@azure/core-client';\nimport {\n Compiler as CompilerApi,\n ErrorModel,\n CompilerError as CompilerErrorApi,\n} from '../../apis/compiler';\nimport { genErrorFormatterPolicy, genVersionCheckPolicy } from '../../utils/autorest';\nimport CompilerBase, { Aci, CompileResult } from './Base';\nimport { Encoded } from '../../utils/encoder';\nimport { CompilerError, NotImplementedError } from '../../utils/errors';\n\ntype GeneralCompilerError = ErrorModel & {\n info?: object;\n parameter?: string;\n};\n\n/**\n * Contract Compiler over HTTP\n *\n * This class include api call's related to contract compiler functionality.\n * @category contract\n * @example CompilerHttp('COMPILER_URL')\n */\nexport default class CompilerHttp extends CompilerBase {\n readonly api: CompilerApi;\n\n /**\n * @param compilerUrl - Url for compiler API\n * @param options - Options\n * @param options.ignoreVersion - Don't check compiler version\n */\n constructor(compilerUrl: string, { ignoreVersion = false }: { ignoreVersion?: boolean } = {}) {\n super();\n\n let version: string | undefined;\n const getVersion = async (opts: OperationOptions): Promise<string> => {\n if (version != null) return version;\n version = (await this.api.apiVersion(opts)).apiVersion;\n return version;\n };\n\n this.api = new CompilerApi(compilerUrl, {\n allowInsecureConnection: true,\n additionalPolicies: [\n ...ignoreVersion ? [] : [genVersionCheckPolicy('compiler', getVersion, '7.3.0', '9.0.0')],\n genErrorFormatterPolicy((body: GeneralCompilerError | CompilerErrorApi[]) => {\n let message = '';\n if ('reason' in body) {\n message += ` ${body.reason\n }${body.parameter != null ? ` in ${body.parameter}` : ''\n // TODO: revising after improving documentation https://github.com/aeternity/aesophia_http/issues/78\n }${body.info != null ? ` (${JSON.stringify(body.info)})` : ''}`;\n }\n if (Array.isArray(body)) {\n message += `\\n${body\n .map((e) => `${e.type}:${e.pos.line}:${e.pos.col}: ${e.message}${e.context != null ? ` (${e.context})` : ''}`)\n .join('\\n')}`;\n }\n return message;\n }),\n ],\n });\n this.api.pipeline.removePolicy({ name: userAgentPolicyName });\n this.api.pipeline.removePolicy({ name: setClientRequestIdPolicyName });\n }\n\n async compileBySourceCode(\n sourceCode: string,\n fileSystem?: Record<string, string>,\n ): CompileResult {\n try {\n const cmpOut = await this.api.compileContract({ code: sourceCode, options: { fileSystem } });\n cmpOut.warnings ??= []; // TODO: remove after requiring http compiler above or equal to 8.0.0\n const warnings = cmpOut.warnings.map(({ type, ...warning }) => warning);\n const res = { ...cmpOut, warnings };\n // TODO: should be fixed when the compiledAci interface gets updated\n return res as Awaited<CompileResult>;\n } catch (error) {\n if (error instanceof RestError && error.statusCode === 400) {\n throw new CompilerError(error.message);\n }\n throw error;\n }\n }\n\n // eslint-disable-next-line class-methods-use-this, @typescript-eslint/no-unused-vars\n async compile(path: string): CompileResult {\n throw new NotImplementedError('File system access, use CompilerHttpNode instead');\n }\n\n async generateAciBySourceCode(\n sourceCode: string,\n fileSystem?: Record<string, string>,\n ): Promise<Aci> {\n try {\n return await this.api.generateACI({ code: sourceCode, options: { fileSystem } });\n } catch (error) {\n if (error instanceof RestError && error.statusCode === 400) {\n throw new CompilerError(error.message);\n }\n throw error;\n }\n }\n\n // eslint-disable-next-line class-methods-use-this, @typescript-eslint/no-unused-vars\n async generateAci(path: string): Promise<Aci> {\n throw new NotImplementedError('File system access, use CompilerHttpNode instead');\n }\n\n async validateBySourceCode(\n bytecode: Encoded.ContractBytearray,\n sourceCode: string,\n fileSystem?: Record<string, string>,\n ): Promise<boolean> {\n try {\n await this.api.validateByteCode({ bytecode, source: sourceCode, options: { fileSystem } });\n return true;\n } catch {\n return false;\n }\n }\n\n // eslint-disable-next-line class-methods-use-this, @typescript-eslint/no-unused-vars\n async validate(bytecode: Encoded.ContractBytearray, path: string): Promise<boolean> {\n throw new NotImplementedError('File system access, use CompilerHttpNode instead');\n }\n\n async version(): Promise<string> {\n return (await this.api.version()).version;\n }\n}\n","/**\n * Convert string from snake_case to PascalCase\n * @param s - String to convert\n * @returns Converted string\n */\nexport function snakeToPascal(s: string): string {\n return s.replace(/_./g, (match) => match[1].toUpperCase());\n}\n\n/**\n * Convert string from PascalCase to snake_case\n * @param s - String to convert\n * @returns Converted string\n */\nexport function pascalToSnake(s: string): string {\n return s.replace(/[A-Z]/g, (match) => `_${match.toLowerCase()}`);\n}\n","import { w3cwebsocket as W3CWebSocket, ICloseEvent } from 'websocket';\nimport BigNumber from 'bignumber.js';\nimport type Channel from './Base';\nimport JsonBig from '../utils/json-big';\nimport { pascalToSnake } from '../utils/string';\nimport { Encoded } from '../utils/encoder';\nimport {\n BaseError,\n ChannelCallError,\n ChannelPingTimedOutError,\n UnexpectedTsError,\n UnknownChannelStateError,\n ChannelIncomingMessageError,\n ChannelError,\n} from '../utils/errors';\nimport { encodeContractAddress } from '../utils/crypto';\nimport { buildTx } from '../tx/builder';\nimport { ensureError } from '../utils/other';\n\nexport interface ChannelEvents {\n statusChanged: (status: ChannelStatus) => void;\n stateChanged: (tx: Encoded.Transaction | '') => void;\n depositLocked: () => void;\n ownDepositLocked: () => void;\n withdrawLocked: () => void;\n ownWithdrawLocked: () => void;\n peerDisconnected: () => void;\n channelReestablished: () => void;\n error: (error: Error) => void;\n onChainTx: (tx: Encoded.Transaction, details: { info: string; type: string }) => void;\n message: (message: string | Object) => void;\n newContract: (contractAddress: Encoded.ContractAddress) => void;\n}\n\nexport interface ChannelAction {\n guard: (channel: Channel, state?: ChannelFsm) => boolean;\n action: (channel: Channel, state?: ChannelFsm) => ChannelFsm;\n}\n\ninterface SignOptions {\n updates?: any[];\n [k: string]: any;\n}\nexport type SignTxWithTag = (tag: string, tx: Encoded.Transaction, options?: SignOptions) => (\n Promise<Encoded.Transaction>\n);\n// TODO: SignTx shouldn't return number or null\nexport type SignTx = (tx: Encoded.Transaction, options?: SignOptions) => (\n Promise<Encoded.Transaction | number | null>\n);\n\n/**\n * @see {@link https://github.com/aeternity/protocol/blob/6734de2e4c7cce7e5e626caa8305fb535785131d/node/api/channels_api_usage.md#channel-establishing-parameters}\n */\nexport interface ChannelOptions {\n existingFsmId?: Encoded.Bytearray;\n /**\n * Channel url (for example: \"ws://localhost:3001\")\n */\n url: string;\n\n /**\n * Initiator's public key\n */\n initiatorId: Encoded.AccountAddress;\n /**\n * Responder's public key\n */\n responderId: Encoded.AccountAddress;\n /**\n * Amount of blocks for disputing a solo close\n */\n lockPeriod: number;\n /**\n * Initial deposit in favour of the responder by the initiator\n */\n pushAmount: number;\n /**\n * Amount of coins the initiator has committed to the channel\n */\n initiatorAmount: BigNumber | number;\n /**\n * Amount of coins the responder has committed to the channel\n */\n responderAmount: BigNumber | number;\n /**\n * The minimum amount both peers need to maintain\n */\n channelReserve?: BigNumber | number;\n /**\n * Minimum block height to include the channel_create_tx\n */\n ttl?: number;\n /**\n * Host of the responder's node\n */\n host: string;\n /**\n * The port of the responders node\n */\n port: number;\n /**\n * Participant role\n */\n role: 'initiator' | 'responder';\n /**\n * How to calculate minimum depth (default: txfee)\n */\n minimumDepthStrategy?: 'txfee' | 'plain';\n /**\n * The minimum amount of blocks to be mined\n */\n minimumDepth?: number;\n /**\n * The fee to be used for the channel open transaction\n */\n fee?: BigNumber | number;\n /**\n * Used for the fee computation of the channel open transaction\n */\n gasPrice?: BigNumber | number;\n\n signedTx?: string;\n /**\n * Existing channel id (required if reestablishing a channel)\n */\n existingChannelId?: string;\n /**\n * Offchain transaction (required if reestablishing a channel)\n */\n offChainTx?: string;\n reconnectTx?: string;\n /**\n * The time waiting for a new event to be initiated (default: 600000)\n */\n timeoutIdle?: number;\n /**\n * The time waiting for the initiator to produce the create channel transaction after the noise\n * session had been established (default: 120000)\n */\n timeoutFundingCreate?: number;\n /**\n * The time frame the other client has to sign an off-chain update after our client had initiated\n * and signed it. This applies only for double signed on-chain intended updates: channel create\n * transaction, deposit, withdrawal and etc. (default: 120000)\n */\n timeoutFundingSign?: number;\n /**\n * The time frame the other client has to confirm an on-chain transaction reaching maturity\n * (passing minimum depth) after the local node has detected this. This applies only for double\n * signed on-chain intended updates: channel create transaction, deposit, withdrawal and etc.\n * (default: 360000)\n */\n timeoutFundingLock?: number;\n /**\n * The time frame the client has to return a signed off-chain update or to decline it.\n * This applies for all off-chain updates (default: 500000)\n */\n timeoutSign?: number;\n /**\n * The time frame the other client has to react to an event. This applies for all off-chain\n * updates that are not meant to land on-chain, as well as some special cases: opening a noise\n * connection, mutual closing acknowledgement and reestablishing an existing channel\n * (default: 120000)\n */\n timeoutAccept?: number;\n /**\n * the time frame the responder has to accept an incoming noise session.\n * Applicable only for initiator (default: timeout_accept's value)\n */\n timeoutInitialized?: number;\n /**\n * The time frame the initiator has to start an outgoing noise session to the responder's node.\n * Applicable only for responder (default: timeout_idle's value)\n */\n timeoutAwaitingOpen?: number;\n statePassword?: string;\n /**\n * Log websocket communication and state changes\n */\n debug?: boolean;\n /**\n * Function which verifies and signs transactions\n */\n sign: SignTxWithTag;\n offchainTx?: string;\n}\n\nexport interface ChannelHandler extends Function {\n enter?: Function;\n}\n\nexport interface ChannelState {\n signedTx: Encoded.Transaction;\n resolve: (r?: any) => void;\n reject: (e: BaseError) => void;\n sign: SignTx;\n handler?: ChannelHandler;\n /**\n * Called when transaction has been posted on chain\n */\n onOnChainTx?: (tx: Encoded.Transaction) => void;\n onOwnWithdrawLocked?: () => void;\n onWithdrawLocked?: () => void;\n onOwnDepositLocked?: () => void;\n onDepositLocked?: () => void;\n closeTx?: string;\n}\n\nexport interface ChannelFsm {\n handler: ChannelHandler;\n state?: ChannelState | {\n resolve: Function;\n reject: Function;\n };\n}\n\nexport interface ChannelMessage {\n id?: number;\n method: string;\n params: any;\n payload?: any;\n data?: any;\n error?: ChannelMessageError;\n}\n\ninterface ChannelMessageError {\n code: number;\n message: string;\n data: [{\n message: string;\n code: number;\n }];\n request: ChannelMessage;\n}\n\n// Send ping message every 10 seconds\nconst PING_TIMEOUT_MS = 10000;\n// Close connection if pong message is not received within 15 seconds\nconst PONG_TIMEOUT_MS = 15000;\n\nexport function emit<E extends keyof ChannelEvents>(\n channel: Channel,\n ...args: [E, ...Parameters<ChannelEvents[E]>]\n): void {\n const [eventName, ...rest] = args;\n channel._eventEmitter.emit(eventName, ...rest);\n}\n\nfunction enterState(channel: Channel, nextState: ChannelFsm): void {\n if (nextState == null) {\n throw new UnknownChannelStateError();\n }\n channel._debug('enter state', nextState.handler.name);\n channel._fsm = nextState;\n if (nextState?.handler?.enter != null) {\n nextState.handler.enter(channel);\n }\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n void dequeueAction(channel);\n}\n\n// TODO: rewrite to enum\nexport type ChannelStatus = 'connecting' | 'connected' | 'accepted' | 'halfSigned' | 'signed'\n| 'open' | 'closing' | 'closed' | 'died' | 'disconnected';\n\nexport function changeStatus(channel: Channel, newStatus: ChannelStatus, debug?: unknown): void {\n channel._debug(newStatus, `(prev. ${channel._status})`, debug ?? '');\n if (newStatus === channel._status) return;\n channel._status = newStatus;\n emit(channel, 'statusChanged', newStatus);\n}\n\nexport function changeState(channel: Channel, newState: Encoded.Transaction | ''): void {\n channel._state = newState;\n emit(channel, 'stateChanged', newState);\n}\n\nfunction send(channel: Channel, message: ChannelMessage): void {\n channel._debug('send message', message.method, message.params);\n channel._websocket.send(JsonBig.stringify({ jsonrpc: '2.0', ...message }));\n}\n\nexport function notify(channel: Channel, method: string, params: object = {}): void {\n send(channel, { method, params });\n}\n\nasync function dequeueAction(channel: Channel): Promise<void> {\n if (channel._isActionQueueLocked) return;\n const queue = channel._actionQueue;\n if (queue.length === 0) return;\n const index = queue.findIndex((action) => action.guard(channel, channel._fsm));\n if (index === -1) return;\n channel._actionQueue = queue.filter((_, i) => index !== i);\n channel._isActionQueueLocked = true;\n const nextState: ChannelFsm = await queue[index].action(channel, channel._fsm);\n channel._isActionQueueLocked = false;\n enterState(channel, nextState);\n}\n\nexport async function enqueueAction(\n channel: Channel,\n guard: ChannelAction['guard'],\n action: () => { handler: ChannelHandler; state?: Partial<ChannelState> },\n): Promise<any> {\n const promise = new Promise((resolve, reject) => {\n channel._actionQueue.push({\n guard,\n action() {\n const res = action();\n return { ...res, state: { ...res.state, resolve, reject } };\n },\n });\n });\n void dequeueAction(channel);\n return promise;\n}\n\nasync function handleMessage(channel: Channel, message: ChannelMessage): Promise<void> {\n const { handler, state: st } = channel._fsm;\n const nextState = await Promise.resolve(handler(channel, message, st));\n enterState(channel, nextState);\n // TODO: emit message and handler name (?) to move this code to Contract constructor\n if (\n message?.params?.data?.updates?.[0]?.op === 'OffChainNewContract'\n // if name is channelOpen, the contract was created by other participant\n && nextState?.handler.name === 'channelOpen'\n ) {\n const round = channel.round();\n if (round == null) throw new UnexpectedTsError('Round is null');\n const owner = message?.params?.data?.updates?.[0]?.owner;\n emit(channel, 'newContract', encodeContractAddress(owner, round + 1));\n }\n}\n\nasync function dequeueMessage(channel: Channel): Promise<void> {\n if (channel._isMessageQueueLocked) return;\n channel._isMessageQueueLocked = true;\n while (channel._messageQueue.length > 0) {\n const message = channel._messageQueue.shift();\n if (message == null) throw new UnexpectedTsError();\n try {\n await handleMessage(channel, message);\n } catch (error) {\n ensureError(error);\n emit(channel, 'error', new ChannelIncomingMessageError(error, message));\n }\n }\n channel._isMessageQueueLocked = false;\n}\n\nexport function disconnect(channel: Channel): void {\n channel._websocket.close();\n clearTimeout(channel._pingTimeoutId);\n}\n\nfunction ping(channel: Channel): void {\n clearTimeout(channel._pingTimeoutId);\n channel._pingTimeoutId = setTimeout(() => {\n notify(channel, 'channels.system', { action: 'ping' });\n channel._pingTimeoutId = setTimeout(() => {\n disconnect(channel);\n emit(channel, 'error', new ChannelPingTimedOutError());\n }, PONG_TIMEOUT_MS);\n }, PING_TIMEOUT_MS);\n}\n\nfunction onMessage(channel: Channel, data: string): void {\n const message = JsonBig.parse(data);\n channel._debug('received message', message.method, message.params);\n if (message.id != null) {\n const callback = channel._rpcCallbacks.get(message.id);\n if (callback == null) {\n emit(channel, 'error', new ChannelError(`Can't find callback by id: ${message.id}`));\n return;\n }\n try {\n callback(message);\n } finally {\n channel._rpcCallbacks.delete(message.id);\n }\n return;\n }\n if (message.method === 'channels.message') {\n emit(channel, 'message', message.params.data.message);\n return;\n }\n if (message.method === 'channels.system.pong') {\n if (message.params.channel_id === channel._channelId || channel._channelId == null) {\n ping(channel);\n }\n return;\n }\n channel._messageQueue.push(message);\n void dequeueMessage(channel);\n}\n\nexport async function call(channel: Channel, method: string, params: any): Promise<any> {\n return new Promise((resolve, reject) => {\n const id = channel._nextRpcMessageId;\n channel._nextRpcMessageId += 1;\n channel._rpcCallbacks.set(id, (\n message: { result: PromiseLike<any>; error?: ChannelMessageError },\n ) => {\n if (message.error != null) {\n const details = message.error.data[0].message ?? '';\n reject(new ChannelCallError(message.error.message + details));\n } else resolve(message.result);\n });\n send(channel, { method, id, params });\n });\n}\n\nexport async function initialize(\n channel: Channel,\n connectionHandler: Function,\n openHandler: Function,\n { url, ...channelOptions }: ChannelOptions,\n): Promise<void> {\n channel._options = { url, ...channelOptions };\n\n const wsUrl = new URL(url);\n Object.entries(channelOptions)\n .filter(([key]) => !['sign', 'debug'].includes(key))\n .forEach(([key, value]) => wsUrl.searchParams.set(pascalToSnake(key), value.toString()));\n wsUrl.searchParams.set('protocol', 'json-rpc');\n changeStatus(channel, 'connecting');\n channel._websocket = new W3CWebSocket(wsUrl.toString());\n await new Promise<void>((resolve, reject) => {\n Object.assign(channel._websocket, {\n onerror: reject,\n onopen: async (event: Event) => {\n resolve();\n changeStatus(channel, 'connected', event);\n if (channelOptions.reconnectTx != null) {\n enterState(channel, { handler: openHandler });\n const { signedTx } = await channel.state();\n if (signedTx == null) {\n throw new ChannelError('`signedTx` missed in state while reconnection');\n }\n changeState(channel, buildTx(signedTx));\n } else {\n enterState(channel, { handler: connectionHandler });\n }\n ping(channel);\n },\n onclose: (event: ICloseEvent) => {\n changeStatus(channel, 'disconnected', event);\n clearTimeout(channel._pingTimeoutId);\n },\n onmessage: ({ data }: { data: string }) => onMessage(channel, data),\n });\n });\n}\n","/* eslint-disable consistent-return */\n/* eslint-disable default-case */\n/* eslint-disable @typescript-eslint/no-use-before-define */\nimport {\n ChannelState,\n changeStatus,\n changeState,\n notify,\n emit,\n disconnect,\n ChannelMessage,\n ChannelFsm,\n SignTx,\n ChannelStatus,\n ChannelEvents,\n} from './internal';\nimport { unpackTx, buildTx } from '../tx/builder';\nimport { decode, Encoded } from '../utils/encoder';\nimport {\n IllegalArgumentError,\n InsufficientBalanceError,\n ChannelConnectionError,\n UnexpectedChannelMessageError,\n ChannelError,\n} from '../utils/errors';\nimport type Channel from './Base';\nimport { Tag } from '../tx/builder/constants';\nimport { snakeToPascal } from '../utils/string';\n\nexport async function appendSignature(\n tx: Encoded.Transaction,\n signFn: SignTx,\n): Promise<Encoded.Transaction | number | null> {\n const { signatures, encodedTx } = unpackTx(tx, Tag.SignedTx);\n const payloadTx = buildTx(encodedTx);\n const result = await signFn(payloadTx);\n if (typeof result === 'string') {\n const { signatures: signatures2 } = unpackTx(result, Tag.SignedTx);\n return buildTx({\n tag: Tag.SignedTx,\n signatures: signatures.concat(signatures2),\n encodedTx: decode(payloadTx),\n });\n }\n return result;\n}\n\nexport async function signAndNotify(\n channel: Channel,\n method: string,\n data: {\n tx?: Encoded.Transaction;\n signed_tx?: Encoded.Transaction;\n },\n signFn: SignTx,\n): Promise<boolean> {\n let signedTx;\n if (data.tx != null) signedTx = await signFn(data.tx);\n else if (data.signed_tx != null) signedTx = await appendSignature(data.signed_tx, signFn);\n else throw new ChannelError('Can\\'t find transaction in message');\n const isError = typeof signedTx !== 'string';\n const key = data.tx != null ? 'tx' : 'signed_tx';\n notify(channel, method, isError ? { error: signedTx ?? 1 } : { [key]: signedTx });\n return isError;\n}\n\nexport function handleUnexpectedMessage(\n _channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): ChannelFsm {\n state?.reject?.(Object.assign(\n new UnexpectedChannelMessageError(`Unexpected message received:\\n\\n${JSON.stringify(message)}`),\n { wsMessage: message },\n ));\n return { handler: channelOpen };\n}\n\nexport function awaitingCompletion(\n channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n onSuccess?: typeof handleUnexpectedMessage,\n): ChannelFsm {\n if (onSuccess != null && message.method === 'channels.update') {\n return onSuccess(channel, message, state);\n }\n if (message.method === 'channels.conflict') {\n state.resolve({\n accepted: false,\n errorCode: message.params.data.error_code,\n errorMessage: message.params.data.error_msg,\n });\n return { handler: channelOpen };\n }\n if (message.method === 'channels.info') {\n if (message.params.data.event === 'aborted_update') {\n state.resolve({ accepted: false });\n return { handler: channelOpen };\n }\n }\n if (message.error != null) {\n const codes = message.error.data.map((d) => d.code);\n if (codes.includes(1001)) {\n state.reject(new InsufficientBalanceError('Insufficient balance'));\n } else if (codes.includes(1002)) {\n state.reject(new IllegalArgumentError('Amount cannot be negative'));\n } else {\n state.reject(new ChannelConnectionError(message.error.message));\n }\n return { handler: channelOpen };\n }\n return handleUnexpectedMessage(channel, message, state);\n}\n\nexport function awaitingConnection(\n channel: Channel,\n message: ChannelMessage,\n): ChannelFsm | undefined {\n if (message.method === 'channels.info') {\n const channelInfoStatus: string = message.params.data.event;\n\n let nextStatus: ChannelStatus | null = null;\n if (channelInfoStatus === 'channel_accept') nextStatus = 'accepted';\n if (channelInfoStatus === 'funding_created') nextStatus = 'halfSigned';\n if (nextStatus != null) {\n changeStatus(channel, nextStatus);\n return { handler: awaitingChannelCreateTx };\n }\n\n if (message.params.data.event === 'channel_reestablished') {\n return { handler: awaitingOpenConfirmation };\n }\n if (message.params.data.event === 'fsm_up') {\n channel._fsmId = message.params.data.fsm_id;\n return { handler: awaitingConnection };\n }\n return { handler: awaitingConnection };\n }\n if (message.method === 'channels.error') {\n emit(channel, 'error', new ChannelConnectionError(message?.payload?.message));\n return { handler: channelClosed };\n }\n}\n\nexport async function awaitingReconnection(\n channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): Promise<ChannelFsm> {\n if (message.method === 'channels.info') {\n if (message.params.data.event === 'fsm_up') {\n channel._fsmId = message.params.data.fsm_id;\n const { signedTx } = await channel.state();\n changeState(channel, signedTx == null ? '' : buildTx(signedTx));\n return { handler: channelOpen };\n }\n }\n return handleUnexpectedMessage(channel, message, state);\n}\n\nexport async function awaitingChannelCreateTx(\n channel: Channel,\n message: ChannelMessage,\n): Promise<ChannelFsm | undefined> {\n const tag = channel._options.role === 'initiator' ? 'initiator_sign' : 'responder_sign';\n if (message.method === `channels.sign.${tag}`) {\n await signAndNotify(\n channel,\n `channels.${tag}`,\n message.params.data,\n async (tx) => channel._options.sign(tag, tx),\n );\n return { handler: awaitingOnChainTx };\n }\n}\n\nexport function awaitingOnChainTx(\n channel: Channel,\n message: ChannelMessage,\n): ChannelFsm | undefined {\n function awaitingBlockInclusion(_: Channel, message2: ChannelMessage): ChannelFsm | undefined {\n if (message2.method === 'channels.info') {\n switch (message2.params.data.event) {\n case 'funding_created':\n case 'own_funding_locked':\n return { handler: awaitingBlockInclusion };\n case 'funding_locked':\n return { handler: awaitingOpenConfirmation };\n }\n }\n if (message2.method === 'channels.on_chain_tx') {\n emit(channel, 'onChainTx', message2.params.data.tx, {\n info: message2.params.data.info,\n type: message2.params.data.type,\n });\n return { handler: awaitingBlockInclusion };\n }\n }\n\n if (message.method === 'channels.on_chain_tx') {\n const { info } = message.params.data;\n const { role } = channel._options;\n if ((info === 'funding_signed' && role === 'initiator')\n || (info === 'funding_created' && role === 'responder')) {\n return { handler: awaitingBlockInclusion };\n }\n }\n if (\n message.method === 'channels.info'\n && message.params.data.event === 'funding_signed'\n && channel._options.role === 'initiator'\n ) {\n channel._channelId = message.params.channel_id;\n changeStatus(channel, 'signed');\n return { handler: awaitingOnChainTx };\n }\n}\n\nfunction awaitingOpenConfirmation(\n channel: Channel,\n message: ChannelMessage,\n): ChannelFsm | undefined {\n if (message.method === 'channels.info' && message.params.data.event === 'open') {\n channel._channelId = message.params.channel_id;\n return {\n handler(_: Channel, message2: ChannelMessage): ChannelFsm | undefined {\n if (message2.method === 'channels.update') {\n changeState(channel, message2.params.data.state);\n return { handler: channelOpen };\n }\n },\n };\n }\n}\n\nexport async function channelOpen(\n channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): Promise<ChannelFsm | undefined> {\n switch (message.method) {\n case 'channels.info':\n switch (message.params.data.event) {\n case 'update':\n case 'withdraw_created':\n case 'deposit_created':\n return { handler: awaitingTxSignRequest };\n case 'own_withdraw_locked':\n case 'withdraw_locked':\n case 'own_deposit_locked':\n case 'deposit_locked':\n case 'peer_disconnected':\n case 'channel_reestablished':\n case 'open':\n // TODO: Better handling of peer_disconnected event.\n //\n // We should enter intermediate state where offchain transactions\n // are blocked until channel is reestablished.\n emit(channel, snakeToPascal(message.params.data.event) as keyof ChannelEvents);\n return { handler: channelOpen };\n case 'fsm_up':\n channel._fsmId = message.params.data.fsm_id;\n return { handler: channelOpen };\n case 'timeout':\n case 'close_mutual':\n return { handler: channelOpen };\n case 'closing':\n changeStatus(channel, 'closing');\n return { handler: channelOpen };\n case 'closed_confirmed':\n changeStatus(channel, 'closed');\n return { handler: channelClosed };\n case 'died':\n changeStatus(channel, 'died');\n return { handler: channelClosed };\n case 'shutdown':\n return { handler: channelOpen };\n }\n break;\n case 'channels.on_chain_tx':\n emit(channel, 'onChainTx', message.params.data.tx, {\n info: message.params.data.info,\n type: message.params.data.type,\n });\n return { handler: channelOpen };\n case 'channels.leave':\n // TODO: emit event\n return { handler: channelOpen };\n case 'channels.update':\n changeState(channel, message.params.data.state);\n return { handler: channelOpen };\n case 'channels.sign.shutdown_sign_ack':\n return awaitingTxSignRequest(channel, message, state);\n }\n}\nchannelOpen.enter = (channel: Channel) => {\n changeStatus(channel, 'open');\n};\n\nasync function awaitingTxSignRequest(\n channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): Promise<ChannelFsm> {\n const [, tag] = message.method.match(/^channels\\.sign\\.([^.]+)$/) ?? [];\n if (tag == null) return handleUnexpectedMessage(channel, message, state);\n const isError = await signAndNotify(\n channel,\n `channels.${tag}`,\n message.params.data,\n async (tx) => channel._options.sign(tag, tx, { updates: message.params.data.updates }),\n );\n\n function awaitingUpdateConflict(_: Channel, message2: ChannelMessage): ChannelFsm {\n if (message2.error != null) {\n return { handler: awaitingUpdateConflict, state };\n }\n if (message2.method === 'channels.conflict') {\n return { handler: channelOpen };\n }\n return handleUnexpectedMessage(channel, message2, state);\n }\n return isError ? { handler: awaitingUpdateConflict, state } : { handler: channelOpen };\n}\n\nexport async function awaitingShutdownTx(\n channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): Promise<ChannelFsm> {\n if (message.method !== 'channels.sign.shutdown_sign') {\n return handleUnexpectedMessage(channel, message, state);\n }\n await signAndNotify(\n channel,\n 'channels.shutdown_sign',\n message.params.data,\n async (tx) => state.sign(tx),\n );\n return {\n handler(_: Channel, message2: ChannelMessage): ChannelFsm {\n if (message2.method !== 'channels.on_chain_tx') {\n return handleUnexpectedMessage(channel, message2, state);\n }\n // state.resolve(message.params.data.tx)\n return { handler: channelClosed, state };\n },\n state,\n };\n}\n\nexport function awaitingLeave(\n channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): ChannelFsm {\n if (message.method === 'channels.leave') {\n state.resolve({ channelId: message.params.channel_id, signedTx: message.params.data.state });\n disconnect(channel);\n return { handler: channelClosed };\n }\n if (message.method === 'channels.error') {\n state.reject(new ChannelConnectionError(message.data.message));\n return { handler: channelOpen };\n }\n return handleUnexpectedMessage(channel, message, state);\n}\n\nexport function channelClosed(\n _channel: Channel,\n message: ChannelMessage,\n state: ChannelState,\n): ChannelFsm {\n if (state == null) return { handler: channelClosed };\n if (message.params.data.event === 'closing') return { handler: channelClosed, state };\n if (message.params.data.info === 'channel_closed') {\n state.closeTx = message.params.data.tx;\n return { handler: channelClosed, state };\n }\n if (message.params.data.event === 'closed_confirmed') {\n state.resolve(state.closeTx);\n return { handler: channelClosed };\n }\n return { handler: channelClosed, state };\n}\n","import EventEmitter from 'events';\nimport { w3cwebsocket as W3CWebSocket } from 'websocket';\nimport { snakeToPascal } from '../utils/string';\nimport { buildTx, unpackTx } from '../tx/builder';\nimport { Tag } from '../tx/builder/constants';\nimport * as handlers from './handlers';\nimport {\n initialize,\n enqueueAction,\n notify,\n call,\n disconnect as channelDisconnect,\n SignTx,\n ChannelOptions,\n ChannelState,\n ChannelHandler,\n ChannelAction,\n ChannelStatus,\n ChannelFsm,\n ChannelMessage,\n ChannelEvents,\n} from './internal';\nimport { ChannelError } from '../utils/errors';\nimport { Encoded } from '../utils/encoder';\nimport { TxUnpacked } from '../tx/builder/schema.generated';\n\nfunction snakeToPascalObjKeys<Type>(obj: object): Type {\n return Object.entries(obj).reduce((result, [key, val]) => ({\n ...result,\n [snakeToPascal(key)]: val,\n }), {}) as Type;\n}\n\nlet channelCounter = 0;\n\n/**\n * Channel\n * @example\n * ```js\n * await Channel.initialize({\n * url: 'ws://localhost:3001',\n * role: 'initiator'\n * initiatorId: 'ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH',\n * responderId: 'ak_V6an1xhec1xVaAhLuak7QoEbi6t7w5hEtYWp9bMKaJ19i6A9E',\n * initiatorAmount: 1e18,\n * responderAmount: 1e18,\n * pushAmount: 0,\n * channelReserve: 0,\n * ttl: 1000,\n * host: 'localhost',\n * port: 3002,\n * lockPeriod: 10,\n * async sign (tag, tx) => await account.signTransaction(tx)\n * })\n * ```\n */\nexport default class Channel {\n _eventEmitter = new EventEmitter();\n\n _pingTimeoutId!: NodeJS.Timeout;\n\n _nextRpcMessageId = 0;\n\n _rpcCallbacks = new Map<number, (message: object) => void>();\n\n _fsmId?: Encoded.Bytearray;\n\n _messageQueue: ChannelMessage[] = [];\n\n _isMessageQueueLocked = false;\n\n _actionQueue: ChannelAction[] = [];\n\n _isActionQueueLocked = false;\n\n _status: ChannelStatus = 'disconnected';\n\n _fsm!: ChannelFsm;\n\n _websocket!: W3CWebSocket;\n\n _state: Encoded.Transaction | '' = '';\n\n _options!: ChannelOptions;\n\n readonly #debugId: number;\n\n _channelId?: Encoded.Channel;\n\n protected constructor() {\n channelCounter += 1;\n this.#debugId = channelCounter;\n }\n\n _debug(...args: any[]): void {\n if (this._options.debug !== true) return;\n console.debug(`Channel #${this.#debugId}`, ...args);\n }\n\n /**\n * @param options - Channel params\n */\n static async initialize(options: ChannelOptions): Promise<Channel> {\n return Channel._initialize(new Channel(), options);\n }\n\n static async _initialize<T extends Channel>(channel: T, options: ChannelOptions): Promise<T> {\n await initialize(\n channel,\n options.existingFsmId != null ? handlers.awaitingReconnection : handlers.awaitingConnection,\n handlers.channelOpen,\n options,\n );\n return channel;\n }\n\n /**\n * Register event listener function\n *\n * Possible events:\n *\n * - \"error\"\n * - \"stateChanged\"\n * - \"statusChanged\"\n * - \"message\"\n * - \"peerDisconnected\"\n * - \"onChainTx\"\n * - \"ownWithdrawLocked\"\n * - \"withdrawLocked\"\n * - \"ownDepositLocked\"\n * - \"depositLocked\"\n * - \"channelReestablished\"\n * - \"newContract\"\n *\n *\n * @param eventName - Event name\n * @param callback - Callback function\n */\n on<E extends keyof ChannelEvents>(eventName: E, callback: ChannelEvents[E]): void {\n this._eventEmitter.on(eventName, callback);\n }\n\n /**\n * Remove event listener function\n * @param eventName - Event name\n * @param callback - Callback function\n */\n off<E extends keyof ChannelEvents>(eventName: E, callback: ChannelEvents[E]): void {\n this._eventEmitter.removeListener(eventName, callback);\n }\n\n /**\n * Close the connection\n */\n disconnect(): void {\n return channelDisconnect(this);\n }\n\n /**\n * Get current status\n */\n status(): ChannelStatus {\n return this._status;\n }\n\n /**\n * Get current state\n */\n async state(): Promise<{\n calls: TxUnpacked & { tag: Tag.CallsMtree };\n halfSignedTx?: TxUnpacked & { tag: Tag.SignedTx };\n signedTx?: TxUnpacked & { tag: Tag.SignedTx };\n trees: TxUnpacked & { tag: Tag.StateTrees };\n }> {\n const res = snakeToPascalObjKeys<{\n calls: Encoded.CallStateTree;\n halfSignedTx: Encoded.Transaction | '';\n signedTx: Encoded.Transaction | '';\n trees: Encoded.StateTrees;\n }>(await call(this, 'channels.get.offchain_state', {}));\n return {\n calls: unpackTx(res.calls, Tag.CallsMtree),\n ...res.halfSignedTx !== '' && { halfSignedTx: unpackTx(res.halfSignedTx, Tag.SignedTx) },\n ...res.signedTx !== '' && { signedTx: unpackTx(res.signedTx, Tag.SignedTx) },\n trees: unpackTx(res.trees, Tag.StateTrees),\n };\n }\n\n /**\n * Get current round\n *\n * If round cannot be determined (for example when channel has not been opened)\n * it will return `null`.\n */\n round(): number | null {\n if (this._state === '') {\n return null;\n }\n const params = unpackTx(this._state, Tag.SignedTx).encodedTx;\n switch (params.tag) {\n case Tag.ChannelCreateTx:\n return 1;\n case Tag.ChannelOffChainTx:\n case Tag.ChannelWithdrawTx:\n case Tag.ChannelDepositTx:\n return params.round;\n default:\n return null;\n }\n }\n\n /**\n * Get channel id\n *\n */\n id(): Encoded.Channel {\n if (this._channelId == null) throw new ChannelError('Channel is not initialized');\n return this._channelId;\n }\n\n /**\n * Get channel's fsm id\n *\n */\n fsmId(): Encoded.Bytearray {\n if (this._fsmId == null) throw new ChannelError('Channel is not initialized');\n return this._fsmId;\n }\n\n protected async enqueueAction(\n action: () => { handler: ChannelHandler; state?: Partial<ChannelState> },\n ): Promise<any> {\n return enqueueAction(\n this,\n (channel, state) => state?.handler === handlers.channelOpen,\n action,\n );\n }\n\n /**\n * Leave channel\n *\n * It is possible to leave a channel and then later reestablish the channel\n * off-chain state and continue operation. When a leave method is called,\n * the channel fsm passes it on to the peer fsm, reports the current mutually\n * signed state and then terminates.\n *\n * The channel can be reestablished by instantiating another Channel instance\n * with two extra params: existingChannelId and offchainTx (returned from leave\n * method as channelId and signedTx respectively).\n *\n * @example\n * ```js\n * channel.leave().then(({ channelId, signedTx }) => {\n * console.log(channelId)\n * console.log(signedTx)\n * })\n * ```\n */\n async leave(): Promise<{ channelId: Encoded.Bytearray; signedTx: Encoded.Transaction }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.leave');\n return { handler: handlers.awaitingLeave };\n });\n }\n\n /**\n * Trigger mutual close\n *\n * At any moment after the channel is opened, a closing procedure can be triggered.\n * This can be done by either of the parties. The process is similar to the off-chain updates.\n *\n * @param sign - Function which verifies and signs mutual close transaction\n * @example\n * ```js\n * channel.shutdown(\n * async (tx) => await account.signTransaction(tx)\n * ).then(tx => console.log('on_chain_tx', tx))\n * ```\n */\n async shutdown(sign: SignTx): Promise<Encoded.Transaction> {\n return this.enqueueAction(() => {\n notify(this, 'channels.shutdown');\n return {\n handler: handlers.awaitingShutdownTx,\n state: { sign },\n };\n });\n }\n\n static async reconnect(options: ChannelOptions, txParams: any): Promise<Channel> {\n const { sign } = options;\n\n return Channel.initialize({\n ...options,\n reconnectTx: await sign(\n 'reconnect',\n buildTx({ ...txParams, tag: Tag.ChannelClientReconnectTx }),\n ),\n });\n }\n}\n","import BigNumber from 'bignumber.js';\nimport {\n notify, call, SignTx, ChannelState, ChannelMessage, ChannelFsm, changeState,\n} from './internal';\nimport { Encoded } from '../utils/encoder';\nimport { pause } from '../utils/other';\nimport Channel from './Base';\nimport { ChannelConnectionError } from '../utils/errors';\nimport {\n awaitingCompletion, channelOpen, handleUnexpectedMessage, signAndNotify,\n} from './handlers';\nimport { unpackTx } from '../tx/builder';\nimport { Tag } from '../tx/builder/constants';\nimport { TxUnpacked } from '../tx/builder/schema.generated';\n\nexport default class ChannelSpend extends Channel {\n /**\n * Trigger a transfer update\n *\n * The transfer update is moving coins from one channel account to another.\n * The update is a change to be applied on top of the latest state.\n *\n * Sender and receiver are the channel parties. Both the initiator and responder\n * can take those roles. Any public key outside the channel is considered invalid.\n *\n * @param from - Sender's public address\n * @param to - Receiver's public address\n * @param amount - Transaction amount\n * @param sign - Function which verifies and signs offchain transaction\n * @param metadata - Metadata\n\n * @example\n * ```js\n * channel.update(\n * 'ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH',\n * 'ak_V6an1xhec1xVaAhLuak7QoEbi6t7w5hEtYWp9bMKaJ19i6A9E',\n * 10,\n * async (tx) => await account.signTransaction(tx)\n * ).then(({ accepted, signedTx }) =>\n * if (accepted) {\n * console.log('Update has been accepted')\n * }\n * )\n * ```\n */\n async update(\n from: Encoded.AccountAddress,\n to: Encoded.AccountAddress,\n amount: number | BigNumber,\n sign: SignTx,\n metadata: string[] = [],\n ): Promise<{\n accepted: boolean;\n signedTx?: Encoded.Transaction;\n errorCode?: number;\n errorMessage?: string;\n }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.update.new', {\n from, to, amount, meta: metadata,\n });\n\n const awaitingOffChainTx = async (\n _: Channel,\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> => {\n if (message.method === 'channels.sign.update') {\n const isError = await signAndNotify(\n this,\n 'channels.update',\n message.params.data,\n async (tx) => sign(tx, { updates: message.params.data.updates }),\n );\n if (isError) return { handler: awaitingOffChainTx, state };\n return {\n handler: (_2: Channel, message2: ChannelMessage): ChannelFsm => (\n awaitingCompletion(this, message2, state, () => {\n changeState(this, message2.params.data.state);\n state.resolve({ accepted: true, signedTx: message2.params.data.state });\n return { handler: channelOpen };\n })\n ),\n state,\n };\n }\n if (message.method === 'channels.error') {\n state.reject(new ChannelConnectionError(message.data.message));\n return { handler: channelOpen };\n }\n return awaitingCompletion(this, message, state);\n };\n\n return { handler: awaitingOffChainTx };\n });\n }\n\n /**\n * Get proof of inclusion\n *\n * If a certain address of an account or a contract is not found\n * in the state tree - the response is an error.\n *\n * @param addresses - Addresses\n * @param addresses.accounts - List of account addresses to include in poi\n * @param addresses.contracts - List of contract addresses to include in poi\n * @example\n * ```js\n * channel.poi({\n * accounts: [\n * 'ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH',\n * 'ak_V6an1xhec1xVaAhLuak7QoEbi6t7w5hEtYWp9bMKaJ19i6A9E'\n * ],\n * contracts: ['ct_2dCUAWYZdrWfACz3a2faJeKVTVrfDYxCQHCqAt5zM15f3u2UfA']\n * }).then(poi => console.log(poi))\n * ```\n */\n async poi(\n { accounts, contracts }: {\n accounts: Encoded.AccountAddress[];\n contracts?: Encoded.ContractAddress[];\n },\n ): Promise<TxUnpacked & { tag: Tag.TreesPoi }> {\n return unpackTx(\n (await call(this, 'channels.get.poi', { accounts, contracts })).poi,\n Tag.TreesPoi,\n );\n }\n\n /**\n * Get balances\n *\n * The accounts param contains a list of addresses to fetch balances of.\n * Those can be either account balances or a contract ones, encoded as an account addresses.\n *\n * If a certain account address had not being found in the state tree - it is simply\n * skipped in the response.\n *\n * @param accounts - List of addresses to fetch balances from\n * @example\n * ```js\n * channel.balances([\n * 'ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH',\n * 'ak_V6an1xhec1xVaAhLuak7QoEbi6t7w5hEtYWp9bMKaJ19i6A9E'\n * 'ct_2dCUAWYZdrWfACz3a2faJeKVTVrfDYxCQHCqAt5zM15f3u2UfA'\n * ]).then(balances =>\n * console.log(balances['ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH'])\n * )\n * ```\n */\n async balances(\n accounts: Encoded.AccountAddress[],\n ): Promise<{ [key: Encoded.AccountAddress]: string }> {\n return Object.fromEntries(\n (await call(this, 'channels.get.balances', { accounts }))\n .map((item: {\n account: Encoded.AccountAddress;\n balance: string;\n }) => [item.account, item.balance]),\n );\n }\n\n private async awaitingActionTx(\n action: 'deposit' | 'withdraw',\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> {\n if (message.method !== `channels.sign.${action}_tx`) {\n return handleUnexpectedMessage(this, message, state);\n }\n\n const awaitingActionCompletion = (_: Channel, message2: ChannelMessage): ChannelFsm => {\n if (message2.method === 'channels.on_chain_tx') {\n state.onOnChainTx?.(message2.params.data.tx);\n return { handler: awaitingActionCompletion, state };\n }\n if (\n message2.method === 'channels.info'\n && [`own_${action}_locked`, `${action}_locked`].includes(message2.params.data.event)\n ) {\n const Action = action === 'deposit' ? 'Deposit' : 'Withdraw';\n const isOwn: boolean = message2.params.data.event.startsWith('own_');\n state[`on${isOwn ? 'Own' : ''}${Action}Locked`]?.();\n return { handler: awaitingActionCompletion, state };\n }\n return awaitingCompletion(this, message2, state, () => {\n changeState(this, message2.params.data.state);\n state.resolve({ accepted: true, signedTx: message2.params.data.state });\n return { handler: channelOpen };\n });\n };\n\n const { sign } = state;\n await signAndNotify(\n this,\n `channels.${action}_tx`,\n message.params.data,\n async (tx) => sign(tx, { updates: message.params.data.updates }),\n );\n return { handler: awaitingActionCompletion, state };\n }\n\n /**\n * Withdraw coins from the channel\n *\n * After the channel had been opened any of the participants can initiate a withdrawal.\n * The process closely resembles the update. The most notable difference is that the\n * transaction has been co-signed: it is channel_withdraw_tx and after the procedure\n * is finished - it is being posted on-chain.\n *\n * Any of the participants can initiate a withdrawal. The only requirements are:\n *\n * - Channel is already opened\n * - No off-chain update/deposit/withdrawal is currently being performed\n * - Channel is not being closed or in a solo closing state\n * - The withdrawal amount must be equal to or greater than zero, and cannot exceed\n * the available balance on the channel (minus the channel_reserve)\n *\n * After the other party had signed the withdraw transaction, the transaction is posted\n * on-chain and onOnChainTx callback is called with on-chain transaction as first argument.\n * After computing transaction hash it can be tracked on the chain: entering the mempool,\n * block inclusion and a number of confirmations.\n *\n * After the minimum_depth block confirmations onOwnWithdrawLocked callback is called\n * (without any arguments).\n *\n * When the other party had confirmed that the block height needed is reached\n * onWithdrawLocked callback is called (without any arguments).\n *\n * @param amount - Amount of coins to withdraw\n * @param sign - Function which verifies and signs withdraw transaction\n * @param callbacks - Callbacks\n * @example\n * ```js\n * channel.withdraw(\n * 100,\n * async (tx) => await account.signTransaction(tx),\n * { onOnChainTx: (tx) => console.log('on_chain_tx', tx) }\n * ).then(({ accepted, signedTx }) => {\n * if (accepted) {\n * console.log('Withdrawal has been accepted')\n * } else {\n * console.log('Withdrawal has been rejected')\n * }\n * })\n * ```\n */\n async withdraw(\n amount: number | BigNumber,\n sign: SignTx,\n { onOnChainTx, onOwnWithdrawLocked, onWithdrawLocked }:\n Pick<ChannelState, 'onOnChainTx' | 'onOwnWithdrawLocked' | 'onWithdrawLocked'> = {},\n ): Promise<{ accepted: boolean; signedTx: Encoded.Transaction }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.withdraw', { amount });\n return {\n handler: async (\n _: Channel,\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> => (\n this.awaitingActionTx('withdraw', message, state)\n ),\n state: {\n sign,\n onOnChainTx,\n onOwnWithdrawLocked,\n onWithdrawLocked,\n },\n };\n });\n }\n\n /**\n * Deposit coins into the channel\n *\n * After the channel had been opened any of the participants can initiate a deposit.\n * The process closely resembles the update. The most notable difference is that the\n * transaction has been co-signed: it is channel_deposit_tx and after the procedure\n * is finished - it is being posted on-chain.\n *\n * Any of the participants can initiate a deposit. The only requirements are:\n *\n * - Channel is already opened\n * - No off-chain update/deposit/withdrawal is currently being performed\n * - Channel is not being closed or in a solo closing state\n * - The deposit amount must be equal to or greater than zero, and cannot exceed\n * the available balance on the channel (minus the channel_reserve)\n *\n * After the other party had signed the deposit transaction, the transaction is posted\n * on-chain and onOnChainTx callback is called with on-chain transaction as first argument.\n * After computing transaction hash it can be tracked on the chain: entering the mempool,\n * block inclusion and a number of confirmations.\n *\n * After the minimum_depth block confirmations onOwnDepositLocked callback is called\n * (without any arguments).\n *\n * When the other party had confirmed that the block height needed is reached\n * onDepositLocked callback is called (without any arguments).\n *\n * @param amount - Amount of coins to deposit\n * @param sign - Function which verifies and signs deposit transaction\n * @param callbacks - Callbacks\n * @example\n * ```js\n * channel.deposit(\n * 100,\n * async (tx) => await account.signTransaction(tx),\n * { onOnChainTx: (tx) => console.log('on_chain_tx', tx) }\n * ).then(({ accepted, state }) => {\n * if (accepted) {\n * console.log('Deposit has been accepted')\n * console.log('The new state is:', state)\n * } else {\n * console.log('Deposit has been rejected')\n * }\n * })\n * ```\n */\n async deposit(\n amount: number | BigNumber,\n sign: SignTx,\n { onOnChainTx, onOwnDepositLocked, onDepositLocked }:\n Pick<ChannelState, 'onOnChainTx' | 'onOwnDepositLocked' | 'onDepositLocked'> = {},\n ): Promise<{ accepted: boolean; state: ChannelState }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.deposit', { amount });\n return {\n handler: async (\n _: Channel,\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> => (\n this.awaitingActionTx('deposit', message, state)\n ),\n state: {\n sign,\n onOnChainTx,\n onOwnDepositLocked,\n onDepositLocked,\n },\n };\n });\n }\n\n /**\n * Send generic message\n *\n * If message is an object it will be serialized into JSON string\n * before sending.\n *\n * If there is ongoing update that has not yet been finished the message\n * will be sent after that update is finalized.\n *\n * @param message - Message\n * @param recipient - Address of the recipient\n * @example\n * ```js\n * channel.sendMessage(\n * 'hello world',\n * 'ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH'\n * )\n * ```\n */\n async sendMessage(\n message: string | object,\n recipient: Encoded.AccountAddress,\n ): Promise<void> {\n const info = typeof message === 'object' ? JSON.stringify(message) : message;\n if (this.status() === 'connecting') {\n await new Promise<void>((resolve) => {\n const onStatusChanged = (status: string): void => {\n if (status === 'connecting') return;\n resolve();\n this.off('statusChanged', onStatusChanged);\n };\n this.on('statusChanged', onStatusChanged);\n });\n // For some reason we can't immediately send a message when connection is\n // established. Thus we wait 500ms which seems to work.\n await pause(500);\n }\n notify(this, 'channels.message', { info, to: recipient });\n }\n}\n","import BigNumber from 'bignumber.js';\nimport { snakeToPascal } from '../utils/string';\nimport {\n MIN_GAS_PRICE, Tag, AbiVersion, VmVersion,\n} from '../tx/builder/constants';\nimport {\n signAndNotify,\n awaitingCompletion,\n channelClosed,\n channelOpen,\n handleUnexpectedMessage,\n} from './handlers';\nimport {\n notify, call, SignTx, ChannelState, ChannelOptions, ChannelMessage, ChannelFsm, changeState, emit,\n} from './internal';\nimport { Encoded } from '../utils/encoder';\nimport { ContractCallReturnType } from '../apis/node';\nimport { ContractCallObject } from '../contract/Contract';\nimport Channel from './Base';\nimport ChannelSpend from './Spend';\nimport { ChannelError, UnexpectedChannelMessageError } from '../utils/errors';\nimport { unpackTx } from '../tx/builder';\nimport { encodeContractAddress } from '../utils/crypto';\n\nfunction snakeToPascalObjKeys<Type>(obj: object): Type {\n return Object.entries(obj).reduce((result, [key, val]) => ({\n ...result,\n [snakeToPascal(key)]: val,\n }), {}) as Type;\n}\n\ninterface CallContractOptions {\n /**\n * Amount the caller of the contract commits to it\n */\n amount?: number | BigNumber;\n /**\n * ABI encoded compiled AEVM call data for the code\n */\n callData?: Encoded.ContractBytearray;\n /**\n * Version of the ABI\n */\n abiVersion?: AbiVersion;\n /**\n * Address of the contract to call\n */\n contract?: Encoded.ContractAddress;\n}\n\ninterface CallContractResult extends CallContractOptions {\n returnValue?: any;\n gasUsed?: number | BigNumber;\n gasPrice?: number | BigNumber;\n height?: number;\n callerNonce?: number;\n log?: any;\n returnType?: ContractCallReturnType;\n}\n\ninterface Contract {\n abiVersion: AbiVersion;\n active: boolean;\n deposit: number | BigNumber;\n id: string;\n ownerId: string;\n referrerIds: string[];\n vmVersion: VmVersion;\n}\n\nexport default class ChannelContract extends ChannelSpend {\n static override async initialize(options: ChannelOptions): Promise<ChannelContract> {\n return Channel._initialize(new ChannelContract(), options);\n }\n\n /**\n * Trigger create contract update\n *\n * The create contract update is creating a contract inside the channel's internal state tree.\n * The update is a change to be applied on top of the latest state.\n *\n * That would create a contract with the poster being the owner of it. Poster commits initially\n * a deposit amount of coins to the new contract.\n *\n * @param options - Options\n * @param options.code - Api encoded compiled AEVM byte code\n * @param options.callData - Api encoded compiled AEVM call data for the code\n * @param options.deposit - Initial amount the owner of the contract commits to it\n * @param options.vmVersion - Version of the Virtual Machine\n * @param options.abiVersion - Version of the Application Binary Interface\n * @param sign - Function which verifies and signs create contract transaction\n * @example\n * ```js\n * channel.createContract({\n * code: 'cb_HKtpipK4aCgYb17wZ...',\n * callData: 'cb_1111111111111111...',\n * deposit: 10,\n * vmVersion: 3,\n * abiVersion: 1\n * }).then(({ accepted, signedTx, address }) => {\n * if (accepted) {\n * console.log('New contract has been created')\n * console.log('Contract address:', address)\n * } else {\n * console.log('New contract has been rejected')\n * }\n * })\n * ```\n */\n async createContract(\n {\n code, callData, deposit, vmVersion, abiVersion,\n }: {\n code: Encoded.ContractBytearray;\n callData: Encoded.ContractBytearray;\n deposit: number | BigNumber;\n vmVersion: VmVersion;\n abiVersion: AbiVersion;\n },\n sign: SignTx,\n ): Promise<{\n accepted: boolean; signedTx: Encoded.Transaction; address: Encoded.ContractAddress;\n }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.update.new_contract', {\n code,\n call_data: callData,\n deposit,\n vm_version: vmVersion,\n abi_version: abiVersion,\n });\n return {\n handler: async (\n _: Channel,\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> => {\n if (message.method !== 'channels.sign.update') {\n return handleUnexpectedMessage(this, message, state);\n }\n await signAndNotify(\n this,\n 'channels.update',\n message.params.data,\n async (tx) => state.sign(tx),\n );\n return {\n handler: (\n _2: Channel,\n message2: ChannelMessage,\n state2: ChannelState,\n ): ChannelFsm => (\n awaitingCompletion(this, message2, state2, () => {\n const params = unpackTx(message2.params.data.state, Tag.SignedTx).encodedTx;\n if (params.tag !== Tag.ChannelOffChainTx) {\n throw new ChannelError(`Tag should be ${Tag[Tag.ChannelOffChainTx]}, got ${Tag[params.tag]} instead`);\n }\n const addressKey = this._options.role === 'initiator'\n ? 'initiatorId' : 'responderId';\n const owner = this._options[addressKey];\n changeState(this, message2.params.data.state);\n const address = encodeContractAddress(owner, params.round);\n emit(this, 'newContract', address);\n state2.resolve({ accepted: true, address, signedTx: message2.params.data.state });\n return { handler: channelOpen };\n })\n ),\n state,\n };\n },\n state: { sign },\n };\n });\n }\n\n /**\n * Trigger call a contract update\n *\n * The call contract update is calling a preexisting contract inside the channel's\n * internal state tree. The update is a change to be applied on top of the latest state.\n *\n * That would call a contract with the poster being the caller of it. Poster commits\n * an amount of coins to the contract.\n *\n * The call would also create a call object inside the channel state tree. It contains\n * the result of the contract call.\n *\n * It is worth mentioning that the gas is not consumed, because this is an off-chain\n * contract call. It would be consumed if it were an on-chain one. This could happen\n * if a call with a similar computation amount is to be forced on-chain.\n *\n * @param options - Options\n * @param sign - Function which verifies and signs contract call transaction\n * @example\n * ```js\n * channel.callContract({\n * contract: 'ct_9sRA9AVE4BYTAkh5RNfJYmwQe1NZ4MErasQLXZkFWG43TPBqa',\n * callData: 'cb_1111111111111111...',\n * amount: 0,\n * abiVersion: 1\n * }).then(({ accepted, signedTx }) => {\n * if (accepted) {\n * console.log('Contract called succesfully')\n * } else {\n * console.log('Contract call has been rejected')\n * }\n * })\n * ```\n */\n async callContract(\n {\n amount, callData, contract, abiVersion,\n }: CallContractOptions,\n sign: SignTx,\n ): Promise<{ accepted: boolean; signedTx: Encoded.Transaction }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.update.call_contract', {\n amount,\n call_data: callData,\n contract_id: contract,\n abi_version: abiVersion,\n });\n return {\n handler: async (\n _: Channel,\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> => {\n if (message.method !== 'channels.sign.update') {\n return handleUnexpectedMessage(this, message, state);\n }\n await signAndNotify(\n this,\n 'channels.update',\n message.params.data,\n async (tx) => state.sign(tx, { updates: message.params.data.updates }),\n );\n return {\n handler: (\n _2: Channel,\n message2: ChannelMessage,\n state2: ChannelState,\n ): ChannelFsm => (\n awaitingCompletion(this, message2, state2, () => {\n changeState(this, message2.params.data.state);\n state2.resolve({ accepted: true, signedTx: message2.params.data.state });\n return { handler: channelOpen };\n })\n ),\n state,\n };\n },\n state: { sign },\n };\n });\n }\n\n /**\n * Trigger a force progress contract call\n * This call is going on-chain\n * @param options - Options\n * @param sign - Function which verifies and signs contract force progress transaction\n * @param callbacks - Callbacks\n * @example\n * ```js\n * channel.forceProgress({\n * contract: 'ct_9sRA9AVE4BYTAkh5RNfJYmwQe1NZ4MErasQLXZkFWG43TPBqa',\n * callData: 'cb_1111111111111111...',\n * amount: 0,\n * abiVersion: 1,\n * gasPrice: 1000005554\n * }).then(({ accepted, signedTx }) => {\n * if (accepted) {\n * console.log('Contract force progress call successful')\n * } else {\n * console.log('Contract force progress call has been rejected')\n * }\n * })\n * ```\n */\n async forceProgress(\n {\n amount, callData, contract, abiVersion, gasLimit = 1000000, gasPrice = MIN_GAS_PRICE,\n }: CallContractOptions & {\n gasLimit?: number;\n gasPrice?: number;\n },\n sign: SignTx,\n { onOnChainTx }: Pick<ChannelState, 'onOnChainTx'> = {},\n ): Promise<{\n accepted: boolean;\n signedTx: Encoded.Transaction;\n tx: Encoded.Transaction | Uint8Array;\n }> {\n return this.enqueueAction(() => {\n notify(this, 'channels.force_progress', {\n amount,\n call_data: callData,\n contract_id: contract,\n abi_version: abiVersion,\n gas_price: gasPrice,\n gas: gasLimit,\n });\n return {\n handler: async (\n _: Channel,\n message: ChannelMessage,\n state: ChannelState,\n ): Promise<ChannelFsm> => {\n if (message.method !== 'channels.sign.force_progress_tx') {\n return handleUnexpectedMessage(this, message, state);\n }\n await signAndNotify(\n this,\n 'channels.force_progress_sign',\n message.params.data,\n async (tx) => state.sign(tx, { updates: message.params.data.updates }),\n );\n return {\n handler: (\n _2: Channel,\n message2: ChannelMessage,\n state2: ChannelState,\n ): ChannelFsm => {\n if (message2.method === 'channels.on_chain_tx') {\n state2.onOnChainTx?.(message2.params.data.tx);\n emit(this, 'onChainTx', message2.params.data.tx, {\n info: message2.params.data.info,\n type: message2.params.data.type,\n });\n state2.resolve({ accepted: true, tx: message2.params.data.tx });\n // TODO: shouldn't be unexpected message in this case\n }\n return handleUnexpectedMessage(this, message2, state2);\n },\n state,\n };\n },\n state: { sign, onOnChainTx },\n };\n });\n }\n\n /**\n * Call contract using dry-run\n *\n * In order to get the result of a potential contract call, one might need to\n * dry-run a contract call. It takes the exact same arguments as a call would\n * and returns the call object.\n *\n * The call is executed in the channel's state, but it does not impact the state\n * whatsoever. It uses as an environment the latest channel's state and the current\n * top of the blockchain as seen by the node.\n *\n * @param options - Options\n * @example\n * ```js\n * channel.callContractStatic({\n * contract: 'ct_9sRA9AVE4BYTAkh5RNfJYmwQe1NZ4MErasQLXZkFWG43TPBqa',\n * callData: 'cb_1111111111111111...',\n * amount: 0,\n * abiVersion: 1\n * }).then(({ returnValue, gasUsed }) => {\n * console.log('Returned value:', returnValue)\n * console.log('Gas used:', gasUsed)\n * })\n * ```\n */\n async callContractStatic(\n {\n amount, callData, contract, abiVersion,\n }: CallContractOptions,\n ): Promise<CallContractResult> {\n return snakeToPascalObjKeys(await call(this, 'channels.dry_run.call_contract', {\n amount,\n call_data: callData,\n contract_id: contract,\n abi_version: abiVersion,\n }));\n }\n\n /**\n * Get contract call result\n *\n * The combination of a caller, contract and a round of execution determines the\n * contract call. Providing an incorrect set of those results in an error response.\n *\n * @param options - Options\n * @param options.caller - Address of contract caller\n * @param options.contract - Address of the contract\n * @param options.round - Round when contract was called\n * @example\n * ```js\n * channel.getContractCall({\n * caller: 'ak_Y1NRjHuoc3CGMYMvCmdHSBpJsMDR6Ra2t5zjhRcbtMeXXLpLH',\n * contract: 'ct_9sRA9AVE4BYTAkh5RNfJYmwQe1NZ4MErasQLXZkFWG43TPBqa',\n * round: 3\n * }).then(({ returnType, returnValue }) => {\n * if (returnType === 'ok') console.log(returnValue)\n * })\n * ```\n */\n async getContractCall(\n { caller, contract, round }: {\n caller: Encoded.AccountAddress;\n contract: Encoded.ContractAddress;\n round: number;\n },\n ): Promise<ContractCallObject> {\n return snakeToPascalObjKeys(\n await call(this, 'channels.get.contract_call', {\n caller_id: caller,\n contract_id: contract,\n round,\n }),\n );\n }\n\n /**\n * Get the latest contract state\n *\n * @param contract - Address of the contract\n * @example\n * ```js\n * channel.getContractState(\n * 'ct_9sRA9AVE4BYTAkh5RNfJYmwQe1NZ4MErasQLXZkFWG43TPBqa'\n * ).then(({ contract }) => {\n * console.log('deposit:', contract.deposit)\n * })\n * ```\n */\n async getContractState(\n contract: Encoded.ContractAddress,\n ): Promise<{ contract: Contract; contractState: object }> {\n const result = await call(this, 'channels.get.contract', { pubkey: contract });\n return snakeToPascalObjKeys({\n ...result,\n contract: snakeToPascalObjKeys(result.contract),\n });\n }\n\n /**\n * Clean up all locally stored contract calls\n *\n * Contract calls are kept locally in order for the participant to be able to look them up.\n * They consume memory and in order for the participant to free it - one can prune all messages.\n * This cleans up all locally stored contract calls and those will no longer be available for\n * fetching and inspection.\n */\n async cleanContractCalls(): Promise<void> {\n return this.enqueueAction(() => {\n notify(this, 'channels.clean_contract_calls');\n return {\n handler(_: Channel, message: ChannelMessage, state: ChannelState): ChannelFsm {\n if (message.method === 'channels.calls_pruned.reply') {\n state.resolve();\n return { handler: channelOpen };\n }\n state.reject(new UnexpectedChannelMessageError('Unexpected message received'));\n return { handler: channelClosed };\n },\n };\n });\n }\n}\n","/* eslint-disable max-classes-per-file */\nimport WebSocket from 'isomorphic-ws';\nimport { BaseError, UnexpectedTsError, InternalError } from './utils/errors';\nimport { Encoded } from './utils/encoder';\n\ninterface Message {\n payload: Object;\n source: Source.Middleware | Source.Node;\n subscription: 'KeyBlocks' | 'MicroBlocks' | 'Transactions' | 'Object';\n target?: string;\n}\n\nenum Source {\n Middleware = 'mdw',\n Node = 'node',\n All = 'all',\n}\n\nexport class MiddlewareSubscriberError extends BaseError {\n constructor(message: string) {\n super(message);\n this.name = 'MiddlewareSubscriberError';\n }\n}\n\nexport class MiddlewareSubscriberDisconnected extends MiddlewareSubscriberError {\n constructor(readonly closeEvent: WebSocket.CloseEvent) {\n super('Connection closed');\n this.name = 'MiddlewareSubscriberDisconnected';\n }\n}\n\nexport default class MiddlewareSubscriber {\n #subscriptions: Array<\n readonly [target: string, s: Source, cb: (p?: Object, e?: Error) => void]\n > = [];\n\n readonly #requestQueue: Array<[isSubscribe: boolean, target: string]> = [];\n\n #webSocket?: WebSocket;\n\n get webSocket(): WebSocket | undefined {\n return this.#webSocket;\n }\n\n get #targets(): Set<string> {\n return new Set(this.#subscriptions.map(([target]) => target));\n }\n\n #sendMessage(message: any): void {\n if (this.#webSocket == null) throw new UnexpectedTsError();\n this.#webSocket.send(JSON.stringify(message));\n }\n\n #sendSubscribe(isSubscribe: boolean, target: string): void {\n if (this.#webSocket == null) return;\n const payload = ['KeyBlocks', 'MicroBlocks', 'Transactions'].includes(target)\n ? target : 'Object';\n this.#sendMessage({\n op: isSubscribe ? 'Subscribe' : 'Unsubscribe',\n payload,\n ...payload === 'Object' && { target },\n });\n this.#requestQueue.push([isSubscribe, target]);\n }\n\n #emit(condition: (target: string, source: Source) => boolean, p?: Object, e?: Error): void {\n this.#subscriptions\n .filter(([target, source]) => condition(target, source))\n .forEach(([, , cb]) => cb(p, e));\n }\n\n constructor(readonly url: string) {\n }\n\n #disconnect(onlyReset = false): void {\n if (this.#webSocket == null) return;\n if (!onlyReset) this.#webSocket.close();\n Object.assign(this.#webSocket, {\n onopen: undefined,\n onerror: undefined,\n onmessage: undefined,\n });\n this.#webSocket = undefined;\n }\n\n async reconnect(): Promise<void> {\n this.#disconnect();\n this.#webSocket = await new Promise((resolve) => {\n const webSocket = new WebSocket(this.url);\n Object.assign(webSocket, {\n onopen: () => resolve(webSocket),\n onerror: (errorEvent: WebSocket.ErrorEvent) => {\n this.#emit(() => true, undefined, errorEvent.error);\n },\n onmessage: (event: WebSocket.MessageEvent) => {\n if (typeof event.data !== 'string') {\n throw new InternalError(`Unknown incoming message type: ${typeof event.data}`);\n }\n this.#messageHandler(JSON.parse(event.data));\n },\n onclose: (event: WebSocket.CloseEvent) => {\n this.#emit(() => true, undefined, new MiddlewareSubscriberDisconnected(event));\n this.#disconnect(true);\n },\n });\n });\n await Promise.all([...this.#targets].map((target) => this.#sendSubscribe(true, target)));\n }\n\n #messageHandler(message: string | string[] | Message): void {\n if (typeof message === 'string' || Array.isArray(message)) {\n const request = this.#requestQueue.shift();\n if (request == null) throw new InternalError('Request queue is empty');\n const [isSubscribe, target] = request;\n let error;\n if (typeof message === 'string') error = new MiddlewareSubscriberError(message);\n if (message.includes(target) !== isSubscribe) {\n error = new InternalError(`Expected ${target} to be${isSubscribe ? '' : ' not'} included into ${message}`);\n }\n if (error != null) this.#emit((t) => target === t, undefined, error);\n return;\n }\n this.#emit(\n (target, source) => (target === message.subscription || target === message.target)\n && (source === message.source || source === Source.All),\n message.payload,\n );\n }\n\n #subscribe(target: string, source: Source, cb: (p?: Object, e?: Error) => void): () => void {\n const subscription = [target, source, cb] as const;\n if (this.#targets.size === 0) this.reconnect();\n if (!this.#targets.has(target)) this.#sendSubscribe(true, target);\n this.#subscriptions.push(subscription);\n return () => {\n this.#subscriptions = this.#subscriptions.filter((item) => item !== subscription);\n if (!this.#targets.has(target)) this.#sendSubscribe(false, target);\n if (this.#targets.size === 0) this.#disconnect();\n };\n }\n\n // TODO: replace p?: any with a proper type definition\n\n subscribeKeyBlocks(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('KeyBlocks', Source.Middleware, cb);\n }\n\n subscribeKeyBlocksNode(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('KeyBlocks', Source.Node, cb);\n }\n\n subscribeKeyBlocksAll(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('KeyBlocks', Source.All, cb);\n }\n\n subscribeMicroBlocks(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('MicroBlocks', Source.Middleware, cb);\n }\n\n subscribeMicroBlocksNode(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('MicroBlocks', Source.Node, cb);\n }\n\n subscribeMicroBlocksAll(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('MicroBlocks', Source.All, cb);\n }\n\n subscribeTransactions(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('Transactions', Source.Middleware, cb);\n }\n\n subscribeTransactionsNode(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('Transactions', Source.Node, cb);\n }\n\n subscribeTransactionsAll(cb: (p?: any, e?: Error) => void): () => void {\n return this.#subscribe('Transactions', Source.All, cb);\n }\n\n subscribeObject(\n target: Encoded.KeyBlockHash | Encoded.Channel | Encoded.ContractAddress\n | Encoded.OracleAddress | Encoded.OracleQueryId | Encoded.AccountAddress\n | Encoded.Name | `${string}.chain`,\n cb: (p?: any, e?: Error) => void,\n ): () => void {\n return this.#subscribe(target, Source.Middleware, cb);\n }\n\n subscribeObjectNode(\n target: Encoded.KeyBlockHash | Encoded.Channel | Encoded.ContractAddress\n | Encoded.OracleAddress | Encoded.OracleQueryId | Encoded.AccountAddress\n | Encoded.Name | `${string}.chain`,\n cb: (p?: any, e?: Error) => void,\n ): () => void {\n return this.#subscribe(target, Source.Node, cb);\n }\n\n subscribeObjectAll(\n target: Encoded.KeyBlockHash | Encoded.Channel | Encoded.ContractAddress\n | Encoded.OracleAddress | Encoded.OracleQueryId | Encoded.AccountAddress\n | Encoded.Name | `${string}.chain`,\n cb: (p?: any, e?: Error) => void,\n ): () => void {\n return this.#subscribe(target, Source.All, cb);\n }\n}\n","import {\n OperationParameter,\n OperationURLParameter,\n OperationQueryParameter,\n} from \"@azure/core-client\";\n\nexport const accept: OperationParameter = {\n parameterPath: \"accept\",\n mapper: {\n defaultValue: \"application/json\",\n isConstant: true,\n serializedName: \"Accept\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const $host: OperationURLParameter = {\n parameterPath: \"$host\",\n mapper: {\n serializedName: \"$host\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n skipEncoding: true,\n};\n\nexport const id: OperationURLParameter = {\n parameterPath: \"id\",\n mapper: {\n serializedName: \"id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const ownedOnly: OperationQueryParameter = {\n parameterPath: [\"options\", \"ownedOnly\"],\n mapper: {\n serializedName: \"owned_only\",\n type: {\n name: \"Boolean\",\n },\n },\n};\n\nexport const typeParam: OperationQueryParameter = {\n parameterPath: [\"options\", \"type\"],\n mapper: {\n serializedName: \"type\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const limit: OperationQueryParameter = {\n parameterPath: \"limit\",\n mapper: {\n defaultValue: 10,\n constraints: {\n InclusiveMaximum: 100,\n InclusiveMinimum: 1,\n },\n serializedName: \"limit\",\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const scope: OperationQueryParameter = {\n parameterPath: \"scope\",\n mapper: {\n constraints: {\n Pattern: new RegExp(\"(txi|gen):\\\\d+(-\\\\d+)?\"),\n },\n serializedName: \"scope\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const direction: OperationQueryParameter = {\n parameterPath: \"direction\",\n mapper: {\n serializedName: \"direction\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const by: OperationQueryParameter = {\n parameterPath: [\"options\", \"by\"],\n mapper: {\n serializedName: \"by\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const prefix: OperationQueryParameter = {\n parameterPath: [\"options\", \"prefix\"],\n mapper: {\n serializedName: \"prefix\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const accountId: OperationURLParameter = {\n parameterPath: \"accountId\",\n mapper: {\n serializedName: \"accountId\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const contract: OperationQueryParameter = {\n parameterPath: [\"options\", \"contract\"],\n mapper: {\n serializedName: \"contract\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const contractId: OperationURLParameter = {\n parameterPath: \"contractId\",\n mapper: {\n serializedName: \"contractId\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const tokenId: OperationURLParameter = {\n parameterPath: \"tokenId\",\n mapper: {\n serializedName: \"tokenId\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const templateId: OperationURLParameter = {\n parameterPath: \"templateId\",\n mapper: {\n serializedName: \"templateId\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const by1: OperationQueryParameter = {\n parameterPath: [\"options\", \"by\"],\n mapper: {\n serializedName: \"by\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const accountId1: OperationURLParameter = {\n parameterPath: \"accountId\",\n mapper: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const sender: OperationURLParameter = {\n parameterPath: \"sender\",\n mapper: {\n serializedName: \"sender\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const recipient: OperationURLParameter = {\n parameterPath: \"recipient\",\n mapper: {\n serializedName: \"recipient\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const by2: OperationQueryParameter = {\n parameterPath: [\"options\", \"by\"],\n mapper: {\n serializedName: \"by\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const hash: OperationQueryParameter = {\n parameterPath: \"hash\",\n mapper: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const hashOrKbi: OperationURLParameter = {\n parameterPath: \"hashOrKbi\",\n mapper: {\n serializedName: \"hash_or_kbi\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const kbi: OperationURLParameter = {\n parameterPath: \"kbi\",\n mapper: {\n serializedName: \"kbi\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const mbi: OperationURLParameter = {\n parameterPath: \"mbi\",\n mapper: {\n serializedName: \"mbi\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n};\n\nexport const state: OperationQueryParameter = {\n parameterPath: [\"options\", \"state\"],\n mapper: {\n serializedName: \"state\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const contractId1: OperationQueryParameter = {\n parameterPath: [\"options\", \"contractId\"],\n mapper: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const event: OperationQueryParameter = {\n parameterPath: [\"options\", \"event\"],\n mapper: {\n serializedName: \"event\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const functionParam: OperationQueryParameter = {\n parameterPath: [\"options\", \"function\"],\n mapper: {\n serializedName: \"function\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const functionPrefix: OperationQueryParameter = {\n parameterPath: [\"options\", \"functionPrefix\"],\n mapper: {\n serializedName: \"function_prefix\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const data: OperationQueryParameter = {\n parameterPath: [\"options\", \"data\"],\n mapper: {\n serializedName: \"data\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const aexnArgs: OperationQueryParameter = {\n parameterPath: [\"options\", \"aexnArgs\"],\n mapper: {\n serializedName: \"aexn-args\",\n type: {\n name: \"Boolean\",\n },\n },\n};\n\nexport const hash1: OperationURLParameter = {\n parameterPath: \"hash\",\n mapper: {\n serializedName: \"hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const ownedBy: OperationQueryParameter = {\n parameterPath: [\"options\", \"ownedBy\"],\n mapper: {\n serializedName: \"owned_by\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const state1: OperationQueryParameter = {\n parameterPath: [\"options\", \"state\"],\n mapper: {\n serializedName: \"state\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const typeParam1: OperationQueryParameter = {\n parameterPath: [\"options\", \"type\"],\n mapper: {\n serializedName: \"type\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n collectionFormat: \"Multi\",\n};\n\nexport const typeGroup: OperationQueryParameter = {\n parameterPath: [\"options\", \"typeGroup\"],\n mapper: {\n serializedName: \"type_group\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n collectionFormat: \"Multi\",\n};\n\nexport const account: OperationQueryParameter = {\n parameterPath: [\"options\", \"account\"],\n mapper: {\n serializedName: \"account\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const channel: OperationQueryParameter = {\n parameterPath: [\"options\", \"channel\"],\n mapper: {\n serializedName: \"channel\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const oracle: OperationQueryParameter = {\n parameterPath: [\"options\", \"oracle\"],\n mapper: {\n serializedName: \"oracle\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const senderId: OperationQueryParameter = {\n parameterPath: [\"options\", \"senderId\"],\n mapper: {\n serializedName: \"sender_id\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const recipientId: OperationQueryParameter = {\n parameterPath: [\"options\", \"recipientId\"],\n mapper: {\n serializedName: \"recipient_id\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const entrypoint: OperationQueryParameter = {\n parameterPath: [\"options\", \"entrypoint\"],\n mapper: {\n serializedName: \"entrypoint\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const txType: OperationQueryParameter = {\n parameterPath: [\"options\", \"txType\"],\n mapper: {\n serializedName: \"tx_type\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const id1: OperationQueryParameter = {\n parameterPath: [\"options\", \"id\"],\n mapper: {\n serializedName: \"id\",\n type: {\n name: \"String\",\n },\n },\n};\n\nexport const hashOrIndex: OperationURLParameter = {\n parameterPath: \"hashOrIndex\",\n mapper: {\n serializedName: \"hash_or_index\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n};\n","import * as coreClient from \"@azure/core-client\";\n\nexport const Paths1I5J7OcV2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1I5J7OcV2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Activity\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Activity: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Activity\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n blockTime: {\n serializedName: \"block_time\",\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n payload: {\n serializedName: \"payload\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n type: {\n serializedName: \"type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PaginatedResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"PaginatedResponse\",\n modelProperties: {\n next: {\n serializedName: \"next\",\n required: true,\n nullable: true,\n type: {\n name: \"String\",\n },\n },\n prev: {\n serializedName: \"prev\",\n required: true,\n nullable: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const ErrorResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ErrorResponse\",\n modelProperties: {\n error: {\n serializedName: \"error\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Paths17FlgdkV2Aex141GetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths17FlgdkV2Aex141GetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex141Response\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex141Response: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex141Response\",\n modelProperties: {\n baseUrl: {\n serializedName: \"base_url\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contractTxi: {\n serializedName: \"contract_txi\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n extensions: {\n serializedName: \"extensions\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n limits: {\n serializedName: \"limits\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n\nexport const PathsAxw0PwV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsAxw0PwV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex141OwnedTokenResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex141OwnedTokenResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex141OwnedTokenResponse\",\n modelProperties: {\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n tokenId: {\n serializedName: \"token_id\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const PathsN3Ru7DV2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsN3Ru7DV2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex141OwnedTokenResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const PathsRa6Pv6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsRa6Pv6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex141TemplatesResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex141TemplatesResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex141TemplatesResponse\",\n modelProperties: {\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n edition: {\n serializedName: \"edition\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n logIdx: {\n serializedName: \"log_idx\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n templateId: {\n serializedName: \"template_id\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Paths19B9O7TV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths19B9O7TV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex141TemplateTokensResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex141TemplateTokensResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex141TemplateTokensResponse\",\n modelProperties: {\n logIdx: {\n serializedName: \"log_idx\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n ownerId: {\n serializedName: \"owner_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n tokenId: {\n serializedName: \"token_id\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Paths1Fe570RV2Aex9GetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Fe570RV2Aex9GetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex9Response\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex9Response: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex9Response\",\n modelProperties: {\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contractTxi: {\n serializedName: \"contract_txi\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n decimals: {\n serializedName: \"decimals\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n eventSupply: {\n serializedName: \"event_supply\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n extensions: {\n serializedName: \"extensions\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n holders: {\n serializedName: \"holders\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n initialSupply: {\n serializedName: \"initial_supply\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n name: {\n serializedName: \"name\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n symbol: {\n serializedName: \"symbol\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PathsO9MbpkV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchemaAllof1: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsO9MbpkV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchemaAllof1\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex9BalanceResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex9BalanceResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex9BalanceResponse\",\n modelProperties: {\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n decimals: {\n serializedName: \"decimals\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n tokenName: {\n serializedName: \"token_name\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n tokenSymbol: {\n serializedName: \"token_symbol\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n txIndex: {\n serializedName: \"tx_index\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n txType: {\n serializedName: \"tx_type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PathsY2JwfkV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsY2JwfkV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex9TransferResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex9TransferResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex9TransferResponse\",\n modelProperties: {\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n blockHeight: {\n serializedName: \"block_height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n callTxi: {\n serializedName: \"call_txi\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n logIdx: {\n serializedName: \"log_idx\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n microTime: {\n serializedName: \"micro_time\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n recipient: {\n serializedName: \"recipient\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n sender: {\n serializedName: \"sender\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Paths5U7W2V2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths5U7W2V2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex9TransferResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Paths12TleqhV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths12TleqhV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex9TransferResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Paths1C2B0UpV2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1C2B0UpV2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Aex9ContractBalanceResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Aex9ContractBalanceResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex9ContractBalanceResponse\",\n modelProperties: {\n accountId: {\n serializedName: \"account_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n lastLogIdx: {\n serializedName: \"last_log_idx\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n lastTxHash: {\n serializedName: \"last_tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PathsBelvp6V2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsBelvp6V2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n account: {\n serializedName: \"account\",\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"Number\",\n },\n },\n contract: {\n serializedName: \"contract\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n };\n\nexport const Paths11X7LpcV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths11X7LpcV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n account: {\n serializedName: \"account\",\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"Number\",\n },\n },\n contract: {\n serializedName: \"contract\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n };\n\nexport const Paths5LeqfqV2BlocksGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths5LeqfqV2BlocksGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Block\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Block: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Block\",\n modelProperties: {\n beneficiary: {\n serializedName: \"beneficiary\",\n type: {\n name: \"String\",\n },\n },\n hash: {\n serializedName: \"hash\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n info: {\n serializedName: \"info\",\n type: {\n name: \"String\",\n },\n },\n miner: {\n serializedName: \"miner\",\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n pow: {\n serializedName: \"pow\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n prevHash: {\n serializedName: \"prev_hash\",\n type: {\n name: \"String\",\n },\n },\n prevKeyHash: {\n serializedName: \"prev_key_hash\",\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n type: {\n name: \"String\",\n },\n },\n target: {\n serializedName: \"target\",\n type: {\n name: \"Number\",\n },\n },\n time: {\n serializedName: \"time\",\n type: {\n name: \"Number\",\n },\n },\n version: {\n serializedName: \"version\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const NotFoundResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NotFoundResponse\",\n modelProperties: {\n error: {\n serializedName: \"error\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PathsC25EgV2ChannelsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsC25EgV2ChannelsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Channel\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Channel: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Channel\",\n modelProperties: {\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"Number\",\n },\n },\n channel: {\n serializedName: \"channel\",\n type: {\n name: \"String\",\n },\n },\n channelReserve: {\n serializedName: \"channel_reserve\",\n type: {\n name: \"Number\",\n },\n },\n delegateIds: {\n serializedName: \"delegate_ids\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n initiator: {\n serializedName: \"initiator\",\n type: {\n name: \"String\",\n },\n },\n initiatorAmount: {\n serializedName: \"initiator_amount\",\n type: {\n name: \"Number\",\n },\n },\n lastUpdatedHeight: {\n serializedName: \"last_updated_height\",\n type: {\n name: \"String\",\n },\n },\n lastUpdatedTime: {\n serializedName: \"last_updated_time\",\n type: {\n name: \"Number\",\n },\n },\n lastUpdatedTxType: {\n serializedName: \"last_updated_tx_type\",\n type: {\n name: \"String\",\n },\n },\n lockPeriod: {\n serializedName: \"lock_period\",\n type: {\n name: \"Number\",\n },\n },\n lockedUntil: {\n serializedName: \"locked_until\",\n type: {\n name: \"Number\",\n },\n },\n responder: {\n serializedName: \"responder\",\n type: {\n name: \"String\",\n },\n },\n responderAmount: {\n serializedName: \"responder_amount\",\n type: {\n name: \"Number\",\n },\n },\n round: {\n serializedName: \"round\",\n type: {\n name: \"Number\",\n },\n },\n soloRound: {\n serializedName: \"solo_round\",\n type: {\n name: \"Number\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n type: {\n name: \"String\",\n },\n },\n updatesCount: {\n serializedName: \"updates_count\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Paths1Csrt0IV2ContractsCallsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Csrt0IV2ContractsCallsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"ContractCall\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const ContractCall: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ContractCall\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n callTxHash: {\n serializedName: \"call_tx_hash\",\n type: {\n name: \"String\",\n },\n },\n callTxi: {\n serializedName: \"call_txi\",\n type: {\n name: \"Number\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n contractTxi: {\n serializedName: \"contract_txi\",\n type: {\n name: \"Number\",\n },\n },\n function: {\n serializedName: \"function\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n internalTx: {\n serializedName: \"internal_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n localIdx: {\n serializedName: \"local_idx\",\n type: {\n name: \"Number\",\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths9Ya94MV2ContractsLogsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths9Ya94MV2ContractsLogsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"ContractLog\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const ContractLog: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"ContractLog\",\n modelProperties: {\n args: {\n serializedName: \"args\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n callTxHash: {\n serializedName: \"call_tx_hash\",\n type: {\n name: \"String\",\n },\n },\n callTxi: {\n serializedName: \"call_txi\",\n type: {\n name: \"Number\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n contractTxi: {\n serializedName: \"contract_txi\",\n type: {\n name: \"Number\",\n },\n },\n data: {\n serializedName: \"data\",\n type: {\n name: \"String\",\n },\n },\n eventHash: {\n serializedName: \"event_hash\",\n type: {\n name: \"String\",\n },\n },\n extCallerContractId: {\n serializedName: \"ext_caller_contract_id\",\n type: {\n name: \"String\",\n },\n },\n extCallerContractTxi: {\n serializedName: \"ext_caller_contract_txi\",\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n logIdx: {\n serializedName: \"log_idx\",\n type: {\n name: \"Number\",\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n type: {\n name: \"Number\",\n },\n },\n parentContractId: {\n serializedName: \"parent_contract_id\",\n nullable: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Contract: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Contract\",\n modelProperties: {\n aexnType: {\n serializedName: \"aexn_type\",\n type: {\n name: \"String\",\n },\n },\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n createTx: {\n serializedName: \"create_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n sourceTxHash: {\n serializedName: \"source_tx_hash\",\n type: {\n name: \"String\",\n },\n },\n sourceTxType: {\n serializedName: \"source_tx_type\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PathsRzn6HzV2DeltastatsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsRzn6HzV2DeltastatsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"DeltaStat\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const DeltaStat: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"DeltaStat\",\n modelProperties: {\n auctionsStarted: {\n serializedName: \"auctions_started\",\n type: {\n name: \"Number\",\n },\n },\n blockReward: {\n serializedName: \"block_reward\",\n type: {\n name: \"Number\",\n },\n },\n contractsCreated: {\n serializedName: \"contracts_created\",\n type: {\n name: \"Number\",\n },\n },\n devReward: {\n serializedName: \"dev_reward\",\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n lastTxHash: {\n serializedName: \"last_tx_hash\",\n type: {\n name: \"String\",\n },\n },\n namesActivated: {\n serializedName: \"names_activated\",\n type: {\n name: \"Number\",\n },\n },\n namesExpired: {\n serializedName: \"names_expired\",\n type: {\n name: \"Number\",\n },\n },\n namesRevoked: {\n serializedName: \"names_revoked\",\n type: {\n name: \"Number\",\n },\n },\n oraclesExpired: {\n serializedName: \"oracles_expired\",\n type: {\n name: \"Number\",\n },\n },\n oraclesRegistered: {\n serializedName: \"oracles_registered\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths10TrrshV2KeyBlocksGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths10TrrshV2KeyBlocksGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"KeyBlock\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const KeyBlock: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"KeyBlock\",\n modelProperties: {\n beneficiary: {\n serializedName: \"beneficiary\",\n type: {\n name: \"String\",\n },\n },\n hash: {\n serializedName: \"hash\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n info: {\n serializedName: \"info\",\n type: {\n name: \"String\",\n },\n },\n miner: {\n serializedName: \"miner\",\n type: {\n name: \"String\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n type: {\n name: \"String\",\n },\n },\n pow: {\n serializedName: \"pow\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n prevHash: {\n serializedName: \"prev_hash\",\n type: {\n name: \"String\",\n },\n },\n prevKeyHash: {\n serializedName: \"prev_key_hash\",\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n type: {\n name: \"String\",\n },\n },\n target: {\n serializedName: \"target\",\n type: {\n name: \"Number\",\n },\n },\n time: {\n serializedName: \"time\",\n type: {\n name: \"Number\",\n },\n },\n version: {\n serializedName: \"version\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths7Hfka2V2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths7Hfka2V2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"MicroBlock\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const MicroBlock: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"MicroBlock\",\n modelProperties: {\n hash: {\n serializedName: \"hash\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n microBlockIndex: {\n serializedName: \"micro_block_index\",\n type: {\n name: \"Number\",\n },\n },\n pofHash: {\n serializedName: \"pof_hash\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n prevHash: {\n serializedName: \"prev_hash\",\n type: {\n name: \"String\",\n },\n },\n prevKeyHash: {\n serializedName: \"prev_key_hash\",\n type: {\n name: \"String\",\n },\n },\n stateHash: {\n serializedName: \"state_hash\",\n type: {\n name: \"String\",\n },\n },\n time: {\n serializedName: \"time\",\n type: {\n name: \"Number\",\n },\n },\n transactionsCount: {\n serializedName: \"transactions_count\",\n type: {\n name: \"Number\",\n },\n },\n version: {\n serializedName: \"version\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths1RxrrvbV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1RxrrvbV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Tx\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Tx: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Tx\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n blockHeight: {\n serializedName: \"block_height\",\n type: {\n name: \"Number\",\n },\n },\n hash: {\n serializedName: \"hash\",\n type: {\n name: \"String\",\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n type: {\n name: \"Number\",\n },\n },\n microTime: {\n serializedName: \"micro_time\",\n type: {\n name: \"Number\",\n },\n },\n signatures: {\n serializedName: \"signatures\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n txIndex: {\n serializedName: \"tx_index\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths16Srg6EV2NamesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths16Srg6EV2NamesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Name\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Name: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Name\",\n modelProperties: {\n active: {\n serializedName: \"active\",\n type: {\n name: \"Boolean\",\n },\n },\n hash: {\n serializedName: \"hash\",\n type: {\n name: \"String\",\n },\n },\n info: {\n serializedName: \"info\",\n type: {\n name: \"Composite\",\n className: \"NameInfo\",\n },\n },\n previous: {\n serializedName: \"previous\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Name\",\n },\n },\n },\n },\n status: {\n serializedName: \"status\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameInfo: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameInfo\",\n modelProperties: {\n activationTime: {\n serializedName: \"activation_time\",\n type: {\n name: \"Number\",\n },\n },\n activeFrom: {\n serializedName: \"active_from\",\n type: {\n name: \"Number\",\n },\n },\n claims: {\n serializedName: \"claims\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n expireHeight: {\n serializedName: \"expire_height\",\n type: {\n name: \"Number\",\n },\n },\n ownership: {\n serializedName: \"ownership\",\n type: {\n name: \"Composite\",\n className: \"NameInfoOwnership\",\n },\n },\n pointers: {\n serializedName: \"pointers\",\n type: {\n name: \"Composite\",\n className: \"NameInfoPointers\",\n },\n },\n transfers: {\n serializedName: \"transfers\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n updates: {\n serializedName: \"updates\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameInfoOwnership: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameInfoOwnership\",\n modelProperties: {\n current: {\n serializedName: \"current\",\n type: {\n name: \"String\",\n },\n },\n original: {\n serializedName: \"original\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameInfoPointers: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameInfoPointers\",\n modelProperties: {\n accountPubkey: {\n serializedName: \"account_pubkey\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Auction: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Auction\",\n modelProperties: {\n active: {\n serializedName: \"active\",\n type: {\n name: \"Boolean\",\n },\n },\n info: {\n serializedName: \"info\",\n type: {\n name: \"Composite\",\n className: \"AuctionInfo\",\n },\n },\n },\n },\n};\n\nexport const AuctionInfo: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"AuctionInfo\",\n modelProperties: {\n auctionEnd: {\n serializedName: \"auction_end\",\n type: {\n name: \"Number\",\n },\n },\n bids: {\n serializedName: \"bids\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Number\",\n },\n },\n },\n },\n lastBid: {\n serializedName: \"last_bid\",\n type: {\n name: \"Composite\",\n className: \"AuctionInfoLastBid\",\n },\n },\n name: {\n serializedName: \"name\",\n type: {\n name: \"String\",\n },\n },\n previous: {\n serializedName: \"previous\",\n type: {\n name: \"Composite\",\n className: \"Auction\",\n },\n },\n status: {\n serializedName: \"status\",\n type: {\n name: \"String\",\n },\n },\n txIndex: {\n serializedName: \"tx_index\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const AuctionInfoLastBid: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"AuctionInfoLastBid\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n blockHeight: {\n serializedName: \"block_height\",\n type: {\n name: \"Number\",\n },\n },\n hash: {\n serializedName: \"hash\",\n type: {\n name: \"String\",\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n type: {\n name: \"Number\",\n },\n },\n microTime: {\n serializedName: \"micro_time\",\n type: {\n name: \"Number\",\n },\n },\n signatures: {\n serializedName: \"signatures\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"String\",\n },\n },\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n\nexport const Paths1I6PwfdV2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1I6PwfdV2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Get200ApplicationJsonAllOfPropertiesItemsItem\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Paths7P6Qc1V2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0PropertiesDataItemsAllof1: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths7P6Qc1V2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0PropertiesDataItemsAllof1\",\n modelProperties: {\n status: {\n serializedName: \"status\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n };\n\nexport const NameClaim: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameClaim\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n\nexport const PathsDjelzuV2NamesIdPointeesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsDjelzuV2NamesIdPointeesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n active: {\n serializedName: \"active\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n inactive: {\n serializedName: \"inactive\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n };\n\nexport const NameTransfer: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameTransfer\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n\nexport const NameUpdate: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameUpdate\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n tx: {\n serializedName: \"tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n};\n\nexport const PathsMherz6V2OraclesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsMherz6V2OraclesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Oracle\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Oracle: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Oracle\",\n modelProperties: {\n active: {\n serializedName: \"active\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n activeFrom: {\n serializedName: \"active_from\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n expireHeight: {\n serializedName: \"expire_height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n extends: {\n serializedName: \"extends\",\n required: true,\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"OracleExtendsItem\",\n },\n },\n },\n },\n oracle: {\n serializedName: \"oracle\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryFee: {\n serializedName: \"query_fee\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n register: {\n serializedName: \"register\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n registerTime: {\n serializedName: \"register_time\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const OracleExtendsItem: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleExtendsItem\",\n modelProperties: {\n query: {\n serializedName: \"query\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n response: {\n serializedName: \"response\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Paths1LaqrzqV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1LaqrzqV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"OracleQuery\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const OracleQuery: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleQuery\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n blockTime: {\n serializedName: \"block_time\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n oracleId: {\n serializedName: \"oracle_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n query: {\n serializedName: \"query\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryFee: {\n serializedName: \"query_fee\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n queryId: {\n serializedName: \"query_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n queryTtl: {\n serializedName: \"query_ttl\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n response: {\n serializedName: \"response\",\n type: {\n name: \"Composite\",\n className: \"OracleResponse\",\n },\n },\n responseTtl: {\n serializedName: \"response_ttl\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n sourceTxHash: {\n serializedName: \"source_tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n sourceTxType: {\n serializedName: \"source_tx_type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const OracleResponse: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"OracleResponse\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n blockTime: {\n serializedName: \"block_time\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n fee: {\n serializedName: \"fee\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n nonce: {\n serializedName: \"nonce\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n oracleId: {\n serializedName: \"oracle_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n query: {\n serializedName: \"query\",\n type: {\n name: \"Composite\",\n className: \"OracleResponse\",\n },\n },\n queryId: {\n serializedName: \"query_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n response: {\n serializedName: \"response\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n responseTtl: {\n serializedName: \"response_ttl\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n sourceTxHash: {\n serializedName: \"source_tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n sourceTxType: {\n serializedName: \"source_tx_type\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n ttl: {\n serializedName: \"ttl\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths3PnwziV2OraclesIdResponsesGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths3PnwziV2OraclesIdResponsesGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"OracleResponse\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Status: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Status\",\n modelProperties: {\n mdwAsyncTasks: {\n serializedName: \"mdw_async_tasks\",\n type: {\n name: \"Composite\",\n className: \"StatusMdwAsyncTasks\",\n },\n },\n mdwGensPerMinute: {\n serializedName: \"mdw_gens_per_minute\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n mdwHeight: {\n serializedName: \"mdw_height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n mdwLastMigration: {\n serializedName: \"mdw_last_migration\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n mdwRevision: {\n serializedName: \"mdw_revision\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n mdwSynced: {\n serializedName: \"mdw_synced\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n mdwSyncing: {\n serializedName: \"mdw_syncing\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n mdwTxIndex: {\n serializedName: \"mdw_tx_index\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n mdwVersion: {\n serializedName: \"mdw_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nodeHeight: {\n serializedName: \"node_height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n nodeProgress: {\n serializedName: \"node_progress\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n nodeRevision: {\n serializedName: \"node_revision\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n nodeSyncing: {\n serializedName: \"node_syncing\",\n required: true,\n type: {\n name: \"Boolean\",\n },\n },\n nodeVersion: {\n serializedName: \"node_version\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const StatusMdwAsyncTasks: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"StatusMdwAsyncTasks\",\n modelProperties: {\n longTasks: {\n serializedName: \"long_tasks\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n producerBuffer: {\n serializedName: \"producer_buffer\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n totalPending: {\n serializedName: \"total_pending\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const PathsDpxn99V2TotalstatsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsDpxn99V2TotalstatsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"TotalStat\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const TotalStat: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"TotalStat\",\n modelProperties: {\n auctionsStarted: {\n serializedName: \"auctions_started\",\n type: {\n name: \"Number\",\n },\n },\n blockReward: {\n serializedName: \"block_reward\",\n type: {\n name: \"Number\",\n },\n },\n contractsCreated: {\n serializedName: \"contracts_created\",\n type: {\n name: \"Number\",\n },\n },\n devReward: {\n serializedName: \"dev_reward\",\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n lastTxHash: {\n serializedName: \"last_tx_hash\",\n type: {\n name: \"String\",\n },\n },\n namesActivated: {\n serializedName: \"names_activated\",\n type: {\n name: \"Number\",\n },\n },\n namesExpired: {\n serializedName: \"names_expired\",\n type: {\n name: \"Number\",\n },\n },\n namesRevoked: {\n serializedName: \"names_revoked\",\n type: {\n name: \"Number\",\n },\n },\n oraclesExpired: {\n serializedName: \"oracles_expired\",\n type: {\n name: \"Number\",\n },\n },\n oraclesRegistered: {\n serializedName: \"oracles_registered\",\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths17Cjtx5V2TransfersGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths17Cjtx5V2TransfersGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Transfer\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Transfer: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Transfer\",\n modelProperties: {\n accountId: {\n serializedName: \"account_id\",\n type: {\n name: \"String\",\n },\n },\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"Number\",\n },\n },\n height: {\n serializedName: \"height\",\n type: {\n name: \"Number\",\n },\n },\n kind: {\n serializedName: \"kind\",\n type: {\n name: \"String\",\n },\n },\n refTxi: {\n serializedName: \"ref_txi\",\n nullable: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const Paths1R74KpvV2TxsGetResponses200ContentApplicationJsonSchemaAllof0: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1R74KpvV2TxsGetResponses200ContentApplicationJsonSchemaAllof0\",\n modelProperties: {\n data: {\n serializedName: \"data\",\n type: {\n name: \"Sequence\",\n element: {\n type: {\n name: \"Composite\",\n className: \"Tx\",\n },\n },\n },\n },\n },\n },\n };\n\nexport const Paths16Tt677V2TxsCountIdGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths16Tt677V2TxsCountIdGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n channelCloseMutualTx: {\n serializedName: \"channel_close_mutual_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelCloseSoloTx: {\n serializedName: \"channel_close_solo_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelCreateTx: {\n serializedName: \"channel_create_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelDepositTx: {\n serializedName: \"channel_deposit_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelForceProgressTx: {\n serializedName: \"channel_force_progress_tx\",\n type: {\n name: \"Number\",\n },\n },\n channelOffchainTx: {\n serializedName: \"channel_offchain_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelSettleTx: {\n serializedName: \"channel_settle_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelSlashTx: {\n serializedName: \"channel_slash_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelSnapshotSoloTx: {\n serializedName: \"channel_snapshot_solo_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n channelWithdrawTx: {\n serializedName: \"channel_withdraw_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n contractCallTx: {\n serializedName: \"contract_call_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n contractCreateTx: {\n serializedName: \"contract_create_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n gaAttachTx: {\n serializedName: \"ga_attach_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n gaMetaTx: {\n serializedName: \"ga_meta_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n nameClaimTx: {\n serializedName: \"name_claim_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n namePreclaimTx: {\n serializedName: \"name_preclaim_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n nameRevokeTx: {\n serializedName: \"name_revoke_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n nameTransferTx: {\n serializedName: \"name_transfer_tx\",\n type: {\n name: \"Number\",\n },\n },\n nameUpdateTx: {\n serializedName: \"name_update_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n oracleExtendTx: {\n serializedName: \"oracle_extend_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n oracleQueryTx: {\n serializedName: \"oracle_query_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n oracleRegisterTx: {\n serializedName: \"oracle_register_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n oracleResponseTx: {\n serializedName: \"oracle_response_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n payingForTx: {\n serializedName: \"paying_for_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n spendTx: {\n serializedName: \"spend_tx\",\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n },\n },\n };\n\nexport const Aex141TransferEvent: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex141TransferEvent\",\n modelProperties: {\n blockHeight: {\n serializedName: \"block_height\",\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n logIdx: {\n serializedName: \"log_idx\",\n type: {\n name: \"Number\",\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n type: {\n name: \"Number\",\n },\n },\n microTime: {\n serializedName: \"micro_time\",\n type: {\n name: \"Number\",\n },\n },\n recipientId: {\n serializedName: \"recipient_id\",\n type: {\n name: \"String\",\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n type: {\n name: \"String\",\n },\n },\n tokenId: {\n serializedName: \"token_id\",\n type: {\n name: \"Number\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const Aex9TransferEvent: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"Aex9TransferEvent\",\n modelProperties: {\n amount: {\n serializedName: \"amount\",\n type: {\n name: \"Number\",\n },\n },\n blockHeight: {\n serializedName: \"block_height\",\n type: {\n name: \"Number\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n type: {\n name: \"String\",\n },\n },\n logIdx: {\n serializedName: \"log_idx\",\n type: {\n name: \"Number\",\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n type: {\n name: \"Number\",\n },\n },\n microTime: {\n serializedName: \"micro_time\",\n type: {\n name: \"Number\",\n },\n },\n recipientId: {\n serializedName: \"recipient_id\",\n type: {\n name: \"String\",\n },\n },\n senderId: {\n serializedName: \"sender_id\",\n type: {\n name: \"String\",\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const InternalContractCallEvent: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"InternalContractCallEvent\",\n modelProperties: {\n blockHash: {\n serializedName: \"block_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n callTxHash: {\n serializedName: \"call_tx_hash\",\n type: {\n name: \"String\",\n },\n },\n contractId: {\n serializedName: \"contract_id\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n contractTxHash: {\n serializedName: \"contract_tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n function: {\n serializedName: \"function\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n height: {\n serializedName: \"height\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n internalTx: {\n serializedName: \"internal_tx\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n microIndex: {\n serializedName: \"micro_index\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n },\n },\n};\n\nexport const InternalTransferEvent: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"InternalTransferEvent\",\n modelProperties: {\n amount: {\n serializedName: \"amount\",\n required: true,\n type: {\n name: \"Number\",\n },\n },\n kind: {\n serializedName: \"kind\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n refTxHash: {\n serializedName: \"ref_tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const NameClaimEvent: coreClient.CompositeMapper = {\n type: {\n name: \"Composite\",\n className: \"NameClaimEvent\",\n modelProperties: {\n tx: {\n serializedName: \"tx\",\n required: true,\n type: {\n name: \"Dictionary\",\n value: { type: { name: \"any\" } },\n },\n },\n txHash: {\n serializedName: \"tx_hash\",\n required: true,\n type: {\n name: \"String\",\n },\n },\n },\n },\n};\n\nexport const PathsKlr2M2V2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsKlr2M2V2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1I5J7OcV2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsFlc7UjV2Aex141GetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsFlc7UjV2Aex141GetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths17FlgdkV2Aex141GetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsSs61ZgV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsSs61ZgV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsAxw0PwV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1Ilysy5V2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Ilysy5V2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsN3Ru7DV2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths17O9Fn6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths17O9Fn6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsRa6Pv6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsNuoourV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsNuoourV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths19B9O7TV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1Wbogg8V2Aex9GetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Wbogg8V2Aex9GetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1Fe570RV2Aex9GetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1BsirxgV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1BsirxgV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PaginatedResponse.type.modelProperties,\n ...PathsO9MbpkV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchemaAllof1\n .type.modelProperties,\n },\n },\n };\n\nexport const Paths1V0FiznV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1V0FiznV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsY2JwfkV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1X48QgjV2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1X48QgjV2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths5U7W2V2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1DkkopqV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1DkkopqV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths12TleqhV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsNi359V2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsNi359V2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1C2B0UpV2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths15Ih6XV2BlocksGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths15Ih6XV2BlocksGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths5LeqfqV2BlocksGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1Txl2A9V2ChannelsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Txl2A9V2ChannelsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsC25EgV2ChannelsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths187U0XzV2ContractsCallsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths187U0XzV2ContractsCallsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1Csrt0IV2ContractsCallsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsB246H1V2ContractsLogsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsB246H1V2ContractsLogsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths9Ya94MV2ContractsLogsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths7Pbec0V2DeltastatsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths7Pbec0V2DeltastatsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsRzn6HzV2DeltastatsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1Ulxr59V2KeyBlocksGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Ulxr59V2KeyBlocksGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths10TrrshV2KeyBlocksGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsO99PhzV2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsO99PhzV2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths7Hfka2V2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsGuqvhdV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsGuqvhdV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1RxrrvbV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsK9TkttV2NamesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsK9TkttV2NamesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths16Srg6EV2NamesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths3Msq0DV2NamesSearchGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths3Msq0DV2NamesSearchGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1I6PwfdV2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsB0YvynV2OraclesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsB0YvynV2OraclesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsMherz6V2OraclesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths4Bbr8KV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths4Bbr8KV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1LaqrzqV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1Ky8Ew4V2OraclesIdResponsesGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1Ky8Ew4V2OraclesIdResponsesGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths3PnwziV2OraclesIdResponsesGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths15PsutbV2TotalstatsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths15PsutbV2TotalstatsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsDpxn99V2TotalstatsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsIgs9Z1V2TransfersGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"PathsIgs9Z1V2TransfersGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths17Cjtx5V2TransfersGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const PathsFclv4TV2TxsGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className: \"PathsFclv4TV2TxsGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths1R74KpvV2TxsGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n ...PaginatedResponse.type.modelProperties,\n },\n },\n };\n\nexport const Paths1R02SlwV2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1R02SlwV2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...PathsBelvp6V2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n },\n },\n };\n\nexport const Paths1T9RwnyV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchema: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className:\n \"Paths1T9RwnyV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchema\",\n modelProperties: {\n ...Paths11X7LpcV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchemaAllof0\n .type.modelProperties,\n },\n },\n };\n\nexport const Get200ApplicationJsonAllOfPropertiesItemsItem: coreClient.CompositeMapper =\n {\n type: {\n name: \"Composite\",\n className: \"Get200ApplicationJsonAllOfPropertiesItemsItem\",\n modelProperties: {\n ...Name.type.modelProperties,\n ...Paths7P6Qc1V2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0PropertiesDataItemsAllof1\n .type.modelProperties,\n },\n },\n };\n","import * as coreClient from \"@azure/core-client\";\nimport * as Parameters from \"./models/parameters\";\nimport * as Mappers from \"./models/mappers\";\nimport {\n Enum1,\n MiddlewareOptionalParams,\n GetAccountActivitiesOptionalParams,\n GetAccountActivitiesResponse,\n GetSortedAex141ContractsOptionalParams,\n GetSortedAex141ContractsResponse,\n GetAex141OwnedTokensOptionalParams,\n GetAex141OwnedTokensResponse,\n GetAex141TokenOwnerOptionalParams,\n GetAex141TokenOwnerResponse,\n GetAex141ContractOwnersOptionalParams,\n GetAex141ContractOwnersResponse,\n GetAex141ContractTemplatesOptionalParams,\n GetAex141ContractTemplatesResponse,\n GetAex141TemplateTokensOptionalParams,\n GetAex141TemplateTokensResponse,\n GetAex141ByContractOptionalParams,\n GetAex141ByContractResponse,\n GetSortedAex9TokensOptionalParams,\n GetSortedAex9TokensResponse,\n GetAex9AccountBalancesOptionalParams,\n GetAex9AccountBalancesResponse,\n GetAex9TokensCountOptionalParams,\n GetAex9TokensCountResponse,\n GetAex9PairTransfersOptionalParams,\n GetAex9PairTransfersResponse,\n GetAex9SenderTransfersOptionalParams,\n GetAex9SenderTransfersResponse,\n GetAex9RecipientTransfersOptionalParams,\n GetAex9RecipientTransfersResponse,\n GetAex9ContractBalancesOptionalParams,\n GetAex9ContractBalancesResponse,\n GetAex9ContractAccountBalanceOptionalParams,\n GetAex9ContractAccountBalanceResponse,\n GetAex9ContractAccountBalanceHistoryOptionalParams,\n GetAex9ContractAccountBalanceHistoryResponse,\n GetAex9LogsCountOptionalParams,\n GetAex9LogsCountResponse,\n GetAex9ByContractOptionalParams,\n GetAex9ByContractResponse,\n GetBlocksOptionalParams,\n GetBlocksResponse,\n GetBlockOptionalParams,\n GetBlockResponse,\n GetBlockByMbiOptionalParams,\n GetBlockByMbiResponse,\n GetChannelsOptionalParams,\n GetChannelsResponse,\n GetChannelOptionalParams,\n GetChannelResponse,\n GetContractsCallsOptionalParams,\n GetContractsCallsResponse,\n GetContractsLogsOptionalParams,\n GetContractsLogsResponse,\n GetContractOptionalParams,\n GetContractResponse,\n GetDeltastatsOptionalParams,\n GetDeltastatsResponse,\n GetKeyBlocksOptionalParams,\n GetKeyBlocksResponse,\n GetKeyBlockOptionalParams,\n GetKeyBlockResponse,\n GetKeyBlockMicroBlocksOptionalParams,\n GetKeyBlockMicroBlocksResponse,\n GetMicroBlockOptionalParams,\n GetMicroBlockResponse,\n GetMicroBlockTransactionsOptionalParams,\n GetMicroBlockTransactionsResponse,\n GetNamesOptionalParams,\n GetNamesResponse,\n GetNamesAuctionsOptionalParams,\n GetNamesAuctionsResponse,\n SearchNamesOptionalParams,\n SearchNamesResponse,\n GetNameOptionalParams,\n GetNameResponse,\n GetNameAuctionOptionalParams,\n GetNameAuctionResponse,\n GetNameClaimsOptionalParams,\n GetNameClaimsResponse,\n GetNamePointeesOptionalParams,\n GetNamePointeesResponse,\n GetNamePointersOptionalParams,\n GetNamePointersResponse,\n GetNameTransfersOptionalParams,\n GetNameTransfersResponse,\n GetNameUpdatesOptionalParams,\n GetNameUpdatesResponse,\n GetOraclesOptionalParams,\n GetOraclesResponse,\n GetOracleOptionalParams,\n GetOracleResponse,\n GetOracleQueriesOptionalParams,\n GetOracleQueriesResponse,\n GetOracleResponsesOptionalParams,\n GetOracleResponsesResponse,\n GetStatusOptionalParams,\n GetStatusResponse,\n GetTotalstatsOptionalParams,\n GetTotalstatsResponse,\n GetTransfersOptionalParams,\n GetTransfersResponse,\n GetTxsOptionalParams,\n GetTxsResponse,\n GetTxCountOptionalParams,\n GetTxCountResponse,\n GetTxCountByIdOptionalParams,\n GetTxCountByIdResponse,\n GetTxOptionalParams,\n GetTxResponse,\n} from \"./models\";\n\nexport class Middleware extends coreClient.ServiceClient {\n $host: string;\n limit?: number;\n scope?: string;\n direction?: Enum1;\n\n /**\n * Initializes a new instance of the Middleware class.\n * @param $host server parameter\n * @param options The parameter options\n */\n constructor($host: string, options?: MiddlewareOptionalParams) {\n if ($host === undefined) {\n throw new Error(\"'$host' cannot be null\");\n }\n\n // Initializing default values for options\n if (!options) {\n options = {};\n }\n const defaults: MiddlewareOptionalParams = {\n requestContentType: \"application/json; charset=utf-8\",\n };\n\n const packageDetails = `azsdk-js-middleware/1.0.0-beta.1`;\n const userAgentPrefix =\n options.userAgentOptions && options.userAgentOptions.userAgentPrefix\n ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`\n : `${packageDetails}`;\n\n const optionsWithDefaults = {\n ...defaults,\n ...options,\n userAgentOptions: {\n userAgentPrefix,\n },\n endpoint: options.endpoint ?? options.baseUri ?? \"{$host}\",\n };\n super(optionsWithDefaults);\n // Parameter assignments\n this.$host = $host;\n }\n\n /**\n * Get an account activities.\n * @param id The account address\n * @param options The options parameters.\n */\n getAccountActivities(\n id: string,\n options?: GetAccountActivitiesOptionalParams,\n ): Promise<GetAccountActivitiesResponse> {\n return this.sendOperationRequest(\n { id, options },\n getAccountActivitiesOperationSpec,\n );\n }\n\n /**\n * Get AEX141 contracts sorted by creation time, name or symbol.\n * @param options The options parameters.\n */\n getSortedAex141Contracts(\n options?: GetSortedAex141ContractsOptionalParams,\n ): Promise<GetSortedAex141ContractsResponse> {\n return this.sendOperationRequest(\n { options },\n getSortedAex141ContractsOperationSpec,\n );\n }\n\n /**\n * Get tokens owned by an account.\n * @param accountId The account id\n * @param options The options parameters.\n */\n getAex141OwnedTokens(\n accountId: string,\n options?: GetAex141OwnedTokensOptionalParams,\n ): Promise<GetAex141OwnedTokensResponse> {\n return this.sendOperationRequest(\n { accountId, options },\n getAex141OwnedTokensOperationSpec,\n );\n }\n\n /**\n * Get owner of a NFT (AEX-141 token).\n * @param contractId The contract id\n * @param tokenId The nft token id\n * @param options The options parameters.\n */\n getAex141TokenOwner(\n contractId: string,\n tokenId: number,\n options?: GetAex141TokenOwnerOptionalParams,\n ): Promise<GetAex141TokenOwnerResponse> {\n return this.sendOperationRequest(\n { contractId, tokenId, options },\n getAex141TokenOwnerOperationSpec,\n );\n }\n\n /**\n * Get owners of tokens of a AEX-141 contract.\n * @param contractId The contract id\n * @param options The options parameters.\n */\n getAex141ContractOwners(\n contractId: string,\n options?: GetAex141ContractOwnersOptionalParams,\n ): Promise<GetAex141ContractOwnersResponse> {\n return this.sendOperationRequest(\n { contractId, options },\n getAex141ContractOwnersOperationSpec,\n );\n }\n\n /**\n * Get templates AEX-141 contract tokens.\n * @param contractId The contract id\n * @param options The options parameters.\n */\n getAex141ContractTemplates(\n contractId: string,\n options?: GetAex141ContractTemplatesOptionalParams,\n ): Promise<GetAex141ContractTemplatesResponse> {\n return this.sendOperationRequest(\n { contractId, options },\n getAex141ContractTemplatesOperationSpec,\n );\n }\n\n /**\n * Get AEX-141 template tokens.\n * @param contractId Contract id\n * @param templateId Template id\n * @param options The options parameters.\n */\n getAex141TemplateTokens(\n contractId: string,\n templateId: number,\n options?: GetAex141TemplateTokensOptionalParams,\n ): Promise<GetAex141TemplateTokensResponse> {\n return this.sendOperationRequest(\n { contractId, templateId, options },\n getAex141TemplateTokensOperationSpec,\n );\n }\n\n /**\n * Get AEX141 contract meta-info, extensions, limits and stats.\n * @param id The contract id\n * @param options The options parameters.\n */\n getAex141ByContract(\n id: string,\n options?: GetAex141ByContractOptionalParams,\n ): Promise<GetAex141ByContractResponse> {\n return this.sendOperationRequest(\n { id, options },\n getAex141ByContractOperationSpec,\n );\n }\n\n /**\n * Get AEX9 tokens sorted by creation time, name or symbol.\n * @param options The options parameters.\n */\n getSortedAex9Tokens(\n options?: GetSortedAex9TokensOptionalParams,\n ): Promise<GetSortedAex9TokensResponse> {\n return this.sendOperationRequest(\n { options },\n getSortedAex9TokensOperationSpec,\n );\n }\n\n /**\n * Get all AEX9 balances for an account on the last block.\n * @param accountId Account id\n * @param options The options parameters.\n */\n getAex9AccountBalances(\n accountId: string,\n options?: GetAex9AccountBalancesOptionalParams,\n ): Promise<GetAex9AccountBalancesResponse> {\n return this.sendOperationRequest(\n { accountId, options },\n getAex9AccountBalancesOperationSpec,\n );\n }\n\n /**\n * Get AEX9 tokens count.\n * @param options The options parameters.\n */\n getAex9TokensCount(\n options?: GetAex9TokensCountOptionalParams,\n ): Promise<GetAex9TokensCountResponse> {\n return this.sendOperationRequest(\n { options },\n getAex9TokensCountOperationSpec,\n );\n }\n\n /**\n * Get AEX9 transfers filtered by sender and recipient.\n * @param sender Sender account id\n * @param recipient Recipient account id\n * @param options The options parameters.\n */\n getAex9PairTransfers(\n sender: string,\n recipient: string,\n options?: GetAex9PairTransfersOptionalParams,\n ): Promise<GetAex9PairTransfersResponse> {\n return this.sendOperationRequest(\n { sender, recipient, options },\n getAex9PairTransfersOperationSpec,\n );\n }\n\n /**\n * Get AEX9 transfers filtered by sender.\n * @param id Sender account id\n * @param options The options parameters.\n */\n getAex9SenderTransfers(\n id: string,\n options?: GetAex9SenderTransfersOptionalParams,\n ): Promise<GetAex9SenderTransfersResponse> {\n return this.sendOperationRequest(\n { id, options },\n getAex9SenderTransfersOperationSpec,\n );\n }\n\n /**\n * Get AEX9 transfers filtered by recipient.\n * @param id Recipient account id\n * @param options The options parameters.\n */\n getAex9RecipientTransfers(\n id: string,\n options?: GetAex9RecipientTransfersOptionalParams,\n ): Promise<GetAex9RecipientTransfersResponse> {\n return this.sendOperationRequest(\n { id, options },\n getAex9RecipientTransfersOperationSpec,\n );\n }\n\n /**\n * Get AEX9 balances on a contract.\n * @param contractId Contract id\n * @param options The options parameters.\n */\n getAex9ContractBalances(\n contractId: string,\n options?: GetAex9ContractBalancesOptionalParams,\n ): Promise<GetAex9ContractBalancesResponse> {\n return this.sendOperationRequest(\n { contractId, options },\n getAex9ContractBalancesOperationSpec,\n );\n }\n\n /**\n * Get AEX9 balance for an account on a contract.\n * @param contractId Contract id\n * @param accountId Account id\n * @param hash Block hash\n * @param options The options parameters.\n */\n getAex9ContractAccountBalance(\n contractId: string,\n accountId: string,\n hash: string,\n options?: GetAex9ContractAccountBalanceOptionalParams,\n ): Promise<GetAex9ContractAccountBalanceResponse> {\n return this.sendOperationRequest(\n { contractId, accountId, hash, options },\n getAex9ContractAccountBalanceOperationSpec,\n );\n }\n\n /**\n * Get AEX9 account balance on a contract throughout all heights when changed.\n * @param contractId Contract id\n * @param accountId Account id\n * @param options The options parameters.\n */\n getAex9ContractAccountBalanceHistory(\n contractId: string,\n accountId: string,\n options?: GetAex9ContractAccountBalanceHistoryOptionalParams,\n ): Promise<GetAex9ContractAccountBalanceHistoryResponse> {\n return this.sendOperationRequest(\n { contractId, accountId, options },\n getAex9ContractAccountBalanceHistoryOperationSpec,\n );\n }\n\n /**\n * Get AEX9 token events count.\n * @param contractId Contract id\n * @param options The options parameters.\n */\n getAex9LogsCount(\n contractId: string,\n options?: GetAex9LogsCountOptionalParams,\n ): Promise<GetAex9LogsCountResponse> {\n return this.sendOperationRequest(\n { contractId, options },\n getAex9LogsCountOperationSpec,\n );\n }\n\n /**\n * Get AEX9 creation and meta_info information by contract id.\n * @param id The contract id\n * @param options The options parameters.\n */\n getAex9ByContract(\n id: string,\n options?: GetAex9ByContractOptionalParams,\n ): Promise<GetAex9ByContractResponse> {\n return this.sendOperationRequest(\n { id, options },\n getAex9ByContractOperationSpec,\n );\n }\n\n /**\n * Get multiple blocks.\n * @param options The options parameters.\n */\n getBlocks(options?: GetBlocksOptionalParams): Promise<GetBlocksResponse> {\n return this.sendOperationRequest({ options }, getBlocksOperationSpec);\n }\n\n /**\n * Get a single block.\n * @param hashOrKbi The block encoded hash or key block index\n * @param options The options parameters.\n */\n getBlock(\n hashOrKbi: string,\n options?: GetBlockOptionalParams,\n ): Promise<GetBlockResponse> {\n return this.sendOperationRequest(\n { hashOrKbi, options },\n getBlockOperationSpec,\n );\n }\n\n /**\n * Get a single block.\n * @param kbi The block key block index\n * @param mbi The block micro block index, starting from 0\n * @param options The options parameters.\n */\n getBlockByMbi(\n kbi: number,\n mbi: number,\n options?: GetBlockByMbiOptionalParams,\n ): Promise<GetBlockByMbiResponse> {\n return this.sendOperationRequest(\n { kbi, mbi, options },\n getBlockByMbiOperationSpec,\n );\n }\n\n /**\n * Get multiple channels.\n * @param options The options parameters.\n */\n getChannels(\n options?: GetChannelsOptionalParams,\n ): Promise<GetChannelsResponse> {\n return this.sendOperationRequest({ options }, getChannelsOperationSpec);\n }\n\n /**\n * Get a single channel.\n * @param id The channel\n * @param options The options parameters.\n */\n getChannel(\n id: string,\n options?: GetChannelOptionalParams,\n ): Promise<GetChannelResponse> {\n return this.sendOperationRequest({ id, options }, getChannelOperationSpec);\n }\n\n /**\n * Get contract calls.\n * @param options The options parameters.\n */\n getContractsCalls(\n options?: GetContractsCallsOptionalParams,\n ): Promise<GetContractsCallsResponse> {\n return this.sendOperationRequest(\n { options },\n getContractsCallsOperationSpec,\n );\n }\n\n /**\n * Get contract logs.\n * @param options The options parameters.\n */\n getContractsLogs(\n options?: GetContractsLogsOptionalParams,\n ): Promise<GetContractsLogsResponse> {\n return this.sendOperationRequest(\n { options },\n getContractsLogsOperationSpec,\n );\n }\n\n /**\n * Gets contract creation info.\n * @param id Contract that emitted the logs\n * @param options The options parameters.\n */\n getContract(\n id: string,\n options?: GetContractOptionalParams,\n ): Promise<GetContractResponse> {\n return this.sendOperationRequest({ id, options }, getContractOperationSpec);\n }\n\n /**\n * Get delta stats.\n * @param options The options parameters.\n */\n getDeltastats(\n options?: GetDeltastatsOptionalParams,\n ): Promise<GetDeltastatsResponse> {\n return this.sendOperationRequest({ options }, getDeltastatsOperationSpec);\n }\n\n /**\n * Get multiple key blocks.\n * @param options The options parameters.\n */\n getKeyBlocks(\n options?: GetKeyBlocksOptionalParams,\n ): Promise<GetKeyBlocksResponse> {\n return this.sendOperationRequest({ options }, getKeyBlocksOperationSpec);\n }\n\n /**\n * Get a single key block.\n * @param hashOrKbi The key block encoded hash or key block index\n * @param options The options parameters.\n */\n getKeyBlock(\n hashOrKbi: string,\n options?: GetKeyBlockOptionalParams,\n ): Promise<GetKeyBlockResponse> {\n return this.sendOperationRequest(\n { hashOrKbi, options },\n getKeyBlockOperationSpec,\n );\n }\n\n /**\n * Get the key block micro blocks.\n * @param hashOrKbi The key block encoded hash or key block index\n * @param options The options parameters.\n */\n getKeyBlockMicroBlocks(\n hashOrKbi: string,\n options?: GetKeyBlockMicroBlocksOptionalParams,\n ): Promise<GetKeyBlockMicroBlocksResponse> {\n return this.sendOperationRequest(\n { hashOrKbi, options },\n getKeyBlockMicroBlocksOperationSpec,\n );\n }\n\n /**\n * Get a micro block\n * @param hash The micro block encoded hash\n * @param options The options parameters.\n */\n getMicroBlock(\n hash: string,\n options?: GetMicroBlockOptionalParams,\n ): Promise<GetMicroBlockResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getMicroBlockOperationSpec,\n );\n }\n\n /**\n * Get a micro block transactions\n * @param hash The micro block encoded hash\n * @param options The options parameters.\n */\n getMicroBlockTransactions(\n hash: string,\n options?: GetMicroBlockTransactionsOptionalParams,\n ): Promise<GetMicroBlockTransactionsResponse> {\n return this.sendOperationRequest(\n { hash, options },\n getMicroBlockTransactionsOperationSpec,\n );\n }\n\n /**\n * Get multiple names.\n * @param options The options parameters.\n */\n getNames(options?: GetNamesOptionalParams): Promise<GetNamesResponse> {\n return this.sendOperationRequest({ options }, getNamesOperationSpec);\n }\n\n /**\n * Get multiple names.\n * @param options The options parameters.\n */\n getNamesAuctions(\n options?: GetNamesAuctionsOptionalParams,\n ): Promise<GetNamesAuctionsResponse> {\n return this.sendOperationRequest(\n { options },\n getNamesAuctionsOperationSpec,\n );\n }\n\n /**\n * Get multiple names.\n * @param options The options parameters.\n */\n searchNames(\n options?: SearchNamesOptionalParams,\n ): Promise<SearchNamesResponse> {\n return this.sendOperationRequest({ options }, searchNamesOperationSpec);\n }\n\n /**\n * Get a single name.\n * @param id The name\n * @param options The options parameters.\n */\n getName(\n id: string,\n options?: GetNameOptionalParams,\n ): Promise<GetNameResponse> {\n return this.sendOperationRequest({ id, options }, getNameOperationSpec);\n }\n\n /**\n * Get name auction\n * @param id The name\n * @param options The options parameters.\n */\n getNameAuction(\n id: string,\n options?: GetNameAuctionOptionalParams,\n ): Promise<GetNameAuctionResponse> {\n return this.sendOperationRequest(\n { id, options },\n getNameAuctionOperationSpec,\n );\n }\n\n /**\n * Get name claims\n * @param id The name or name hash\n * @param options The options parameters.\n */\n getNameClaims(\n id: string,\n options?: GetNameClaimsOptionalParams,\n ): Promise<GetNameClaimsResponse> {\n return this.sendOperationRequest(\n { id, options },\n getNameClaimsOperationSpec,\n );\n }\n\n /**\n * Get name pointees\n * @param id The name\n * @param options The options parameters.\n */\n getNamePointees(\n id: string,\n options?: GetNamePointeesOptionalParams,\n ): Promise<GetNamePointeesResponse> {\n return this.sendOperationRequest(\n { id, options },\n getNamePointeesOperationSpec,\n );\n }\n\n /**\n * Get name pointers\n * @param id The name\n * @param options The options parameters.\n */\n getNamePointers(\n id: string,\n options?: GetNamePointersOptionalParams,\n ): Promise<GetNamePointersResponse> {\n return this.sendOperationRequest(\n { id, options },\n getNamePointersOperationSpec,\n );\n }\n\n /**\n * Get name transfers\n * @param id The name or name hash\n * @param options The options parameters.\n */\n getNameTransfers(\n id: string,\n options?: GetNameTransfersOptionalParams,\n ): Promise<GetNameTransfersResponse> {\n return this.sendOperationRequest(\n { id, options },\n getNameTransfersOperationSpec,\n );\n }\n\n /**\n * Get name updates\n * @param id The name or name hash\n * @param options The options parameters.\n */\n getNameUpdates(\n id: string,\n options?: GetNameUpdatesOptionalParams,\n ): Promise<GetNameUpdatesResponse> {\n return this.sendOperationRequest(\n { id, options },\n getNameUpdatesOperationSpec,\n );\n }\n\n /**\n * Get multiple oracles.\n * @param options The options parameters.\n */\n getOracles(options?: GetOraclesOptionalParams): Promise<GetOraclesResponse> {\n return this.sendOperationRequest({ options }, getOraclesOperationSpec);\n }\n\n /**\n * Get a single oracle.\n * @param id The oracle\n * @param options The options parameters.\n */\n getOracle(\n id: string,\n options?: GetOracleOptionalParams,\n ): Promise<GetOracleResponse> {\n return this.sendOperationRequest({ id, options }, getOracleOperationSpec);\n }\n\n /**\n * Get an oracle's queries.\n * @param id The oracle\n * @param options The options parameters.\n */\n getOracleQueries(\n id: string,\n options?: GetOracleQueriesOptionalParams,\n ): Promise<GetOracleQueriesResponse> {\n return this.sendOperationRequest(\n { id, options },\n getOracleQueriesOperationSpec,\n );\n }\n\n /**\n * Get an oracle's responses.\n * @param id The oracle\n * @param options The options parameters.\n */\n getOracleResponses(\n id: string,\n options?: GetOracleResponsesOptionalParams,\n ): Promise<GetOracleResponsesResponse> {\n return this.sendOperationRequest(\n { id, options },\n getOracleResponsesOperationSpec,\n );\n }\n\n /**\n * Gets the current syncing status of both middleware and the node\n * @param options The options parameters.\n */\n getStatus(options?: GetStatusOptionalParams): Promise<GetStatusResponse> {\n return this.sendOperationRequest({ options }, getStatusOperationSpec);\n }\n\n /**\n * Get total accumulated stats.\n * @param options The options parameters.\n */\n getTotalstats(\n options?: GetTotalstatsOptionalParams,\n ): Promise<GetTotalstatsResponse> {\n return this.sendOperationRequest({ options }, getTotalstatsOperationSpec);\n }\n\n /**\n * Get multiple transfers.\n * @param options The options parameters.\n */\n getTransfers(\n options?: GetTransfersOptionalParams,\n ): Promise<GetTransfersResponse> {\n return this.sendOperationRequest({ options }, getTransfersOperationSpec);\n }\n\n /**\n * Get multiple transactions.\n * @param options The options parameters.\n */\n getTxs(options?: GetTxsOptionalParams): Promise<GetTxsResponse> {\n return this.sendOperationRequest({ options }, getTxsOperationSpec);\n }\n\n /**\n * Get count of transactions at the latest height.\n * @param options The options parameters.\n */\n getTxCount(options?: GetTxCountOptionalParams): Promise<GetTxCountResponse> {\n return this.sendOperationRequest({ options }, getTxCountOperationSpec);\n }\n\n /**\n * Get transactions count and its type for given aeternity ID.\n * @param id The ID of the address/name/oracle/etc\n * @param options The options parameters.\n */\n getTxCountById(\n id: string,\n options?: GetTxCountByIdOptionalParams,\n ): Promise<GetTxCountByIdResponse> {\n return this.sendOperationRequest(\n { id, options },\n getTxCountByIdOperationSpec,\n );\n }\n\n /**\n * Get a single transaction.\n * @param hashOrIndex The transaction encoded hash or index (txi)\n * @param options The options parameters.\n */\n getTx(\n hashOrIndex: string,\n options?: GetTxOptionalParams,\n ): Promise<GetTxResponse> {\n return this.sendOperationRequest(\n { hashOrIndex, options },\n getTxOperationSpec,\n );\n }\n}\n// Operation Specifications\nconst serializer = coreClient.createSerializer(Mappers, /* isXml */ false);\n\nconst getAccountActivitiesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/accounts/{id}/activities\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsKlr2M2V2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.ownedOnly,\n Parameters.typeParam,\n Parameters.limit,\n Parameters.scope,\n Parameters.direction,\n ],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getSortedAex141ContractsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsFlc7UjV2Aex141GetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.direction,\n Parameters.by,\n Parameters.prefix,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex141OwnedTokensOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141/owned-nfts/{accountId}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsSs61ZgV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.direction,\n Parameters.contract,\n ],\n urlParameters: [Parameters.$host, Parameters.accountId],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex141TokenOwnerOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141/{contractId}/owner/{tokenId}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: { type: { name: \"String\" } },\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.contractId, Parameters.tokenId],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex141ContractOwnersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141/{contractId}/owners\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1Ilysy5V2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.contractId],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex141ContractTemplatesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141/{contractId}/templates\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths17O9Fn6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.contractId],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex141TemplateTokensOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141/{contractId}/templates/{templateId}/tokens\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsNuoourV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction],\n urlParameters: [\n Parameters.$host,\n Parameters.contractId,\n Parameters.templateId,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex141ByContractOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex141/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Aex141Response,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getSortedAex9TokensOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1Wbogg8V2Aex9GetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.direction,\n Parameters.prefix,\n Parameters.by1,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9AccountBalancesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/account-balances/{account_id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1BsirxgV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.accountId1],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9TokensCountOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/count\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: { type: { name: \"Number\" } },\n },\n },\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9PairTransfersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/transfers/from-to/{sender}/{recipient}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1V0FiznV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.sender, Parameters.recipient],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9SenderTransfersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/transfers/from/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1X48QgjV2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9RecipientTransfersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/transfers/to/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1DkkopqV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9ContractBalancesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/{contractId}/balances\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsNi359V2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.direction, Parameters.by2],\n urlParameters: [Parameters.$host, Parameters.contractId],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9ContractAccountBalanceOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/{contractId}/balances/{accountId}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1R02SlwV2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.hash],\n urlParameters: [\n Parameters.$host,\n Parameters.accountId,\n Parameters.contractId,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9ContractAccountBalanceHistoryOperationSpec: coreClient.OperationSpec =\n {\n path: \"/v2/aex9/{contractId}/balances/{accountId}/history\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1T9RwnyV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [\n Parameters.$host,\n Parameters.accountId,\n Parameters.contractId,\n ],\n headerParameters: [Parameters.accept],\n serializer,\n };\nconst getAex9LogsCountOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/{contractId}/logs-count\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: { type: { name: \"Number\" } },\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.contractId],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getAex9ByContractOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/aex9/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Aex9Response,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getBlocksOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/blocks\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths15Ih6XV2BlocksGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getBlockOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/blocks/{hash_or_kbi}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Block,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.hashOrKbi],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getBlockByMbiOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/blocks/{kbi}/{mbi}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Block,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.kbi, Parameters.mbi],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getChannelsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/channels\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1Txl2A9V2ChannelsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.scope,\n Parameters.direction,\n Parameters.state,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getChannelOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/channels/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Channel,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getContractsCallsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/contracts/calls\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths187U0XzV2ContractsCallsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getContractsLogsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/contracts/logs\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsB246H1V2ContractsLogsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.scope,\n Parameters.direction,\n Parameters.contractId1,\n Parameters.event,\n Parameters.functionParam,\n Parameters.functionPrefix,\n Parameters.data,\n Parameters.aexnArgs,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getContractOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/contracts/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Contract,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getDeltastatsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/deltastats\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths7Pbec0V2DeltastatsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getKeyBlocksOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/key-blocks\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1Ulxr59V2KeyBlocksGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getKeyBlockOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/key-blocks/{hash_or_kbi}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.KeyBlock,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.hashOrKbi],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getKeyBlockMicroBlocksOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/key-blocks/{hash_or_kbi}/micro-blocks\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsO99PhzV2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.hashOrKbi],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getMicroBlockOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/micro-blocks/{hash}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.MicroBlock,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.hash1],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getMicroBlockTransactionsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/micro-blocks/{hash}/txs\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsGuqvhdV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.hash1],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNamesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsK9TkttV2NamesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.direction,\n Parameters.by2,\n Parameters.ownedBy,\n Parameters.state1,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNamesAuctionsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/auctions\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Auction,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst searchNamesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/search\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths3Msq0DV2NamesSearchGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNameOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Name,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNameAuctionOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}/auction\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Auction,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNameClaimsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}/claims\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.NameClaim,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNamePointeesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}/pointees\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsDjelzuV2NamesIdPointeesGetResponses200ContentApplicationJsonSchema,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNamePointersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}/pointers\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: {\n type: { name: \"Dictionary\", value: { type: { name: \"any\" } } },\n },\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNameTransfersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}/transfers\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.NameTransfer,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getNameUpdatesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/names/{id}/updates\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.NameUpdate,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOraclesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/oracles\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsB0YvynV2OraclesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.scope,\n Parameters.direction,\n Parameters.state1,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOracleOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/oracles/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Oracle,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOracleQueriesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/oracles/{id}/queries\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths4Bbr8KV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getOracleResponsesOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/oracles/{id}/responses\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths1Ky8Ew4V2OraclesIdResponsesGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getStatusOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/status\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Status,\n },\n },\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTotalstatsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/totalstats\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths15PsutbV2TotalstatsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTransfersOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/transfers\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsIgs9Z1V2TransfersGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [Parameters.limit, Parameters.scope, Parameters.direction],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTxsOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/txs\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.PathsFclv4TV2TxsGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n queryParameters: [\n Parameters.limit,\n Parameters.scope,\n Parameters.direction,\n Parameters.contract,\n Parameters.typeParam1,\n Parameters.typeGroup,\n Parameters.account,\n Parameters.channel,\n Parameters.oracle,\n Parameters.senderId,\n Parameters.recipientId,\n Parameters.entrypoint,\n ],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTxCountOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/txs/count\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: { type: { name: \"Number\" } },\n },\n },\n queryParameters: [Parameters.scope, Parameters.txType, Parameters.id1],\n urlParameters: [Parameters.$host],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTxCountByIdOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/txs/count/{id}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper:\n Mappers.Paths16Tt677V2TxsCountIdGetResponses200ContentApplicationJsonSchema,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.id],\n headerParameters: [Parameters.accept],\n serializer,\n};\nconst getTxOperationSpec: coreClient.OperationSpec = {\n path: \"/v2/txs/{hash_or_index}\",\n httpMethod: \"GET\",\n responses: {\n 200: {\n bodyMapper: Mappers.Tx,\n },\n 400: {\n bodyMapper: Mappers.ErrorResponse,\n isError: true,\n },\n 404: {\n bodyMapper: Mappers.NotFoundResponse,\n isError: true,\n },\n },\n urlParameters: [Parameters.$host, Parameters.hashOrIndex],\n headerParameters: [Parameters.accept],\n serializer,\n};\n","// eslint-disable-next-line max-classes-per-file\nimport BigNumber from 'bignumber.js';\nimport { OperationArguments, OperationOptions, OperationSpec } from '@azure/core-client';\nimport { userAgentPolicyName, setClientRequestIdPolicyName } from '@azure/core-rest-pipeline';\nimport {\n genRequestQueuesPolicy, genCombineGetRequestsPolicy, genErrorFormatterPolicy,\n genVersionCheckPolicy, genRetryOnFailurePolicy,\n} from './utils/autorest';\nimport { Middleware as MiddlewareApi, MiddlewareOptionalParams, ErrorResponse } from './apis/middleware';\nimport { mapObject } from './utils/other';\nimport { Encoded } from './utils/encoder';\nimport { ConsensusProtocolVersion } from './tx/builder/constants';\n\nconst bigIntPropertyNames = [] as const;\n\nconst numberPropertyNames = [] as const;\n\nclass MiddlewareTransformed extends MiddlewareApi {\n override async sendOperationRequest(\n operationArguments: OperationArguments,\n operationSpec: OperationSpec,\n ): Promise<any> {\n const args = mapObject(\n operationArguments,\n ([key, value]) => [key, this.#encodeArg(value)],\n ) as OperationArguments;\n return this.#decodeRes(await super.sendOperationRequest(args, operationSpec));\n }\n\n #mapData(data: any, transform: {\n bigInt: (v: any) => any;\n number: (v: any) => any;\n }): unknown {\n if (Array.isArray(data)) return data.map((d) => this.#mapData(d, transform));\n if (data != null && typeof data === 'object') {\n return mapObject(data, ([key, value]) => {\n if (value == null) return [key, value];\n if (bigIntPropertyNames.some((k) => k === key)) return [key, transform.bigInt(value)];\n if (numberPropertyNames.some((k) => k === key)) return [key, transform.number(value)];\n return [key, this.#mapData(value, transform)];\n });\n }\n return data;\n }\n\n #encodeArg(data: any): any {\n return this.#mapData(data, {\n bigInt: (value) => {\n if (value instanceof BigNumber) return value.toFixed();\n return value.toString();\n },\n number: (value) => value.toString(),\n });\n }\n\n #decodeRes(data: any): any {\n return this.#mapData(data, {\n bigInt: (value) => BigInt(value),\n number: (value) => +value,\n });\n }\n}\n\ntype BigIntPropertyNames = typeof bigIntPropertyNames[number];\ntype NumberPropertyNames = typeof numberPropertyNames[number];\ntype PreserveOptional<NewType, OrigType> =\n OrigType extends undefined ? NewType | undefined : NewType;\nexport type TransformMiddlewareType<Type> =\n Type extends (...args: infer Args) => infer Ret\n ? (...args: TransformMiddlewareType<Args>) => TransformMiddlewareType<Ret>\n : Type extends [infer Item, ...infer Rest]\n ? [TransformMiddlewareType<Item>, ...TransformMiddlewareType<Rest>]\n : Type extends Array<infer Item>\n ? Array<TransformMiddlewareType<Item>>\n : Type extends Promise<infer T>\n ? Promise<TransformMiddlewareType<T>>\n : Type extends { [P in any]: any }\n ? {\n [Property in keyof Type]:\n Property extends BigIntPropertyNames\n ? PreserveOptional<bigint, Type[Property]>\n : Property extends NumberPropertyNames\n ? PreserveOptional<number, Type[Property]>\n : Property extends 'txHash'\n ? PreserveOptional<Encoded.TxHash, Type[Property]>\n : Property extends 'bytecode'\n ? PreserveOptional<Encoded.ContractBytearray, Type[Property]>\n : TransformMiddlewareType<Type[Property]>\n }\n : Type;\ntype MiddlewareTransformedApi = new (...args: ConstructorParameters<typeof MiddlewareApi>) => {\n [Name in keyof InstanceType<typeof MiddlewareApi>]:\n Name extends 'pipeline' | 'sendRequest' | 'sendOperationRequest'\n ? MiddlewareApi[Name] : TransformMiddlewareType<MiddlewareApi[Name]>\n};\n\nexport interface MiddlewareInfo {\n url: string;\n nodeNetworkId: string;\n version: string;\n consensusProtocolVersion: ConsensusProtocolVersion;\n}\n\nexport default class Middleware\n extends (MiddlewareTransformed as unknown as MiddlewareTransformedApi) {\n /**\n * @param url - Url for middleware API\n * @param options - Options\n * @param options.ignoreVersion - Don't ensure that the middleware is supported\n * @param options.retryCount - Amount of extra requests to do in case of failure\n * @param options.retryOverallDelay - Time in ms to wait between all retries\n */\n constructor(\n url: string,\n {\n ignoreVersion = false, retryCount = 3, retryOverallDelay = 800, ...options\n }: MiddlewareOptionalParams & {\n ignoreVersion?: boolean;\n retryCount?: number;\n retryOverallDelay?: number;\n } = {},\n ) {\n let version: string | undefined;\n const getVersion = async (opts: OperationOptions): Promise<string> => {\n if (version != null) return version;\n version = (await this.getStatus(opts)).mdwVersion;\n return version;\n };\n\n // eslint-disable-next-line constructor-super\n super(url, {\n allowInsecureConnection: true,\n additionalPolicies: [\n ...ignoreVersion ? [] : [\n genVersionCheckPolicy('middleware', getVersion, '1.47.0', '2.0.0'),\n ],\n genRequestQueuesPolicy(),\n genCombineGetRequestsPolicy(),\n genRetryOnFailurePolicy(retryCount, retryOverallDelay),\n genErrorFormatterPolicy((body: ErrorResponse) => ` ${body.error}`),\n ],\n ...options,\n });\n this.pipeline.removePolicy({ name: userAgentPolicyName });\n this.pipeline.removePolicy({ name: setClientRequestIdPolicyName });\n // TODO: use instead our retry policy\n this.pipeline.removePolicy({ name: 'defaultRetryPolicy' });\n }\n}\n","import BrowserConnection from './connection/Browser';\n\n/**\n * Browser connection proxy\n * Provide functionality to easily forward messages from one connection to another and back\n * @category aepp wallet communication\n * @param con1 - first connection\n * @param con2 - second connection\n * @returns a function to stop proxying\n */\nexport default (con1: BrowserConnection, con2: BrowserConnection): () => void => {\n con1.connect((msg: any) => con2.sendMessage(msg), () => con2.disconnect());\n con2.connect((msg: any) => con1.sendMessage(msg), () => con1.disconnect());\n\n return () => {\n con1.disconnect();\n con2.disconnect();\n };\n};\n","import { AlreadyConnectedError, NoWalletConnectedError } from '../../utils/errors';\n\n/**\n * Browser connection base interface\n * @category aepp wallet communication\n */\nexport default abstract class BrowserConnection {\n debug: boolean;\n\n protected constructor({ debug = false }: { debug?: boolean }) {\n this.debug = debug;\n }\n\n /**\n * Connect\n * @param onMessage - Message handler\n * @param onDisconnect - trigger when runtime connection in closed\n */\n connect(\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n onMessage: (message: any, origin: string, source: any) => void,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n onDisconnect: () => void,\n ): void {\n if (this.isConnected()) throw new AlreadyConnectedError('You already connected');\n }\n\n /**\n * Disconnect\n */\n disconnect(): void {\n if (!this.isConnected()) throw new NoWalletConnectedError('You dont have connection. Please connect before');\n }\n\n /**\n * Receive message\n */\n protected receiveMessage(message: any): void {\n if (this.debug) console.log('Receive message:', message);\n }\n\n /**\n * Send message\n */\n sendMessage(message: any): void {\n if (this.debug) console.log('Send message:', message);\n }\n\n /**\n * Check if connected\n * @returns Is connected\n */\n abstract isConnected(): boolean;\n}\n","import BrowserConnection from './Browser';\nimport { MESSAGE_DIRECTION } from '../schema';\nimport { InternalError, RpcConnectionError } from '../../utils/errors';\n\nexport type ImplPostMessage = Pick<Window, 'addEventListener' | 'removeEventListener' | 'postMessage'>;\n\n/**\n * Browser window Post Message connector module\n * @category aepp wallet communication\n */\nexport default class BrowserWindowMessageConnection extends BrowserConnection {\n origin?: string;\n\n sendDirection?: MESSAGE_DIRECTION;\n\n receiveDirection: MESSAGE_DIRECTION;\n\n listener?: (this: Window, ev: MessageEvent<any>) => void;\n\n #onDisconnect?: () => void;\n\n readonly #target?: ImplPostMessage;\n\n readonly #self: ImplPostMessage;\n\n /**\n * @param options - Options\n * @param options.target Target window for message\n * @param options.self Host window for message\n * @param options.origin Origin of receiver\n * @param options.sendDirection Wrapping messages into additional struct\n * `({ type: 'to_aepp' || 'to_waellet', data })`\n * Used for handling messages between content script and page\n * @param options.receiveDirection Unwrapping messages from additional struct\n */\n constructor({\n target,\n self = window,\n origin,\n sendDirection,\n receiveDirection = MESSAGE_DIRECTION.to_aepp,\n ...options\n }: {\n target?: ImplPostMessage;\n self?: ImplPostMessage;\n origin?: string;\n sendDirection?: MESSAGE_DIRECTION;\n receiveDirection?: MESSAGE_DIRECTION;\n debug?: boolean;\n } = {}) {\n super(options);\n this.#target = target;\n this.#self = self;\n this.origin = origin;\n this.sendDirection = sendDirection;\n this.receiveDirection = receiveDirection;\n }\n\n isConnected(): boolean {\n return this.listener != null;\n }\n\n override connect(\n onMessage: (message: any, origin: string, source: MessageEventSource | null) => void,\n onDisconnect: () => void,\n ): void {\n super.connect(onMessage, onDisconnect);\n this.listener = (message: MessageEvent<any>) => {\n // TODO: strict validate origin and source instead of checking message structure\n if (\n typeof message.data !== 'object'\n || (message.data.jsonrpc ?? message.data.data?.jsonrpc) !== '2.0'\n ) return;\n if (this.origin != null && this.origin !== message.origin) return;\n if (this.#target != null && this.#target !== message.source) return;\n this.receiveMessage(message);\n let { data } = message;\n if (data.type != null) {\n if (message.data.type !== this.receiveDirection) return;\n data = data.data;\n }\n onMessage(data, message.origin, message.source);\n };\n this.#self.addEventListener('message', this.listener);\n this.#onDisconnect = onDisconnect;\n }\n\n override disconnect(): void {\n super.disconnect();\n if (this.listener == null || this.#onDisconnect == null) {\n throw new InternalError('Expected to not happen, required for TS');\n }\n this.#self.removeEventListener('message', this.listener);\n delete this.listener;\n this.#onDisconnect();\n this.#onDisconnect = undefined;\n }\n\n override sendMessage(msg: any): void {\n if (this.#target == null) throw new RpcConnectionError('Can\\'t send messages without target');\n const message = this.sendDirection != null ? { type: this.sendDirection, data: msg } : msg;\n super.sendMessage(message);\n this.#target.postMessage(message, this.origin ?? '*');\n }\n}\n","import BrowserConnection from './connection/Browser';\nimport BrowserWindowMessageConnection from './connection/BrowserWindowMessage';\nimport { MESSAGE_DIRECTION, METHODS } from './schema';\nimport { WalletInfo } from './rpc/types';\nimport { UnsupportedPlatformError } from '../utils/errors';\n\ninterface Wallet {\n info: WalletInfo;\n getConnection: () => BrowserWindowMessageConnection;\n}\ninterface Wallets { [key: string]: Wallet }\n\n/**\n * A function to detect available wallets\n * @category aepp wallet communication\n * @param connection - connection to use to detect wallets\n * @param onDetected - call-back function which trigger on new wallet\n * @returns a function to stop scanning\n */\nexport default (\n connection: BrowserConnection,\n onDetected: ({ wallets, newWallet }: { wallets: Wallets; newWallet: Wallet }) => void,\n): () => void => {\n if (window == null) throw new UnsupportedPlatformError('Window object not found, you can run wallet detector only in browser');\n const wallets: Wallets = {};\n\n connection.connect((\n { method, params }: { method: string; params: WalletInfo },\n origin: string,\n source: Window,\n ) => {\n if (method !== METHODS.readyToConnect || wallets[params.id] != null) return;\n\n const wallet = {\n info: params,\n getConnection() {\n return new BrowserWindowMessageConnection({\n target: source,\n ...params.type === 'extension' ? {\n sendDirection: MESSAGE_DIRECTION.to_waellet,\n receiveDirection: MESSAGE_DIRECTION.to_aepp,\n ...window.origin !== 'null' && { origin: window.origin },\n } : {\n origin: params.origin,\n },\n });\n },\n };\n wallets[wallet.info.id] = wallet;\n onDetected({ wallets, newWallet: wallet });\n }, () => {});\n\n return () => connection.disconnect();\n};\n","import { Runtime } from 'webextension-polyfill';\nimport BrowserConnection from './Browser';\nimport { UnexpectedTsError } from '../../utils/errors';\n\n/**\n * BrowserRuntimeConnection\n * Handle browser runtime communication\n * @category aepp wallet communication\n */\nexport default class BrowserRuntimeConnection extends BrowserConnection {\n port: Runtime.Port;\n\n #listeners?: [(message: any, port: Runtime.Port) => void, () => void];\n\n /**\n * @param options - Options\n */\n constructor({ port, ...options }: { port: Runtime.Port; debug: boolean }) {\n super(options);\n this.port = port;\n }\n\n override disconnect(): void {\n super.disconnect();\n this.port.disconnect();\n if (this.#listeners == null) throw new UnexpectedTsError();\n this.port.onMessage.removeListener(this.#listeners[0]);\n this.port.onDisconnect.removeListener(this.#listeners[1]);\n this.#listeners = undefined;\n }\n\n override connect(\n onMessage: (message: any, origin: string, source: Runtime.Port) => void,\n onDisconnect: () => void,\n ): void {\n super.connect(onMessage, onDisconnect);\n this.#listeners = [\n (message, port) => {\n this.receiveMessage(message);\n // TODO: make `origin` optional because sender url is not available on aepp side\n onMessage(message, port.sender?.url ?? '', port);\n },\n onDisconnect,\n ];\n this.port.onMessage.addListener(this.#listeners[0]);\n this.port.onDisconnect.addListener(this.#listeners[1]);\n }\n\n override sendMessage(message: any): void {\n super.sendMessage(message);\n this.port.postMessage(message);\n }\n\n isConnected(): boolean {\n return this.#listeners != null;\n }\n}\n","import { TypeResolver, ContractByteArrayEncoder } from '@aeternity/aepp-calldata';\nimport { AciValue } from './utils/typed-data';\nimport { Encoded } from './utils/encoder';\nimport { RpcError } from './aepp-wallet-communication/schema';\nimport { ORACLE_TTL_TYPES } from './tx/builder/schema';\n\n/**\n * @category exception\n * @deprecated this exception is not thrown anymore\n */\nexport class RpcBroadcastError extends RpcError {\n static override code = 3;\n\n override code = 3;\n\n constructor(data?: any) {\n super('Broadcast failed');\n this.data = data;\n this.name = 'RpcBroadcastError';\n }\n}\n\n/**\n * @deprecated use isAuctionName instead\n */\nexport const NAME_BID_MAX_LENGTH = 12; // # this is the max length for a domain to be part of a bid\n\n/**\n * @deprecated use ContractByteArrayEncoder:encodeWithType from \\@aeternity/aepp-calldata\n */\nexport function encodeFateValue(value: unknown, aci: AciValue): Encoded.ContractBytearray {\n const valueType = new TypeResolver().resolveType(aci, {});\n return new ContractByteArrayEncoder().encodeWithType(value, valueType);\n}\n\n/**\n * @deprecated use ContractByteArrayEncoder:decodeWithType from \\@aeternity/aepp-calldata\n */\nexport function decodeFateValue(value: Encoded.ContractBytearray, aci: AciValue): any {\n const valueType = new TypeResolver().resolveType(aci, {});\n return new ContractByteArrayEncoder().decodeWithType(value, valueType);\n}\n\n/**\n * @deprecated inlined in buildTx or use `180000`\n */\nexport const NAME_TTL = 180000;\n\n/**\n * @deprecated inlined in buildTx or use `36000`\n */\nexport const NAME_MAX_TTL = 36000;\n\n/**\n * @deprecated inlined in buildTx or use `60 * 60`\n */\nexport const NAME_MAX_CLIENT_TTL = 60 * 60;\n\n/**\n * @deprecated inlined in buildTx or use `60 * 60`\n */\nexport const CLIENT_TTL = NAME_MAX_CLIENT_TTL;\n\n/**\n * @deprecated inlined in buildTx or use `{ type: ORACLE_TTL_TYPES.delta, value: 500 }`\n */\nexport const ORACLE_TTL = { type: ORACLE_TTL_TYPES.delta, value: 500 };\n\n/**\n * @deprecated inlined in buildTx or use `{ type: ORACLE_TTL_TYPES.delta, value: 10 }`\n */\nexport const QUERY_TTL = { type: ORACLE_TTL_TYPES.delta, value: 10 };\n\n/**\n * @deprecated inlined in buildTx or use `{ type: ORACLE_TTL_TYPES.delta, value: 10 }`\n */\nexport const RESPONSE_TTL = { type: ORACLE_TTL_TYPES.delta, value: 10 };\n"],"names":["root","factory","exports","module","require","define","amd","self","__WEBPACK_EXTERNAL_MODULE__6168__","__WEBPACK_EXTERNAL_MODULE__833__","__WEBPACK_EXTERNAL_MODULE__18__","__WEBPACK_EXTERNAL_MODULE__1655__","__WEBPACK_EXTERNAL_MODULE__4054__","__WEBPACK_EXTERNAL_MODULE__4578__","__WEBPACK_EXTERNAL_MODULE__6514__","__WEBPACK_EXTERNAL_MODULE__1081__","__WEBPACK_EXTERNAL_MODULE__2853__","__WEBPACK_EXTERNAL_MODULE__6016__","__WEBPACK_EXTERNAL_MODULE__1635__","__WEBPACK_EXTERNAL_MODULE__6717__","__WEBPACK_EXTERNAL_MODULE__5196__","__WEBPACK_EXTERNAL_MODULE__5898__","__WEBPACK_EXTERNAL_MODULE__8921__","__WEBPACK_EXTERNAL_MODULE__4146__","__WEBPACK_EXTERNAL_MODULE__8963__","__WEBPACK_EXTERNAL_MODULE__761__","__WEBPACK_EXTERNAL_MODULE__7250__","util","ADD64AA","v","a","b","o0","o1","ADD64AC","b0","b1","B2B_GET32","arr","i","B2B_G","c","d","ix","iy","x0","m","x1","y0","y1","xor0","xor1","BLAKE2B_IV32","Uint32Array","SIGMA82","Uint8Array","map","x","blake2bCompress","ctx","last","h","t","parameterBlock","blake2bInit","outlen","key","salt","personal","Error","length","fill","set","blake2bUpdate","input","blake2bFinal","out","blake2b","normalizeInput","blake2bHex","output","toHex","uint32ToHex","val","toString","substring","ret","TextEncoder","encode","bytes","Array","prototype","call","n","join","debugPrint","label","size","msg","toUpperCase","console","log","testSpeed","hashFn","N","M","startMs","Date","getTime","genMs","hashHex","hashMs","ms","Math","round","Object","create","ctor","superCtor","super_","constructor","value","enumerable","writable","configurable","TempCtor","buffer","Buffer","copyProps","src","dst","SafeBuffer","arg","encodingOrOffset","from","alloc","allocUnsafe","allocUnsafeSlow","TypeError","encoding","buf","undefined","SlowBuffer","Hash","blockSize","finalSize","this","_block","_finalSize","_blockSize","_len","update","data","enc","block","accum","offset","assigned","remainder","min","_update","digest","rem","bits","writeUInt32BE","lowBits","highBits","hash","_hash","inherits","K","W","Sha256","init","_w","ch","y","z","maj","sigma0","sigma1","gamma0","_a","_b","_c","_d","_e","_f","_g","_h","e","f","g","readInt32BE","j","T1","T2","H","writeInt32BE","parent","defineProperty","it","desc","sham","path","Symbol","WrappedWellKnownSymbolModule","isCallable","tryToString","$TypeError","argument","isPossiblePrototype","$String","String","isObject","toIndexedObject","toAbsoluteIndex","lengthOfArrayLike","createMethod","IS_INCLUDES","$this","el","fromIndex","O","index","includes","indexOf","bind","uncurryThis","IndexedObject","toObject","arraySpeciesCreate","push","TYPE","IS_MAP","IS_FILTER","IS_SOME","IS_EVERY","IS_FIND_INDEX","IS_FILTER_REJECT","NO_HOLES","callbackfn","that","specificCreate","result","boundFunction","target","forEach","filter","some","every","find","findIndex","filterReject","fails","wellKnownSymbol","V8_VERSION","SPECIES","METHOD_NAME","array","foo","Boolean","slice","isArray","isConstructor","$Array","originalArray","C","arraySpeciesConstructor","stringSlice","TO_STRING_TAG_SUPPORT","classofRaw","TO_STRING_TAG","$Object","CORRECT_ARGUMENTS","arguments","tag","error","tryGet","callee","F","getPrototypeOf","done","DESCRIPTORS","definePropertyModule","createPropertyDescriptor","object","bitmap","toPropertyKey","propertyKey","name","descriptor","createNonEnumerableProperty","options","global","get","document","EXISTS","createElement","CSSRuleList","CSSStyleDeclaration","CSSValueList","ClientRectList","DOMRectList","DOMStringList","DOMTokenList","DataTransferItemList","FileList","HTMLAllCollection","HTMLCollection","HTMLFormElement","HTMLSelectElement","MediaList","MimeTypeArray","NamedNodeMap","NodeList","PaintRequestList","Plugin","PluginArray","SVGLengthList","SVGNumberList","SVGPathSegList","SVGPointList","SVGStringList","SVGTransformList","SourceBufferList","StyleSheetList","TextTrackCueList","TextTrackList","TouchList","navigator","userAgent","match","version","process","Deno","versions","v8","split","apply","getOwnPropertyDescriptor","isForced","hasOwn","wrapConstructor","NativeConstructor","Wrapper","source","FORCED","USE_NATIVE","VIRTUAL_PROTOTYPE","sourceProperty","targetProperty","nativeProperty","resultProperty","TARGET","GLOBAL","STATIC","stat","PROTO","proto","nativeSource","targetPrototype","forced","dontCallGetSet","wrap","real","exec","NATIVE_BIND","FunctionPrototype","Function","Reflect","aCallable","fn","test","hasOwnProperty","getDescriptor","PROPER","CONFIGURABLE","method","uncurryThisWithBind","aFunction","variable","namespace","classof","replacer","rawLength","keys","element","keysLength","isNullOrUndefined","V","P","func","check","globalThis","window","getBuiltIn","propertyIsEnumerable","store","functionToString","inspectSource","has","NATIVE_WEAK_MAP","shared","sharedKey","hiddenKeys","OBJECT_ALREADY_INITIALIZED","WeakMap","state","metadata","facade","STATE","enforce","getterFor","type","documentAll","all","noop","construct","constructorRegExp","INCORRECT_TO_STRING","isConstructorModern","isConstructorLegacy","called","replacement","feature","detection","normalize","POLYFILL","NATIVE","string","replace","toLowerCase","isPrototypeOf","USE_SYMBOL_AS_UID","$Symbol","IteratorPrototype","setToStringTag","Iterators","returnThis","IteratorConstructor","NAME","next","ENUMERABLE_NEXT","$","IS_PURE","FunctionName","createIteratorConstructor","setPrototypeOf","defineBuiltIn","IteratorsCore","PROPER_FUNCTION_NAME","CONFIGURABLE_FUNCTION_NAME","BUGGY_SAFARI_ITERATORS","ITERATOR","KEYS","VALUES","ENTRIES","Iterable","DEFAULT","IS_SET","CurrentIteratorPrototype","methods","KEY","getIterationMethod","KIND","defaultIterator","IterablePrototype","INCORRECT_VALUES_NAME","nativeIterator","anyNativeIterator","entries","values","PrototypeOfArrayIteratorPrototype","arrayIterator","toLength","obj","ceil","floor","trunc","activeXDocument","anObject","definePropertiesModule","enumBugKeys","html","documentCreateElement","PROTOTYPE","SCRIPT","IE_PROTO","EmptyConstructor","scriptTag","content","LT","NullProtoObjectViaActiveX","write","close","temp","parentWindow","NullProtoObject","ActiveXObject","iframeDocument","iframe","JS","domain","style","display","appendChild","contentWindow","open","Properties","V8_PROTOTYPE_DEFINE_BUG","objectKeys","defineProperties","props","IE8_DOM_DEFINE","$defineProperty","$getOwnPropertyDescriptor","ENUMERABLE","WRITABLE","Attributes","current","propertyIsEnumerableModule","$getOwnPropertyNames","arraySlice","windowNames","getOwnPropertyNames","getWindowNames","internalObjectKeys","concat","getOwnPropertySymbols","CORRECT_PROTOTYPE_GETTER","ObjectPrototype","names","$propertyIsEnumerable","NASHORN_BUG","uncurryThisAccessor","aPossiblePrototype","setter","CORRECT_SETTER","__proto__","pref","valueOf","TAG","SET_METHOD","uid","defineGlobalProperty","SHARED","mode","copyright","license","toIntegerOrInfinity","requireObjectCoercible","charAt","charCodeAt","CONVERT_TO_STRING","pos","first","second","S","position","codeAt","symbol","SymbolPrototype","TO_PRIMITIVE","hint","arity","keyFor","thisSymbolValue","isRegisteredSymbol","isSymbol","$isWellKnownSymbol","isWellKnownSymbol","WellKnownSymbolsStore","symbolKeys","symbolKeysLength","symbolKey","NATIVE_SYMBOL","max","integer","number","len","getMethod","ordinaryToPrimitive","exoticToPrim","toPrimitive","id","postfix","random","iterator","wrappedWellKnownSymbolModule","createWellKnownSymbol","withoutSetter","doesNotExceedSafeInteger","createProperty","arrayMethodHasSpeciesSupport","IS_CONCAT_SPREADABLE","IS_CONCAT_SPREADABLE_SUPPORT","isConcatSpreadable","spreadable","k","E","A","addToUnscopables","InternalStateModule","defineIterator","createIterResultObject","ARRAY_ITERATOR","setInternalState","getInternalState","iterated","kind","Arguments","getReplacerFunction","$stringify","numberToString","tester","low","hi","WRONG_SYMBOLS_CONVERSION","ILL_FORMED_UNICODE","stringifyWithSymbolsFix","args","$replacer","fixIllFormed","prev","stringify","space","JSON","getOwnPropertySymbolsModule","$getOwnPropertySymbols","STRING_ITERATOR","point","defineWellKnownSymbol","$toString","nativeObjectCreate","getOwnPropertyNamesModule","getOwnPropertyNamesExternal","getOwnPropertyDescriptorModule","defineBuiltInAccessor","defineSymbolToPrimitive","$forEach","HIDDEN","SYMBOL","RangeError","QObject","nativeGetOwnPropertyDescriptor","nativeDefineProperty","nativeGetOwnPropertyNames","nativePropertyIsEnumerable","AllSymbols","ObjectPrototypeSymbols","USE_SETTER","findChild","fallbackDefineProperty","ObjectPrototypeDescriptor","setSymbolDescriptor","description","$defineProperties","properties","IS_OBJECT_PROTOTYPE","unsafe","useSetter","useSimple","NATIVE_SYMBOL_REGISTRY","StringToSymbolRegistry","SymbolToStringRegistry","sym","METADATA","isRegistered","isWellKnown","DOMIterables","COLLECTION_NAME","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","__webpack_modules__","getter","__esModule","definition","o","prop","r","toStringTag","bigNumber","integerValue","BigNumber","BaseError","message","super","AccountError","AensError","AeppError","ChannelError","CompilerError","ContractError","CryptographyError","NodeError","TransactionError","WalletError","ArgumentError","argumentName","requirement","argumentValue","IllegalArgumentError","ArgumentCountMismatchError","functionName","requiredCount","providedCount","InsufficientBalanceError","MissingParamError","NoSerializerFoundError","RequestTimedOutError","height","TxTimedOutError","blocks","th","UnsupportedPlatformError","UnsupportedProtocolError","NotImplementedError","UnsupportedVersionError","dependency","geVersion","ltVersion","LogicError","InternalError","UnexpectedTsError","UnavailableAccountError","address","AensPointerContextError","nameOrId","prefix","InsufficientNameFeeError","nameFee","minNameFee","InvalidAensNameError","InvalidRpcMessageError","MissingCallbackError","UnAuthorizedAccountError","onAccount","UnknownRpcClientError","UnsubscribedAccountError","ChannelCallError","ChannelConnectionError","ChannelPingTimedOutError","UnexpectedChannelMessageError","ChannelIncomingMessageError","handlerError","incomingMessage","UnknownChannelStateError","InvalidAuthDataError","BytecodeMismatchError","DuplicateContractError","InactiveContractError","contractAddress","InvalidMethodInvocationError","MissingContractAddressError","MissingContractDefError","MissingFunctionNameError","NodeInvocationError","transaction","NoSuchContractFunctionError","NotPayableFunctionError","amount","MissingEventDefinitionError","eventNameHash","eventAddress","AmbiguousEventDefinitionError","matchedEvents","InvalidChecksumError","InvalidPasswordError","MerkleTreeHashMismatchError","MissingNodeInTreeError","UnknownNodeLengthError","nodeLength","UnknownPathNibbleError","nibble","DuplicateNodeError","NodeNotFoundError","DecodeError","PayloadLengthError","DryRunError","IllegalBidFeeError","InvalidSignatureError","PrefixNotFoundError","SchemaNotFoundError","TagNotFoundError","TxNotInChainError","txHash","AlreadyConnectedError","NoWalletConnectedError","RpcConnectionError","AE_AMOUNT_FORMATS","DENOMINATION_MAGNITUDE","AE","MILI_AE","MICRO_AE","NANO_AE","PICO_AE","FEMTO_AE","AETTOS","formatAmount","denomination","targetDenomination","isNaN","Number","isInteger","shiftedBy","toFixed","toAe","toAettos","prefixes","magnitude","getNearestPrefix","exponent","reduce","p","abs","getLowerBoundPrefix","_prefixes$find","prefixedAmount","rawValue","_value$e","exp","precision","pause","async","Promise","resolve","setTimeout","duration","mapObject","fromEntries","concatBuffers","list","totalLength","isKeyOfObject","isItemOfArray","item","isAccountNotFoundError","RestError","statusCode","ensureError","wrapWithProxy","valueCb","Proxy","res","Encoding","sha256hash","base64Types","ContractBytearray","ContractStoreKey","ContractStoreValue","Transaction","OracleQuery","OracleResponse","State","Poi","StateTrees","CallStateTree","Bytearray","base58Types","KeyBlockHash","MicroBlockHash","BlockPofHash","BlockTxHash","BlockStateHash","Channel","ContractAddress","TxHash","OracleAddress","OracleQueryId","AccountAddress","Signature","Commitment","PeerPubkey","Name","byteSizeForType","ensureValidLength","reqLen","getChecksum","payload","addChecksum","getPayload","equals","base64","decode","base58","bs58Encode","bs58Decode","parseType","maybeType","base64Type","base58Type","encodedPayload","extra","encoder","getAddressFromPriv","secret","secretBuffer","nacl","keyPair","fromSecretKey","publicKey","isAddressValid","maybeEncoded","encodings","genSalt","BigUint64Array","BigInt","MAX_SAFE_INTEGER","encodeUnsigned","binary","encodeContractAddress","owner","nonce","generateKeyPairFromSecret","generateKeyPair","raw","publicBuffer","secretKey","sign","privateKey","detached","verify","signature","messagePrefix","messagePrefixLength","varuintEncode","messageToHash","signMessage","verifyMessage","isValidKeypair","toBytes","big","hexString","DRY_RUN_ACCOUNT","pub","MAX_AUTH_FUN_GAS","MIN_GAS_PRICE","NAME_FEE_MULTIPLIER","NAME_FEE_BID_INCREMENT","NAME_BID_TIMEOUT_BLOCKS","NAME_MAX_LENGTH_FEE","NAME_BID_RANGES","times","ConsensusProtocolVersion","VmVersion","AbiVersion","Tag","buildContractId","ownerId","oracleQueryId","senderId","oracleId","nonceBE","_int32","AENS_SUFFIX","nameToPunycode","maybeName","suffix","other","punycode","u","URL","username","password","port","search","pathname","host","produceNameId","commitmentHash","padStart","readInt","ensureName","isNameValid","encodingToPointerKey","getDefaultPointerKey","identifier","getMinimumNameFee","nameLength","computeBidFee","startFee","increment","plus","computeAuctionEndBlock","claimHeight","_ref","_ref2","_ref3","isAuctionName","_getPollInterval","_expectedMineRate","_microBlockCycle","onNode","_await$getVal","getVal","devModeDef","def","getNetworkId","base","heightCache","getHeight","cached","_wrappedValue","cache","time","now","getCurrentKeyBlockHeight","poll","interval","_interval","tx","getTransactionByHash","blockHeight","ttl","awaitHeight","_interval2","currentHeight","waitForTxConfirm","confirm","newBlockHeight","getAccount","getAccountByPubkeyAndHeight","getAccountByPubkeyAndHash","getAccountByPubkey","getBalance","format","addr","startsWith","balance","catch","getCurrentGeneration","getGeneration","hashOrHeight","getGenerationByHeight","getGenerationByHash","getMicroBlockTransactions","getMicroBlockTransactionsByHash","transactions","getKeyBlock","getKeyBlockByHeight","getKeyBlockByHash","getMicroBlockHeader","getMicroBlockHeaderByHash","txDryRunRequests","Map","txDryRunHandler","rs","delete","dryRunRes","top","protectedDryRunTxs","txEvents","txs","req","accounts","Set","accountAddress","pubKey","reject","results","reason","resultPayload","idx","assign","txDryRun","combine","_txDryRunRequests$get","requests","_requests$timeout","timeout","getContractByteCode","contractId","getContractCode","getContract","getName","getNameEntryByName","resolveName","resolveByNode","pointer","pointers","ProtocolToVmAbi","Iris","vmVersion","Fate2","abiVersion","Fate","Sophia","NoAbi","Ceres","Fate3","getProtocolDetails","protocolVersion","_protocol$vmVersion$","protocol","serialize","params","consensusProtocolVersion","_value","prepare","getNodeInfo","deserialize","vm","abi","genEntryField","txParams","buildTx","ArrayBuffer","isView","unpackTx","genArrayField","itemHandler","items","buffers","genMapField","Mtree","MtreeValue","recursiveType","withDefault","defaultValue","field","uInt","withFormatting","genShortUIntConstField","constValue","optional","shortUInt","constValueOptional","idTagToEncoding","genAddressField","hashId","idTag","readUIntBE","subarray","genEncodedField","encodedData","serializeAettos","verCmp","getComponents","aComponents","bComponents","componentsToNumber","components","reverse","acc","semverSatisfies","gasPriceCache","getCachedIncreasedGasPrice","node","gasPrice","nodeVersion","_getCachedStatus","minGasPrice","utilization","getRecentGasPrices","maxSafeGasPrice","warn","coinAmount","getOracleRelativeTtl","ttlKeys","OracleRegisterTx","OracleExtendTx","OracleQueryTx","OracleResponseTx","buildGas","builtTx","txObject","innerTxSize","GaMetaTx","PayingForTx","encodedTx","txType","_feeFactors","ChannelForceProgressTx","ChannelOffChainTx","ContractCreateTx","ContractCallTx","GaAttachTx","TX_OTHER_GAS","txSize","relativeTtl","gasPricePrefix","rebuildTx","_computingMinFee","_canIncreaseFee","minFee","previousFee","fee","eq","calculateMinFee","dividedBy","gt","absoluteTtl","_isInternalBuild","genNonceField","senderKey","strategy","getAccountNextNonce","nextNonce","addressAny","txFields","parameters","addressName","ID_TAG","DATA_TAG","bKey","bId","_computingGasLimit","gasMax","gasLimitMax","calculateGasLimitMax","gasLimit","_getProtocolDetails","genEnumerationField","enm","getOracleByPubkey","queryFee","_classPrivateFieldGet2","s","_classPrivateFieldSet","receiver","privateMap","_classPrivateFieldGet","NodeType","_rootHash","_isComplete","_nodes","_encoding","_tag","_unpackTx","_getRaw","WeakSet","_entriesRaw","MPTree","isComplete","unpTx","_classPrivateMethodInitSpec","_classPrivateFieldInitSpec","_classStaticPrivateMethodGet","_nodeHash","_parseNode","Branch","Extension","Leaf","isEqual","tree","mptHash","_classPrivateMethodGet","_getRaw2","_entriesRaw2","rlpEncode","_key","searchFrom","rec","genMPTreeField","genWrappedField","_MPTree","ORACLE_TTL_TYPES","CallReturnType","entryAny","entry","entrySignedTx","SignedTx","entryMtreeValueArray","entryTreesPoi","TreesPoi","mapContracts","Contract","mapAccounts","Account","mapCalls","ContractCall","mapChannels","mapNames","mapOracles","Oracle","clientTtl","nameTtl","NAME_TTL","txSchema","shortUIntConst","flags","gaContract","gaAuthFun","encoded","signatures","SpendTx","recipientId","accountId","status","NamePreclaimTx","commitmentId","NameClaimTx","nameSalt","NameUpdateTx","nameId","pointers2","NameTransferTx","NameRevokeTx","ctVersion","code","active","boolean","referers","deposit","callData","callerId","callerNonce","gasUsed","returnValue","returnType","enumeration","queryFormat","responseFormat","oracleTtlValue","oracleTtlType","delta","query","queryTtlType","queryTtlValue","responseTtlType","responseTtlValue","queryId","response","ChannelCreateTx","initiator","initiatorAmount","responder","responderAmount","channelReserve","lockPeriod","initiatorDelegateIds","responderDelegateIds","stateHash","ChannelCloseMutualTx","channelId","fromId","initiatorAmountFinal","responderAmountFinal","ChannelCloseSoloTx","poi","ChannelSlashTx","ChannelDepositTx","ChannelWithdrawTx","toId","ChannelSettleTx","offChainTrees","channelAmount","soloRound","lockedUntil","initiatorAuth","responderAuth","ChannelSnapshotSoloTx","ChannelOffChainUpdateTransfer","to","ChannelOffChainUpdateDeposit","ChannelOffChainUpdateWithdraw","ChannelOffChainUpdateCreateContract","ChannelOffChainUpdateCallContract","caller","contract","callStack","ChannelClientReconnectTx","role","pubkey","mptree","calls","channels","contracts","ns","oracles","wrapped","ContractsMtree","CallsMtree","ChannelsMtree","NameserviceMtree","OraclesMtree","AccountsMtree","authFun","gaId","authData","payerId","GaMetaTxAuthData","getSchema","schemas","subSchemas","defaultSchema","schema","packRecord","extraParams","unpackRecord","encodedRecord","expectedTag","rlpDecode","getSchemaCommon","overrideParams","buildTxAsync","buildTxHash","rawTx","buildContractIdByContractTx","contractTx","genRequestQueuesPolicy","requestQueues","policy","sendRequest","request","_requestQueues$get","headers","getResponse","then","genCombineGetRequestsPolicy","pendingGetRequests","_pendingGetRequests$g","url","body","genAggressiveCacheGetResponsesPolicy","getRequests","_getRequests$get","genErrorFormatterPolicy","getMessage","bodyAsText","parsedBody","genVersionCheckPolicy","versionCb","requestOptions","customHeaders","genRetryOnFailurePolicy","retryCount","retryOverallDelay","_request$headers$get","retryCode","NaN","statusesToNotRetry","intervals","_","intervalSum","intervalsInMs","attempt","urlParsed","searchParams","_e$response$status","Header","className","modelProperties","serializedName","required","prevHash","prevKeyHash","miner","beneficiary","pow","constraints","MinItems","MaxItems","info","pofHash","txsHash","ErrorModel","errorCode","KeyBlock","HashResponse","HeightResponse","MicroBlockHeader","SignedTxs","blockHash","Tx","initiatorId","responderId","delegateIds","offchainTrees","oracleTtl","queryTtl","responseTtl","gas","Pattern","RegExp","allowedValues","Delegates","OffChainUpdate","uberParent","polymorphicDiscriminator","clientName","op","RelativeTTL","isConstant","Ttl","NamePointer","CountResponse","count","Generation","keyBlock","microBlocks","payable","NextNonceResponse","DryRunInput","DryRunAccount","DryRunInputItem","callReq","DryRunCallReq","calldata","context","DryRunCallContext","stateful","DryRunResults","DryRunResult","callObj","ContractCallObject","Event","topics","TxInfoObject","callInfo","gaInfo","txInfo","GAObject","innerObject","EncodedTx","PostTxResponse","ContractObject","referrerIds","ByteCode","bytecode","PoI","RegisteredOracle","OracleQueries","oracleQueries","senderNonce","AuctionEntry","startedAt","endsAt","highestBidder","highestBid","NameEntry","PeerPubKey","SyncStatus","progress","speed","estimate","Status","genesisKeyBlockHash","solutions","difficulty","hashrate","syncing","syncProgress","InclusiveMaximum","InclusiveMinimum","uptime","listening","protocols","nodeRevision","peerCount","peerConnections","pendingTransactionsCount","networkId","peerPubkey","topKeyBlockHash","topBlockHeight","Protocol","effectiveAtHeight","PeerConnections","inbound","outbound","Currency","subunit","subunitsPerUnit","fiatConverstionUrl","logo","primaryColour","secondaryColour","networkName","Image","GasPricesItem","minutes","OracleRespondTx","CommitmentId","NameHash","ChannelSetDelegatesTx","PubKey","PeerDetails","firstSeen","lastSeen","genesisHash","topHash","topDifficulty","nodeVendor","nodeOs","Peers","peers","blocked","PeerCount","connected","available","PeerCountConnected","PeerCountAvailable","verified","unverified","UnsignedTx","TokenSupply","contractOracles","locked","pendingRewards","total","GAAttachTx","GAMetaTx","CheckTxInPoolResponse","OffChainTransfer","OffChainWithdrawal","OffChainDeposit","OffChainNewContract","OffChainCallContract","CreateContractUnsignedTx","discriminators","accept","parameterPath","mapper","$host","skipEncoding","intAsString","contentType","DryRunInputMapper","body1","EncodedTxMapper","Node","coreClient","_options$endpoint","packageDetails","userAgentPrefix","userAgentOptions","requestContentType","endpoint","baseUri","getTopHeader","sendOperationRequest","getTopHeaderOperationSpec","getCurrentKeyBlock","getCurrentKeyBlockOperationSpec","getCurrentKeyBlockHash","getCurrentKeyBlockHashOperationSpec","getCurrentKeyBlockHeightOperationSpec","getPendingKeyBlock","getPendingKeyBlockOperationSpec","getKeyBlockByHashOperationSpec","getKeyBlockByHeightOperationSpec","getMicroBlockHeaderByHashOperationSpec","getMicroBlockTransactionsByHashOperationSpec","getMicroBlockTransactionByHashAndIndex","getMicroBlockTransactionByHashAndIndexOperationSpec","getMicroBlockTransactionsCountByHash","getMicroBlockTransactionsCountByHashOperationSpec","getCurrentGenerationOperationSpec","getGenerationByHashOperationSpec","getGenerationByHeightOperationSpec","getAccountByPubkeyOperationSpec","getAccountByPubkeyAndHeightOperationSpec","getAccountByPubkeyAndHashOperationSpec","getPendingAccountTransactionsByPubkey","getPendingAccountTransactionsByPubkeyOperationSpec","getAccountNextNonceOperationSpec","protectedDryRunTxsOperationSpec","getTransactionByHashOperationSpec","getTransactionInfoByHash","getTransactionInfoByHashOperationSpec","postTransaction","postTransactionOperationSpec","getContractOperationSpec","getContractCodeOperationSpec","getContractPoI","getContractPoIOperationSpec","getOracleByPubkeyOperationSpec","getOracleQueriesByPubkey","getOracleQueriesByPubkeyOperationSpec","getOracleQueryByPubkeyAndQueryId","getOracleQueryByPubkeyAndQueryIdOperationSpec","getAuctionEntryByName","getAuctionEntryByNameOperationSpec","getNameEntryByNameOperationSpec","getChannelByPubkey","getChannelByPubkeyOperationSpec","getPeerPubkey","getPeerPubkeyOperationSpec","getSyncStatus","getSyncStatusOperationSpec","getStatus","getStatusOperationSpec","getChainEnds","getChainEndsOperationSpec","getCurrency","getCurrencyOperationSpec","getRecentGasPricesOperationSpec","serializer","Mappers","httpMethod","responses","bodyMapper","isError","queryParameters","Parameters","urlParameters","headerParameters","requestBody","mediaType","bigIntPropertyNames","numberPropertyNames","_mapData","_encodeArg","_decodeRes","NodeTransformed","NodeApi","operationArguments","operationSpec","_encodeArg2","_decodeRes2","_mapData2","transform","bigInt","_cachedStatusPromise","ignoreVersion","allowInsecureConnection","additionalPolicies","opts","pipeline","removePolicy","userAgentPolicyName","setClientRequestIdPolicyName","promise","nodeNetworkId","getTransactionSignerAddress","AccountBase","signTypedData","aci","signDelegationToContract","signNameDelegationToContract","signAllNamesDelegationToContract","signOracleQueryDelegationToContract","signDelegation","delegation","hashJson","_canonicalize","canonicalize","hashDomain","domainType","TypeResolver","resolveType","record","option","ContractByteArrayEncoder","encodeWithType","hashTypedData","DelegationTag","oracleAddressField","queryIdField","AensWildcard","AensName","AensPreclaim","packDelegation","unpackDelegation","secretKeys","getBufferToSign","innerTx","rlpBinaryTx","AccountMemory","generate","signTransaction","txWithNetworkId","dHash","isOracle","oracleQueryIdDecoded","addressDecoded","compare","getExecutionCost","isInitiator","getExecutionCostBySignedTx","isInnerTx","isNotInnerTx","getExecutionCostUsingNode","isMined","isSignedTx","combinedInfo","validators","verifyTransactionInternal","parentTxTypes","account","flat","verifyTransaction","nodeNotCached","clone","txBinary","txHashWithNetworkId","checkedKeys","nestedTx","cost","recipient","oracleCall","contractCreate","contractCall","parse","InvalidTxError","validation","sendTransaction","txUnsigned","waitMined","__queue","pollResult","txData","confirmationHeight","verifyTx","toBase64Url","replaceAll","fromBase64Url","objectToBase64Url","header","signJwt","originalPayload","sub_jwk","kty","crv","unpackJwt","jwt","_payload$sub_jwk","payloadEncoded","jwk","signer","isJwt","maybeJwt","ensureJwt","verifyJwt","DERIVED_KEY_FUNCTIONS","argon2id","pass","memlimit_kib","memoryCost","opslimit","timeCost","hashLength","CRYPTO_FUNCTIONS","encrypt","decrypt","CRYPTO_DEFAULTS","secret_type","symmetric_alg","kdf","kdf_params","parallelism","plaintext","algo","deriveKey","kdfParams","recover","crypto","ciphertext","cipher_params","dump","opt","derivedKey","public_key","uuid","Ecb","aesjs","ecb","encryptKey","binaryData","hashedPasswordBytes","decryptKey","encrypted","encryptedBytes","DerivationError","ED25519_CURVE","HARDENED_OFFSET","deriveChild","chainCode","indexBuffer","I","hmac","derivePathFromKey","segments","fromString","toPathArray","segment","parentKey","getMasterKeyFromSeed","seed","derivePathFromSeed","masterKey","formatAccount","getKeyPair","fromSeed","generateSaveHDWalletFromSeed","walletKey","getSaveHDWalletAccounts","saveHDWallet","accountCount","getHdWalletAccountFromSeed","accountIdx","aensRevoke","aensUpdate","extendPointers","allPointers","hasRawPointers","isIris","nameUpdateTx","aensTransfer","aensQuery","nameEntry","freeze","transfer","revoke","extendTtl","aensClaim","claimTx","nameInter","aensPreclaim","preclaimTx","claim","otherOptions","aensBid","_getCallResult","_sendAndProcess","_getFunctionAci","_getContractNameByEvent","_aciContract","_getCallResult2","fnName","fnAci","_getFunctionAci2","decodedResult","_calldata","_name","decodedEvents","$decodeEvents","decodeFateString","_sendAndProcess2","$options","$getCallResultByTxHash","functions","returns","_getContractNameByEvent2","ctAddress","nameHash","contractAddressToName","addressToName","_aci","event","variant","events","eventName","calcHash","ContractWithMethods","$compile","onCompiler","sourceCode","compileBySourceCode","fileSystem","sourceCodePath","compile","callInfoTyped","_estimateGas","$call","callStatic","$deploy","_opt$gasLimit","_opt$gasLimit2","topOption","txOpt","dryRunOther","omitUnknown","contractName","decoded","decodeEvent","initialize","validateBytecode","_bytecode","onChanBytecode","isValid","validateBySourceCode","validate","aciLast","Calldata","aciArgs","pop","pollForQueries","onQuery","knownQueryIds","checkNewQueries","_await$options$onNode","queries","add","stopped","pollForQueryResponse","responseBuffer","getQueryObject","decodedQuery","decodedResponse","respond","respondToQuery","pollForResponse","postQueryToOracle","oracleQueryTx","extendOracleTtl","oracleExtendTx","getOracleObject","oracleRespondTx","pollQueries","postQuery","extendOracle","getQuery","handler","lastArg","registerOracle","oracleRegisterTx","spend","recipientIdOrName","transferFunds","fraction","desiredAmount","minus","payForTransaction","createGeneralizedAccount","authFnName","_options$gasLimit","gaContractId","buildAuthTxHash","buildAuthTxHashByGaMetaTx","_typeof","_defineProperty","chainMethods","aensMethods","spendMethods","oracleMethods","createDelegationSignature","ids","omitAddress","signOpts","oq","ensureOracleQuery","contractGaMethods","_wrappedOptions","AeSdkMethods","_options","getContext","mergeWith","initializeContract","AeSdkBase","nodes","instance","addNode","api","compilerApi","_resolveAccount","ensureNodeConnected","pool","selectedNodeName","select","selectNode","isNodeConnected","getNodesInPool","addresses","_options$networkId","_options$consensusPro","_options$networkId2","_options$consensusPro2","_options$networkId3","_options$consensusPro3","_options$networkId4","_options$consensusPro4","_options$networkId5","AeSdk","addAccount","selectedAddress","selectAccount","removeAccount","MESSAGE_DIRECTION","WALLET_TYPE","SUBSCRIPTION_TYPES","METHODS","RPC_STATUS","rpcErrors","RpcError","toJSON","json","RpcErr","cl","RpcInvalidTransactionError","RpcRejectedByUserError","RpcUnsupportedProtocolError","RpcConnectionDenyError","RpcNotAuthorizeError","RpcPermissionDenyError","RpcInternalError","RpcMethodNotFoundError","AccountRpc","rpcClient","_rpcClient","dataRaw","unsafeSign","returnSigned","signedTransaction","allNames","_callbacks","_messageId","_methods","_handleMessage","_sendRequest","_sendResponse","_processResponse","RpcClient","connection","onDisconnect","connect","_handleMessage2","_sendRequest2","notify","origin","jsonrpc","_processResponse2","methodName","_sendResponse2","sendMessage","callbacks","AeSdkAepp","onAddressChange","onNetworkChange","_ensureConnected","_ensureAccountAccess","_accounts","connectToWallet","connectNode","disconnectParams","updateNetwork","client","updateAddress","closeConnection","disconnect","readyToConnect","walletInfo","disconnectWallet","askAddresses","subscribeAddress","jsonBig","JsonBig","storeAsString","convertValuesToBigNumbers","bn","AeSdkWallet","onConnection","onSubscription","onAskAccounts","_type","_getAccountsForClient","addressSubscription","getAccounts","_pushAccountsToApps","_clients","clientId","_isRpcClientConnected","_getClient","rpc","_getNode","CONNECTED","isConnected","_disconnectRpcClient","DISCONNECTED","removeRpcClient","addRpcClient","clientConnection","WAITING_FOR_CONNECTION_REQUEST","icons","getWalletInfo","subscribe","unsubscribe","subscription","aeppOrigin","aeppRpcClientId","transactionHash","_isOracle","shareWalletInfo","location","_authFun","AccountGeneralized","authCallData","gaMetaTx","CLA","AccountLedger","transport","decorateAppAPIMethods","networkIdBuffer","toSend","maxChunkSize","chunkSize","bufferOffset","writeUInt8","copy","previous","send","messageStr","AccountLedgerFactory","versionCheckPromise","getAppConfiguration","getAddress","accountIndex","addressLength","discover","CompilerBase","CompileOpts","srcFile","ErrorPos","file","line","col","CompileResult","warnings","SophiaCallResultInput","function","callResult","callValue","BytecodeCallResultInput","DecodedCallresult","FunctionCallInput","DecodeCalldataBytecode","DecodedCalldata","DecodeCalldataSource","ByteCodeInput","FateAssembler","fateAssembler","ValidateByteCodeInput","CompilerVersion","ApiVersion","apiVersion","SophiaBinaryData","sophiaType","SophiaJsonData","ContractMapper","SophiaCallResultInputMapper","body2","BytecodeCallResultInputMapper","body3","FunctionCallInputMapper","body4","DecodeCalldataBytecodeMapper","body5","DecodeCalldataSourceMapper","body6","ByteCodeInputMapper","body7","ValidateByteCodeInputMapper","Compiler","generateACI","generateACIOperationSpec","compileContract","compileContractOperationSpec","decodeCallResult","decodeCallResultOperationSpec","decodeCallResultBytecode","decodeCallResultBytecodeOperationSpec","encodeCalldata","encodeCalldataOperationSpec","decodeCalldataBytecode","decodeCalldataBytecodeOperationSpec","decodeCalldataSource","decodeCalldataSourceOperationSpec","getFateAssemblerCode","getFateAssemblerCodeOperationSpec","validateByteCode","validateByteCodeOperationSpec","getCompilerVersion","getCompilerVersionOperationSpec","versionOperationSpec","apiVersionOperationSpec","apiOperationSpec","CompilerHttp","compilerUrl","CompilerApi","parameter","_cmpOut$warnings","cmpOut","warning","generateAciBySourceCode","generateAci","snakeToPascal","PING_TIMEOUT_MS","PONG_TIMEOUT_MS","emit","channel","rest","_eventEmitter","enterState","nextState","_debug","_fsm","enter","dequeueAction","changeStatus","newStatus","debug","_status","changeState","newState","_state","_websocket","_isActionQueueLocked","queue","_actionQueue","action","guard","handleMessage","st","updates","clearTimeout","_pingTimeoutId","ping","_nextRpcMessageId","_rpcCallbacks","_message$error$data$","details","signAndNotify","signFn","_signedTx","signedTx","signed_tx","payloadTx","signatures2","appendSignature","handleUnexpectedMessage","_channel","wsMessage","channelOpen","awaitingCompletion","onSuccess","accepted","error_code","errorMessage","error_msg","codes","awaitingConnection","channelInfoStatus","nextStatus","awaitingChannelCreateTx","awaitingOpenConfirmation","_fsmId","fsm_id","channelClosed","awaitingReconnection","awaitingOnChainTx","awaitingBlockInclusion","message2","_channelId","channel_id","awaitingTxSignRequest","_message$method$match","awaitingUpdateConflict","awaitingShutdownTx","awaitingLeave","closeTx","channelCounter","_debugId","EventEmitter","_initialize","connectionHandler","openHandler","channelOptions","wsUrl","W3CWebSocket","onerror","onopen","reconnectTx","onclose","onmessage","_messageQueue","_isMessageQueueLocked","shift","dequeueMessage","callback","onMessage","existingFsmId","handlers","on","off","removeListener","channelDisconnect","halfSignedTx","trees","fsmId","enqueueAction","leave","shutdown","reconnect","ChannelSpend","meta","awaitingOffChainTx","_2","balances","awaitingActionTx","awaitingActionCompletion","onOnChainTx","Action","isOwn","withdraw","onOwnWithdrawLocked","onWithdrawLocked","onOwnDepositLocked","onDepositLocked","onStatusChanged","snakeToPascalObjKeys","ChannelContract","createContract","call_data","vm_version","abi_version","state2","addressKey","callContract","contract_id","forceProgress","gas_price","callContractStatic","getContractCall","caller_id","getContractState","cleanContractCalls","Source","MiddlewareSubscriberError","MiddlewareSubscriberDisconnected","closeEvent","_subscriptions","_requestQueue","_webSocket","_targets","_sendMessage","_sendSubscribe","_emit","_disconnect","_messageHandler","_subscribe","MiddlewareSubscriber","webSocket","_get_targets","_disconnect2","WebSocket","errorEvent","_emit2","_messageHandler2","_sendSubscribe2","subscribeKeyBlocks","cb","_subscribe2","Middleware","subscribeKeyBlocksNode","subscribeKeyBlocksAll","All","subscribeMicroBlocks","subscribeMicroBlocksNode","subscribeMicroBlocksAll","subscribeTransactions","subscribeTransactionsNode","subscribeTransactionsAll","subscribeObject","subscribeObjectNode","subscribeObjectAll","_sendMessage2","isSubscribe","condition","onlyReset","limit","scope","direction","by2","hashOrKbi","hash1","state1","Paths1I5J7OcV2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchemaAllof0","Activity","blockTime","PaginatedResponse","nullable","ErrorResponse","Paths17FlgdkV2Aex141GetResponses200ContentApplicationJsonSchemaAllof0","Aex141Response","baseUrl","contractTxi","extensions","limits","PathsAxw0PwV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchemaAllof0","Aex141OwnedTokenResponse","tokenId","PathsN3Ru7DV2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchemaAllof0","PathsRa6Pv6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchemaAllof0","Aex141TemplatesResponse","edition","logIdx","templateId","Paths19B9O7TV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchemaAllof0","Aex141TemplateTokensResponse","Paths1Fe570RV2Aex9GetResponses200ContentApplicationJsonSchemaAllof0","Aex9Response","decimals","eventSupply","holders","initialSupply","PathsO9MbpkV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchemaAllof1","Aex9BalanceResponse","tokenName","tokenSymbol","txIndex","PathsY2JwfkV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchemaAllof0","Aex9TransferResponse","callTxi","microTime","sender","Paths5U7W2V2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchemaAllof0","Paths12TleqhV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchemaAllof0","Paths1C2B0UpV2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchemaAllof0","Aex9ContractBalanceResponse","lastLogIdx","lastTxHash","PathsBelvp6V2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchemaAllof0","Paths11X7LpcV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchemaAllof0","Paths5LeqfqV2BlocksGetResponses200ContentApplicationJsonSchemaAllof0","Block","NotFoundResponse","PathsC25EgV2ChannelsGetResponses200ContentApplicationJsonSchemaAllof0","lastUpdatedHeight","lastUpdatedTime","lastUpdatedTxType","updatesCount","Paths1Csrt0IV2ContractsCallsGetResponses200ContentApplicationJsonSchemaAllof0","callTxHash","internalTx","localIdx","microIndex","Paths9Ya94MV2ContractsLogsGetResponses200ContentApplicationJsonSchemaAllof0","ContractLog","eventHash","extCallerContractId","extCallerContractTxi","parentContractId","aexnType","createTx","sourceTxHash","sourceTxType","PathsRzn6HzV2DeltastatsGetResponses200ContentApplicationJsonSchemaAllof0","DeltaStat","auctionsStarted","blockReward","contractsCreated","devReward","namesActivated","namesExpired","namesRevoked","oraclesExpired","oraclesRegistered","Paths10TrrshV2KeyBlocksGetResponses200ContentApplicationJsonSchemaAllof0","Paths7Hfka2V2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchemaAllof0","MicroBlock","microBlockIndex","transactionsCount","Paths1RxrrvbV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchemaAllof0","Paths16Srg6EV2NamesGetResponses200ContentApplicationJsonSchemaAllof0","NameInfo","activationTime","activeFrom","claims","expireHeight","ownership","transfers","NameInfoOwnership","original","NameInfoPointers","accountPubkey","Auction","AuctionInfo","auctionEnd","bids","lastBid","AuctionInfoLastBid","Paths1I6PwfdV2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0","Paths7P6Qc1V2NamesSearchGetResponses200ContentApplicationJsonSchemaAllof0PropertiesDataItemsAllof1","NameClaim","PathsDjelzuV2NamesIdPointeesGetResponses200ContentApplicationJsonSchema","inactive","NameTransfer","NameUpdate","PathsMherz6V2OraclesGetResponses200ContentApplicationJsonSchemaAllof0","extends","oracle","register","registerTime","OracleExtendsItem","Paths1LaqrzqV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchemaAllof0","Paths3PnwziV2OraclesIdResponsesGetResponses200ContentApplicationJsonSchemaAllof0","mdwAsyncTasks","mdwGensPerMinute","mdwHeight","mdwLastMigration","mdwRevision","mdwSynced","mdwSyncing","mdwTxIndex","mdwVersion","nodeHeight","nodeProgress","nodeSyncing","StatusMdwAsyncTasks","longTasks","producerBuffer","totalPending","PathsDpxn99V2TotalstatsGetResponses200ContentApplicationJsonSchemaAllof0","TotalStat","Paths17Cjtx5V2TransfersGetResponses200ContentApplicationJsonSchemaAllof0","Transfer","refTxi","Paths1R74KpvV2TxsGetResponses200ContentApplicationJsonSchemaAllof0","Paths16Tt677V2TxsCountIdGetResponses200ContentApplicationJsonSchema","channelCloseMutualTx","channelCloseSoloTx","channelCreateTx","channelDepositTx","channelForceProgressTx","channelOffchainTx","channelSettleTx","channelSlashTx","channelSnapshotSoloTx","channelWithdrawTx","contractCallTx","contractCreateTx","gaAttachTx","nameClaimTx","namePreclaimTx","nameRevokeTx","nameTransferTx","oracleResponseTx","payingForTx","spendTx","Aex141TransferEvent","Aex9TransferEvent","InternalContractCallEvent","contractTxHash","InternalTransferEvent","refTxHash","NameClaimEvent","PathsKlr2M2V2AccountsIdActivitiesGetResponses200ContentApplicationJsonSchema","PathsFlc7UjV2Aex141GetResponses200ContentApplicationJsonSchema","PathsSs61ZgV2Aex141OwnedNftsAccountidGetResponses200ContentApplicationJsonSchema","Paths1Ilysy5V2Aex141ContractidOwnersGetResponses200ContentApplicationJsonSchema","Paths17O9Fn6V2Aex141ContractidTemplatesGetResponses200ContentApplicationJsonSchema","PathsNuoourV2Aex141ContractidTemplatesTemplateidTokensGetResponses200ContentApplicationJsonSchema","Paths1Wbogg8V2Aex9GetResponses200ContentApplicationJsonSchema","Paths1BsirxgV2Aex9AccountBalancesAccountIdGetResponses200ContentApplicationJsonSchema","Paths1V0FiznV2Aex9TransfersFromToSenderRecipientGetResponses200ContentApplicationJsonSchema","Paths1X48QgjV2Aex9TransfersFromIdGetResponses200ContentApplicationJsonSchema","Paths1DkkopqV2Aex9TransfersToIdGetResponses200ContentApplicationJsonSchema","PathsNi359V2Aex9ContractidBalancesGetResponses200ContentApplicationJsonSchema","Paths15Ih6XV2BlocksGetResponses200ContentApplicationJsonSchema","Paths1Txl2A9V2ChannelsGetResponses200ContentApplicationJsonSchema","Paths187U0XzV2ContractsCallsGetResponses200ContentApplicationJsonSchema","PathsB246H1V2ContractsLogsGetResponses200ContentApplicationJsonSchema","Paths7Pbec0V2DeltastatsGetResponses200ContentApplicationJsonSchema","Paths1Ulxr59V2KeyBlocksGetResponses200ContentApplicationJsonSchema","PathsO99PhzV2KeyBlocksHashOrKbiMicroBlocksGetResponses200ContentApplicationJsonSchema","PathsGuqvhdV2MicroBlocksHashTxsGetResponses200ContentApplicationJsonSchema","PathsK9TkttV2NamesGetResponses200ContentApplicationJsonSchema","Paths3Msq0DV2NamesSearchGetResponses200ContentApplicationJsonSchema","PathsB0YvynV2OraclesGetResponses200ContentApplicationJsonSchema","Paths4Bbr8KV2OraclesIdQueriesGetResponses200ContentApplicationJsonSchema","Paths1Ky8Ew4V2OraclesIdResponsesGetResponses200ContentApplicationJsonSchema","Paths15PsutbV2TotalstatsGetResponses200ContentApplicationJsonSchema","PathsIgs9Z1V2TransfersGetResponses200ContentApplicationJsonSchema","PathsFclv4TV2TxsGetResponses200ContentApplicationJsonSchema","Paths1R02SlwV2Aex9ContractidBalancesAccountidGetResponses200ContentApplicationJsonSchema","Paths1T9RwnyV2Aex9ContractidBalancesAccountidHistoryGetResponses200ContentApplicationJsonSchema","Get200ApplicationJsonAllOfPropertiesItemsItem","getAccountActivities","getAccountActivitiesOperationSpec","getSortedAex141Contracts","getSortedAex141ContractsOperationSpec","getAex141OwnedTokens","getAex141OwnedTokensOperationSpec","getAex141TokenOwner","getAex141TokenOwnerOperationSpec","getAex141ContractOwners","getAex141ContractOwnersOperationSpec","getAex141ContractTemplates","getAex141ContractTemplatesOperationSpec","getAex141TemplateTokens","getAex141TemplateTokensOperationSpec","getAex141ByContract","getAex141ByContractOperationSpec","getSortedAex9Tokens","getSortedAex9TokensOperationSpec","getAex9AccountBalances","getAex9AccountBalancesOperationSpec","getAex9TokensCount","getAex9TokensCountOperationSpec","getAex9PairTransfers","getAex9PairTransfersOperationSpec","getAex9SenderTransfers","getAex9SenderTransfersOperationSpec","getAex9RecipientTransfers","getAex9RecipientTransfersOperationSpec","getAex9ContractBalances","getAex9ContractBalancesOperationSpec","getAex9ContractAccountBalance","getAex9ContractAccountBalanceOperationSpec","getAex9ContractAccountBalanceHistory","getAex9ContractAccountBalanceHistoryOperationSpec","getAex9LogsCount","getAex9LogsCountOperationSpec","getAex9ByContract","getAex9ByContractOperationSpec","getBlocks","getBlocksOperationSpec","getBlock","getBlockOperationSpec","getBlockByMbi","kbi","mbi","getBlockByMbiOperationSpec","getChannels","getChannelsOperationSpec","getChannel","getChannelOperationSpec","getContractsCalls","getContractsCallsOperationSpec","getContractsLogs","getContractsLogsOperationSpec","getDeltastats","getDeltastatsOperationSpec","getKeyBlocks","getKeyBlocksOperationSpec","getKeyBlockOperationSpec","getKeyBlockMicroBlocks","getKeyBlockMicroBlocksOperationSpec","getMicroBlock","getMicroBlockOperationSpec","getMicroBlockTransactionsOperationSpec","getNames","getNamesOperationSpec","getNamesAuctions","getNamesAuctionsOperationSpec","searchNames","searchNamesOperationSpec","getNameOperationSpec","getNameAuction","getNameAuctionOperationSpec","getNameClaims","getNameClaimsOperationSpec","getNamePointees","getNamePointeesOperationSpec","getNamePointers","getNamePointersOperationSpec","getNameTransfers","getNameTransfersOperationSpec","getNameUpdates","getNameUpdatesOperationSpec","getOracles","getOraclesOperationSpec","getOracle","getOracleOperationSpec","getOracleQueries","getOracleQueriesOperationSpec","getOracleResponses","getOracleResponsesOperationSpec","getTotalstats","getTotalstatsOperationSpec","getTransfers","getTransfersOperationSpec","getTxs","getTxsOperationSpec","getTxCount","getTxCountOperationSpec","getTxCountById","getTxCountByIdOperationSpec","getTx","hashOrIndex","getTxOperationSpec","collectionFormat","MiddlewareTransformed","MiddlewareApi","con1","con2","BrowserConnection","receiveMessage","_onDisconnect","_target","_self","BrowserWindowMessageConnection","sendDirection","receiveDirection","to_aepp","listener","_message$data$jsonrpc","addEventListener","removeEventListener","_this$origin","postMessage","onDetected","wallets","wallet","getConnection","to_waellet","newWallet","_listeners","BrowserRuntimeConnection","_port$sender$url","addListener","RpcBroadcastError","NAME_BID_MAX_LENGTH","encodeFateValue","valueType","decodeFateValue","decodeWithType","NAME_MAX_TTL","NAME_MAX_CLIENT_TTL","CLIENT_TTL","ORACLE_TTL","QUERY_TTL","RESPONSE_TTL"],"sourceRoot":""}