@typus/typus-sdk 1.5.4 → 1.5.5-a

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 (411) hide show
  1. package/dist/src/constants/token.d.ts +5 -53
  2. package/dist/src/constants/token.js +174 -104
  3. package/dist/src/typus-dov-single-v2/history/user-history.d.ts +2 -1
  4. package/dist/src/typus-launch/airdrop/authority-entry.js +2 -2
  5. package/package.json +2 -1
  6. package/dist/src/typus-perp/_dependencies/source/0x1/ascii/structs.d.ts +0 -92
  7. package/dist/src/typus-perp/_dependencies/source/0x1/ascii/structs.js +0 -406
  8. package/dist/src/typus-perp/_dependencies/source/0x1/bit-vector/structs.d.ts +0 -56
  9. package/dist/src/typus-perp/_dependencies/source/0x1/bit-vector/structs.js +0 -268
  10. package/dist/src/typus-perp/_dependencies/source/0x1/fixed-point32/structs.d.ts +0 -46
  11. package/dist/src/typus-perp/_dependencies/source/0x1/fixed-point32/structs.js +0 -228
  12. package/dist/src/typus-perp/_dependencies/source/0x1/index.d.ts +0 -3
  13. package/dist/src/typus-perp/_dependencies/source/0x1/index.js +0 -6
  14. package/dist/src/typus-perp/_dependencies/source/0x1/init.d.ts +0 -2
  15. package/dist/src/typus-perp/_dependencies/source/0x1/init.js +0 -55
  16. package/dist/src/typus-perp/_dependencies/source/0x1/option/structs.d.ts +0 -52
  17. package/dist/src/typus-perp/_dependencies/source/0x1/option/structs.js +0 -277
  18. package/dist/src/typus-perp/_dependencies/source/0x1/string/structs.d.ts +0 -50
  19. package/dist/src/typus-perp/_dependencies/source/0x1/string/structs.js +0 -262
  20. package/dist/src/typus-perp/_dependencies/source/0x1/type-name/structs.d.ts +0 -53
  21. package/dist/src/typus-perp/_dependencies/source/0x1/type-name/structs.js +0 -229
  22. package/dist/src/typus-perp/_dependencies/source/0x1/uq32-32/structs.d.ts +0 -46
  23. package/dist/src/typus-perp/_dependencies/source/0x1/uq32-32/structs.js +0 -228
  24. package/dist/src/typus-perp/_dependencies/source/0x1/uq64-64/structs.d.ts +0 -46
  25. package/dist/src/typus-perp/_dependencies/source/0x1/uq64-64/structs.js +0 -228
  26. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/index.d.ts +0 -5
  27. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/index.js +0 -8
  28. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/init.d.ts +0 -2
  29. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/init.js +0 -50
  30. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/oracle/structs.d.ts +0 -350
  31. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/oracle/structs.js +0 -803
  32. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/pyth-parser/structs.d.ts +0 -111
  33. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/pyth-parser/structs.js +0 -395
  34. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/supra/structs.d.ts +0 -70
  35. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/supra/structs.js +0 -252
  36. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/switchboard-feed-parser/structs.d.ts +0 -70
  37. package/dist/src/typus-perp/_dependencies/source/0x1d17058789bd1e1e79f1a92424519a88146f191f58a06cc4d9ab23d17d46ab73/switchboard-feed-parser/structs.js +0 -255
  38. package/dist/src/typus-perp/_dependencies/source/0x2/authenticator-state/structs.d.ts +0 -464
  39. package/dist/src/typus-perp/_dependencies/source/0x2/authenticator-state/structs.js +0 -904
  40. package/dist/src/typus-perp/_dependencies/source/0x2/bag/structs.d.ts +0 -61
  41. package/dist/src/typus-perp/_dependencies/source/0x2/bag/structs.js +0 -235
  42. package/dist/src/typus-perp/_dependencies/source/0x2/balance/structs.d.ts +0 -88
  43. package/dist/src/typus-perp/_dependencies/source/0x2/balance/structs.js +0 -398
  44. package/dist/src/typus-perp/_dependencies/source/0x2/bcs/structs.d.ts +0 -50
  45. package/dist/src/typus-perp/_dependencies/source/0x2/bcs/structs.js +0 -262
  46. package/dist/src/typus-perp/_dependencies/source/0x2/bls12381/structs.d.ts +0 -214
  47. package/dist/src/typus-perp/_dependencies/source/0x2/bls12381/structs.js +0 -820
  48. package/dist/src/typus-perp/_dependencies/source/0x2/borrow/structs.d.ts +0 -113
  49. package/dist/src/typus-perp/_dependencies/source/0x2/borrow/structs.js +0 -410
  50. package/dist/src/typus-perp/_dependencies/source/0x2/clock/structs.d.ts +0 -61
  51. package/dist/src/typus-perp/_dependencies/source/0x2/clock/structs.js +0 -235
  52. package/dist/src/typus-perp/_dependencies/source/0x2/coin/structs.d.ts +0 -460
  53. package/dist/src/typus-perp/_dependencies/source/0x2/coin/structs.js +0 -1259
  54. package/dist/src/typus-perp/_dependencies/source/0x2/config/structs.d.ts +0 -179
  55. package/dist/src/typus-perp/_dependencies/source/0x2/config/structs.js +0 -577
  56. package/dist/src/typus-perp/_dependencies/source/0x2/deny-list/structs.d.ts +0 -430
  57. package/dist/src/typus-perp/_dependencies/source/0x2/deny-list/structs.js +0 -1187
  58. package/dist/src/typus-perp/_dependencies/source/0x2/display/structs.d.ts +0 -241
  59. package/dist/src/typus-perp/_dependencies/source/0x2/display/structs.js +0 -584
  60. package/dist/src/typus-perp/_dependencies/source/0x2/dynamic-field/structs.d.ts +0 -68
  61. package/dist/src/typus-perp/_dependencies/source/0x2/dynamic-field/structs.js +0 -256
  62. package/dist/src/typus-perp/_dependencies/source/0x2/dynamic-object-field/structs.d.ts +0 -47
  63. package/dist/src/typus-perp/_dependencies/source/0x2/dynamic-object-field/structs.js +0 -242
  64. package/dist/src/typus-perp/_dependencies/source/0x2/groth16/structs.d.ts +0 -204
  65. package/dist/src/typus-perp/_dependencies/source/0x2/groth16/structs.js +0 -720
  66. package/dist/src/typus-perp/_dependencies/source/0x2/group-ops/structs.d.ts +0 -50
  67. package/dist/src/typus-perp/_dependencies/source/0x2/group-ops/structs.js +0 -273
  68. package/dist/src/typus-perp/_dependencies/source/0x2/index.d.ts +0 -3
  69. package/dist/src/typus-perp/_dependencies/source/0x2/index.js +0 -6
  70. package/dist/src/typus-perp/_dependencies/source/0x2/init.d.ts +0 -2
  71. package/dist/src/typus-perp/_dependencies/source/0x2/init.js +0 -171
  72. package/dist/src/typus-perp/_dependencies/source/0x2/kiosk/structs.d.ts +0 -606
  73. package/dist/src/typus-perp/_dependencies/source/0x2/kiosk/structs.js +0 -1734
  74. package/dist/src/typus-perp/_dependencies/source/0x2/kiosk-extension/structs.d.ts +0 -121
  75. package/dist/src/typus-perp/_dependencies/source/0x2/kiosk-extension/structs.js +0 -400
  76. package/dist/src/typus-perp/_dependencies/source/0x2/linked-table/structs.d.ts +0 -153
  77. package/dist/src/typus-perp/_dependencies/source/0x2/linked-table/structs.js +0 -438
  78. package/dist/src/typus-perp/_dependencies/source/0x2/object/structs.d.ts +0 -92
  79. package/dist/src/typus-perp/_dependencies/source/0x2/object/structs.js +0 -377
  80. package/dist/src/typus-perp/_dependencies/source/0x2/object-bag/structs.d.ts +0 -61
  81. package/dist/src/typus-perp/_dependencies/source/0x2/object-bag/structs.js +0 -235
  82. package/dist/src/typus-perp/_dependencies/source/0x2/object-table/structs.d.ts +0 -61
  83. package/dist/src/typus-perp/_dependencies/source/0x2/object-table/structs.js +0 -248
  84. package/dist/src/typus-perp/_dependencies/source/0x2/package/structs.d.ts +0 -280
  85. package/dist/src/typus-perp/_dependencies/source/0x2/package/structs.js +0 -762
  86. package/dist/src/typus-perp/_dependencies/source/0x2/priority-queue/structs.d.ts +0 -111
  87. package/dist/src/typus-perp/_dependencies/source/0x2/priority-queue/structs.js +0 -444
  88. package/dist/src/typus-perp/_dependencies/source/0x2/random/structs.d.ts +0 -204
  89. package/dist/src/typus-perp/_dependencies/source/0x2/random/structs.js +0 -596
  90. package/dist/src/typus-perp/_dependencies/source/0x2/sui/structs.d.ts +0 -46
  91. package/dist/src/typus-perp/_dependencies/source/0x2/sui/structs.js +0 -228
  92. package/dist/src/typus-perp/_dependencies/source/0x2/table/structs.d.ts +0 -61
  93. package/dist/src/typus-perp/_dependencies/source/0x2/table/structs.js +0 -248
  94. package/dist/src/typus-perp/_dependencies/source/0x2/table-vec/structs.d.ts +0 -68
  95. package/dist/src/typus-perp/_dependencies/source/0x2/table-vec/structs.js +0 -274
  96. package/dist/src/typus-perp/_dependencies/source/0x2/token/structs.d.ts +0 -449
  97. package/dist/src/typus-perp/_dependencies/source/0x2/token/structs.js +0 -1107
  98. package/dist/src/typus-perp/_dependencies/source/0x2/transfer/structs.d.ts +0 -57
  99. package/dist/src/typus-perp/_dependencies/source/0x2/transfer/structs.js +0 -246
  100. package/dist/src/typus-perp/_dependencies/source/0x2/transfer-policy/structs.d.ts +0 -370
  101. package/dist/src/typus-perp/_dependencies/source/0x2/transfer-policy/structs.js +0 -1109
  102. package/dist/src/typus-perp/_dependencies/source/0x2/tx-context/structs.d.ts +0 -74
  103. package/dist/src/typus-perp/_dependencies/source/0x2/tx-context/structs.js +0 -289
  104. package/dist/src/typus-perp/_dependencies/source/0x2/url/structs.d.ts +0 -53
  105. package/dist/src/typus-perp/_dependencies/source/0x2/url/structs.js +0 -229
  106. package/dist/src/typus-perp/_dependencies/source/0x2/vec-map/structs.d.ts +0 -111
  107. package/dist/src/typus-perp/_dependencies/source/0x2/vec-map/structs.js +0 -446
  108. package/dist/src/typus-perp/_dependencies/source/0x2/vec-set/structs.d.ts +0 -51
  109. package/dist/src/typus-perp/_dependencies/source/0x2/vec-set/structs.js +0 -276
  110. package/dist/src/typus-perp/_dependencies/source/0x2/versioned/structs.d.ts +0 -113
  111. package/dist/src/typus-perp/_dependencies/source/0x2/versioned/structs.js +0 -389
  112. package/dist/src/typus-perp/_dependencies/source/0x2/zklogin-verified-id/structs.d.ts +0 -110
  113. package/dist/src/typus-perp/_dependencies/source/0x2/zklogin-verified-id/structs.js +0 -263
  114. package/dist/src/typus-perp/_dependencies/source/0x2/zklogin-verified-issuer/structs.d.ts +0 -74
  115. package/dist/src/typus-perp/_dependencies/source/0x2/zklogin-verified-issuer/structs.js +0 -245
  116. package/dist/src/typus-perp/_dependencies/source/0x277f90d256d1015a78cad646db091bec451c5bbab834b9fb70bace7885b5c698/index.d.ts +0 -3
  117. package/dist/src/typus-perp/_dependencies/source/0x277f90d256d1015a78cad646db091bec451c5bbab834b9fb70bace7885b5c698/index.js +0 -6
  118. package/dist/src/typus-perp/_dependencies/source/0x277f90d256d1015a78cad646db091bec451c5bbab834b9fb70bace7885b5c698/init.d.ts +0 -2
  119. package/dist/src/typus-perp/_dependencies/source/0x277f90d256d1015a78cad646db091bec451c5bbab834b9fb70bace7885b5c698/init.js +0 -40
  120. package/dist/src/typus-perp/_dependencies/source/0x277f90d256d1015a78cad646db091bec451c5bbab834b9fb70bace7885b5c698/validator/structs.d.ts +0 -55
  121. package/dist/src/typus-perp/_dependencies/source/0x277f90d256d1015a78cad646db091bec451c5bbab834b9fb70bace7885b5c698/validator/structs.js +0 -229
  122. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/index.d.ts +0 -4
  123. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/index.js +0 -7
  124. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/init.d.ts +0 -2
  125. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/init.js +0 -43
  126. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/price-data-pull/structs.d.ts +0 -46
  127. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/price-data-pull/structs.js +0 -228
  128. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/suprasvaluefeed/structs.d.ts +0 -121
  129. package/dist/src/typus-perp/_dependencies/source/0x2fdff17b86e34ab722c8ba5e63f0da070d9a4163705b3fdc6a95802cab40a72a/suprasvaluefeed/structs.js +0 -401
  130. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/airdrop/structs.d.ts +0 -489
  131. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/airdrop/structs.js +0 -1102
  132. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/big-vector/structs.d.ts +0 -147
  133. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/big-vector/structs.js +0 -456
  134. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/critbit/structs.d.ts +0 -239
  135. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/critbit/structs.js +0 -653
  136. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/ecosystem/structs.d.ts +0 -405
  137. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/ecosystem/structs.js +0 -908
  138. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/index.d.ts +0 -8
  139. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/index.js +0 -11
  140. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/init.d.ts +0 -2
  141. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/init.js +0 -102
  142. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/keyed-big-vector/structs.d.ts +0 -227
  143. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/keyed-big-vector/structs.js +0 -632
  144. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/leaderboard/structs.d.ts +0 -699
  145. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/leaderboard/structs.js +0 -1486
  146. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/linked-object-table/structs.d.ts +0 -161
  147. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/linked-object-table/structs.js +0 -438
  148. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/linked-set/structs.d.ts +0 -147
  149. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/linked-set/structs.js +0 -430
  150. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/tails-staking/structs.d.ts +0 -1071
  151. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/tails-staking/structs.js +0 -2285
  152. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/tgld/structs.d.ts +0 -279
  153. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/tgld/structs.js +0 -742
  154. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/user/structs.d.ts +0 -328
  155. package/dist/src/typus-perp/_dependencies/source/0x4213e12a2220f15f1837a76897110d2260786558169bd8d0847f21e9b551f277/user/structs.js +0 -910
  156. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/discount-mint/structs.d.ts +0 -628
  157. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/discount-mint/structs.js +0 -1345
  158. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/index.d.ts +0 -9
  159. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/index.js +0 -12
  160. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/init.d.ts +0 -2
  161. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/init.js +0 -72
  162. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/royalty-rule/structs.d.ts +0 -94
  163. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/royalty-rule/structs.js +0 -382
  164. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/staking/structs.d.ts +0 -454
  165. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/staking/structs.js +0 -896
  166. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/table-vec/structs.d.ts +0 -68
  167. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/table-vec/structs.js +0 -274
  168. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/typus-nft/structs.d.ts +0 -1117
  169. package/dist/src/typus-perp/_dependencies/source/0x5cfd0819411be98034cba544cbffab192c2c35674a05ff57f4f1c5042875b828/typus-nft/structs.js +0 -2417
  170. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/auto-bid/structs.d.ts +0 -1524
  171. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/auto-bid/structs.js +0 -3062
  172. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/index.d.ts +0 -10
  173. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/index.js +0 -13
  174. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/init.d.ts +0 -2
  175. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/init.js +0 -145
  176. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tails-staking/structs.d.ts +0 -1267
  177. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tails-staking/structs.js +0 -2856
  178. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-authorized-entry/structs.d.ts +0 -1412
  179. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-authorized-entry/structs.js +0 -1679
  180. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-fee-pool-entry/structs.d.ts +0 -425
  181. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-fee-pool-entry/structs.js +0 -1259
  182. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-registry-authorized-entry/structs.d.ts +0 -1156
  183. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-registry-authorized-entry/structs.js +0 -1879
  184. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-view-function/structs.d.ts +0 -82
  185. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/tds-view-function/structs.js +0 -264
  186. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/typus-dov-single/structs.d.ts +0 -5022
  187. package/dist/src/typus-perp/_dependencies/source/0x6c9a394a43844fc09d9617bc8a8e775a4521f0e28e83de1da780d043a498671f/typus-dov-single/structs.js +0 -7690
  188. package/dist/src/typus-perp/_dependencies/source/0x7237ec8436ef7e927c45470db6db3a834dd84cf903aedee3844e847fe4805399/index.d.ts +0 -3
  189. package/dist/src/typus-perp/_dependencies/source/0x7237ec8436ef7e927c45470db6db3a834dd84cf903aedee3844e847fe4805399/index.js +0 -6
  190. package/dist/src/typus-perp/_dependencies/source/0x7237ec8436ef7e927c45470db6db3a834dd84cf903aedee3844e847fe4805399/init.d.ts +0 -2
  191. package/dist/src/typus-perp/_dependencies/source/0x7237ec8436ef7e927c45470db6db3a834dd84cf903aedee3844e847fe4805399/init.js +0 -4
  192. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/authority/structs.d.ts +0 -88
  193. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/authority/structs.js +0 -266
  194. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/balance-pool/structs.d.ts +0 -347
  195. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/balance-pool/structs.js +0 -591
  196. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/big-vector/structs.d.ts +0 -73
  197. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/big-vector/structs.js +0 -258
  198. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/dutch/structs.d.ts +0 -876
  199. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/dutch/structs.js +0 -1745
  200. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/i64/structs.d.ts +0 -46
  201. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/i64/structs.js +0 -224
  202. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/index.d.ts +0 -3
  203. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/index.js +0 -6
  204. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/init.d.ts +0 -2
  205. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/init.js +0 -89
  206. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/linked-list/structs.d.ts +0 -155
  207. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/linked-list/structs.js +0 -444
  208. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/vault/structs.d.ts +0 -2386
  209. package/dist/src/typus-perp/_dependencies/source/0x908a10789a1a6953e0b73a997c10e3552f7ce4e2907afd00a334ed74bd973ded/vault/structs.js +0 -5024
  210. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/aggregator/structs.d.ts +0 -745
  211. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/aggregator/structs.js +0 -1239
  212. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/index.d.ts +0 -3
  213. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/index.js +0 -6
  214. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/init.d.ts +0 -2
  215. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/init.js +0 -53
  216. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/job/structs.d.ts +0 -87
  217. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/job/structs.js +0 -287
  218. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/math/structs.d.ts +0 -58
  219. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/math/structs.js +0 -240
  220. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/quote/structs.d.ts +0 -121
  221. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/quote/structs.js +0 -332
  222. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/switchboard/structs.d.ts +0 -55
  223. package/dist/src/typus-perp/_dependencies/source/0x98670585b87e06628ef2d7f7cb1e7bee8ada65b43b82997935225a7e6e21d18e/switchboard/structs.js +0 -229
  224. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/batch-price-attestation/structs.d.ts +0 -289
  225. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/batch-price-attestation/structs.js +0 -453
  226. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/contract-upgrade/structs.d.ts +0 -114
  227. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/contract-upgrade/structs.js +0 -384
  228. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/data-source/structs.d.ts +0 -71
  229. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/data-source/structs.js +0 -235
  230. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/event/structs.d.ts +0 -209
  231. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/event/structs.js +0 -383
  232. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/governance/structs.d.ts +0 -73
  233. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/governance/structs.js +0 -275
  234. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/governance-action/structs.d.ts +0 -46
  235. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/governance-action/structs.js +0 -228
  236. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/governance-instruction/structs.d.ts +0 -77
  237. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/governance-instruction/structs.js +0 -281
  238. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/hot-potato-vector/structs.d.ts +0 -51
  239. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/hot-potato-vector/structs.js +0 -276
  240. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/i64/structs.d.ts +0 -52
  241. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/i64/structs.js +0 -234
  242. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/index.d.ts +0 -3
  243. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/index.js +0 -6
  244. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/init.d.ts +0 -2
  245. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/init.js +0 -95
  246. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/migrate/structs.d.ts +0 -51
  247. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/migrate/structs.js +0 -229
  248. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price/structs.d.ts +0 -89
  249. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price/structs.js +0 -247
  250. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-feed/structs.d.ts +0 -158
  251. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-feed/structs.js +0 -242
  252. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-identifier/structs.d.ts +0 -50
  253. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-identifier/structs.js +0 -262
  254. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-info/structs.d.ts +0 -360
  255. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-info/structs.js +0 -396
  256. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-status/structs.d.ts +0 -46
  257. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/price-status/structs.js +0 -228
  258. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set/structs.d.ts +0 -120
  259. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set/structs.js +0 -431
  260. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-data-sources/structs.d.ts +0 -81
  261. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-data-sources/structs.js +0 -263
  262. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-fee-recipient/structs.d.ts +0 -46
  263. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-fee-recipient/structs.js +0 -231
  264. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-governance-data-source/structs.d.ts +0 -77
  265. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-governance-data-source/structs.js +0 -241
  266. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-stale-price-threshold/structs.d.ts +0 -46
  267. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-stale-price-threshold/structs.js +0 -228
  268. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-update-fee/structs.d.ts +0 -52
  269. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/set-update-fee/structs.js +0 -234
  270. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/setup/structs.d.ts +0 -55
  271. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/setup/structs.js +0 -229
  272. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/state/structs.d.ts +0 -282
  273. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/state/structs.js +0 -573
  274. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/version-control/structs.d.ts +0 -130
  275. package/dist/src/typus-perp/_dependencies/source/0xabf837e98c26087cba0883c0a7a28326b1fa3c5e1e2c5abdb486f9e8f594c837/version-control/structs.js +0 -524
  276. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/index.d.ts +0 -3
  277. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/index.js +0 -6
  278. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/init.d.ts +0 -2
  279. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/init.js +0 -46
  280. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/kiosk-lock-rule/structs.d.ts +0 -88
  281. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/kiosk-lock-rule/structs.js +0 -376
  282. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/royalty-rule/structs.d.ts +0 -94
  283. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/royalty-rule/structs.js +0 -382
  284. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/witness-rule/structs.d.ts +0 -46
  285. package/dist/src/typus-perp/_dependencies/source/0xbd8fc1947cf119350184107a3087e2dc27efefa0dd82e25a1f699069fe81a585/witness-rule/structs.js +0 -239
  286. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/bytes20/structs.d.ts +0 -50
  287. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/bytes20/structs.js +0 -262
  288. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/bytes32/structs.d.ts +0 -50
  289. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/bytes32/structs.js +0 -262
  290. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/consumed-vaas/structs.d.ts +0 -77
  291. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/consumed-vaas/structs.js +0 -264
  292. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/cursor/structs.d.ts +0 -51
  293. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/cursor/structs.js +0 -276
  294. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/emitter/structs.d.ts +0 -153
  295. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/emitter/structs.js +0 -531
  296. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/external-address/structs.d.ts +0 -57
  297. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/external-address/structs.js +0 -229
  298. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/fee-collector/structs.d.ts +0 -63
  299. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/fee-collector/structs.js +0 -270
  300. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/governance-message/structs.d.ts +0 -168
  301. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/governance-message/structs.js +0 -470
  302. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/guardian/structs.d.ts +0 -57
  303. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/guardian/structs.js +0 -229
  304. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/guardian-set/structs.d.ts +0 -81
  305. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/guardian-set/structs.js +0 -275
  306. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/guardian-signature/structs.d.ts +0 -85
  307. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/guardian-signature/structs.js +0 -247
  308. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/index.d.ts +0 -3
  309. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/index.js +0 -6
  310. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/init.d.ts +0 -2
  311. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/init.js +0 -100
  312. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/migrate/structs.d.ts +0 -51
  313. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/migrate/structs.js +0 -229
  314. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/package-utils/structs.d.ts +0 -194
  315. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/package-utils/structs.js +0 -680
  316. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/publish-message/structs.d.ts +0 -151
  317. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/publish-message/structs.js +0 -459
  318. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/set/structs.d.ts +0 -110
  319. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/set/structs.js +0 -422
  320. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/set-fee/structs.d.ts +0 -88
  321. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/set-fee/structs.js +0 -376
  322. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/setup/structs.d.ts +0 -55
  323. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/setup/structs.js +0 -229
  324. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/state/structs.d.ts +0 -278
  325. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/state/structs.js +0 -465
  326. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/transfer-fee/structs.d.ts +0 -94
  327. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/transfer-fee/structs.js +0 -385
  328. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/update-guardian-set/structs.d.ts +0 -159
  329. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/update-guardian-set/structs.js +0 -565
  330. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/upgrade-contract/structs.d.ts +0 -156
  331. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/upgrade-contract/structs.js +0 -532
  332. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/vaa/structs.d.ts +0 -128
  333. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/vaa/structs.js +0 -312
  334. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/version-control/structs.d.ts +0 -88
  335. package/dist/src/typus-perp/_dependencies/source/0xf47329f4344f3bf0f8e436e2f7b485466cff300f12a166563995d3888c296a94/version-control/structs.js +0 -376
  336. package/dist/src/typus-perp/_framework/init-loader.d.ts +0 -2
  337. package/dist/src/typus-perp/_framework/init-loader.js +0 -73
  338. package/dist/src/typus-perp/_framework/loader.d.ts +0 -17
  339. package/dist/src/typus-perp/_framework/loader.js +0 -108
  340. package/dist/src/typus-perp/_framework/reified.d.ts +0 -108
  341. package/dist/src/typus-perp/_framework/reified.js +0 -237
  342. package/dist/src/typus-perp/_framework/util.d.ts +0 -35
  343. package/dist/src/typus-perp/_framework/util.js +0 -396
  344. package/dist/src/typus-perp/_framework/vector.d.ts +0 -35
  345. package/dist/src/typus-perp/_framework/vector.js +0 -112
  346. package/dist/src/typus-perp/fetch.d.ts +0 -17
  347. package/dist/src/typus-perp/fetch.js +0 -410
  348. package/dist/src/typus-perp/index.d.ts +0 -5
  349. package/dist/src/typus-perp/index.js +0 -29
  350. package/dist/src/typus-perp/readVec.d.ts +0 -3
  351. package/dist/src/typus-perp/readVec.js +0 -117
  352. package/dist/src/typus-perp/typus_perp/admin/functions.d.ts +0 -50
  353. package/dist/src/typus-perp/typus_perp/admin/functions.js +0 -116
  354. package/dist/src/typus-perp/typus_perp/admin/structs.d.ts +0 -447
  355. package/dist/src/typus-perp/typus_perp/admin/structs.js +0 -908
  356. package/dist/src/typus-perp/typus_perp/index.d.ts +0 -3
  357. package/dist/src/typus-perp/typus_perp/index.js +0 -6
  358. package/dist/src/typus-perp/typus_perp/init.d.ts +0 -2
  359. package/dist/src/typus-perp/typus_perp/init.js +0 -117
  360. package/dist/src/typus-perp/typus_perp/lp-pool/functions.d.ts +0 -342
  361. package/dist/src/typus-perp/typus_perp/lp-pool/functions.js +0 -517
  362. package/dist/src/typus-perp/typus_perp/lp-pool/structs.d.ts +0 -3088
  363. package/dist/src/typus-perp/typus_perp/lp-pool/structs.js +0 -4810
  364. package/dist/src/typus-perp/typus_perp/math/functions.d.ts +0 -18
  365. package/dist/src/typus-perp/typus_perp/math/functions.js +0 -49
  366. package/dist/src/typus-perp/typus_perp/oracle/functions.d.ts +0 -13
  367. package/dist/src/typus-perp/typus_perp/oracle/functions.js +0 -25
  368. package/dist/src/typus-perp/typus_perp/oracle/structs.d.ts +0 -111
  369. package/dist/src/typus-perp/typus_perp/oracle/structs.js +0 -395
  370. package/dist/src/typus-perp/typus_perp/position/functions.d.ts +0 -343
  371. package/dist/src/typus-perp/typus_perp/position/functions.js +0 -659
  372. package/dist/src/typus-perp/typus_perp/position/structs.d.ts +0 -1174
  373. package/dist/src/typus-perp/typus_perp/position/structs.js +0 -1634
  374. package/dist/src/typus-perp/typus_perp/symbol/functions.d.ts +0 -9
  375. package/dist/src/typus-perp/typus_perp/symbol/functions.js +0 -33
  376. package/dist/src/typus-perp/typus_perp/symbol/structs.d.ts +0 -81
  377. package/dist/src/typus-perp/typus_perp/symbol/structs.js +0 -235
  378. package/dist/src/typus-perp/typus_perp/tlp/functions.d.ts +0 -19
  379. package/dist/src/typus-perp/typus_perp/tlp/functions.js +0 -41
  380. package/dist/src/typus-perp/typus_perp/tlp/structs.d.ts +0 -97
  381. package/dist/src/typus-perp/typus_perp/tlp/structs.js +0 -377
  382. package/dist/src/typus-perp/typus_perp/token-interface/functions.d.ts +0 -11
  383. package/dist/src/typus-perp/typus_perp/token-interface/functions.js +0 -20
  384. package/dist/src/typus-perp/typus_perp/trading/functions.d.ts +0 -493
  385. package/dist/src/typus-perp/typus_perp/trading/functions.js +0 -711
  386. package/dist/src/typus-perp/typus_perp/trading/structs.d.ts +0 -2993
  387. package/dist/src/typus-perp/typus_perp/trading/structs.js +0 -5012
  388. package/dist/src/typus-perp/typus_perp/treasury-caps/functions.d.ts +0 -9
  389. package/dist/src/typus-perp/typus_perp/treasury-caps/functions.js +0 -35
  390. package/dist/src/typus-perp/typus_perp/treasury-caps/structs.d.ts +0 -55
  391. package/dist/src/typus-perp/typus_perp/treasury-caps/structs.js +0 -229
  392. package/dist/src/typus-perp/typus_stake_pool/admin/functions.d.ts +0 -50
  393. package/dist/src/typus-perp/typus_stake_pool/admin/functions.js +0 -116
  394. package/dist/src/typus-perp/typus_stake_pool/admin/structs.d.ts +0 -447
  395. package/dist/src/typus-perp/typus_stake_pool/admin/structs.js +0 -908
  396. package/dist/src/typus-perp/typus_stake_pool/index.d.ts +0 -3
  397. package/dist/src/typus-perp/typus_stake_pool/index.js +0 -6
  398. package/dist/src/typus-perp/typus_stake_pool/init.d.ts +0 -2
  399. package/dist/src/typus-perp/typus_stake_pool/init.js +0 -67
  400. package/dist/src/typus-perp/typus_stake_pool/stake-pool/functions.d.ts +0 -175
  401. package/dist/src/typus-perp/typus_stake_pool/stake-pool/functions.js +0 -275
  402. package/dist/src/typus-perp/typus_stake_pool/stake-pool/structs.d.ts +0 -2179
  403. package/dist/src/typus-perp/typus_stake_pool/stake-pool/structs.js +0 -3949
  404. package/dist/src/typus-perp/user/index.d.ts +0 -3
  405. package/dist/src/typus-perp/user/index.js +0 -19
  406. package/dist/src/typus-perp/user/order.d.ts +0 -29
  407. package/dist/src/typus-perp/user/order.js +0 -206
  408. package/dist/src/typus-perp/user/orderWithBidReceipt.d.ts +0 -22
  409. package/dist/src/typus-perp/user/orderWithBidReceipt.js +0 -144
  410. package/dist/src/typus-perp/user/tlp.d.ts +0 -32
  411. package/dist/src/typus-perp/user/tlp.js +0 -267
@@ -1,1745 +0,0 @@
1
- "use strict";
2
- var __assign = (this && this.__assign) || function () {
3
- __assign = Object.assign || function(t) {
4
- for (var s, i = 1, n = arguments.length; i < n; i++) {
5
- s = arguments[i];
6
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
- t[p] = s[p];
8
- }
9
- return t;
10
- };
11
- return __assign.apply(this, arguments);
12
- };
13
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
14
- if (k2 === undefined) k2 = k;
15
- var desc = Object.getOwnPropertyDescriptor(m, k);
16
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
17
- desc = { enumerable: true, get: function() { return m[k]; } };
18
- }
19
- Object.defineProperty(o, k2, desc);
20
- }) : (function(o, m, k, k2) {
21
- if (k2 === undefined) k2 = k;
22
- o[k2] = m[k];
23
- }));
24
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
25
- Object.defineProperty(o, "default", { enumerable: true, value: v });
26
- }) : function(o, v) {
27
- o["default"] = v;
28
- });
29
- var __importStar = (this && this.__importStar) || (function () {
30
- var ownKeys = function(o) {
31
- ownKeys = Object.getOwnPropertyNames || function (o) {
32
- var ar = [];
33
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
34
- return ar;
35
- };
36
- return ownKeys(o);
37
- };
38
- return function (mod) {
39
- if (mod && mod.__esModule) return mod;
40
- var result = {};
41
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
42
- __setModuleDefault(result, mod);
43
- return result;
44
- };
45
- })();
46
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
47
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
48
- return new (P || (P = Promise))(function (resolve, reject) {
49
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
50
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
51
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
52
- step((generator = generator.apply(thisArg, _arguments || [])).next());
53
- });
54
- };
55
- var __generator = (this && this.__generator) || function (thisArg, body) {
56
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
57
- return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
58
- function verb(n) { return function (v) { return step([n, v]); }; }
59
- function step(op) {
60
- if (f) throw new TypeError("Generator is already executing.");
61
- while (g && (g = 0, op[0] && (_ = 0)), _) try {
62
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
63
- if (y = 0, t) op = [op[0] & 2, t.value];
64
- switch (op[0]) {
65
- case 0: case 1: t = op; break;
66
- case 4: _.label++; return { value: op[1], done: false };
67
- case 5: _.label++; y = op[1]; op = [0]; continue;
68
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
69
- default:
70
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
71
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
72
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
73
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
74
- if (t[2]) _.ops.pop();
75
- _.trys.pop(); continue;
76
- }
77
- op = body.call(thisArg, _);
78
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
79
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
80
- }
81
- };
82
- var __read = (this && this.__read) || function (o, n) {
83
- var m = typeof Symbol === "function" && o[Symbol.iterator];
84
- if (!m) return o;
85
- var i = m.call(o), r, ar = [], e;
86
- try {
87
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
88
- }
89
- catch (error) { e = { error: error }; }
90
- finally {
91
- try {
92
- if (r && !r.done && (m = i["return"])) m.call(i);
93
- }
94
- finally { if (e) throw e.error; }
95
- }
96
- return ar;
97
- };
98
- var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
99
- if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
100
- if (ar || !(i in from)) {
101
- if (!ar) ar = Array.prototype.slice.call(from, 0, i);
102
- ar[i] = from[i];
103
- }
104
- }
105
- return to.concat(ar || Array.prototype.slice.call(from));
106
- };
107
- Object.defineProperty(exports, "__esModule", { value: true });
108
- exports.UpdateAuctionConfig = exports.RemoveBid = exports.NewBid = exports.DUTCH = exports.Bid = exports.Auction = exports.Terminate = exports.Delivery = void 0;
109
- exports.isDelivery = isDelivery;
110
- exports.isTerminate = isTerminate;
111
- exports.isAuction = isAuction;
112
- exports.isBid = isBid;
113
- exports.isDUTCH = isDUTCH;
114
- exports.isNewBid = isNewBid;
115
- exports.isRemoveBid = isRemoveBid;
116
- exports.isUpdateAuctionConfig = isUpdateAuctionConfig;
117
- var reified = __importStar(require("../../../../_framework/reified"));
118
- var reified_1 = require("../../../../_framework/reified");
119
- var util_1 = require("../../../../_framework/util");
120
- var structs_1 = require("../../0x1/type-name/structs");
121
- var structs_2 = require("../../0x2/object/structs");
122
- var structs_3 = require("../big-vector/structs");
123
- var index_1 = require("../index");
124
- var bcs_1 = require("@mysten/sui/bcs");
125
- var utils_1 = require("@mysten/sui/utils");
126
- /* ============================== Delivery =============================== */
127
- function isDelivery(type) {
128
- type = (0, util_1.compressSuiType)(type);
129
- return type === "".concat(index_1.PKG_V1, "::dutch::Delivery");
130
- }
131
- var Delivery = /** @class */ (function () {
132
- function Delivery(typeArgs, fields) {
133
- this.__StructClass = true;
134
- this.$typeName = Delivery.$typeName;
135
- this.$isPhantom = Delivery.$isPhantom;
136
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([Delivery.$typeName], __read(typeArgs), false));
137
- this.$typeArgs = typeArgs;
138
- this.signer = fields.signer;
139
- this.index = fields.index;
140
- this.token = fields.token;
141
- this.price = fields.price;
142
- this.size = fields.size;
143
- this.bidderBidValue = fields.bidderBidValue;
144
- this.bidderFee = fields.bidderFee;
145
- this.incentiveBidValue = fields.incentiveBidValue;
146
- this.incentiveFee = fields.incentiveFee;
147
- }
148
- Delivery.reified = function () {
149
- var _this = this;
150
- return {
151
- typeName: Delivery.$typeName,
152
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([Delivery.$typeName], [], false)),
153
- typeArgs: [],
154
- isPhantom: Delivery.$isPhantom,
155
- reifiedTypeArgs: [],
156
- fromFields: function (fields) { return Delivery.fromFields(fields); },
157
- fromFieldsWithTypes: function (item) { return Delivery.fromFieldsWithTypes(item); },
158
- fromBcs: function (data) { return Delivery.fromBcs(data); },
159
- bcs: Delivery.bcs,
160
- fromJSONField: function (field) { return Delivery.fromJSONField(field); },
161
- fromJSON: function (json) { return Delivery.fromJSON(json); },
162
- fromSuiParsedData: function (content) { return Delivery.fromSuiParsedData(content); },
163
- fromSuiObjectData: function (content) { return Delivery.fromSuiObjectData(content); },
164
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
165
- return [2 /*return*/, Delivery.fetch(client, id)];
166
- }); }); },
167
- new: function (fields) {
168
- return new Delivery([], fields);
169
- },
170
- kind: "StructClassReified",
171
- };
172
- };
173
- Object.defineProperty(Delivery, "r", {
174
- get: function () {
175
- return Delivery.reified();
176
- },
177
- enumerable: false,
178
- configurable: true
179
- });
180
- Delivery.phantom = function () {
181
- return (0, reified_1.phantom)(Delivery.reified());
182
- };
183
- Object.defineProperty(Delivery, "p", {
184
- get: function () {
185
- return Delivery.phantom();
186
- },
187
- enumerable: false,
188
- configurable: true
189
- });
190
- Object.defineProperty(Delivery, "bcs", {
191
- get: function () {
192
- return bcs_1.bcs.struct("Delivery", {
193
- signer: bcs_1.bcs.bytes(32).transform({
194
- input: function (val) { return (0, utils_1.fromHEX)(val); },
195
- output: function (val) { return (0, utils_1.toHEX)(val); },
196
- }),
197
- index: bcs_1.bcs.u64(),
198
- token: structs_1.TypeName.bcs,
199
- price: bcs_1.bcs.u64(),
200
- size: bcs_1.bcs.u64(),
201
- bidder_bid_value: bcs_1.bcs.u64(),
202
- bidder_fee: bcs_1.bcs.u64(),
203
- incentive_bid_value: bcs_1.bcs.u64(),
204
- incentive_fee: bcs_1.bcs.u64(),
205
- });
206
- },
207
- enumerable: false,
208
- configurable: true
209
- });
210
- Delivery.fromFields = function (fields) {
211
- return Delivery.reified().new({
212
- signer: (0, reified_1.decodeFromFields)("address", fields.signer),
213
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
214
- token: (0, reified_1.decodeFromFields)(structs_1.TypeName.reified(), fields.token),
215
- price: (0, reified_1.decodeFromFields)("u64", fields.price),
216
- size: (0, reified_1.decodeFromFields)("u64", fields.size),
217
- bidderBidValue: (0, reified_1.decodeFromFields)("u64", fields.bidder_bid_value),
218
- bidderFee: (0, reified_1.decodeFromFields)("u64", fields.bidder_fee),
219
- incentiveBidValue: (0, reified_1.decodeFromFields)("u64", fields.incentive_bid_value),
220
- incentiveFee: (0, reified_1.decodeFromFields)("u64", fields.incentive_fee),
221
- });
222
- };
223
- Delivery.fromFieldsWithTypes = function (item) {
224
- if (!isDelivery(item.type)) {
225
- throw new Error("not a Delivery type");
226
- }
227
- return Delivery.reified().new({
228
- signer: (0, reified_1.decodeFromFieldsWithTypes)("address", item.fields.signer),
229
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
230
- token: (0, reified_1.decodeFromFieldsWithTypes)(structs_1.TypeName.reified(), item.fields.token),
231
- price: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.price),
232
- size: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size),
233
- bidderBidValue: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bidder_bid_value),
234
- bidderFee: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bidder_fee),
235
- incentiveBidValue: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_bid_value),
236
- incentiveFee: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_fee),
237
- });
238
- };
239
- Delivery.fromBcs = function (data) {
240
- return Delivery.fromFields(Delivery.bcs.parse(data));
241
- };
242
- Delivery.prototype.toJSONField = function () {
243
- return {
244
- signer: this.signer,
245
- index: this.index.toString(),
246
- token: this.token.toJSONField(),
247
- price: this.price.toString(),
248
- size: this.size.toString(),
249
- bidderBidValue: this.bidderBidValue.toString(),
250
- bidderFee: this.bidderFee.toString(),
251
- incentiveBidValue: this.incentiveBidValue.toString(),
252
- incentiveFee: this.incentiveFee.toString(),
253
- };
254
- };
255
- Delivery.prototype.toJSON = function () {
256
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
257
- };
258
- Delivery.fromJSONField = function (field) {
259
- return Delivery.reified().new({
260
- signer: (0, reified_1.decodeFromJSONField)("address", field.signer),
261
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
262
- token: (0, reified_1.decodeFromJSONField)(structs_1.TypeName.reified(), field.token),
263
- price: (0, reified_1.decodeFromJSONField)("u64", field.price),
264
- size: (0, reified_1.decodeFromJSONField)("u64", field.size),
265
- bidderBidValue: (0, reified_1.decodeFromJSONField)("u64", field.bidderBidValue),
266
- bidderFee: (0, reified_1.decodeFromJSONField)("u64", field.bidderFee),
267
- incentiveBidValue: (0, reified_1.decodeFromJSONField)("u64", field.incentiveBidValue),
268
- incentiveFee: (0, reified_1.decodeFromJSONField)("u64", field.incentiveFee),
269
- });
270
- };
271
- Delivery.fromJSON = function (json) {
272
- if (json.$typeName !== Delivery.$typeName) {
273
- throw new Error("not a WithTwoGenerics json object");
274
- }
275
- return Delivery.fromJSONField(json);
276
- };
277
- Delivery.fromSuiParsedData = function (content) {
278
- if (content.dataType !== "moveObject") {
279
- throw new Error("not an object");
280
- }
281
- if (!isDelivery(content.type)) {
282
- throw new Error("object at ".concat(content.fields.id, " is not a Delivery object"));
283
- }
284
- return Delivery.fromFieldsWithTypes(content);
285
- };
286
- Delivery.fromSuiObjectData = function (data) {
287
- if (data.bcs) {
288
- if (data.bcs.dataType !== "moveObject" || !isDelivery(data.bcs.type)) {
289
- throw new Error("object at is not a Delivery object");
290
- }
291
- return Delivery.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
292
- }
293
- if (data.content) {
294
- return Delivery.fromSuiParsedData(data.content);
295
- }
296
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
297
- };
298
- Delivery.fetch = function (client, id) {
299
- return __awaiter(this, void 0, void 0, function () {
300
- var res;
301
- var _a, _b;
302
- return __generator(this, function (_c) {
303
- switch (_c.label) {
304
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
305
- case 1:
306
- res = _c.sent();
307
- if (res.error) {
308
- throw new Error("error fetching Delivery object at id ".concat(id, ": ").concat(res.error.code));
309
- }
310
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isDelivery(res.data.bcs.type)) {
311
- throw new Error("object at id ".concat(id, " is not a Delivery object"));
312
- }
313
- return [2 /*return*/, Delivery.fromSuiObjectData(res.data)];
314
- }
315
- });
316
- });
317
- };
318
- Delivery.$typeName = "".concat(index_1.PKG_V1, "::dutch::Delivery");
319
- Delivery.$numTypeParams = 0;
320
- Delivery.$isPhantom = [];
321
- return Delivery;
322
- }());
323
- exports.Delivery = Delivery;
324
- /* ============================== Terminate =============================== */
325
- function isTerminate(type) {
326
- type = (0, util_1.compressSuiType)(type);
327
- return type === "".concat(index_1.PKG_V1, "::dutch::Terminate");
328
- }
329
- var Terminate = /** @class */ (function () {
330
- function Terminate(typeArgs, fields) {
331
- this.__StructClass = true;
332
- this.$typeName = Terminate.$typeName;
333
- this.$isPhantom = Terminate.$isPhantom;
334
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([Terminate.$typeName], __read(typeArgs), false));
335
- this.$typeArgs = typeArgs;
336
- this.signer = fields.signer;
337
- this.index = fields.index;
338
- this.token = fields.token;
339
- }
340
- Terminate.reified = function () {
341
- var _this = this;
342
- return {
343
- typeName: Terminate.$typeName,
344
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([Terminate.$typeName], [], false)),
345
- typeArgs: [],
346
- isPhantom: Terminate.$isPhantom,
347
- reifiedTypeArgs: [],
348
- fromFields: function (fields) { return Terminate.fromFields(fields); },
349
- fromFieldsWithTypes: function (item) { return Terminate.fromFieldsWithTypes(item); },
350
- fromBcs: function (data) { return Terminate.fromBcs(data); },
351
- bcs: Terminate.bcs,
352
- fromJSONField: function (field) { return Terminate.fromJSONField(field); },
353
- fromJSON: function (json) { return Terminate.fromJSON(json); },
354
- fromSuiParsedData: function (content) { return Terminate.fromSuiParsedData(content); },
355
- fromSuiObjectData: function (content) { return Terminate.fromSuiObjectData(content); },
356
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
357
- return [2 /*return*/, Terminate.fetch(client, id)];
358
- }); }); },
359
- new: function (fields) {
360
- return new Terminate([], fields);
361
- },
362
- kind: "StructClassReified",
363
- };
364
- };
365
- Object.defineProperty(Terminate, "r", {
366
- get: function () {
367
- return Terminate.reified();
368
- },
369
- enumerable: false,
370
- configurable: true
371
- });
372
- Terminate.phantom = function () {
373
- return (0, reified_1.phantom)(Terminate.reified());
374
- };
375
- Object.defineProperty(Terminate, "p", {
376
- get: function () {
377
- return Terminate.phantom();
378
- },
379
- enumerable: false,
380
- configurable: true
381
- });
382
- Object.defineProperty(Terminate, "bcs", {
383
- get: function () {
384
- return bcs_1.bcs.struct("Terminate", {
385
- signer: bcs_1.bcs.bytes(32).transform({
386
- input: function (val) { return (0, utils_1.fromHEX)(val); },
387
- output: function (val) { return (0, utils_1.toHEX)(val); },
388
- }),
389
- index: bcs_1.bcs.u64(),
390
- token: structs_1.TypeName.bcs,
391
- });
392
- },
393
- enumerable: false,
394
- configurable: true
395
- });
396
- Terminate.fromFields = function (fields) {
397
- return Terminate.reified().new({
398
- signer: (0, reified_1.decodeFromFields)("address", fields.signer),
399
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
400
- token: (0, reified_1.decodeFromFields)(structs_1.TypeName.reified(), fields.token),
401
- });
402
- };
403
- Terminate.fromFieldsWithTypes = function (item) {
404
- if (!isTerminate(item.type)) {
405
- throw new Error("not a Terminate type");
406
- }
407
- return Terminate.reified().new({
408
- signer: (0, reified_1.decodeFromFieldsWithTypes)("address", item.fields.signer),
409
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
410
- token: (0, reified_1.decodeFromFieldsWithTypes)(structs_1.TypeName.reified(), item.fields.token),
411
- });
412
- };
413
- Terminate.fromBcs = function (data) {
414
- return Terminate.fromFields(Terminate.bcs.parse(data));
415
- };
416
- Terminate.prototype.toJSONField = function () {
417
- return {
418
- signer: this.signer,
419
- index: this.index.toString(),
420
- token: this.token.toJSONField(),
421
- };
422
- };
423
- Terminate.prototype.toJSON = function () {
424
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
425
- };
426
- Terminate.fromJSONField = function (field) {
427
- return Terminate.reified().new({
428
- signer: (0, reified_1.decodeFromJSONField)("address", field.signer),
429
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
430
- token: (0, reified_1.decodeFromJSONField)(structs_1.TypeName.reified(), field.token),
431
- });
432
- };
433
- Terminate.fromJSON = function (json) {
434
- if (json.$typeName !== Terminate.$typeName) {
435
- throw new Error("not a WithTwoGenerics json object");
436
- }
437
- return Terminate.fromJSONField(json);
438
- };
439
- Terminate.fromSuiParsedData = function (content) {
440
- if (content.dataType !== "moveObject") {
441
- throw new Error("not an object");
442
- }
443
- if (!isTerminate(content.type)) {
444
- throw new Error("object at ".concat(content.fields.id, " is not a Terminate object"));
445
- }
446
- return Terminate.fromFieldsWithTypes(content);
447
- };
448
- Terminate.fromSuiObjectData = function (data) {
449
- if (data.bcs) {
450
- if (data.bcs.dataType !== "moveObject" || !isTerminate(data.bcs.type)) {
451
- throw new Error("object at is not a Terminate object");
452
- }
453
- return Terminate.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
454
- }
455
- if (data.content) {
456
- return Terminate.fromSuiParsedData(data.content);
457
- }
458
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
459
- };
460
- Terminate.fetch = function (client, id) {
461
- return __awaiter(this, void 0, void 0, function () {
462
- var res;
463
- var _a, _b;
464
- return __generator(this, function (_c) {
465
- switch (_c.label) {
466
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
467
- case 1:
468
- res = _c.sent();
469
- if (res.error) {
470
- throw new Error("error fetching Terminate object at id ".concat(id, ": ").concat(res.error.code));
471
- }
472
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isTerminate(res.data.bcs.type)) {
473
- throw new Error("object at id ".concat(id, " is not a Terminate object"));
474
- }
475
- return [2 /*return*/, Terminate.fromSuiObjectData(res.data)];
476
- }
477
- });
478
- });
479
- };
480
- Terminate.$typeName = "".concat(index_1.PKG_V1, "::dutch::Terminate");
481
- Terminate.$numTypeParams = 0;
482
- Terminate.$isPhantom = [];
483
- return Terminate;
484
- }());
485
- exports.Terminate = Terminate;
486
- /* ============================== Auction =============================== */
487
- function isAuction(type) {
488
- type = (0, util_1.compressSuiType)(type);
489
- return type === "".concat(index_1.PKG_V1, "::dutch::Auction");
490
- }
491
- var Auction = /** @class */ (function () {
492
- function Auction(typeArgs, fields) {
493
- this.__StructClass = true;
494
- this.$typeName = Auction.$typeName;
495
- this.$isPhantom = Auction.$isPhantom;
496
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([Auction.$typeName], __read(typeArgs), false));
497
- this.$typeArgs = typeArgs;
498
- this.id = fields.id;
499
- this.index = fields.index;
500
- this.token = fields.token;
501
- this.startTsMs = fields.startTsMs;
502
- this.endTsMs = fields.endTsMs;
503
- this.size = fields.size;
504
- this.decaySpeed = fields.decaySpeed;
505
- this.initialPrice = fields.initialPrice;
506
- this.finalPrice = fields.finalPrice;
507
- this.feeBp = fields.feeBp;
508
- this.incentiveBp = fields.incentiveBp;
509
- this.tokenDecimal = fields.tokenDecimal;
510
- this.sizeDecimal = fields.sizeDecimal;
511
- this.totalBidSize = fields.totalBidSize;
512
- this.ableToRemoveBid = fields.ableToRemoveBid;
513
- this.bids = fields.bids;
514
- this.bidIndex = fields.bidIndex;
515
- }
516
- Auction.reified = function () {
517
- var _this = this;
518
- return {
519
- typeName: Auction.$typeName,
520
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([Auction.$typeName], [], false)),
521
- typeArgs: [],
522
- isPhantom: Auction.$isPhantom,
523
- reifiedTypeArgs: [],
524
- fromFields: function (fields) { return Auction.fromFields(fields); },
525
- fromFieldsWithTypes: function (item) { return Auction.fromFieldsWithTypes(item); },
526
- fromBcs: function (data) { return Auction.fromBcs(data); },
527
- bcs: Auction.bcs,
528
- fromJSONField: function (field) { return Auction.fromJSONField(field); },
529
- fromJSON: function (json) { return Auction.fromJSON(json); },
530
- fromSuiParsedData: function (content) { return Auction.fromSuiParsedData(content); },
531
- fromSuiObjectData: function (content) { return Auction.fromSuiObjectData(content); },
532
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
533
- return [2 /*return*/, Auction.fetch(client, id)];
534
- }); }); },
535
- new: function (fields) {
536
- return new Auction([], fields);
537
- },
538
- kind: "StructClassReified",
539
- };
540
- };
541
- Object.defineProperty(Auction, "r", {
542
- get: function () {
543
- return Auction.reified();
544
- },
545
- enumerable: false,
546
- configurable: true
547
- });
548
- Auction.phantom = function () {
549
- return (0, reified_1.phantom)(Auction.reified());
550
- };
551
- Object.defineProperty(Auction, "p", {
552
- get: function () {
553
- return Auction.phantom();
554
- },
555
- enumerable: false,
556
- configurable: true
557
- });
558
- Object.defineProperty(Auction, "bcs", {
559
- get: function () {
560
- return bcs_1.bcs.struct("Auction", {
561
- id: structs_2.UID.bcs,
562
- index: bcs_1.bcs.u64(),
563
- token: structs_1.TypeName.bcs,
564
- start_ts_ms: bcs_1.bcs.u64(),
565
- end_ts_ms: bcs_1.bcs.u64(),
566
- size: bcs_1.bcs.u64(),
567
- decay_speed: bcs_1.bcs.u64(),
568
- initial_price: bcs_1.bcs.u64(),
569
- final_price: bcs_1.bcs.u64(),
570
- fee_bp: bcs_1.bcs.u64(),
571
- incentive_bp: bcs_1.bcs.u64(),
572
- token_decimal: bcs_1.bcs.u64(),
573
- size_decimal: bcs_1.bcs.u64(),
574
- total_bid_size: bcs_1.bcs.u64(),
575
- able_to_remove_bid: bcs_1.bcs.bool(),
576
- bids: structs_3.BigVector.bcs,
577
- bid_index: bcs_1.bcs.u64(),
578
- });
579
- },
580
- enumerable: false,
581
- configurable: true
582
- });
583
- Auction.fromFields = function (fields) {
584
- return Auction.reified().new({
585
- id: (0, reified_1.decodeFromFields)(structs_2.UID.reified(), fields.id),
586
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
587
- token: (0, reified_1.decodeFromFields)(structs_1.TypeName.reified(), fields.token),
588
- startTsMs: (0, reified_1.decodeFromFields)("u64", fields.start_ts_ms),
589
- endTsMs: (0, reified_1.decodeFromFields)("u64", fields.end_ts_ms),
590
- size: (0, reified_1.decodeFromFields)("u64", fields.size),
591
- decaySpeed: (0, reified_1.decodeFromFields)("u64", fields.decay_speed),
592
- initialPrice: (0, reified_1.decodeFromFields)("u64", fields.initial_price),
593
- finalPrice: (0, reified_1.decodeFromFields)("u64", fields.final_price),
594
- feeBp: (0, reified_1.decodeFromFields)("u64", fields.fee_bp),
595
- incentiveBp: (0, reified_1.decodeFromFields)("u64", fields.incentive_bp),
596
- tokenDecimal: (0, reified_1.decodeFromFields)("u64", fields.token_decimal),
597
- sizeDecimal: (0, reified_1.decodeFromFields)("u64", fields.size_decimal),
598
- totalBidSize: (0, reified_1.decodeFromFields)("u64", fields.total_bid_size),
599
- ableToRemoveBid: (0, reified_1.decodeFromFields)("bool", fields.able_to_remove_bid),
600
- bids: (0, reified_1.decodeFromFields)(structs_3.BigVector.reified(reified.phantom(Bid.reified())), fields.bids),
601
- bidIndex: (0, reified_1.decodeFromFields)("u64", fields.bid_index),
602
- });
603
- };
604
- Auction.fromFieldsWithTypes = function (item) {
605
- if (!isAuction(item.type)) {
606
- throw new Error("not a Auction type");
607
- }
608
- return Auction.reified().new({
609
- id: (0, reified_1.decodeFromFieldsWithTypes)(structs_2.UID.reified(), item.fields.id),
610
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
611
- token: (0, reified_1.decodeFromFieldsWithTypes)(structs_1.TypeName.reified(), item.fields.token),
612
- startTsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.start_ts_ms),
613
- endTsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.end_ts_ms),
614
- size: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size),
615
- decaySpeed: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.decay_speed),
616
- initialPrice: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.initial_price),
617
- finalPrice: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.final_price),
618
- feeBp: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.fee_bp),
619
- incentiveBp: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_bp),
620
- tokenDecimal: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.token_decimal),
621
- sizeDecimal: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size_decimal),
622
- totalBidSize: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.total_bid_size),
623
- ableToRemoveBid: (0, reified_1.decodeFromFieldsWithTypes)("bool", item.fields.able_to_remove_bid),
624
- bids: (0, reified_1.decodeFromFieldsWithTypes)(structs_3.BigVector.reified(reified.phantom(Bid.reified())), item.fields.bids),
625
- bidIndex: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bid_index),
626
- });
627
- };
628
- Auction.fromBcs = function (data) {
629
- return Auction.fromFields(Auction.bcs.parse(data));
630
- };
631
- Auction.prototype.toJSONField = function () {
632
- return {
633
- id: this.id,
634
- index: this.index.toString(),
635
- token: this.token.toJSONField(),
636
- startTsMs: this.startTsMs.toString(),
637
- endTsMs: this.endTsMs.toString(),
638
- size: this.size.toString(),
639
- decaySpeed: this.decaySpeed.toString(),
640
- initialPrice: this.initialPrice.toString(),
641
- finalPrice: this.finalPrice.toString(),
642
- feeBp: this.feeBp.toString(),
643
- incentiveBp: this.incentiveBp.toString(),
644
- tokenDecimal: this.tokenDecimal.toString(),
645
- sizeDecimal: this.sizeDecimal.toString(),
646
- totalBidSize: this.totalBidSize.toString(),
647
- ableToRemoveBid: this.ableToRemoveBid,
648
- bids: this.bids.toJSONField(),
649
- bidIndex: this.bidIndex.toString(),
650
- };
651
- };
652
- Auction.prototype.toJSON = function () {
653
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
654
- };
655
- Auction.fromJSONField = function (field) {
656
- return Auction.reified().new({
657
- id: (0, reified_1.decodeFromJSONField)(structs_2.UID.reified(), field.id),
658
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
659
- token: (0, reified_1.decodeFromJSONField)(structs_1.TypeName.reified(), field.token),
660
- startTsMs: (0, reified_1.decodeFromJSONField)("u64", field.startTsMs),
661
- endTsMs: (0, reified_1.decodeFromJSONField)("u64", field.endTsMs),
662
- size: (0, reified_1.decodeFromJSONField)("u64", field.size),
663
- decaySpeed: (0, reified_1.decodeFromJSONField)("u64", field.decaySpeed),
664
- initialPrice: (0, reified_1.decodeFromJSONField)("u64", field.initialPrice),
665
- finalPrice: (0, reified_1.decodeFromJSONField)("u64", field.finalPrice),
666
- feeBp: (0, reified_1.decodeFromJSONField)("u64", field.feeBp),
667
- incentiveBp: (0, reified_1.decodeFromJSONField)("u64", field.incentiveBp),
668
- tokenDecimal: (0, reified_1.decodeFromJSONField)("u64", field.tokenDecimal),
669
- sizeDecimal: (0, reified_1.decodeFromJSONField)("u64", field.sizeDecimal),
670
- totalBidSize: (0, reified_1.decodeFromJSONField)("u64", field.totalBidSize),
671
- ableToRemoveBid: (0, reified_1.decodeFromJSONField)("bool", field.ableToRemoveBid),
672
- bids: (0, reified_1.decodeFromJSONField)(structs_3.BigVector.reified(reified.phantom(Bid.reified())), field.bids),
673
- bidIndex: (0, reified_1.decodeFromJSONField)("u64", field.bidIndex),
674
- });
675
- };
676
- Auction.fromJSON = function (json) {
677
- if (json.$typeName !== Auction.$typeName) {
678
- throw new Error("not a WithTwoGenerics json object");
679
- }
680
- return Auction.fromJSONField(json);
681
- };
682
- Auction.fromSuiParsedData = function (content) {
683
- if (content.dataType !== "moveObject") {
684
- throw new Error("not an object");
685
- }
686
- if (!isAuction(content.type)) {
687
- throw new Error("object at ".concat(content.fields.id, " is not a Auction object"));
688
- }
689
- return Auction.fromFieldsWithTypes(content);
690
- };
691
- Auction.fromSuiObjectData = function (data) {
692
- if (data.bcs) {
693
- if (data.bcs.dataType !== "moveObject" || !isAuction(data.bcs.type)) {
694
- throw new Error("object at is not a Auction object");
695
- }
696
- return Auction.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
697
- }
698
- if (data.content) {
699
- return Auction.fromSuiParsedData(data.content);
700
- }
701
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
702
- };
703
- Auction.fetch = function (client, id) {
704
- return __awaiter(this, void 0, void 0, function () {
705
- var res;
706
- var _a, _b;
707
- return __generator(this, function (_c) {
708
- switch (_c.label) {
709
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
710
- case 1:
711
- res = _c.sent();
712
- if (res.error) {
713
- throw new Error("error fetching Auction object at id ".concat(id, ": ").concat(res.error.code));
714
- }
715
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isAuction(res.data.bcs.type)) {
716
- throw new Error("object at id ".concat(id, " is not a Auction object"));
717
- }
718
- return [2 /*return*/, Auction.fromSuiObjectData(res.data)];
719
- }
720
- });
721
- });
722
- };
723
- Auction.$typeName = "".concat(index_1.PKG_V1, "::dutch::Auction");
724
- Auction.$numTypeParams = 0;
725
- Auction.$isPhantom = [];
726
- return Auction;
727
- }());
728
- exports.Auction = Auction;
729
- /* ============================== Bid =============================== */
730
- function isBid(type) {
731
- type = (0, util_1.compressSuiType)(type);
732
- return type === "".concat(index_1.PKG_V1, "::dutch::Bid");
733
- }
734
- var Bid = /** @class */ (function () {
735
- function Bid(typeArgs, fields) {
736
- this.__StructClass = true;
737
- this.$typeName = Bid.$typeName;
738
- this.$isPhantom = Bid.$isPhantom;
739
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([Bid.$typeName], __read(typeArgs), false));
740
- this.$typeArgs = typeArgs;
741
- this.index = fields.index;
742
- this.bidder = fields.bidder;
743
- this.price = fields.price;
744
- this.size = fields.size;
745
- this.bidderBalance = fields.bidderBalance;
746
- this.incentiveBalance = fields.incentiveBalance;
747
- this.feeDiscount = fields.feeDiscount;
748
- this.tsMs = fields.tsMs;
749
- }
750
- Bid.reified = function () {
751
- var _this = this;
752
- return {
753
- typeName: Bid.$typeName,
754
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([Bid.$typeName], [], false)),
755
- typeArgs: [],
756
- isPhantom: Bid.$isPhantom,
757
- reifiedTypeArgs: [],
758
- fromFields: function (fields) { return Bid.fromFields(fields); },
759
- fromFieldsWithTypes: function (item) { return Bid.fromFieldsWithTypes(item); },
760
- fromBcs: function (data) { return Bid.fromBcs(data); },
761
- bcs: Bid.bcs,
762
- fromJSONField: function (field) { return Bid.fromJSONField(field); },
763
- fromJSON: function (json) { return Bid.fromJSON(json); },
764
- fromSuiParsedData: function (content) { return Bid.fromSuiParsedData(content); },
765
- fromSuiObjectData: function (content) { return Bid.fromSuiObjectData(content); },
766
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
767
- return [2 /*return*/, Bid.fetch(client, id)];
768
- }); }); },
769
- new: function (fields) {
770
- return new Bid([], fields);
771
- },
772
- kind: "StructClassReified",
773
- };
774
- };
775
- Object.defineProperty(Bid, "r", {
776
- get: function () {
777
- return Bid.reified();
778
- },
779
- enumerable: false,
780
- configurable: true
781
- });
782
- Bid.phantom = function () {
783
- return (0, reified_1.phantom)(Bid.reified());
784
- };
785
- Object.defineProperty(Bid, "p", {
786
- get: function () {
787
- return Bid.phantom();
788
- },
789
- enumerable: false,
790
- configurable: true
791
- });
792
- Object.defineProperty(Bid, "bcs", {
793
- get: function () {
794
- return bcs_1.bcs.struct("Bid", {
795
- index: bcs_1.bcs.u64(),
796
- bidder: bcs_1.bcs.bytes(32).transform({
797
- input: function (val) { return (0, utils_1.fromHEX)(val); },
798
- output: function (val) { return (0, utils_1.toHEX)(val); },
799
- }),
800
- price: bcs_1.bcs.u64(),
801
- size: bcs_1.bcs.u64(),
802
- bidder_balance: bcs_1.bcs.u64(),
803
- incentive_balance: bcs_1.bcs.u64(),
804
- fee_discount: bcs_1.bcs.u64(),
805
- ts_ms: bcs_1.bcs.u64(),
806
- });
807
- },
808
- enumerable: false,
809
- configurable: true
810
- });
811
- Bid.fromFields = function (fields) {
812
- return Bid.reified().new({
813
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
814
- bidder: (0, reified_1.decodeFromFields)("address", fields.bidder),
815
- price: (0, reified_1.decodeFromFields)("u64", fields.price),
816
- size: (0, reified_1.decodeFromFields)("u64", fields.size),
817
- bidderBalance: (0, reified_1.decodeFromFields)("u64", fields.bidder_balance),
818
- incentiveBalance: (0, reified_1.decodeFromFields)("u64", fields.incentive_balance),
819
- feeDiscount: (0, reified_1.decodeFromFields)("u64", fields.fee_discount),
820
- tsMs: (0, reified_1.decodeFromFields)("u64", fields.ts_ms),
821
- });
822
- };
823
- Bid.fromFieldsWithTypes = function (item) {
824
- if (!isBid(item.type)) {
825
- throw new Error("not a Bid type");
826
- }
827
- return Bid.reified().new({
828
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
829
- bidder: (0, reified_1.decodeFromFieldsWithTypes)("address", item.fields.bidder),
830
- price: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.price),
831
- size: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size),
832
- bidderBalance: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bidder_balance),
833
- incentiveBalance: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_balance),
834
- feeDiscount: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.fee_discount),
835
- tsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.ts_ms),
836
- });
837
- };
838
- Bid.fromBcs = function (data) {
839
- return Bid.fromFields(Bid.bcs.parse(data));
840
- };
841
- Bid.prototype.toJSONField = function () {
842
- return {
843
- index: this.index.toString(),
844
- bidder: this.bidder,
845
- price: this.price.toString(),
846
- size: this.size.toString(),
847
- bidderBalance: this.bidderBalance.toString(),
848
- incentiveBalance: this.incentiveBalance.toString(),
849
- feeDiscount: this.feeDiscount.toString(),
850
- tsMs: this.tsMs.toString(),
851
- };
852
- };
853
- Bid.prototype.toJSON = function () {
854
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
855
- };
856
- Bid.fromJSONField = function (field) {
857
- return Bid.reified().new({
858
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
859
- bidder: (0, reified_1.decodeFromJSONField)("address", field.bidder),
860
- price: (0, reified_1.decodeFromJSONField)("u64", field.price),
861
- size: (0, reified_1.decodeFromJSONField)("u64", field.size),
862
- bidderBalance: (0, reified_1.decodeFromJSONField)("u64", field.bidderBalance),
863
- incentiveBalance: (0, reified_1.decodeFromJSONField)("u64", field.incentiveBalance),
864
- feeDiscount: (0, reified_1.decodeFromJSONField)("u64", field.feeDiscount),
865
- tsMs: (0, reified_1.decodeFromJSONField)("u64", field.tsMs),
866
- });
867
- };
868
- Bid.fromJSON = function (json) {
869
- if (json.$typeName !== Bid.$typeName) {
870
- throw new Error("not a WithTwoGenerics json object");
871
- }
872
- return Bid.fromJSONField(json);
873
- };
874
- Bid.fromSuiParsedData = function (content) {
875
- if (content.dataType !== "moveObject") {
876
- throw new Error("not an object");
877
- }
878
- if (!isBid(content.type)) {
879
- throw new Error("object at ".concat(content.fields.id, " is not a Bid object"));
880
- }
881
- return Bid.fromFieldsWithTypes(content);
882
- };
883
- Bid.fromSuiObjectData = function (data) {
884
- if (data.bcs) {
885
- if (data.bcs.dataType !== "moveObject" || !isBid(data.bcs.type)) {
886
- throw new Error("object at is not a Bid object");
887
- }
888
- return Bid.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
889
- }
890
- if (data.content) {
891
- return Bid.fromSuiParsedData(data.content);
892
- }
893
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
894
- };
895
- Bid.fetch = function (client, id) {
896
- return __awaiter(this, void 0, void 0, function () {
897
- var res;
898
- var _a, _b;
899
- return __generator(this, function (_c) {
900
- switch (_c.label) {
901
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
902
- case 1:
903
- res = _c.sent();
904
- if (res.error) {
905
- throw new Error("error fetching Bid object at id ".concat(id, ": ").concat(res.error.code));
906
- }
907
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isBid(res.data.bcs.type)) {
908
- throw new Error("object at id ".concat(id, " is not a Bid object"));
909
- }
910
- return [2 /*return*/, Bid.fromSuiObjectData(res.data)];
911
- }
912
- });
913
- });
914
- };
915
- Bid.$typeName = "".concat(index_1.PKG_V1, "::dutch::Bid");
916
- Bid.$numTypeParams = 0;
917
- Bid.$isPhantom = [];
918
- return Bid;
919
- }());
920
- exports.Bid = Bid;
921
- /* ============================== DUTCH =============================== */
922
- function isDUTCH(type) {
923
- type = (0, util_1.compressSuiType)(type);
924
- return type === "".concat(index_1.PKG_V1, "::dutch::DUTCH");
925
- }
926
- var DUTCH = /** @class */ (function () {
927
- function DUTCH(typeArgs, fields) {
928
- this.__StructClass = true;
929
- this.$typeName = DUTCH.$typeName;
930
- this.$isPhantom = DUTCH.$isPhantom;
931
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([DUTCH.$typeName], __read(typeArgs), false));
932
- this.$typeArgs = typeArgs;
933
- this.dummyField = fields.dummyField;
934
- }
935
- DUTCH.reified = function () {
936
- var _this = this;
937
- return {
938
- typeName: DUTCH.$typeName,
939
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([DUTCH.$typeName], [], false)),
940
- typeArgs: [],
941
- isPhantom: DUTCH.$isPhantom,
942
- reifiedTypeArgs: [],
943
- fromFields: function (fields) { return DUTCH.fromFields(fields); },
944
- fromFieldsWithTypes: function (item) { return DUTCH.fromFieldsWithTypes(item); },
945
- fromBcs: function (data) { return DUTCH.fromBcs(data); },
946
- bcs: DUTCH.bcs,
947
- fromJSONField: function (field) { return DUTCH.fromJSONField(field); },
948
- fromJSON: function (json) { return DUTCH.fromJSON(json); },
949
- fromSuiParsedData: function (content) { return DUTCH.fromSuiParsedData(content); },
950
- fromSuiObjectData: function (content) { return DUTCH.fromSuiObjectData(content); },
951
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
952
- return [2 /*return*/, DUTCH.fetch(client, id)];
953
- }); }); },
954
- new: function (fields) {
955
- return new DUTCH([], fields);
956
- },
957
- kind: "StructClassReified",
958
- };
959
- };
960
- Object.defineProperty(DUTCH, "r", {
961
- get: function () {
962
- return DUTCH.reified();
963
- },
964
- enumerable: false,
965
- configurable: true
966
- });
967
- DUTCH.phantom = function () {
968
- return (0, reified_1.phantom)(DUTCH.reified());
969
- };
970
- Object.defineProperty(DUTCH, "p", {
971
- get: function () {
972
- return DUTCH.phantom();
973
- },
974
- enumerable: false,
975
- configurable: true
976
- });
977
- Object.defineProperty(DUTCH, "bcs", {
978
- get: function () {
979
- return bcs_1.bcs.struct("DUTCH", {
980
- dummy_field: bcs_1.bcs.bool(),
981
- });
982
- },
983
- enumerable: false,
984
- configurable: true
985
- });
986
- DUTCH.fromFields = function (fields) {
987
- return DUTCH.reified().new({
988
- dummyField: (0, reified_1.decodeFromFields)("bool", fields.dummy_field),
989
- });
990
- };
991
- DUTCH.fromFieldsWithTypes = function (item) {
992
- if (!isDUTCH(item.type)) {
993
- throw new Error("not a DUTCH type");
994
- }
995
- return DUTCH.reified().new({
996
- dummyField: (0, reified_1.decodeFromFieldsWithTypes)("bool", item.fields.dummy_field),
997
- });
998
- };
999
- DUTCH.fromBcs = function (data) {
1000
- return DUTCH.fromFields(DUTCH.bcs.parse(data));
1001
- };
1002
- DUTCH.prototype.toJSONField = function () {
1003
- return {
1004
- dummyField: this.dummyField,
1005
- };
1006
- };
1007
- DUTCH.prototype.toJSON = function () {
1008
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
1009
- };
1010
- DUTCH.fromJSONField = function (field) {
1011
- return DUTCH.reified().new({
1012
- dummyField: (0, reified_1.decodeFromJSONField)("bool", field.dummyField),
1013
- });
1014
- };
1015
- DUTCH.fromJSON = function (json) {
1016
- if (json.$typeName !== DUTCH.$typeName) {
1017
- throw new Error("not a WithTwoGenerics json object");
1018
- }
1019
- return DUTCH.fromJSONField(json);
1020
- };
1021
- DUTCH.fromSuiParsedData = function (content) {
1022
- if (content.dataType !== "moveObject") {
1023
- throw new Error("not an object");
1024
- }
1025
- if (!isDUTCH(content.type)) {
1026
- throw new Error("object at ".concat(content.fields.id, " is not a DUTCH object"));
1027
- }
1028
- return DUTCH.fromFieldsWithTypes(content);
1029
- };
1030
- DUTCH.fromSuiObjectData = function (data) {
1031
- if (data.bcs) {
1032
- if (data.bcs.dataType !== "moveObject" || !isDUTCH(data.bcs.type)) {
1033
- throw new Error("object at is not a DUTCH object");
1034
- }
1035
- return DUTCH.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
1036
- }
1037
- if (data.content) {
1038
- return DUTCH.fromSuiParsedData(data.content);
1039
- }
1040
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
1041
- };
1042
- DUTCH.fetch = function (client, id) {
1043
- return __awaiter(this, void 0, void 0, function () {
1044
- var res;
1045
- var _a, _b;
1046
- return __generator(this, function (_c) {
1047
- switch (_c.label) {
1048
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
1049
- case 1:
1050
- res = _c.sent();
1051
- if (res.error) {
1052
- throw new Error("error fetching DUTCH object at id ".concat(id, ": ").concat(res.error.code));
1053
- }
1054
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isDUTCH(res.data.bcs.type)) {
1055
- throw new Error("object at id ".concat(id, " is not a DUTCH object"));
1056
- }
1057
- return [2 /*return*/, DUTCH.fromSuiObjectData(res.data)];
1058
- }
1059
- });
1060
- });
1061
- };
1062
- DUTCH.$typeName = "".concat(index_1.PKG_V1, "::dutch::DUTCH");
1063
- DUTCH.$numTypeParams = 0;
1064
- DUTCH.$isPhantom = [];
1065
- return DUTCH;
1066
- }());
1067
- exports.DUTCH = DUTCH;
1068
- /* ============================== NewBid =============================== */
1069
- function isNewBid(type) {
1070
- type = (0, util_1.compressSuiType)(type);
1071
- return type === "".concat(index_1.PKG_V1, "::dutch::NewBid");
1072
- }
1073
- var NewBid = /** @class */ (function () {
1074
- function NewBid(typeArgs, fields) {
1075
- this.__StructClass = true;
1076
- this.$typeName = NewBid.$typeName;
1077
- this.$isPhantom = NewBid.$isPhantom;
1078
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([NewBid.$typeName], __read(typeArgs), false));
1079
- this.$typeArgs = typeArgs;
1080
- this.signer = fields.signer;
1081
- this.index = fields.index;
1082
- this.token = fields.token;
1083
- this.bidIndex = fields.bidIndex;
1084
- this.price = fields.price;
1085
- this.size = fields.size;
1086
- this.bidderBalance = fields.bidderBalance;
1087
- this.incentiveBalance = fields.incentiveBalance;
1088
- this.tsMs = fields.tsMs;
1089
- }
1090
- NewBid.reified = function () {
1091
- var _this = this;
1092
- return {
1093
- typeName: NewBid.$typeName,
1094
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([NewBid.$typeName], [], false)),
1095
- typeArgs: [],
1096
- isPhantom: NewBid.$isPhantom,
1097
- reifiedTypeArgs: [],
1098
- fromFields: function (fields) { return NewBid.fromFields(fields); },
1099
- fromFieldsWithTypes: function (item) { return NewBid.fromFieldsWithTypes(item); },
1100
- fromBcs: function (data) { return NewBid.fromBcs(data); },
1101
- bcs: NewBid.bcs,
1102
- fromJSONField: function (field) { return NewBid.fromJSONField(field); },
1103
- fromJSON: function (json) { return NewBid.fromJSON(json); },
1104
- fromSuiParsedData: function (content) { return NewBid.fromSuiParsedData(content); },
1105
- fromSuiObjectData: function (content) { return NewBid.fromSuiObjectData(content); },
1106
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
1107
- return [2 /*return*/, NewBid.fetch(client, id)];
1108
- }); }); },
1109
- new: function (fields) {
1110
- return new NewBid([], fields);
1111
- },
1112
- kind: "StructClassReified",
1113
- };
1114
- };
1115
- Object.defineProperty(NewBid, "r", {
1116
- get: function () {
1117
- return NewBid.reified();
1118
- },
1119
- enumerable: false,
1120
- configurable: true
1121
- });
1122
- NewBid.phantom = function () {
1123
- return (0, reified_1.phantom)(NewBid.reified());
1124
- };
1125
- Object.defineProperty(NewBid, "p", {
1126
- get: function () {
1127
- return NewBid.phantom();
1128
- },
1129
- enumerable: false,
1130
- configurable: true
1131
- });
1132
- Object.defineProperty(NewBid, "bcs", {
1133
- get: function () {
1134
- return bcs_1.bcs.struct("NewBid", {
1135
- signer: bcs_1.bcs.bytes(32).transform({
1136
- input: function (val) { return (0, utils_1.fromHEX)(val); },
1137
- output: function (val) { return (0, utils_1.toHEX)(val); },
1138
- }),
1139
- index: bcs_1.bcs.u64(),
1140
- token: structs_1.TypeName.bcs,
1141
- bid_index: bcs_1.bcs.u64(),
1142
- price: bcs_1.bcs.u64(),
1143
- size: bcs_1.bcs.u64(),
1144
- bidder_balance: bcs_1.bcs.u64(),
1145
- incentive_balance: bcs_1.bcs.u64(),
1146
- ts_ms: bcs_1.bcs.u64(),
1147
- });
1148
- },
1149
- enumerable: false,
1150
- configurable: true
1151
- });
1152
- NewBid.fromFields = function (fields) {
1153
- return NewBid.reified().new({
1154
- signer: (0, reified_1.decodeFromFields)("address", fields.signer),
1155
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
1156
- token: (0, reified_1.decodeFromFields)(structs_1.TypeName.reified(), fields.token),
1157
- bidIndex: (0, reified_1.decodeFromFields)("u64", fields.bid_index),
1158
- price: (0, reified_1.decodeFromFields)("u64", fields.price),
1159
- size: (0, reified_1.decodeFromFields)("u64", fields.size),
1160
- bidderBalance: (0, reified_1.decodeFromFields)("u64", fields.bidder_balance),
1161
- incentiveBalance: (0, reified_1.decodeFromFields)("u64", fields.incentive_balance),
1162
- tsMs: (0, reified_1.decodeFromFields)("u64", fields.ts_ms),
1163
- });
1164
- };
1165
- NewBid.fromFieldsWithTypes = function (item) {
1166
- if (!isNewBid(item.type)) {
1167
- throw new Error("not a NewBid type");
1168
- }
1169
- return NewBid.reified().new({
1170
- signer: (0, reified_1.decodeFromFieldsWithTypes)("address", item.fields.signer),
1171
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
1172
- token: (0, reified_1.decodeFromFieldsWithTypes)(structs_1.TypeName.reified(), item.fields.token),
1173
- bidIndex: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bid_index),
1174
- price: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.price),
1175
- size: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size),
1176
- bidderBalance: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bidder_balance),
1177
- incentiveBalance: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_balance),
1178
- tsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.ts_ms),
1179
- });
1180
- };
1181
- NewBid.fromBcs = function (data) {
1182
- return NewBid.fromFields(NewBid.bcs.parse(data));
1183
- };
1184
- NewBid.prototype.toJSONField = function () {
1185
- return {
1186
- signer: this.signer,
1187
- index: this.index.toString(),
1188
- token: this.token.toJSONField(),
1189
- bidIndex: this.bidIndex.toString(),
1190
- price: this.price.toString(),
1191
- size: this.size.toString(),
1192
- bidderBalance: this.bidderBalance.toString(),
1193
- incentiveBalance: this.incentiveBalance.toString(),
1194
- tsMs: this.tsMs.toString(),
1195
- };
1196
- };
1197
- NewBid.prototype.toJSON = function () {
1198
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
1199
- };
1200
- NewBid.fromJSONField = function (field) {
1201
- return NewBid.reified().new({
1202
- signer: (0, reified_1.decodeFromJSONField)("address", field.signer),
1203
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
1204
- token: (0, reified_1.decodeFromJSONField)(structs_1.TypeName.reified(), field.token),
1205
- bidIndex: (0, reified_1.decodeFromJSONField)("u64", field.bidIndex),
1206
- price: (0, reified_1.decodeFromJSONField)("u64", field.price),
1207
- size: (0, reified_1.decodeFromJSONField)("u64", field.size),
1208
- bidderBalance: (0, reified_1.decodeFromJSONField)("u64", field.bidderBalance),
1209
- incentiveBalance: (0, reified_1.decodeFromJSONField)("u64", field.incentiveBalance),
1210
- tsMs: (0, reified_1.decodeFromJSONField)("u64", field.tsMs),
1211
- });
1212
- };
1213
- NewBid.fromJSON = function (json) {
1214
- if (json.$typeName !== NewBid.$typeName) {
1215
- throw new Error("not a WithTwoGenerics json object");
1216
- }
1217
- return NewBid.fromJSONField(json);
1218
- };
1219
- NewBid.fromSuiParsedData = function (content) {
1220
- if (content.dataType !== "moveObject") {
1221
- throw new Error("not an object");
1222
- }
1223
- if (!isNewBid(content.type)) {
1224
- throw new Error("object at ".concat(content.fields.id, " is not a NewBid object"));
1225
- }
1226
- return NewBid.fromFieldsWithTypes(content);
1227
- };
1228
- NewBid.fromSuiObjectData = function (data) {
1229
- if (data.bcs) {
1230
- if (data.bcs.dataType !== "moveObject" || !isNewBid(data.bcs.type)) {
1231
- throw new Error("object at is not a NewBid object");
1232
- }
1233
- return NewBid.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
1234
- }
1235
- if (data.content) {
1236
- return NewBid.fromSuiParsedData(data.content);
1237
- }
1238
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
1239
- };
1240
- NewBid.fetch = function (client, id) {
1241
- return __awaiter(this, void 0, void 0, function () {
1242
- var res;
1243
- var _a, _b;
1244
- return __generator(this, function (_c) {
1245
- switch (_c.label) {
1246
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
1247
- case 1:
1248
- res = _c.sent();
1249
- if (res.error) {
1250
- throw new Error("error fetching NewBid object at id ".concat(id, ": ").concat(res.error.code));
1251
- }
1252
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isNewBid(res.data.bcs.type)) {
1253
- throw new Error("object at id ".concat(id, " is not a NewBid object"));
1254
- }
1255
- return [2 /*return*/, NewBid.fromSuiObjectData(res.data)];
1256
- }
1257
- });
1258
- });
1259
- };
1260
- NewBid.$typeName = "".concat(index_1.PKG_V1, "::dutch::NewBid");
1261
- NewBid.$numTypeParams = 0;
1262
- NewBid.$isPhantom = [];
1263
- return NewBid;
1264
- }());
1265
- exports.NewBid = NewBid;
1266
- /* ============================== RemoveBid =============================== */
1267
- function isRemoveBid(type) {
1268
- type = (0, util_1.compressSuiType)(type);
1269
- return type === "".concat(index_1.PKG_V1, "::dutch::RemoveBid");
1270
- }
1271
- var RemoveBid = /** @class */ (function () {
1272
- function RemoveBid(typeArgs, fields) {
1273
- this.__StructClass = true;
1274
- this.$typeName = RemoveBid.$typeName;
1275
- this.$isPhantom = RemoveBid.$isPhantom;
1276
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([RemoveBid.$typeName], __read(typeArgs), false));
1277
- this.$typeArgs = typeArgs;
1278
- this.signer = fields.signer;
1279
- this.index = fields.index;
1280
- this.token = fields.token;
1281
- this.bidIndex = fields.bidIndex;
1282
- this.price = fields.price;
1283
- this.size = fields.size;
1284
- this.bidderBalance = fields.bidderBalance;
1285
- this.incentiveBalance = fields.incentiveBalance;
1286
- this.feeDiscount = fields.feeDiscount;
1287
- this.tsMs = fields.tsMs;
1288
- }
1289
- RemoveBid.reified = function () {
1290
- var _this = this;
1291
- return {
1292
- typeName: RemoveBid.$typeName,
1293
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([RemoveBid.$typeName], [], false)),
1294
- typeArgs: [],
1295
- isPhantom: RemoveBid.$isPhantom,
1296
- reifiedTypeArgs: [],
1297
- fromFields: function (fields) { return RemoveBid.fromFields(fields); },
1298
- fromFieldsWithTypes: function (item) { return RemoveBid.fromFieldsWithTypes(item); },
1299
- fromBcs: function (data) { return RemoveBid.fromBcs(data); },
1300
- bcs: RemoveBid.bcs,
1301
- fromJSONField: function (field) { return RemoveBid.fromJSONField(field); },
1302
- fromJSON: function (json) { return RemoveBid.fromJSON(json); },
1303
- fromSuiParsedData: function (content) { return RemoveBid.fromSuiParsedData(content); },
1304
- fromSuiObjectData: function (content) { return RemoveBid.fromSuiObjectData(content); },
1305
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
1306
- return [2 /*return*/, RemoveBid.fetch(client, id)];
1307
- }); }); },
1308
- new: function (fields) {
1309
- return new RemoveBid([], fields);
1310
- },
1311
- kind: "StructClassReified",
1312
- };
1313
- };
1314
- Object.defineProperty(RemoveBid, "r", {
1315
- get: function () {
1316
- return RemoveBid.reified();
1317
- },
1318
- enumerable: false,
1319
- configurable: true
1320
- });
1321
- RemoveBid.phantom = function () {
1322
- return (0, reified_1.phantom)(RemoveBid.reified());
1323
- };
1324
- Object.defineProperty(RemoveBid, "p", {
1325
- get: function () {
1326
- return RemoveBid.phantom();
1327
- },
1328
- enumerable: false,
1329
- configurable: true
1330
- });
1331
- Object.defineProperty(RemoveBid, "bcs", {
1332
- get: function () {
1333
- return bcs_1.bcs.struct("RemoveBid", {
1334
- signer: bcs_1.bcs.bytes(32).transform({
1335
- input: function (val) { return (0, utils_1.fromHEX)(val); },
1336
- output: function (val) { return (0, utils_1.toHEX)(val); },
1337
- }),
1338
- index: bcs_1.bcs.u64(),
1339
- token: structs_1.TypeName.bcs,
1340
- bid_index: bcs_1.bcs.u64(),
1341
- price: bcs_1.bcs.u64(),
1342
- size: bcs_1.bcs.u64(),
1343
- bidder_balance: bcs_1.bcs.u64(),
1344
- incentive_balance: bcs_1.bcs.u64(),
1345
- fee_discount: bcs_1.bcs.u64(),
1346
- ts_ms: bcs_1.bcs.u64(),
1347
- });
1348
- },
1349
- enumerable: false,
1350
- configurable: true
1351
- });
1352
- RemoveBid.fromFields = function (fields) {
1353
- return RemoveBid.reified().new({
1354
- signer: (0, reified_1.decodeFromFields)("address", fields.signer),
1355
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
1356
- token: (0, reified_1.decodeFromFields)(structs_1.TypeName.reified(), fields.token),
1357
- bidIndex: (0, reified_1.decodeFromFields)("u64", fields.bid_index),
1358
- price: (0, reified_1.decodeFromFields)("u64", fields.price),
1359
- size: (0, reified_1.decodeFromFields)("u64", fields.size),
1360
- bidderBalance: (0, reified_1.decodeFromFields)("u64", fields.bidder_balance),
1361
- incentiveBalance: (0, reified_1.decodeFromFields)("u64", fields.incentive_balance),
1362
- feeDiscount: (0, reified_1.decodeFromFields)("u64", fields.fee_discount),
1363
- tsMs: (0, reified_1.decodeFromFields)("u64", fields.ts_ms),
1364
- });
1365
- };
1366
- RemoveBid.fromFieldsWithTypes = function (item) {
1367
- if (!isRemoveBid(item.type)) {
1368
- throw new Error("not a RemoveBid type");
1369
- }
1370
- return RemoveBid.reified().new({
1371
- signer: (0, reified_1.decodeFromFieldsWithTypes)("address", item.fields.signer),
1372
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
1373
- token: (0, reified_1.decodeFromFieldsWithTypes)(structs_1.TypeName.reified(), item.fields.token),
1374
- bidIndex: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bid_index),
1375
- price: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.price),
1376
- size: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size),
1377
- bidderBalance: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.bidder_balance),
1378
- incentiveBalance: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_balance),
1379
- feeDiscount: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.fee_discount),
1380
- tsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.ts_ms),
1381
- });
1382
- };
1383
- RemoveBid.fromBcs = function (data) {
1384
- return RemoveBid.fromFields(RemoveBid.bcs.parse(data));
1385
- };
1386
- RemoveBid.prototype.toJSONField = function () {
1387
- return {
1388
- signer: this.signer,
1389
- index: this.index.toString(),
1390
- token: this.token.toJSONField(),
1391
- bidIndex: this.bidIndex.toString(),
1392
- price: this.price.toString(),
1393
- size: this.size.toString(),
1394
- bidderBalance: this.bidderBalance.toString(),
1395
- incentiveBalance: this.incentiveBalance.toString(),
1396
- feeDiscount: this.feeDiscount.toString(),
1397
- tsMs: this.tsMs.toString(),
1398
- };
1399
- };
1400
- RemoveBid.prototype.toJSON = function () {
1401
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
1402
- };
1403
- RemoveBid.fromJSONField = function (field) {
1404
- return RemoveBid.reified().new({
1405
- signer: (0, reified_1.decodeFromJSONField)("address", field.signer),
1406
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
1407
- token: (0, reified_1.decodeFromJSONField)(structs_1.TypeName.reified(), field.token),
1408
- bidIndex: (0, reified_1.decodeFromJSONField)("u64", field.bidIndex),
1409
- price: (0, reified_1.decodeFromJSONField)("u64", field.price),
1410
- size: (0, reified_1.decodeFromJSONField)("u64", field.size),
1411
- bidderBalance: (0, reified_1.decodeFromJSONField)("u64", field.bidderBalance),
1412
- incentiveBalance: (0, reified_1.decodeFromJSONField)("u64", field.incentiveBalance),
1413
- feeDiscount: (0, reified_1.decodeFromJSONField)("u64", field.feeDiscount),
1414
- tsMs: (0, reified_1.decodeFromJSONField)("u64", field.tsMs),
1415
- });
1416
- };
1417
- RemoveBid.fromJSON = function (json) {
1418
- if (json.$typeName !== RemoveBid.$typeName) {
1419
- throw new Error("not a WithTwoGenerics json object");
1420
- }
1421
- return RemoveBid.fromJSONField(json);
1422
- };
1423
- RemoveBid.fromSuiParsedData = function (content) {
1424
- if (content.dataType !== "moveObject") {
1425
- throw new Error("not an object");
1426
- }
1427
- if (!isRemoveBid(content.type)) {
1428
- throw new Error("object at ".concat(content.fields.id, " is not a RemoveBid object"));
1429
- }
1430
- return RemoveBid.fromFieldsWithTypes(content);
1431
- };
1432
- RemoveBid.fromSuiObjectData = function (data) {
1433
- if (data.bcs) {
1434
- if (data.bcs.dataType !== "moveObject" || !isRemoveBid(data.bcs.type)) {
1435
- throw new Error("object at is not a RemoveBid object");
1436
- }
1437
- return RemoveBid.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
1438
- }
1439
- if (data.content) {
1440
- return RemoveBid.fromSuiParsedData(data.content);
1441
- }
1442
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
1443
- };
1444
- RemoveBid.fetch = function (client, id) {
1445
- return __awaiter(this, void 0, void 0, function () {
1446
- var res;
1447
- var _a, _b;
1448
- return __generator(this, function (_c) {
1449
- switch (_c.label) {
1450
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
1451
- case 1:
1452
- res = _c.sent();
1453
- if (res.error) {
1454
- throw new Error("error fetching RemoveBid object at id ".concat(id, ": ").concat(res.error.code));
1455
- }
1456
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isRemoveBid(res.data.bcs.type)) {
1457
- throw new Error("object at id ".concat(id, " is not a RemoveBid object"));
1458
- }
1459
- return [2 /*return*/, RemoveBid.fromSuiObjectData(res.data)];
1460
- }
1461
- });
1462
- });
1463
- };
1464
- RemoveBid.$typeName = "".concat(index_1.PKG_V1, "::dutch::RemoveBid");
1465
- RemoveBid.$numTypeParams = 0;
1466
- RemoveBid.$isPhantom = [];
1467
- return RemoveBid;
1468
- }());
1469
- exports.RemoveBid = RemoveBid;
1470
- /* ============================== UpdateAuctionConfig =============================== */
1471
- function isUpdateAuctionConfig(type) {
1472
- type = (0, util_1.compressSuiType)(type);
1473
- return type === "".concat(index_1.PKG_V1, "::dutch::UpdateAuctionConfig");
1474
- }
1475
- var UpdateAuctionConfig = /** @class */ (function () {
1476
- function UpdateAuctionConfig(typeArgs, fields) {
1477
- this.__StructClass = true;
1478
- this.$typeName = UpdateAuctionConfig.$typeName;
1479
- this.$isPhantom = UpdateAuctionConfig.$isPhantom;
1480
- this.$fullTypeName = util_1.composeSuiType.apply(void 0, __spreadArray([UpdateAuctionConfig.$typeName], __read(typeArgs), false));
1481
- this.$typeArgs = typeArgs;
1482
- this.signer = fields.signer;
1483
- this.index = fields.index;
1484
- this.prevStartTsMs = fields.prevStartTsMs;
1485
- this.prevEndTsMs = fields.prevEndTsMs;
1486
- this.prevDecaySpeed = fields.prevDecaySpeed;
1487
- this.prevInitialPrice = fields.prevInitialPrice;
1488
- this.prevFinalPrice = fields.prevFinalPrice;
1489
- this.prevFeeBp = fields.prevFeeBp;
1490
- this.prevIncentiveBp = fields.prevIncentiveBp;
1491
- this.prevTokenDecimal = fields.prevTokenDecimal;
1492
- this.prevSizeDecimal = fields.prevSizeDecimal;
1493
- this.prevAbleToRemoveBid = fields.prevAbleToRemoveBid;
1494
- this.startTsMs = fields.startTsMs;
1495
- this.endTsMs = fields.endTsMs;
1496
- this.decaySpeed = fields.decaySpeed;
1497
- this.initialPrice = fields.initialPrice;
1498
- this.finalPrice = fields.finalPrice;
1499
- this.feeBp = fields.feeBp;
1500
- this.incentiveBp = fields.incentiveBp;
1501
- this.tokenDecimal = fields.tokenDecimal;
1502
- this.sizeDecimal = fields.sizeDecimal;
1503
- this.ableToRemoveBid = fields.ableToRemoveBid;
1504
- }
1505
- UpdateAuctionConfig.reified = function () {
1506
- var _this = this;
1507
- return {
1508
- typeName: UpdateAuctionConfig.$typeName,
1509
- fullTypeName: util_1.composeSuiType.apply(void 0, __spreadArray([UpdateAuctionConfig.$typeName], [], false)),
1510
- typeArgs: [],
1511
- isPhantom: UpdateAuctionConfig.$isPhantom,
1512
- reifiedTypeArgs: [],
1513
- fromFields: function (fields) { return UpdateAuctionConfig.fromFields(fields); },
1514
- fromFieldsWithTypes: function (item) { return UpdateAuctionConfig.fromFieldsWithTypes(item); },
1515
- fromBcs: function (data) { return UpdateAuctionConfig.fromBcs(data); },
1516
- bcs: UpdateAuctionConfig.bcs,
1517
- fromJSONField: function (field) { return UpdateAuctionConfig.fromJSONField(field); },
1518
- fromJSON: function (json) { return UpdateAuctionConfig.fromJSON(json); },
1519
- fromSuiParsedData: function (content) { return UpdateAuctionConfig.fromSuiParsedData(content); },
1520
- fromSuiObjectData: function (content) { return UpdateAuctionConfig.fromSuiObjectData(content); },
1521
- fetch: function (client, id) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_a) {
1522
- return [2 /*return*/, UpdateAuctionConfig.fetch(client, id)];
1523
- }); }); },
1524
- new: function (fields) {
1525
- return new UpdateAuctionConfig([], fields);
1526
- },
1527
- kind: "StructClassReified",
1528
- };
1529
- };
1530
- Object.defineProperty(UpdateAuctionConfig, "r", {
1531
- get: function () {
1532
- return UpdateAuctionConfig.reified();
1533
- },
1534
- enumerable: false,
1535
- configurable: true
1536
- });
1537
- UpdateAuctionConfig.phantom = function () {
1538
- return (0, reified_1.phantom)(UpdateAuctionConfig.reified());
1539
- };
1540
- Object.defineProperty(UpdateAuctionConfig, "p", {
1541
- get: function () {
1542
- return UpdateAuctionConfig.phantom();
1543
- },
1544
- enumerable: false,
1545
- configurable: true
1546
- });
1547
- Object.defineProperty(UpdateAuctionConfig, "bcs", {
1548
- get: function () {
1549
- return bcs_1.bcs.struct("UpdateAuctionConfig", {
1550
- signer: bcs_1.bcs.bytes(32).transform({
1551
- input: function (val) { return (0, utils_1.fromHEX)(val); },
1552
- output: function (val) { return (0, utils_1.toHEX)(val); },
1553
- }),
1554
- index: bcs_1.bcs.u64(),
1555
- prev_start_ts_ms: bcs_1.bcs.u64(),
1556
- prev_end_ts_ms: bcs_1.bcs.u64(),
1557
- prev_decay_speed: bcs_1.bcs.u64(),
1558
- prev_initial_price: bcs_1.bcs.u64(),
1559
- prev_final_price: bcs_1.bcs.u64(),
1560
- prev_fee_bp: bcs_1.bcs.u64(),
1561
- prev_incentive_bp: bcs_1.bcs.u64(),
1562
- prev_token_decimal: bcs_1.bcs.u64(),
1563
- prev_size_decimal: bcs_1.bcs.u64(),
1564
- prev_able_to_remove_bid: bcs_1.bcs.bool(),
1565
- start_ts_ms: bcs_1.bcs.u64(),
1566
- end_ts_ms: bcs_1.bcs.u64(),
1567
- decay_speed: bcs_1.bcs.u64(),
1568
- initial_price: bcs_1.bcs.u64(),
1569
- final_price: bcs_1.bcs.u64(),
1570
- fee_bp: bcs_1.bcs.u64(),
1571
- incentive_bp: bcs_1.bcs.u64(),
1572
- token_decimal: bcs_1.bcs.u64(),
1573
- size_decimal: bcs_1.bcs.u64(),
1574
- able_to_remove_bid: bcs_1.bcs.bool(),
1575
- });
1576
- },
1577
- enumerable: false,
1578
- configurable: true
1579
- });
1580
- UpdateAuctionConfig.fromFields = function (fields) {
1581
- return UpdateAuctionConfig.reified().new({
1582
- signer: (0, reified_1.decodeFromFields)("address", fields.signer),
1583
- index: (0, reified_1.decodeFromFields)("u64", fields.index),
1584
- prevStartTsMs: (0, reified_1.decodeFromFields)("u64", fields.prev_start_ts_ms),
1585
- prevEndTsMs: (0, reified_1.decodeFromFields)("u64", fields.prev_end_ts_ms),
1586
- prevDecaySpeed: (0, reified_1.decodeFromFields)("u64", fields.prev_decay_speed),
1587
- prevInitialPrice: (0, reified_1.decodeFromFields)("u64", fields.prev_initial_price),
1588
- prevFinalPrice: (0, reified_1.decodeFromFields)("u64", fields.prev_final_price),
1589
- prevFeeBp: (0, reified_1.decodeFromFields)("u64", fields.prev_fee_bp),
1590
- prevIncentiveBp: (0, reified_1.decodeFromFields)("u64", fields.prev_incentive_bp),
1591
- prevTokenDecimal: (0, reified_1.decodeFromFields)("u64", fields.prev_token_decimal),
1592
- prevSizeDecimal: (0, reified_1.decodeFromFields)("u64", fields.prev_size_decimal),
1593
- prevAbleToRemoveBid: (0, reified_1.decodeFromFields)("bool", fields.prev_able_to_remove_bid),
1594
- startTsMs: (0, reified_1.decodeFromFields)("u64", fields.start_ts_ms),
1595
- endTsMs: (0, reified_1.decodeFromFields)("u64", fields.end_ts_ms),
1596
- decaySpeed: (0, reified_1.decodeFromFields)("u64", fields.decay_speed),
1597
- initialPrice: (0, reified_1.decodeFromFields)("u64", fields.initial_price),
1598
- finalPrice: (0, reified_1.decodeFromFields)("u64", fields.final_price),
1599
- feeBp: (0, reified_1.decodeFromFields)("u64", fields.fee_bp),
1600
- incentiveBp: (0, reified_1.decodeFromFields)("u64", fields.incentive_bp),
1601
- tokenDecimal: (0, reified_1.decodeFromFields)("u64", fields.token_decimal),
1602
- sizeDecimal: (0, reified_1.decodeFromFields)("u64", fields.size_decimal),
1603
- ableToRemoveBid: (0, reified_1.decodeFromFields)("bool", fields.able_to_remove_bid),
1604
- });
1605
- };
1606
- UpdateAuctionConfig.fromFieldsWithTypes = function (item) {
1607
- if (!isUpdateAuctionConfig(item.type)) {
1608
- throw new Error("not a UpdateAuctionConfig type");
1609
- }
1610
- return UpdateAuctionConfig.reified().new({
1611
- signer: (0, reified_1.decodeFromFieldsWithTypes)("address", item.fields.signer),
1612
- index: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.index),
1613
- prevStartTsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_start_ts_ms),
1614
- prevEndTsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_end_ts_ms),
1615
- prevDecaySpeed: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_decay_speed),
1616
- prevInitialPrice: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_initial_price),
1617
- prevFinalPrice: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_final_price),
1618
- prevFeeBp: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_fee_bp),
1619
- prevIncentiveBp: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_incentive_bp),
1620
- prevTokenDecimal: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_token_decimal),
1621
- prevSizeDecimal: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.prev_size_decimal),
1622
- prevAbleToRemoveBid: (0, reified_1.decodeFromFieldsWithTypes)("bool", item.fields.prev_able_to_remove_bid),
1623
- startTsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.start_ts_ms),
1624
- endTsMs: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.end_ts_ms),
1625
- decaySpeed: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.decay_speed),
1626
- initialPrice: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.initial_price),
1627
- finalPrice: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.final_price),
1628
- feeBp: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.fee_bp),
1629
- incentiveBp: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.incentive_bp),
1630
- tokenDecimal: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.token_decimal),
1631
- sizeDecimal: (0, reified_1.decodeFromFieldsWithTypes)("u64", item.fields.size_decimal),
1632
- ableToRemoveBid: (0, reified_1.decodeFromFieldsWithTypes)("bool", item.fields.able_to_remove_bid),
1633
- });
1634
- };
1635
- UpdateAuctionConfig.fromBcs = function (data) {
1636
- return UpdateAuctionConfig.fromFields(UpdateAuctionConfig.bcs.parse(data));
1637
- };
1638
- UpdateAuctionConfig.prototype.toJSONField = function () {
1639
- return {
1640
- signer: this.signer,
1641
- index: this.index.toString(),
1642
- prevStartTsMs: this.prevStartTsMs.toString(),
1643
- prevEndTsMs: this.prevEndTsMs.toString(),
1644
- prevDecaySpeed: this.prevDecaySpeed.toString(),
1645
- prevInitialPrice: this.prevInitialPrice.toString(),
1646
- prevFinalPrice: this.prevFinalPrice.toString(),
1647
- prevFeeBp: this.prevFeeBp.toString(),
1648
- prevIncentiveBp: this.prevIncentiveBp.toString(),
1649
- prevTokenDecimal: this.prevTokenDecimal.toString(),
1650
- prevSizeDecimal: this.prevSizeDecimal.toString(),
1651
- prevAbleToRemoveBid: this.prevAbleToRemoveBid,
1652
- startTsMs: this.startTsMs.toString(),
1653
- endTsMs: this.endTsMs.toString(),
1654
- decaySpeed: this.decaySpeed.toString(),
1655
- initialPrice: this.initialPrice.toString(),
1656
- finalPrice: this.finalPrice.toString(),
1657
- feeBp: this.feeBp.toString(),
1658
- incentiveBp: this.incentiveBp.toString(),
1659
- tokenDecimal: this.tokenDecimal.toString(),
1660
- sizeDecimal: this.sizeDecimal.toString(),
1661
- ableToRemoveBid: this.ableToRemoveBid,
1662
- };
1663
- };
1664
- UpdateAuctionConfig.prototype.toJSON = function () {
1665
- return __assign({ $typeName: this.$typeName, $typeArgs: this.$typeArgs }, this.toJSONField());
1666
- };
1667
- UpdateAuctionConfig.fromJSONField = function (field) {
1668
- return UpdateAuctionConfig.reified().new({
1669
- signer: (0, reified_1.decodeFromJSONField)("address", field.signer),
1670
- index: (0, reified_1.decodeFromJSONField)("u64", field.index),
1671
- prevStartTsMs: (0, reified_1.decodeFromJSONField)("u64", field.prevStartTsMs),
1672
- prevEndTsMs: (0, reified_1.decodeFromJSONField)("u64", field.prevEndTsMs),
1673
- prevDecaySpeed: (0, reified_1.decodeFromJSONField)("u64", field.prevDecaySpeed),
1674
- prevInitialPrice: (0, reified_1.decodeFromJSONField)("u64", field.prevInitialPrice),
1675
- prevFinalPrice: (0, reified_1.decodeFromJSONField)("u64", field.prevFinalPrice),
1676
- prevFeeBp: (0, reified_1.decodeFromJSONField)("u64", field.prevFeeBp),
1677
- prevIncentiveBp: (0, reified_1.decodeFromJSONField)("u64", field.prevIncentiveBp),
1678
- prevTokenDecimal: (0, reified_1.decodeFromJSONField)("u64", field.prevTokenDecimal),
1679
- prevSizeDecimal: (0, reified_1.decodeFromJSONField)("u64", field.prevSizeDecimal),
1680
- prevAbleToRemoveBid: (0, reified_1.decodeFromJSONField)("bool", field.prevAbleToRemoveBid),
1681
- startTsMs: (0, reified_1.decodeFromJSONField)("u64", field.startTsMs),
1682
- endTsMs: (0, reified_1.decodeFromJSONField)("u64", field.endTsMs),
1683
- decaySpeed: (0, reified_1.decodeFromJSONField)("u64", field.decaySpeed),
1684
- initialPrice: (0, reified_1.decodeFromJSONField)("u64", field.initialPrice),
1685
- finalPrice: (0, reified_1.decodeFromJSONField)("u64", field.finalPrice),
1686
- feeBp: (0, reified_1.decodeFromJSONField)("u64", field.feeBp),
1687
- incentiveBp: (0, reified_1.decodeFromJSONField)("u64", field.incentiveBp),
1688
- tokenDecimal: (0, reified_1.decodeFromJSONField)("u64", field.tokenDecimal),
1689
- sizeDecimal: (0, reified_1.decodeFromJSONField)("u64", field.sizeDecimal),
1690
- ableToRemoveBid: (0, reified_1.decodeFromJSONField)("bool", field.ableToRemoveBid),
1691
- });
1692
- };
1693
- UpdateAuctionConfig.fromJSON = function (json) {
1694
- if (json.$typeName !== UpdateAuctionConfig.$typeName) {
1695
- throw new Error("not a WithTwoGenerics json object");
1696
- }
1697
- return UpdateAuctionConfig.fromJSONField(json);
1698
- };
1699
- UpdateAuctionConfig.fromSuiParsedData = function (content) {
1700
- if (content.dataType !== "moveObject") {
1701
- throw new Error("not an object");
1702
- }
1703
- if (!isUpdateAuctionConfig(content.type)) {
1704
- throw new Error("object at ".concat(content.fields.id, " is not a UpdateAuctionConfig object"));
1705
- }
1706
- return UpdateAuctionConfig.fromFieldsWithTypes(content);
1707
- };
1708
- UpdateAuctionConfig.fromSuiObjectData = function (data) {
1709
- if (data.bcs) {
1710
- if (data.bcs.dataType !== "moveObject" || !isUpdateAuctionConfig(data.bcs.type)) {
1711
- throw new Error("object at is not a UpdateAuctionConfig object");
1712
- }
1713
- return UpdateAuctionConfig.fromBcs((0, utils_1.fromB64)(data.bcs.bcsBytes));
1714
- }
1715
- if (data.content) {
1716
- return UpdateAuctionConfig.fromSuiParsedData(data.content);
1717
- }
1718
- throw new Error("Both `bcs` and `content` fields are missing from the data. Include `showBcs` or `showContent` in the request.");
1719
- };
1720
- UpdateAuctionConfig.fetch = function (client, id) {
1721
- return __awaiter(this, void 0, void 0, function () {
1722
- var res;
1723
- var _a, _b;
1724
- return __generator(this, function (_c) {
1725
- switch (_c.label) {
1726
- case 0: return [4 /*yield*/, client.getObject({ id: id, options: { showBcs: true } })];
1727
- case 1:
1728
- res = _c.sent();
1729
- if (res.error) {
1730
- throw new Error("error fetching UpdateAuctionConfig object at id ".concat(id, ": ").concat(res.error.code));
1731
- }
1732
- if (((_b = (_a = res.data) === null || _a === void 0 ? void 0 : _a.bcs) === null || _b === void 0 ? void 0 : _b.dataType) !== "moveObject" || !isUpdateAuctionConfig(res.data.bcs.type)) {
1733
- throw new Error("object at id ".concat(id, " is not a UpdateAuctionConfig object"));
1734
- }
1735
- return [2 /*return*/, UpdateAuctionConfig.fromSuiObjectData(res.data)];
1736
- }
1737
- });
1738
- });
1739
- };
1740
- UpdateAuctionConfig.$typeName = "".concat(index_1.PKG_V1, "::dutch::UpdateAuctionConfig");
1741
- UpdateAuctionConfig.$numTypeParams = 0;
1742
- UpdateAuctionConfig.$isPhantom = [];
1743
- return UpdateAuctionConfig;
1744
- }());
1745
- exports.UpdateAuctionConfig = UpdateAuctionConfig;