@aeternity/aepp-sdk 11.0.0 → 12.1.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 (442) hide show
  1. package/LICENSE +1 -1
  2. package/dist/aepp-sdk.browser-script.js +1 -1
  3. package/dist/aepp-sdk.browser-script.js.LICENSE.txt +0 -22
  4. package/dist/aepp-sdk.browser-script.js.map +1 -1
  5. package/dist/aepp-sdk.browser.js +2 -1
  6. package/dist/aepp-sdk.browser.js.LICENSE.txt +1 -0
  7. package/dist/aepp-sdk.browser.js.map +1 -1
  8. package/dist/aepp-sdk.js +20764 -1
  9. package/dist/aepp-sdk.js.map +1 -1
  10. package/es/AeSdk.d.ts +37 -0
  11. package/es/AeSdk.mjs +81 -0
  12. package/es/AeSdk.mjs.map +1 -0
  13. package/es/AeSdkAepp.d.ts +70 -0
  14. package/es/AeSdkAepp.mjs +176 -0
  15. package/es/AeSdkAepp.mjs.map +1 -0
  16. package/es/AeSdkBase.d.ts +213 -0
  17. package/es/AeSdkBase.mjs +314 -0
  18. package/es/AeSdkBase.mjs.map +1 -0
  19. package/es/AeSdkWallet.d.ts +104 -0
  20. package/es/AeSdkWallet.mjs +326 -0
  21. package/es/AeSdkWallet.mjs.map +1 -0
  22. package/es/Node.d.ts +41 -0
  23. package/es/Node.mjs +147 -0
  24. package/es/Node.mjs.map +1 -0
  25. package/es/account/Base.d.ts +68 -0
  26. package/es/account/Base.mjs +123 -0
  27. package/es/account/Base.mjs.map +1 -0
  28. package/es/account/Memory.d.ts +26 -0
  29. package/es/account/Memory.mjs +103 -0
  30. package/es/account/Memory.mjs.map +1 -0
  31. package/es/account/Rpc.d.ts +27 -0
  32. package/es/account/Rpc.mjs +80 -0
  33. package/es/account/Rpc.mjs.map +1 -0
  34. package/es/aens.d.ts +222 -0
  35. package/es/aens.mjs +338 -0
  36. package/es/aens.mjs.map +1 -0
  37. package/es/aepp-wallet-communication/connection/Browser.d.ts +33 -0
  38. package/es/aepp-wallet-communication/connection/Browser.mjs +73 -0
  39. package/es/aepp-wallet-communication/connection/Browser.mjs.map +1 -0
  40. package/es/aepp-wallet-communication/connection/BrowserRuntime.d.ts +18 -0
  41. package/es/aepp-wallet-communication/connection/BrowserRuntime.mjs +58 -0
  42. package/es/aepp-wallet-communication/connection/BrowserRuntime.mjs.map +1 -0
  43. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.d.ts +36 -0
  44. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.mjs +146 -0
  45. package/es/aepp-wallet-communication/connection/BrowserWindowMessage.mjs.map +1 -0
  46. package/es/aepp-wallet-communication/connection-proxy.d.ts +11 -0
  47. package/{src/utils/crypto-ts.ts → es/aepp-wallet-communication/connection-proxy.mjs} +16 -11
  48. package/es/aepp-wallet-communication/connection-proxy.mjs.map +1 -0
  49. package/es/aepp-wallet-communication/rpc/RpcClient.d.ts +34 -0
  50. package/es/aepp-wallet-communication/rpc/RpcClient.mjs +169 -0
  51. package/es/aepp-wallet-communication/rpc/RpcClient.mjs.map +1 -0
  52. package/es/aepp-wallet-communication/rpc/types.d.ts +77 -0
  53. package/es/aepp-wallet-communication/rpc/types.mjs +3 -0
  54. package/es/aepp-wallet-communication/rpc/types.mjs.map +1 -0
  55. package/es/aepp-wallet-communication/schema.d.ts +105 -46
  56. package/es/aepp-wallet-communication/schema.mjs +251 -0
  57. package/es/aepp-wallet-communication/schema.mjs.map +1 -0
  58. package/es/aepp-wallet-communication/wallet-detector.d.ts +25 -0
  59. package/es/aepp-wallet-communication/wallet-detector.mjs +62 -0
  60. package/es/aepp-wallet-communication/wallet-detector.mjs.map +1 -0
  61. package/es/apis/compiler/compiler.d.ts +92 -0
  62. package/es/apis/compiler/compiler.mjs +576 -0
  63. package/es/apis/compiler/compiler.mjs.map +1 -0
  64. package/es/apis/compiler/index.d.ts +2 -0
  65. package/es/apis/compiler/index.mjs +3 -0
  66. package/es/apis/compiler/index.mjs.map +1 -0
  67. package/es/apis/compiler/models/index.d.ts +248 -0
  68. package/es/apis/compiler/models/index.mjs +48 -0
  69. package/es/apis/compiler/models/index.mjs.map +1 -0
  70. package/es/apis/compiler/models/mappers.d.ts +23 -0
  71. package/es/apis/compiler/models/mappers.mjs +585 -0
  72. package/es/apis/compiler/models/mappers.mjs.map +1 -0
  73. package/es/apis/compiler/models/parameters.d.ts +13 -0
  74. package/es/apis/compiler/models/parameters.mjs +71 -0
  75. package/es/apis/compiler/models/parameters.mjs.map +1 -0
  76. package/es/apis/node/index.d.ts +2 -0
  77. package/es/apis/node/index.mjs +3 -0
  78. package/es/apis/node/index.mjs.map +1 -0
  79. package/es/apis/node/models/index.d.ts +1065 -0
  80. package/es/apis/node/models/index.mjs +2 -0
  81. package/es/apis/node/models/index.mjs.map +1 -0
  82. package/es/apis/node/models/mappers.d.ts +95 -0
  83. package/es/apis/node/models/mappers.mjs +4166 -0
  84. package/es/apis/node/models/mappers.mjs.map +1 -0
  85. package/es/apis/node/models/parameters.d.ts +17 -0
  86. package/es/apis/node/models/parameters.mjs +165 -0
  87. package/es/apis/node/models/parameters.mjs.map +1 -0
  88. package/es/apis/node/node.d.ts +215 -0
  89. package/es/apis/node/node.mjs +1165 -0
  90. package/es/apis/node/node.mjs.map +1 -0
  91. package/es/chain.d.ts +248 -0
  92. package/es/chain.mjs +560 -0
  93. package/es/chain.mjs.map +1 -0
  94. package/es/channel/handlers.d.ts +34 -0
  95. package/es/channel/handlers.mjs +164 -131
  96. package/es/channel/handlers.mjs.map +1 -1
  97. package/es/channel/index.d.ts +625 -0
  98. package/es/channel/index.mjs +897 -902
  99. package/es/channel/index.mjs.map +1 -1
  100. package/es/channel/internal.d.ts +101 -0
  101. package/es/channel/internal.mjs +138 -88
  102. package/es/channel/internal.mjs.map +1 -1
  103. package/es/contract/Compiler.d.ts +18 -0
  104. package/es/contract/Compiler.mjs +68 -0
  105. package/es/contract/Compiler.mjs.map +1 -0
  106. package/es/contract/aci.d.ts +127 -0
  107. package/es/contract/aci.mjs +225 -193
  108. package/es/contract/aci.mjs.map +1 -1
  109. package/es/contract/ga.d.ts +69 -0
  110. package/es/contract/ga.mjs +195 -0
  111. package/es/contract/ga.mjs.map +1 -0
  112. package/es/contract/methods.d.ts +71 -0
  113. package/es/contract/methods.mjs +104 -0
  114. package/es/contract/methods.mjs.map +1 -0
  115. package/es/deprecated/index.d.ts +143 -0
  116. package/es/deprecated/index.mjs +162 -0
  117. package/es/deprecated/index.mjs.map +1 -0
  118. package/es/deprecated/methods.d.ts +18 -0
  119. package/es/deprecated/methods.mjs +26 -0
  120. package/es/deprecated/methods.mjs.map +1 -0
  121. package/es/index.d.ts +35 -0
  122. package/es/index.mjs +35 -40
  123. package/es/index.mjs.map +1 -1
  124. package/es/oracle.d.ts +161 -0
  125. package/es/oracle.mjs +306 -0
  126. package/es/oracle.mjs.map +1 -0
  127. package/es/spend.d.ts +62 -0
  128. package/es/spend.mjs +111 -0
  129. package/es/spend.mjs.map +1 -0
  130. package/es/tx/builder/address.d.ts +25 -0
  131. package/es/tx/builder/address.mjs +45 -0
  132. package/es/tx/builder/address.mjs.map +1 -0
  133. package/es/tx/builder/constants.d.ts +70 -0
  134. package/es/tx/builder/constants.mjs +122 -0
  135. package/es/tx/builder/constants.mjs.map +1 -0
  136. package/es/tx/builder/field-types/coin-amount.d.ts +13 -0
  137. package/es/tx/builder/field-types/coin-amount.mjs +26 -0
  138. package/es/tx/builder/field-types/coin-amount.mjs.map +1 -0
  139. package/es/tx/builder/field-types/deposit.d.ts +15 -0
  140. package/es/tx/builder/field-types/deposit.mjs +19 -0
  141. package/es/tx/builder/field-types/deposit.mjs.map +1 -0
  142. package/es/tx/builder/field-types/fee.d.ts +25 -0
  143. package/es/tx/builder/field-types/fee.mjs +150 -0
  144. package/es/tx/builder/field-types/fee.mjs.map +1 -0
  145. package/es/tx/builder/field-types/field.d.ts +6 -0
  146. package/es/tx/builder/field-types/field.mjs +15 -0
  147. package/es/tx/builder/field-types/field.mjs.map +1 -0
  148. package/es/tx/builder/field-types/gas-limit.d.ts +12 -0
  149. package/es/tx/builder/field-types/gas-limit.mjs +33 -0
  150. package/es/tx/builder/field-types/gas-limit.mjs.map +1 -0
  151. package/es/tx/builder/field-types/gas-price.d.ts +8 -0
  152. package/es/tx/builder/field-types/gas-price.mjs +18 -0
  153. package/es/tx/builder/field-types/gas-price.mjs.map +1 -0
  154. package/es/tx/builder/field-types/index.d.ts +70 -0
  155. package/es/tx/builder/field-types/index.mjs +25 -0
  156. package/es/tx/builder/field-types/index.mjs.map +1 -0
  157. package/es/tx/builder/field-types/name-fee.d.ts +20 -0
  158. package/es/tx/builder/field-types/name-fee.mjs +24 -0
  159. package/es/tx/builder/field-types/name-fee.mjs.map +1 -0
  160. package/es/tx/builder/field-types/name-id.d.ts +14 -0
  161. package/es/tx/builder/field-types/name-id.mjs +19 -0
  162. package/es/tx/builder/field-types/name-id.mjs.map +1 -0
  163. package/es/tx/builder/field-types/name.d.ts +13 -0
  164. package/es/tx/builder/field-types/name.mjs +18 -0
  165. package/es/tx/builder/field-types/name.mjs.map +1 -0
  166. package/es/tx/builder/field-types/short-u-int.d.ts +6 -0
  167. package/es/tx/builder/field-types/short-u-int.mjs +12 -0
  168. package/es/tx/builder/field-types/short-u-int.mjs.map +1 -0
  169. package/es/tx/builder/field-types/u-int.d.ts +8 -0
  170. package/es/tx/builder/field-types/u-int.mjs +14 -0
  171. package/es/tx/builder/field-types/u-int.mjs.map +1 -0
  172. package/es/tx/builder/helpers.d.ts +125 -0
  173. package/es/tx/builder/helpers.mjs +94 -240
  174. package/es/tx/builder/helpers.mjs.map +1 -1
  175. package/es/tx/builder/index.d.ts +88 -0
  176. package/es/tx/builder/index.mjs +167 -358
  177. package/es/tx/builder/index.mjs.map +1 -1
  178. package/es/tx/builder/schema.d.ts +1201 -0
  179. package/es/tx/builder/schema.mjs +175 -664
  180. package/es/tx/builder/schema.mjs.map +1 -1
  181. package/es/tx/index.d.ts +64 -0
  182. package/es/tx/index.mjs +151 -265
  183. package/es/tx/index.mjs.map +1 -1
  184. package/es/tx/validator.d.ts +20 -0
  185. package/es/tx/validator.mjs +104 -124
  186. package/es/tx/validator.mjs.map +1 -1
  187. package/es/typings/@aeternity__argon2-browser/index.d.mjs +2 -0
  188. package/es/typings/@aeternity__argon2-browser/index.d.mjs.map +1 -0
  189. package/es/typings/@aeternity__uuid/index.d.mjs +2 -0
  190. package/es/typings/@aeternity__uuid/index.d.mjs.map +1 -0
  191. package/es/typings/bip32-path/index.d.mjs +2 -0
  192. package/es/typings/bip32-path/index.d.mjs.map +1 -0
  193. package/es/typings/blakejs/index.d.mjs.map +1 -1
  194. package/es/typings/sha-js/index.d.mjs +2 -0
  195. package/es/typings/sha-js/index.d.mjs.map +1 -0
  196. package/es/typings/tweetnacl-auth/index.d.mjs +2 -0
  197. package/es/typings/tweetnacl-auth/index.d.mjs.map +1 -0
  198. package/es/utils/amount-formatter.d.ts +42 -0
  199. package/es/utils/amount-formatter.mjs +36 -49
  200. package/es/utils/amount-formatter.mjs.map +1 -1
  201. package/es/utils/autorest.d.ts +6 -0
  202. package/es/utils/autorest.mjs +97 -0
  203. package/es/utils/autorest.mjs.map +1 -0
  204. package/es/utils/bignumber.d.ts +13 -0
  205. package/es/utils/bignumber.mjs +11 -8
  206. package/es/utils/bignumber.mjs.map +1 -1
  207. package/es/{bytes.d.ts → utils/bytes.d.ts} +10 -13
  208. package/es/utils/bytes.mjs +11 -15
  209. package/es/utils/bytes.mjs.map +1 -1
  210. package/es/utils/crypto.d.ts +88 -0
  211. package/es/utils/crypto.mjs +64 -108
  212. package/es/utils/crypto.mjs.map +1 -1
  213. package/es/utils/encoder-types.d.ts +61 -0
  214. package/es/utils/encoder-types.mjs +36 -0
  215. package/es/utils/encoder-types.mjs.map +1 -0
  216. package/es/utils/encoder.d.ts +25 -0
  217. package/es/utils/encoder.mjs +118 -0
  218. package/es/utils/encoder.mjs.map +1 -0
  219. package/es/{errors.d.ts → utils/errors.d.ts} +246 -59
  220. package/es/utils/errors.mjs +313 -136
  221. package/es/utils/errors.mjs.map +1 -1
  222. package/es/utils/hd-wallet.d.ts +50 -0
  223. package/es/utils/hd-wallet.mjs +86 -45
  224. package/es/utils/hd-wallet.mjs.map +1 -1
  225. package/es/utils/json-big.d.ts +5 -0
  226. package/es/utils/json-big.mjs +12 -16
  227. package/es/utils/json-big.mjs.map +1 -1
  228. package/es/utils/keystore.d.ts +51 -0
  229. package/es/utils/keystore.mjs +101 -194
  230. package/es/utils/keystore.mjs.map +1 -1
  231. package/es/{mptree.d.ts → utils/mptree.d.ts} +6 -9
  232. package/es/utils/mptree.mjs +22 -18
  233. package/es/utils/mptree.mjs.map +1 -1
  234. package/es/utils/other.d.ts +20 -0
  235. package/es/utils/other.mjs +32 -35
  236. package/es/utils/other.mjs.map +1 -1
  237. package/es/utils/semver-satisfies.d.ts +1 -0
  238. package/es/utils/semver-satisfies.mjs +2 -2
  239. package/es/utils/semver-satisfies.mjs.map +1 -1
  240. package/es/utils/string.d.ts +24 -0
  241. package/es/utils/string.mjs +8 -10
  242. package/es/utils/string.mjs.map +1 -1
  243. package/package.json +56 -42
  244. package/src/AeSdk.ts +68 -0
  245. package/src/AeSdkAepp.ts +176 -0
  246. package/src/AeSdkBase.ts +338 -0
  247. package/src/AeSdkWallet.ts +348 -0
  248. package/src/Node.ts +173 -0
  249. package/src/account/Base.ts +124 -0
  250. package/src/account/Memory.ts +98 -0
  251. package/src/account/Rpc.ts +69 -0
  252. package/src/aens.ts +407 -0
  253. package/src/aepp-wallet-communication/connection/Browser.ts +71 -0
  254. package/src/aepp-wallet-communication/connection/BrowserRuntime.ts +59 -0
  255. package/src/aepp-wallet-communication/connection/BrowserWindowMessage.ts +122 -0
  256. package/{es/utils/crypto-ts.mjs → src/aepp-wallet-communication/connection-proxy.ts} +18 -18
  257. package/src/aepp-wallet-communication/rpc/RpcClient.ts +143 -0
  258. package/src/aepp-wallet-communication/rpc/types.ts +66 -0
  259. package/src/aepp-wallet-communication/schema.ts +224 -0
  260. package/src/aepp-wallet-communication/wallet-detector.ts +72 -0
  261. package/src/apis/compiler/code-model-v4.yaml +2649 -0
  262. package/src/apis/compiler/compiler.ts +585 -0
  263. package/src/apis/compiler/index.ts +2 -0
  264. package/src/apis/compiler/models/index.ts +301 -0
  265. package/src/apis/compiler/models/mappers.ts +583 -0
  266. package/src/apis/compiler/models/parameters.ts +93 -0
  267. package/src/apis/node/code-model-v4.yaml +10080 -0
  268. package/src/apis/node/index.ts +2 -0
  269. package/src/apis/node/models/index.ts +1257 -0
  270. package/src/apis/node/models/mappers.ts +4280 -0
  271. package/src/apis/node/models/parameters.ts +188 -0
  272. package/src/apis/node/node.ts +1299 -0
  273. package/src/chain.ts +502 -0
  274. package/src/channel/handlers.ts +817 -0
  275. package/src/channel/index.ts +1025 -0
  276. package/src/channel/internal.ts +361 -0
  277. package/src/contract/Compiler.ts +67 -0
  278. package/src/contract/aci.ts +538 -0
  279. package/src/contract/ga.ts +199 -0
  280. package/src/contract/methods.ts +123 -0
  281. package/src/deprecated/index.ts +170 -0
  282. package/src/deprecated/methods.ts +25 -0
  283. package/src/index.ts +56 -0
  284. package/src/oracle.ts +364 -0
  285. package/src/spend.ts +164 -0
  286. package/src/tx/builder/address.ts +50 -0
  287. package/src/tx/builder/constants.ts +126 -0
  288. package/src/tx/builder/field-types/coin-amount.ts +27 -0
  289. package/src/tx/builder/field-types/deposit.ts +21 -0
  290. package/src/tx/builder/field-types/fee.ts +143 -0
  291. package/src/tx/builder/field-types/field.ts +9 -0
  292. package/src/tx/builder/field-types/gas-limit.ts +41 -0
  293. package/src/tx/builder/field-types/gas-price.ts +16 -0
  294. package/src/tx/builder/field-types/index.ts +45 -0
  295. package/src/tx/builder/field-types/name-fee.ts +32 -0
  296. package/src/tx/builder/field-types/name-id.ts +20 -0
  297. package/src/tx/builder/field-types/name.ts +18 -0
  298. package/src/tx/builder/field-types/short-u-int.ts +11 -0
  299. package/src/tx/builder/field-types/u-int.ts +16 -0
  300. package/src/tx/builder/helpers.ts +248 -0
  301. package/src/tx/builder/index.ts +400 -0
  302. package/src/tx/builder/schema.ts +727 -0
  303. package/src/tx/index.ts +192 -0
  304. package/src/tx/validator.ts +230 -0
  305. package/src/typings/@aeternity__argon2-browser/index.d.ts +3 -0
  306. package/src/typings/@aeternity__uuid/index.d.ts +5 -0
  307. package/src/typings/bip32-path/index.d.ts +33 -0
  308. package/src/typings/blakejs/index.d.ts +4 -32
  309. package/src/typings/sha-js/index.d.ts +5 -0
  310. package/src/typings/tweetnacl-auth/index.d.ts +14 -0
  311. package/src/utils/amount-formatter.ts +56 -69
  312. package/src/utils/autorest.ts +93 -0
  313. package/src/utils/bignumber.ts +11 -12
  314. package/src/utils/bytes.ts +29 -31
  315. package/src/utils/crypto.ts +205 -0
  316. package/src/utils/encoder-types.ts +63 -0
  317. package/src/utils/encoder.ts +146 -0
  318. package/src/utils/errors.ts +482 -366
  319. package/src/utils/hd-wallet.ts +166 -0
  320. package/src/utils/json-big.ts +27 -0
  321. package/src/utils/keystore.ts +182 -0
  322. package/src/utils/mptree.ts +64 -61
  323. package/src/utils/other.ts +34 -41
  324. package/src/utils/semver-satisfies.ts +15 -11
  325. package/src/utils/string.ts +18 -20
  326. package/es/account/base.mjs +0 -179
  327. package/es/account/base.mjs.map +0 -1
  328. package/es/account/memory.mjs +0 -99
  329. package/es/account/memory.mjs.map +0 -1
  330. package/es/account/multiple.mjs +0 -179
  331. package/es/account/multiple.mjs.map +0 -1
  332. package/es/ae/aens.mjs +0 -404
  333. package/es/ae/aens.mjs.map +0 -1
  334. package/es/ae/aepp.mjs +0 -45
  335. package/es/ae/aepp.mjs.map +0 -1
  336. package/es/ae/contract.mjs +0 -159
  337. package/es/ae/contract.mjs.map +0 -1
  338. package/es/ae/index.mjs +0 -207
  339. package/es/ae/index.mjs.map +0 -1
  340. package/es/ae/oracle.mjs +0 -339
  341. package/es/ae/oracle.mjs.map +0 -1
  342. package/es/ae/universal.mjs +0 -45
  343. package/es/ae/universal.mjs.map +0 -1
  344. package/es/ae/wallet.mjs +0 -50
  345. package/es/ae/wallet.mjs.map +0 -1
  346. package/es/amount-formatter.d.ts +0 -58
  347. package/es/bignumber.d.ts +0 -18
  348. package/es/chain/index.mjs +0 -272
  349. package/es/chain/index.mjs.map +0 -1
  350. package/es/chain/node.mjs +0 -442
  351. package/es/chain/node.mjs.map +0 -1
  352. package/es/contract/compiler.mjs +0 -115
  353. package/es/contract/compiler.mjs.map +0 -1
  354. package/es/contract/ga/helpers.mjs +0 -30
  355. package/es/contract/ga/helpers.mjs.map +0 -1
  356. package/es/contract/ga/index.mjs +0 -178
  357. package/es/contract/ga/index.mjs.map +0 -1
  358. package/es/crypto-ts.d.ts +0 -9
  359. package/es/node-pool/index.mjs +0 -188
  360. package/es/node-pool/index.mjs.map +0 -1
  361. package/es/node.mjs +0 -133
  362. package/es/node.mjs.map +0 -1
  363. package/es/other.d.ts +0 -31
  364. package/es/semver-satisfies.d.ts +0 -1
  365. package/es/string.d.ts +0 -26
  366. package/es/tx/builder/field-types.mjs +0 -74
  367. package/es/tx/builder/field-types.mjs.map +0 -1
  368. package/es/tx/tx-object.mjs +0 -283
  369. package/es/tx/tx-object.mjs.map +0 -1
  370. package/es/tx/tx.mjs +0 -938
  371. package/es/tx/tx.mjs.map +0 -1
  372. package/es/utils/aepp-wallet-communication/connection/browser-runtime.mjs +0 -132
  373. package/es/utils/aepp-wallet-communication/connection/browser-runtime.mjs.map +0 -1
  374. package/es/utils/aepp-wallet-communication/connection/browser-window-message.mjs +0 -183
  375. package/es/utils/aepp-wallet-communication/connection/browser-window-message.mjs.map +0 -1
  376. package/es/utils/aepp-wallet-communication/connection/index.mjs +0 -87
  377. package/es/utils/aepp-wallet-communication/connection/index.mjs.map +0 -1
  378. package/es/utils/aepp-wallet-communication/content-script-bridge.mjs +0 -98
  379. package/es/utils/aepp-wallet-communication/content-script-bridge.mjs.map +0 -1
  380. package/es/utils/aepp-wallet-communication/helpers.mjs +0 -92
  381. package/es/utils/aepp-wallet-communication/helpers.mjs.map +0 -1
  382. package/es/utils/aepp-wallet-communication/rpc/aepp-rpc.mjs +0 -375
  383. package/es/utils/aepp-wallet-communication/rpc/aepp-rpc.mjs.map +0 -1
  384. package/es/utils/aepp-wallet-communication/rpc/rpc-client.mjs +0 -275
  385. package/es/utils/aepp-wallet-communication/rpc/rpc-client.mjs.map +0 -1
  386. package/es/utils/aepp-wallet-communication/rpc/wallet-rpc.mjs +0 -541
  387. package/es/utils/aepp-wallet-communication/rpc/wallet-rpc.mjs.map +0 -1
  388. package/es/utils/aepp-wallet-communication/schema.mjs +0 -102
  389. package/es/utils/aepp-wallet-communication/schema.mjs.map +0 -1
  390. package/es/utils/aepp-wallet-communication/wallet-detector.mjs +0 -110
  391. package/es/utils/aepp-wallet-communication/wallet-detector.mjs.map +0 -1
  392. package/es/utils/async-init.mjs +0 -64
  393. package/es/utils/async-init.mjs.map +0 -1
  394. package/es/utils/crypto-ts.mjs.map +0 -1
  395. package/es/utils/swagger.mjs +0 -164
  396. package/es/utils/swagger.mjs.map +0 -1
  397. package/src/account/base.js +0 -153
  398. package/src/account/memory.js +0 -83
  399. package/src/account/multiple.js +0 -162
  400. package/src/ae/aens.js +0 -361
  401. package/src/ae/aepp.js +0 -45
  402. package/src/ae/contract.js +0 -148
  403. package/src/ae/index.js +0 -168
  404. package/src/ae/oracle.js +0 -311
  405. package/src/ae/universal.js +0 -47
  406. package/src/ae/wallet.js +0 -50
  407. package/src/chain/index.js +0 -269
  408. package/src/chain/node.js +0 -320
  409. package/src/channel/handlers.js +0 -673
  410. package/src/channel/index.js +0 -898
  411. package/src/channel/internal.js +0 -237
  412. package/src/contract/aci.js +0 -376
  413. package/src/contract/compiler.js +0 -100
  414. package/src/contract/ga/helpers.js +0 -19
  415. package/src/contract/ga/index.js +0 -150
  416. package/src/index.js +0 -89
  417. package/src/node-pool/index.js +0 -172
  418. package/src/node.js +0 -116
  419. package/src/tx/builder/field-types.js +0 -61
  420. package/src/tx/builder/helpers.js +0 -380
  421. package/src/tx/builder/index.js +0 -465
  422. package/src/tx/builder/schema.js +0 -1197
  423. package/src/tx/index.js +0 -301
  424. package/src/tx/tx-object.js +0 -187
  425. package/src/tx/tx.js +0 -631
  426. package/src/tx/validator.js +0 -181
  427. package/src/utils/aepp-wallet-communication/connection/browser-runtime.js +0 -119
  428. package/src/utils/aepp-wallet-communication/connection/browser-window-message.js +0 -165
  429. package/src/utils/aepp-wallet-communication/connection/index.js +0 -85
  430. package/src/utils/aepp-wallet-communication/content-script-bridge.js +0 -86
  431. package/src/utils/aepp-wallet-communication/helpers.js +0 -60
  432. package/src/utils/aepp-wallet-communication/rpc/aepp-rpc.js +0 -294
  433. package/src/utils/aepp-wallet-communication/rpc/rpc-client.js +0 -232
  434. package/src/utils/aepp-wallet-communication/rpc/wallet-rpc.js +0 -401
  435. package/src/utils/aepp-wallet-communication/schema.ts +0 -80
  436. package/src/utils/aepp-wallet-communication/wallet-detector.js +0 -92
  437. package/src/utils/async-init.js +0 -45
  438. package/src/utils/crypto.js +0 -229
  439. package/src/utils/hd-wallet.js +0 -100
  440. package/src/utils/json-big.js +0 -26
  441. package/src/utils/keystore.js +0 -219
  442. package/src/utils/swagger.js +0 -156
@@ -0,0 +1,1165 @@
1
+ import * as coreClient from "@azure/core-client";
2
+ import * as coreRestPipeline from "@azure/core-rest-pipeline";
3
+ import * as Parameters from "./models/parameters.mjs";
4
+ import * as Mappers from "./models/mappers.mjs";
5
+ export class Node extends coreClient.ServiceClient {
6
+ /**
7
+ * Initializes a new instance of the Node class.
8
+ * @param $host server parameter
9
+ * @param options The parameter options
10
+ */
11
+ constructor($host, options) {
12
+ var _ref, _options$endpoint, _options;
13
+
14
+ if ($host === undefined) {
15
+ throw new Error("'$host' cannot be null");
16
+ } // Initializing default values for options
17
+
18
+
19
+ if (!options) {
20
+ options = {};
21
+ }
22
+
23
+ const defaults = {
24
+ requestContentType: "application/json; charset=utf-8"
25
+ };
26
+ const packageDetails = `azsdk-js-node/1.0.0-beta.1`;
27
+ const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}` : `${packageDetails}`;
28
+ const optionsWithDefaults = { ...defaults,
29
+ ...options,
30
+ userAgentOptions: {
31
+ userAgentPrefix
32
+ },
33
+ baseUri: (_ref = (_options$endpoint = options.endpoint) !== null && _options$endpoint !== void 0 ? _options$endpoint : options.baseUri) !== null && _ref !== void 0 ? _ref : "{$host}"
34
+ };
35
+ super(optionsWithDefaults);
36
+
37
+ if ((_options = options) !== null && _options !== void 0 && _options.pipeline && options.pipeline.getOrderedPolicies().length > 0) {
38
+ const pipelinePolicies = options.pipeline.getOrderedPolicies();
39
+ const bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(pipelinePolicy => pipelinePolicy.name === coreRestPipeline.bearerTokenAuthenticationPolicyName);
40
+
41
+ if (!bearerTokenAuthenticationPolicyFound) {
42
+ this.pipeline.removePolicy({
43
+ name: coreRestPipeline.bearerTokenAuthenticationPolicyName
44
+ });
45
+ this.pipeline.addPolicy(coreRestPipeline.bearerTokenAuthenticationPolicy({
46
+ scopes: `${optionsWithDefaults.baseUri}/.default`,
47
+ challengeCallbacks: {
48
+ authorizeRequestOnChallenge: coreClient.authorizeRequestOnClaimChallenge
49
+ }
50
+ }));
51
+ }
52
+ } // Parameter assignments
53
+
54
+
55
+ this.$host = $host;
56
+ }
57
+ /**
58
+ * Get the top header (either key or micro block)
59
+ * @param options The options parameters.
60
+ */
61
+
62
+
63
+ getTopHeader(options) {
64
+ return this.sendOperationRequest({
65
+ options
66
+ }, getTopHeaderOperationSpec);
67
+ }
68
+ /**
69
+ * Get the current key block
70
+ * @param options The options parameters.
71
+ */
72
+
73
+
74
+ getCurrentKeyBlock(options) {
75
+ return this.sendOperationRequest({
76
+ options
77
+ }, getCurrentKeyBlockOperationSpec);
78
+ }
79
+ /**
80
+ * Get the hash of the current key block
81
+ * @param options The options parameters.
82
+ */
83
+
84
+
85
+ getCurrentKeyBlockHash(options) {
86
+ return this.sendOperationRequest({
87
+ options
88
+ }, getCurrentKeyBlockHashOperationSpec);
89
+ }
90
+ /**
91
+ * Get the height of the current key block
92
+ * @param options The options parameters.
93
+ */
94
+
95
+
96
+ getCurrentKeyBlockHeight(options) {
97
+ return this.sendOperationRequest({
98
+ options
99
+ }, getCurrentKeyBlockHeightOperationSpec);
100
+ }
101
+ /**
102
+ * Get the pending key block
103
+ * @param options The options parameters.
104
+ */
105
+
106
+
107
+ getPendingKeyBlock(options) {
108
+ return this.sendOperationRequest({
109
+ options
110
+ }, getPendingKeyBlockOperationSpec);
111
+ }
112
+ /**
113
+ * Get a key block by hash
114
+ * @param hash The hash of the block - either a keyblock or a microblock
115
+ * @param options The options parameters.
116
+ */
117
+
118
+
119
+ getKeyBlockByHash(hash, options) {
120
+ return this.sendOperationRequest({
121
+ hash,
122
+ options
123
+ }, getKeyBlockByHashOperationSpec);
124
+ }
125
+ /**
126
+ * Get a key block by height
127
+ * @param height The height
128
+ * @param options The options parameters.
129
+ */
130
+
131
+
132
+ getKeyBlockByHeight(height, options) {
133
+ return this.sendOperationRequest({
134
+ height,
135
+ options
136
+ }, getKeyBlockByHeightOperationSpec);
137
+ }
138
+ /**
139
+ * Get a micro block header by hash
140
+ * @param hash The hash of the block - either a keyblock or a microblock
141
+ * @param options The options parameters.
142
+ */
143
+
144
+
145
+ getMicroBlockHeaderByHash(hash, options) {
146
+ return this.sendOperationRequest({
147
+ hash,
148
+ options
149
+ }, getMicroBlockHeaderByHashOperationSpec);
150
+ }
151
+ /**
152
+ * Get micro block transactions by hash
153
+ * @param hash The hash of the micro block
154
+ * @param options The options parameters.
155
+ */
156
+
157
+
158
+ getMicroBlockTransactionsByHash(hash, options) {
159
+ return this.sendOperationRequest({
160
+ hash,
161
+ options
162
+ }, getMicroBlockTransactionsByHashOperationSpec);
163
+ }
164
+ /**
165
+ * Get a micro block transaction by hash and index
166
+ * @param hash The hash of the micro block
167
+ * @param index The index of the transaction in a block
168
+ * @param options The options parameters.
169
+ */
170
+
171
+
172
+ getMicroBlockTransactionByHashAndIndex(hash, index, options) {
173
+ return this.sendOperationRequest({
174
+ hash,
175
+ index,
176
+ options
177
+ }, getMicroBlockTransactionByHashAndIndexOperationSpec);
178
+ }
179
+ /**
180
+ * Get micro block transaction count by hash
181
+ * @param hash The hash of the micro block
182
+ * @param options The options parameters.
183
+ */
184
+
185
+
186
+ getMicroBlockTransactionsCountByHash(hash, options) {
187
+ return this.sendOperationRequest({
188
+ hash,
189
+ options
190
+ }, getMicroBlockTransactionsCountByHashOperationSpec);
191
+ }
192
+ /**
193
+ * Get the current generation
194
+ * @param options The options parameters.
195
+ */
196
+
197
+
198
+ getCurrentGeneration(options) {
199
+ return this.sendOperationRequest({
200
+ options
201
+ }, getCurrentGenerationOperationSpec);
202
+ }
203
+ /**
204
+ * Get a generation by hash
205
+ * @param hash The hash of the key block
206
+ * @param options The options parameters.
207
+ */
208
+
209
+
210
+ getGenerationByHash(hash, options) {
211
+ return this.sendOperationRequest({
212
+ hash,
213
+ options
214
+ }, getGenerationByHashOperationSpec);
215
+ }
216
+ /**
217
+ * Get a generation by height
218
+ * @param height The height
219
+ * @param options The options parameters.
220
+ */
221
+
222
+
223
+ getGenerationByHeight(height, options) {
224
+ return this.sendOperationRequest({
225
+ height,
226
+ options
227
+ }, getGenerationByHeightOperationSpec);
228
+ }
229
+ /**
230
+ * Get an account by public key
231
+ * @param pubkey The public key of the account
232
+ * @param options The options parameters.
233
+ */
234
+
235
+
236
+ getAccountByPubkey(pubkey, options) {
237
+ return this.sendOperationRequest({
238
+ pubkey,
239
+ options
240
+ }, getAccountByPubkeyOperationSpec);
241
+ }
242
+ /**
243
+ * Get an account by public key after the opening key block of the generation at height
244
+ * @param pubkey The public key of the account
245
+ * @param height The height
246
+ * @param options The options parameters.
247
+ */
248
+
249
+
250
+ getAccountByPubkeyAndHeight(pubkey, height, options) {
251
+ return this.sendOperationRequest({
252
+ pubkey,
253
+ height,
254
+ options
255
+ }, getAccountByPubkeyAndHeightOperationSpec);
256
+ }
257
+ /**
258
+ * Get an account by public key after the block indicated by hash. Can be either a micro block or a
259
+ * keyblock hash
260
+ * @param pubkey The public key of the account
261
+ * @param hash The hash of the block - either a keyblock or a microblock
262
+ * @param options The options parameters.
263
+ */
264
+
265
+
266
+ getAccountByPubkeyAndHash(pubkey, hash, options) {
267
+ return this.sendOperationRequest({
268
+ pubkey,
269
+ hash,
270
+ options
271
+ }, getAccountByPubkeyAndHashOperationSpec);
272
+ }
273
+ /**
274
+ * Get pending account transactions by public key
275
+ * @param pubkey The public key of the account
276
+ * @param options The options parameters.
277
+ */
278
+
279
+
280
+ getPendingAccountTransactionsByPubkey(pubkey, options) {
281
+ return this.sendOperationRequest({
282
+ pubkey,
283
+ options
284
+ }, getPendingAccountTransactionsByPubkeyOperationSpec);
285
+ }
286
+ /**
287
+ * Get an account's next nonce; This is computed according to whatever is the current account nonce and
288
+ * what transactions are currently present in the transaction pool
289
+ * @param pubkey The public key of the account
290
+ * @param options The options parameters.
291
+ */
292
+
293
+
294
+ getAccountNextNonce(pubkey, options) {
295
+ return this.sendOperationRequest({
296
+ pubkey,
297
+ options
298
+ }, getAccountNextNonceOperationSpec);
299
+ }
300
+ /**
301
+ * Dry-run transactions on top of a given block. Supports all TXs except GAMetaTx, PayingForTx and
302
+ * OffchainTx. The maximum gas limit of all calls is capped. The maximum gas limit per request is a
303
+ * global node setting. Since DryRunCallReq object do not have a mandatory gas field, if not set a
304
+ * default value of 1000000 is being used instead.
305
+ * @param body transactions
306
+ * @param options The options parameters.
307
+ */
308
+
309
+
310
+ protectedDryRunTxs(body, options) {
311
+ return this.sendOperationRequest({
312
+ body,
313
+ options
314
+ }, protectedDryRunTxsOperationSpec);
315
+ }
316
+ /**
317
+ * Get a transaction by hash
318
+ * @param hash The hash of the transaction
319
+ * @param options The options parameters.
320
+ */
321
+
322
+
323
+ getTransactionByHash(hash, options) {
324
+ return this.sendOperationRequest({
325
+ hash,
326
+ options
327
+ }, getTransactionByHashOperationSpec);
328
+ }
329
+ /**
330
+ * @param hash The hash of the transaction
331
+ * @param options The options parameters.
332
+ */
333
+
334
+
335
+ getTransactionInfoByHash(hash, options) {
336
+ return this.sendOperationRequest({
337
+ hash,
338
+ options
339
+ }, getTransactionInfoByHashOperationSpec);
340
+ }
341
+ /**
342
+ * Post a new transaction
343
+ * @param body The new transaction
344
+ * @param options The options parameters.
345
+ */
346
+
347
+
348
+ postTransaction(body, options) {
349
+ return this.sendOperationRequest({
350
+ body,
351
+ options
352
+ }, postTransactionOperationSpec);
353
+ }
354
+ /**
355
+ * Get a contract by pubkey
356
+ * @param pubkey Contract pubkey to get proof for
357
+ * @param options The options parameters.
358
+ */
359
+
360
+
361
+ getContract(pubkey, options) {
362
+ return this.sendOperationRequest({
363
+ pubkey,
364
+ options
365
+ }, getContractOperationSpec);
366
+ }
367
+ /**
368
+ * Get contract code by pubkey
369
+ * @param pubkey Contract pubkey to get proof for
370
+ * @param options The options parameters.
371
+ */
372
+
373
+
374
+ getContractCode(pubkey, options) {
375
+ return this.sendOperationRequest({
376
+ pubkey,
377
+ options
378
+ }, getContractCodeOperationSpec);
379
+ }
380
+ /**
381
+ * Get a proof of inclusion for a contract
382
+ * @param pubkey Contract pubkey to get proof for
383
+ * @param options The options parameters.
384
+ */
385
+
386
+
387
+ getContractPoI(pubkey, options) {
388
+ return this.sendOperationRequest({
389
+ pubkey,
390
+ options
391
+ }, getContractPoIOperationSpec);
392
+ }
393
+ /**
394
+ * Get an oracle by public key
395
+ * @param pubkey The public key of the oracle
396
+ * @param options The options parameters.
397
+ */
398
+
399
+
400
+ getOracleByPubkey(pubkey, options) {
401
+ return this.sendOperationRequest({
402
+ pubkey,
403
+ options
404
+ }, getOracleByPubkeyOperationSpec);
405
+ }
406
+ /**
407
+ * Get oracle queries by public key
408
+ * @param pubkey The public key of the oracle
409
+ * @param options The options parameters.
410
+ */
411
+
412
+
413
+ getOracleQueriesByPubkey(pubkey, options) {
414
+ return this.sendOperationRequest({
415
+ pubkey,
416
+ options
417
+ }, getOracleQueriesByPubkeyOperationSpec);
418
+ }
419
+ /**
420
+ * Get an oracle query by public key and query ID
421
+ * @param pubkey The public key of the oracle
422
+ * @param queryId The ID of the query
423
+ * @param options The options parameters.
424
+ */
425
+
426
+
427
+ getOracleQueryByPubkeyAndQueryId(pubkey, queryId, options) {
428
+ return this.sendOperationRequest({
429
+ pubkey,
430
+ queryId,
431
+ options
432
+ }, getOracleQueryByPubkeyAndQueryIdOperationSpec);
433
+ }
434
+ /**
435
+ * Get name entry from naming system
436
+ * @param name The name key of the name entry
437
+ * @param options The options parameters.
438
+ */
439
+
440
+
441
+ getNameEntryByName(name, options) {
442
+ return this.sendOperationRequest({
443
+ name,
444
+ options
445
+ }, getNameEntryByNameOperationSpec);
446
+ }
447
+ /**
448
+ * Get channel by public key
449
+ * @param pubkey The pubkey of the channel
450
+ * @param options The options parameters.
451
+ */
452
+
453
+
454
+ getChannelByPubkey(pubkey, options) {
455
+ return this.sendOperationRequest({
456
+ pubkey,
457
+ options
458
+ }, getChannelByPubkeyOperationSpec);
459
+ }
460
+ /**
461
+ * Get peer public key
462
+ * @param options The options parameters.
463
+ */
464
+
465
+
466
+ getPeerPubkey(options) {
467
+ return this.sendOperationRequest({
468
+ options
469
+ }, getPeerPubkeyOperationSpec);
470
+ }
471
+ /**
472
+ * Get the status of a node
473
+ * @param options The options parameters.
474
+ */
475
+
476
+
477
+ getStatus(options) {
478
+ return this.sendOperationRequest({
479
+ options
480
+ }, getStatusOperationSpec);
481
+ }
482
+ /**
483
+ * Get oldest keyblock hashes counting from genesis including orphans
484
+ * @param options The options parameters.
485
+ */
486
+
487
+
488
+ getChainEnds(options) {
489
+ return this.sendOperationRequest({
490
+ options
491
+ }, getChainEndsOperationSpec);
492
+ }
493
+
494
+ } // Operation Specifications
495
+
496
+ const serializer = coreClient.createSerializer(Mappers,
497
+ /* isXml */
498
+ false);
499
+ const getTopHeaderOperationSpec = {
500
+ path: "/v3/headers/top",
501
+ httpMethod: "GET",
502
+ responses: {
503
+ 200: {
504
+ bodyMapper: Mappers.Header
505
+ },
506
+ 404: {
507
+ bodyMapper: Mappers.ErrorModel,
508
+ isError: true
509
+ }
510
+ },
511
+ queryParameters: [Parameters.intAsString],
512
+ urlParameters: [Parameters.$host],
513
+ headerParameters: [Parameters.accept],
514
+ serializer
515
+ };
516
+ const getCurrentKeyBlockOperationSpec = {
517
+ path: "/v3/key-blocks/current",
518
+ httpMethod: "GET",
519
+ responses: {
520
+ 200: {
521
+ bodyMapper: Mappers.KeyBlock
522
+ },
523
+ 404: {
524
+ bodyMapper: Mappers.ErrorModel,
525
+ isError: true
526
+ }
527
+ },
528
+ queryParameters: [Parameters.intAsString],
529
+ urlParameters: [Parameters.$host],
530
+ headerParameters: [Parameters.accept],
531
+ serializer
532
+ };
533
+ const getCurrentKeyBlockHashOperationSpec = {
534
+ path: "/v3/key-blocks/current/hash",
535
+ httpMethod: "GET",
536
+ responses: {
537
+ 200: {
538
+ bodyMapper: Mappers.HashResponse
539
+ },
540
+ 404: {
541
+ bodyMapper: Mappers.ErrorModel,
542
+ isError: true
543
+ }
544
+ },
545
+ queryParameters: [Parameters.intAsString],
546
+ urlParameters: [Parameters.$host],
547
+ headerParameters: [Parameters.accept],
548
+ serializer
549
+ };
550
+ const getCurrentKeyBlockHeightOperationSpec = {
551
+ path: "/v3/key-blocks/current/height",
552
+ httpMethod: "GET",
553
+ responses: {
554
+ 200: {
555
+ bodyMapper: Mappers.HeightResponse
556
+ },
557
+ 404: {
558
+ bodyMapper: Mappers.ErrorModel,
559
+ isError: true
560
+ }
561
+ },
562
+ queryParameters: [Parameters.intAsString],
563
+ urlParameters: [Parameters.$host],
564
+ headerParameters: [Parameters.accept],
565
+ serializer
566
+ };
567
+ const getPendingKeyBlockOperationSpec = {
568
+ path: "/v3/key-blocks/pending",
569
+ httpMethod: "GET",
570
+ responses: {
571
+ 200: {
572
+ bodyMapper: Mappers.KeyBlock
573
+ },
574
+ 400: {
575
+ bodyMapper: Mappers.ErrorModel,
576
+ isError: true
577
+ },
578
+ 404: {
579
+ bodyMapper: Mappers.ErrorModel,
580
+ isError: true
581
+ }
582
+ },
583
+ queryParameters: [Parameters.intAsString],
584
+ urlParameters: [Parameters.$host],
585
+ headerParameters: [Parameters.accept],
586
+ serializer
587
+ };
588
+ const getKeyBlockByHashOperationSpec = {
589
+ path: "/v3/key-blocks/hash/{hash}",
590
+ httpMethod: "GET",
591
+ responses: {
592
+ 200: {
593
+ bodyMapper: Mappers.KeyBlock
594
+ },
595
+ 400: {
596
+ bodyMapper: Mappers.ErrorModel,
597
+ isError: true
598
+ },
599
+ 404: {
600
+ bodyMapper: Mappers.ErrorModel,
601
+ isError: true
602
+ }
603
+ },
604
+ queryParameters: [Parameters.intAsString],
605
+ urlParameters: [Parameters.$host, Parameters.hash],
606
+ headerParameters: [Parameters.accept],
607
+ serializer
608
+ };
609
+ const getKeyBlockByHeightOperationSpec = {
610
+ path: "/v3/key-blocks/height/{height}",
611
+ httpMethod: "GET",
612
+ responses: {
613
+ 200: {
614
+ bodyMapper: Mappers.KeyBlock
615
+ },
616
+ 404: {
617
+ bodyMapper: Mappers.ErrorModel,
618
+ isError: true
619
+ }
620
+ },
621
+ queryParameters: [Parameters.intAsString],
622
+ urlParameters: [Parameters.$host, Parameters.height],
623
+ headerParameters: [Parameters.accept],
624
+ serializer
625
+ };
626
+ const getMicroBlockHeaderByHashOperationSpec = {
627
+ path: "/v3/micro-blocks/hash/{hash}/header",
628
+ httpMethod: "GET",
629
+ responses: {
630
+ 200: {
631
+ bodyMapper: Mappers.MicroBlockHeader
632
+ },
633
+ 400: {
634
+ bodyMapper: Mappers.ErrorModel,
635
+ isError: true
636
+ },
637
+ 404: {
638
+ bodyMapper: Mappers.ErrorModel,
639
+ isError: true
640
+ }
641
+ },
642
+ queryParameters: [Parameters.intAsString],
643
+ urlParameters: [Parameters.$host, Parameters.hash],
644
+ headerParameters: [Parameters.accept],
645
+ serializer
646
+ };
647
+ const getMicroBlockTransactionsByHashOperationSpec = {
648
+ path: "/v3/micro-blocks/hash/{hash}/transactions",
649
+ httpMethod: "GET",
650
+ responses: {
651
+ 200: {
652
+ bodyMapper: Mappers.SignedTxs
653
+ },
654
+ 400: {
655
+ bodyMapper: Mappers.ErrorModel,
656
+ isError: true
657
+ },
658
+ 404: {
659
+ bodyMapper: Mappers.ErrorModel,
660
+ isError: true
661
+ }
662
+ },
663
+ queryParameters: [Parameters.intAsString],
664
+ urlParameters: [Parameters.$host, Parameters.hash],
665
+ headerParameters: [Parameters.accept],
666
+ serializer
667
+ };
668
+ const getMicroBlockTransactionByHashAndIndexOperationSpec = {
669
+ path: "/v3/micro-blocks/hash/{hash}/transactions/index/{index}",
670
+ httpMethod: "GET",
671
+ responses: {
672
+ 200: {
673
+ bodyMapper: Mappers.SignedTx
674
+ },
675
+ 400: {
676
+ bodyMapper: Mappers.ErrorModel,
677
+ isError: true
678
+ },
679
+ 404: {
680
+ bodyMapper: Mappers.ErrorModel,
681
+ isError: true
682
+ }
683
+ },
684
+ queryParameters: [Parameters.intAsString],
685
+ urlParameters: [Parameters.$host, Parameters.hash, Parameters.index],
686
+ headerParameters: [Parameters.accept],
687
+ serializer
688
+ };
689
+ const getMicroBlockTransactionsCountByHashOperationSpec = {
690
+ path: "/v3/micro-blocks/hash/{hash}/transactions/count",
691
+ httpMethod: "GET",
692
+ responses: {
693
+ 200: {
694
+ bodyMapper: Mappers.CountResponse
695
+ },
696
+ 400: {
697
+ bodyMapper: Mappers.ErrorModel,
698
+ isError: true
699
+ },
700
+ 404: {
701
+ bodyMapper: Mappers.ErrorModel,
702
+ isError: true
703
+ }
704
+ },
705
+ queryParameters: [Parameters.intAsString],
706
+ urlParameters: [Parameters.$host, Parameters.hash],
707
+ headerParameters: [Parameters.accept],
708
+ serializer
709
+ };
710
+ const getCurrentGenerationOperationSpec = {
711
+ path: "/v3/generations/current",
712
+ httpMethod: "GET",
713
+ responses: {
714
+ 200: {
715
+ bodyMapper: Mappers.Generation
716
+ },
717
+ 404: {
718
+ bodyMapper: Mappers.ErrorModel,
719
+ isError: true
720
+ }
721
+ },
722
+ queryParameters: [Parameters.intAsString],
723
+ urlParameters: [Parameters.$host],
724
+ headerParameters: [Parameters.accept],
725
+ serializer
726
+ };
727
+ const getGenerationByHashOperationSpec = {
728
+ path: "/v3/generations/hash/{hash}",
729
+ httpMethod: "GET",
730
+ responses: {
731
+ 200: {
732
+ bodyMapper: Mappers.Generation
733
+ },
734
+ 400: {
735
+ bodyMapper: Mappers.ErrorModel,
736
+ isError: true
737
+ },
738
+ 404: {
739
+ bodyMapper: Mappers.ErrorModel,
740
+ isError: true
741
+ }
742
+ },
743
+ queryParameters: [Parameters.intAsString],
744
+ urlParameters: [Parameters.$host, Parameters.hash],
745
+ headerParameters: [Parameters.accept],
746
+ serializer
747
+ };
748
+ const getGenerationByHeightOperationSpec = {
749
+ path: "/v3/generations/height/{height}",
750
+ httpMethod: "GET",
751
+ responses: {
752
+ 200: {
753
+ bodyMapper: Mappers.Generation
754
+ },
755
+ 404: {
756
+ bodyMapper: Mappers.ErrorModel,
757
+ isError: true
758
+ }
759
+ },
760
+ queryParameters: [Parameters.intAsString],
761
+ urlParameters: [Parameters.$host, Parameters.height],
762
+ headerParameters: [Parameters.accept],
763
+ serializer
764
+ };
765
+ const getAccountByPubkeyOperationSpec = {
766
+ path: "/v3/accounts/{pubkey}",
767
+ httpMethod: "GET",
768
+ responses: {
769
+ 200: {
770
+ bodyMapper: Mappers.Account
771
+ },
772
+ 400: {
773
+ bodyMapper: Mappers.ErrorModel,
774
+ isError: true
775
+ },
776
+ 404: {
777
+ bodyMapper: Mappers.ErrorModel,
778
+ isError: true
779
+ }
780
+ },
781
+ queryParameters: [Parameters.intAsString],
782
+ urlParameters: [Parameters.$host, Parameters.pubkey],
783
+ headerParameters: [Parameters.accept],
784
+ serializer
785
+ };
786
+ const getAccountByPubkeyAndHeightOperationSpec = {
787
+ path: "/v3/accounts/{pubkey}/height/{height}",
788
+ httpMethod: "GET",
789
+ responses: {
790
+ 200: {
791
+ bodyMapper: Mappers.Account
792
+ },
793
+ 400: {
794
+ bodyMapper: Mappers.ErrorModel,
795
+ isError: true
796
+ },
797
+ 404: {
798
+ bodyMapper: Mappers.ErrorModel,
799
+ isError: true
800
+ }
801
+ },
802
+ queryParameters: [Parameters.intAsString],
803
+ urlParameters: [Parameters.$host, Parameters.height, Parameters.pubkey],
804
+ headerParameters: [Parameters.accept],
805
+ serializer
806
+ };
807
+ const getAccountByPubkeyAndHashOperationSpec = {
808
+ path: "/v3/accounts/{pubkey}/hash/{hash}",
809
+ httpMethod: "GET",
810
+ responses: {
811
+ 200: {
812
+ bodyMapper: Mappers.Account
813
+ },
814
+ 400: {
815
+ bodyMapper: Mappers.ErrorModel,
816
+ isError: true
817
+ },
818
+ 404: {
819
+ bodyMapper: Mappers.ErrorModel,
820
+ isError: true
821
+ }
822
+ },
823
+ queryParameters: [Parameters.intAsString],
824
+ urlParameters: [Parameters.$host, Parameters.hash, Parameters.pubkey],
825
+ headerParameters: [Parameters.accept],
826
+ serializer
827
+ };
828
+ const getPendingAccountTransactionsByPubkeyOperationSpec = {
829
+ path: "/v3/accounts/{pubkey}/transactions/pending",
830
+ httpMethod: "GET",
831
+ responses: {
832
+ 200: {
833
+ bodyMapper: Mappers.SignedTxs
834
+ },
835
+ 400: {
836
+ bodyMapper: Mappers.ErrorModel,
837
+ isError: true
838
+ },
839
+ 404: {
840
+ bodyMapper: Mappers.ErrorModel,
841
+ isError: true
842
+ }
843
+ },
844
+ queryParameters: [Parameters.intAsString],
845
+ urlParameters: [Parameters.$host, Parameters.pubkey],
846
+ headerParameters: [Parameters.accept],
847
+ serializer
848
+ };
849
+ const getAccountNextNonceOperationSpec = {
850
+ path: "/v3/accounts/{pubkey}/next-nonce",
851
+ httpMethod: "GET",
852
+ responses: {
853
+ 200: {
854
+ bodyMapper: Mappers.NextNonceResponse
855
+ },
856
+ 400: {
857
+ bodyMapper: Mappers.ErrorModel,
858
+ isError: true
859
+ },
860
+ 404: {
861
+ bodyMapper: Mappers.ErrorModel,
862
+ isError: true
863
+ }
864
+ },
865
+ queryParameters: [Parameters.intAsString, Parameters.strategy],
866
+ urlParameters: [Parameters.$host, Parameters.pubkey],
867
+ headerParameters: [Parameters.accept],
868
+ serializer
869
+ };
870
+ const protectedDryRunTxsOperationSpec = {
871
+ path: "/v3/dry-run",
872
+ httpMethod: "POST",
873
+ responses: {
874
+ 200: {
875
+ bodyMapper: Mappers.DryRunResults
876
+ },
877
+ 403: {
878
+ bodyMapper: Mappers.ErrorModel,
879
+ isError: true
880
+ }
881
+ },
882
+ requestBody: Parameters.body,
883
+ queryParameters: [Parameters.intAsString],
884
+ urlParameters: [Parameters.$host],
885
+ headerParameters: [Parameters.accept, Parameters.contentType],
886
+ mediaType: "json",
887
+ serializer
888
+ };
889
+ const getTransactionByHashOperationSpec = {
890
+ path: "/v3/transactions/{hash}",
891
+ httpMethod: "GET",
892
+ responses: {
893
+ 200: {
894
+ bodyMapper: Mappers.SignedTx
895
+ },
896
+ 400: {
897
+ bodyMapper: Mappers.ErrorModel,
898
+ isError: true
899
+ },
900
+ 404: {
901
+ bodyMapper: Mappers.ErrorModel,
902
+ isError: true
903
+ }
904
+ },
905
+ queryParameters: [Parameters.intAsString],
906
+ urlParameters: [Parameters.$host, Parameters.hash],
907
+ headerParameters: [Parameters.accept],
908
+ serializer
909
+ };
910
+ const getTransactionInfoByHashOperationSpec = {
911
+ path: "/v3/transactions/{hash}/info",
912
+ httpMethod: "GET",
913
+ responses: {
914
+ 200: {
915
+ bodyMapper: Mappers.TxInfoObject
916
+ },
917
+ 400: {
918
+ bodyMapper: Mappers.ErrorModel,
919
+ isError: true
920
+ },
921
+ 404: {
922
+ bodyMapper: Mappers.ErrorModel,
923
+ isError: true
924
+ }
925
+ },
926
+ queryParameters: [Parameters.intAsString],
927
+ urlParameters: [Parameters.$host, Parameters.hash],
928
+ headerParameters: [Parameters.accept],
929
+ serializer
930
+ };
931
+ const postTransactionOperationSpec = {
932
+ path: "/v3/transactions",
933
+ httpMethod: "POST",
934
+ responses: {
935
+ 200: {
936
+ bodyMapper: Mappers.PostTxResponse
937
+ },
938
+ 400: {
939
+ bodyMapper: Mappers.ErrorModel,
940
+ isError: true
941
+ }
942
+ },
943
+ requestBody: Parameters.body1,
944
+ queryParameters: [Parameters.intAsString],
945
+ urlParameters: [Parameters.$host],
946
+ headerParameters: [Parameters.accept, Parameters.contentType],
947
+ mediaType: "json",
948
+ serializer
949
+ };
950
+ const getContractOperationSpec = {
951
+ path: "/v3/contracts/{pubkey}",
952
+ httpMethod: "GET",
953
+ responses: {
954
+ 200: {
955
+ bodyMapper: Mappers.ContractObject
956
+ },
957
+ 400: {
958
+ bodyMapper: Mappers.ErrorModel,
959
+ isError: true
960
+ },
961
+ 404: {
962
+ isError: true
963
+ }
964
+ },
965
+ queryParameters: [Parameters.intAsString],
966
+ urlParameters: [Parameters.$host, Parameters.pubkey],
967
+ headerParameters: [Parameters.accept],
968
+ serializer
969
+ };
970
+ const getContractCodeOperationSpec = {
971
+ path: "/v3/contracts/{pubkey}/code",
972
+ httpMethod: "GET",
973
+ responses: {
974
+ 200: {
975
+ bodyMapper: Mappers.ByteCode
976
+ },
977
+ 400: {
978
+ bodyMapper: Mappers.ErrorModel,
979
+ isError: true
980
+ },
981
+ 404: {
982
+ bodyMapper: Mappers.ErrorModel,
983
+ isError: true
984
+ }
985
+ },
986
+ queryParameters: [Parameters.intAsString],
987
+ urlParameters: [Parameters.$host, Parameters.pubkey],
988
+ headerParameters: [Parameters.accept],
989
+ serializer
990
+ };
991
+ const getContractPoIOperationSpec = {
992
+ path: "/v3/contracts/{pubkey}/poi",
993
+ httpMethod: "GET",
994
+ responses: {
995
+ 200: {
996
+ bodyMapper: Mappers.PoI
997
+ },
998
+ 400: {
999
+ bodyMapper: Mappers.ErrorModel,
1000
+ isError: true
1001
+ },
1002
+ 404: {
1003
+ bodyMapper: Mappers.ErrorModel,
1004
+ isError: true
1005
+ }
1006
+ },
1007
+ queryParameters: [Parameters.intAsString],
1008
+ urlParameters: [Parameters.$host, Parameters.pubkey],
1009
+ headerParameters: [Parameters.accept],
1010
+ serializer
1011
+ };
1012
+ const getOracleByPubkeyOperationSpec = {
1013
+ path: "/v3/oracles/{pubkey}",
1014
+ httpMethod: "GET",
1015
+ responses: {
1016
+ 200: {
1017
+ bodyMapper: Mappers.RegisteredOracle
1018
+ },
1019
+ 400: {
1020
+ bodyMapper: Mappers.ErrorModel,
1021
+ isError: true
1022
+ },
1023
+ 404: {
1024
+ bodyMapper: Mappers.ErrorModel,
1025
+ isError: true
1026
+ }
1027
+ },
1028
+ queryParameters: [Parameters.intAsString],
1029
+ urlParameters: [Parameters.$host, Parameters.pubkey],
1030
+ headerParameters: [Parameters.accept],
1031
+ serializer
1032
+ };
1033
+ const getOracleQueriesByPubkeyOperationSpec = {
1034
+ path: "/v3/oracles/{pubkey}/queries",
1035
+ httpMethod: "GET",
1036
+ responses: {
1037
+ 200: {
1038
+ bodyMapper: Mappers.OracleQueries
1039
+ },
1040
+ 400: {
1041
+ bodyMapper: Mappers.ErrorModel,
1042
+ isError: true
1043
+ },
1044
+ 404: {
1045
+ bodyMapper: Mappers.ErrorModel,
1046
+ isError: true
1047
+ }
1048
+ },
1049
+ queryParameters: [Parameters.intAsString, Parameters.fromParam, Parameters.limit, Parameters.typeParam],
1050
+ urlParameters: [Parameters.$host, Parameters.pubkey],
1051
+ headerParameters: [Parameters.accept],
1052
+ serializer
1053
+ };
1054
+ const getOracleQueryByPubkeyAndQueryIdOperationSpec = {
1055
+ path: "/v3/oracles/{pubkey}/queries/{query-id}",
1056
+ httpMethod: "GET",
1057
+ responses: {
1058
+ 200: {
1059
+ bodyMapper: Mappers.OracleQuery
1060
+ },
1061
+ 400: {
1062
+ bodyMapper: Mappers.ErrorModel,
1063
+ isError: true
1064
+ },
1065
+ 404: {
1066
+ bodyMapper: Mappers.ErrorModel,
1067
+ isError: true
1068
+ }
1069
+ },
1070
+ queryParameters: [Parameters.intAsString],
1071
+ urlParameters: [Parameters.$host, Parameters.pubkey, Parameters.queryId],
1072
+ headerParameters: [Parameters.accept],
1073
+ serializer
1074
+ };
1075
+ const getNameEntryByNameOperationSpec = {
1076
+ path: "/v3/names/{name}",
1077
+ httpMethod: "GET",
1078
+ responses: {
1079
+ 200: {
1080
+ bodyMapper: Mappers.NameEntry
1081
+ },
1082
+ 400: {
1083
+ bodyMapper: Mappers.ErrorModel,
1084
+ isError: true
1085
+ },
1086
+ 404: {
1087
+ bodyMapper: Mappers.ErrorModel,
1088
+ isError: true
1089
+ }
1090
+ },
1091
+ queryParameters: [Parameters.intAsString],
1092
+ urlParameters: [Parameters.$host, Parameters.name],
1093
+ headerParameters: [Parameters.accept],
1094
+ serializer
1095
+ };
1096
+ const getChannelByPubkeyOperationSpec = {
1097
+ path: "/v3/channels/{pubkey}",
1098
+ httpMethod: "GET",
1099
+ responses: {
1100
+ 200: {
1101
+ bodyMapper: Mappers.Channel
1102
+ },
1103
+ 400: {
1104
+ bodyMapper: Mappers.ErrorModel,
1105
+ isError: true
1106
+ },
1107
+ 404: {
1108
+ bodyMapper: Mappers.ErrorModel,
1109
+ isError: true
1110
+ }
1111
+ },
1112
+ queryParameters: [Parameters.intAsString],
1113
+ urlParameters: [Parameters.$host, Parameters.pubkey],
1114
+ headerParameters: [Parameters.accept],
1115
+ serializer
1116
+ };
1117
+ const getPeerPubkeyOperationSpec = {
1118
+ path: "/v3/peers/pubkey",
1119
+ httpMethod: "GET",
1120
+ responses: {
1121
+ 200: {
1122
+ bodyMapper: Mappers.PeerPubKey
1123
+ }
1124
+ },
1125
+ queryParameters: [Parameters.intAsString],
1126
+ urlParameters: [Parameters.$host],
1127
+ headerParameters: [Parameters.accept],
1128
+ serializer
1129
+ };
1130
+ const getStatusOperationSpec = {
1131
+ path: "/v3/status",
1132
+ httpMethod: "GET",
1133
+ responses: {
1134
+ 200: {
1135
+ bodyMapper: Mappers.Status
1136
+ }
1137
+ },
1138
+ queryParameters: [Parameters.intAsString],
1139
+ urlParameters: [Parameters.$host],
1140
+ headerParameters: [Parameters.accept],
1141
+ serializer
1142
+ };
1143
+ const getChainEndsOperationSpec = {
1144
+ path: "/v3/status/chain-ends",
1145
+ httpMethod: "GET",
1146
+ responses: {
1147
+ 200: {
1148
+ bodyMapper: {
1149
+ type: {
1150
+ name: "Sequence",
1151
+ element: {
1152
+ type: {
1153
+ name: "String"
1154
+ }
1155
+ }
1156
+ }
1157
+ }
1158
+ }
1159
+ },
1160
+ queryParameters: [Parameters.intAsString],
1161
+ urlParameters: [Parameters.$host],
1162
+ headerParameters: [Parameters.accept],
1163
+ serializer
1164
+ };
1165
+ //# sourceMappingURL=node.mjs.map