@evergonlabs/tmi-protocol-api 0.5.0 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (854) hide show
  1. package/README.md +169 -0
  2. package/dist/app.d.ts +3301 -2851
  3. package/dist/app.d.ts.map +1 -1
  4. package/dist/app.js +36 -23
  5. package/dist/apps.d.ts +30 -0
  6. package/dist/apps.d.ts.map +1 -0
  7. package/dist/apps.js +16 -0
  8. package/dist/client.d.ts +2170 -1996
  9. package/dist/client.d.ts.map +1 -1
  10. package/dist/client.js +23 -2
  11. package/dist/common/blockchain.d.ts +26 -26
  12. package/dist/common/blockchain.d.ts.map +1 -1
  13. package/dist/common/blockchain.js +6 -10
  14. package/dist/common/config.d.ts +6 -27
  15. package/dist/common/config.d.ts.map +1 -1
  16. package/dist/common/config.js +2 -11
  17. package/dist/common/context.d.ts +2 -2
  18. package/dist/common/context.d.ts.map +1 -1
  19. package/dist/common/controller.d.ts +12 -0
  20. package/dist/common/controller.d.ts.map +1 -0
  21. package/dist/common/controller.js +6 -0
  22. package/dist/common/exports.d.ts +3 -0
  23. package/dist/common/exports.d.ts.map +1 -0
  24. package/dist/common/exports.js +2 -0
  25. package/dist/common/http-error.d.ts +1 -1
  26. package/dist/common/http-error.d.ts.map +1 -1
  27. package/dist/common/indexer/client.d.ts +138 -2
  28. package/dist/common/indexer/client.d.ts.map +1 -1
  29. package/dist/common/indexer/schemas.d.ts +69 -1
  30. package/dist/common/indexer/schemas.d.ts.map +1 -1
  31. package/dist/common/indexer/schemas.js +1 -1
  32. package/dist/common/int256.d.ts +3 -0
  33. package/dist/common/int256.d.ts.map +1 -0
  34. package/dist/common/int256.js +12 -0
  35. package/dist/common/models/asset.d.ts +5 -23
  36. package/dist/common/models/asset.d.ts.map +1 -1
  37. package/dist/common/models/asset.js +4 -6
  38. package/dist/common/models/base/chainId.d.ts +8 -0
  39. package/dist/common/models/base/chainId.d.ts.map +1 -0
  40. package/dist/common/models/base/chainId.js +11 -0
  41. package/dist/common/models/base/deployTransaction.d.ts +8 -0
  42. package/dist/common/models/base/deployTransaction.d.ts.map +1 -0
  43. package/dist/common/models/base/deployTransaction.js +7 -0
  44. package/dist/common/models/base/page.d.ts +7 -0
  45. package/dist/common/models/base/page.d.ts.map +1 -0
  46. package/dist/common/models/base/page.js +5 -0
  47. package/dist/common/models/base/transaction.d.ts +13 -0
  48. package/dist/common/models/base/transaction.d.ts.map +1 -0
  49. package/dist/common/models/base/transaction.js +12 -0
  50. package/dist/common/models/base/viem.d.ts +6 -0
  51. package/dist/common/models/base/viem.d.ts.map +1 -0
  52. package/dist/common/models/base/viem.js +5 -0
  53. package/dist/common/models/chainId.d.ts +7 -7
  54. package/dist/common/models/chainId.d.ts.map +1 -1
  55. package/dist/common/models/chainId.js +27 -12
  56. package/dist/common/models/compilot.d.ts +3 -0
  57. package/dist/common/models/compilot.d.ts.map +1 -0
  58. package/dist/common/models/compilot.js +1 -0
  59. package/dist/common/models/date.d.ts +5 -2
  60. package/dist/common/models/date.d.ts.map +1 -1
  61. package/dist/common/models/date.js +13 -5
  62. package/dist/common/models/deployTransaction.d.ts +8 -0
  63. package/dist/common/models/deployTransaction.d.ts.map +1 -0
  64. package/dist/common/models/deployTransaction.js +12 -0
  65. package/dist/common/models/erc721.d.ts +3 -11
  66. package/dist/common/models/erc721.d.ts.map +1 -1
  67. package/dist/common/models/erc721.js +2 -4
  68. package/dist/common/models/exports.d.ts +5 -0
  69. package/dist/common/models/exports.d.ts.map +1 -0
  70. package/dist/common/models/exports.js +4 -0
  71. package/dist/common/models/index.d.ts +7 -4
  72. package/dist/common/models/index.d.ts.map +1 -1
  73. package/dist/common/models/index.js +7 -4
  74. package/dist/common/models/page.d.ts +3 -8
  75. package/dist/common/models/page.d.ts.map +1 -1
  76. package/dist/common/models/page.js +2 -5
  77. package/dist/common/models/platform.d.ts +19 -6
  78. package/dist/common/models/platform.d.ts.map +1 -1
  79. package/dist/common/models/platform.js +6 -6
  80. package/dist/common/models/routes.d.ts +2 -10
  81. package/dist/common/models/routes.d.ts.map +1 -1
  82. package/dist/common/models/routes.js +1 -1
  83. package/dist/common/models/saleId.d.ts +3 -9
  84. package/dist/common/models/saleId.d.ts.map +1 -1
  85. package/dist/common/models/saleId.js +2 -1
  86. package/dist/common/models/transaction.d.ts +20 -81
  87. package/dist/common/models/transaction.d.ts.map +1 -1
  88. package/dist/common/models/transaction.js +13 -21
  89. package/dist/common/models/viem.d.ts +5 -3
  90. package/dist/common/models/viem.d.ts.map +1 -1
  91. package/dist/common/models/viem.js +6 -1
  92. package/dist/common/roles/erc20-gated-roles.d.ts +4 -2
  93. package/dist/common/roles/erc20-gated-roles.d.ts.map +1 -1
  94. package/dist/common/roles/erc20-gated-roles.js +3 -1
  95. package/dist/common/roles/erc721-factory-roles.d.ts +8 -0
  96. package/dist/common/roles/erc721-factory-roles.d.ts.map +1 -0
  97. package/dist/common/roles/erc721-factory-roles.js +13 -0
  98. package/dist/common/roles/exports.d.ts +3 -0
  99. package/dist/common/roles/exports.d.ts.map +1 -0
  100. package/dist/common/roles/exports.js +2 -0
  101. package/dist/factory.d.ts +11 -0
  102. package/dist/factory.d.ts.map +1 -0
  103. package/dist/factory.js +19 -0
  104. package/dist/fractions/activity/searchActivity.route.d.ts +7 -7
  105. package/dist/fractions/activity/searchActivity.route.js +2 -2
  106. package/dist/fractions/activity/utils.d.ts +3 -3
  107. package/dist/fractions/activity/utils.js +2 -2
  108. package/dist/fractions/createFractions/v0/createFractions.route.d.ts +4 -4
  109. package/dist/fractions/createFractions/v0/createFractions.route.d.ts.map +1 -1
  110. package/dist/fractions/createFractions/v0/createFractions.route.js +3 -16
  111. package/dist/fractions/createFractions/v0/createFractions.schema.d.ts +14 -3
  112. package/dist/fractions/createFractions/v0/createFractions.schema.d.ts.map +1 -1
  113. package/dist/fractions/createFractions/v0/createFractions.schema.js +13 -2
  114. package/dist/fractions/createFractions/v0/parseFractionsCreatedEvent.d.ts +2 -2
  115. package/dist/fractions/deployMarket/v0/deployMarket.routes.d.ts +36 -22
  116. package/dist/fractions/deployMarket/v0/deployMarket.routes.d.ts.map +1 -1
  117. package/dist/fractions/deployMarket/v0/deployMarket.routes.js +30 -32
  118. package/dist/fractions/deployMarket/v0/deployMarket.schema.d.ts +6 -3
  119. package/dist/fractions/deployMarket/v0/deployMarket.schema.d.ts.map +1 -1
  120. package/dist/fractions/deployMarket/v0/deployMarket.schema.js +5 -2
  121. package/dist/fractions/fractions/approveWrapper.route.d.ts +88 -0
  122. package/dist/fractions/fractions/approveWrapper.route.d.ts.map +1 -0
  123. package/dist/fractions/fractions/approveWrapper.route.js +92 -0
  124. package/dist/fractions/fractions/index.d.ts +72 -0
  125. package/dist/fractions/fractions/index.d.ts.map +1 -0
  126. package/dist/fractions/fractions/index.js +9 -0
  127. package/dist/fractions/gating/v0/getAuthData.d.ts +7 -7
  128. package/dist/fractions/gating/v0/getAuthData.js +2 -2
  129. package/dist/fractions/gating/v0/getNonce.route.d.ts +7 -7
  130. package/dist/fractions/gating/v0/getNonce.route.js +2 -2
  131. package/dist/fractions/grantRole/v0/grantRole.route.d.ts +4 -4
  132. package/dist/fractions/grantRole/v0/grantRole.schema.d.ts +3 -3
  133. package/dist/fractions/grantRole/v0/grantRole.schema.js +2 -2
  134. package/dist/fractions/index.d.ts +1106 -1148
  135. package/dist/fractions/index.d.ts.map +1 -1
  136. package/dist/fractions/index.js +20 -105
  137. package/dist/fractions/markets/common/platform.d.ts +23 -75
  138. package/dist/fractions/markets/common/platform.d.ts.map +1 -1
  139. package/dist/fractions/markets/common/platform.js +11 -13
  140. package/dist/fractions/markets/getDeployEvent.d.ts +17 -39
  141. package/dist/fractions/markets/getDeployEvent.d.ts.map +1 -1
  142. package/dist/fractions/markets/getDeployEvent.js +10 -9
  143. package/dist/fractions/markets/getMarket/getMarket.d.ts +30 -0
  144. package/dist/fractions/markets/getMarket/getMarket.d.ts.map +1 -0
  145. package/dist/fractions/markets/getMarket/getMarket.js +65 -0
  146. package/dist/fractions/markets/getMarket/index.d.ts +4 -27
  147. package/dist/fractions/markets/getMarket/index.d.ts.map +1 -1
  148. package/dist/fractions/markets/getMarket/index.js +5 -4
  149. package/dist/fractions/markets/getMarket/v0/getMarket.d.ts +14 -14
  150. package/dist/fractions/markets/getMarket/v0/getMarket.js +2 -2
  151. package/dist/fractions/markets/index.d.ts +12 -54
  152. package/dist/fractions/markets/index.d.ts.map +1 -1
  153. package/dist/fractions/markets/index.js +10 -11
  154. package/dist/fractions/markets/searchMarkets/index.d.ts +7 -30
  155. package/dist/fractions/markets/searchMarkets/index.d.ts.map +1 -1
  156. package/dist/fractions/markets/searchMarkets/index.js +5 -4
  157. package/dist/fractions/markets/searchMarkets/searchMarkets.d.ts +22 -0
  158. package/dist/fractions/markets/searchMarkets/searchMarkets.d.ts.map +1 -0
  159. package/dist/fractions/markets/searchMarkets/searchMarkets.js +45 -0
  160. package/dist/fractions/markets/searchMarkets/v0/searchMarkets.d.ts +13 -13
  161. package/dist/fractions/markets/searchMarkets/v0/searchMarkets.js +2 -2
  162. package/dist/fractions/nftfractions/index.d.ts +6 -0
  163. package/dist/fractions/nftfractions/index.d.ts.map +1 -0
  164. package/dist/fractions/nftfractions/index.js +5 -0
  165. package/dist/fractions/nftfractions/v0/createNftFractions.routes.d.ts +192 -0
  166. package/dist/fractions/nftfractions/v0/createNftFractions.routes.d.ts.map +1 -0
  167. package/dist/fractions/nftfractions/v0/createNftFractions.routes.js +58 -0
  168. package/dist/fractions/nftfractions/v0/createNftFractions.schema.d.ts +245 -0
  169. package/dist/fractions/nftfractions/v0/createNftFractions.schema.d.ts.map +1 -0
  170. package/dist/fractions/nftfractions/v0/createNftFractions.schema.js +65 -0
  171. package/dist/fractions/nftfractions/v0/deployNftFractionsMarket.routes.d.ts +96 -0
  172. package/dist/fractions/nftfractions/v0/deployNftFractionsMarket.routes.d.ts.map +1 -0
  173. package/dist/fractions/nftfractions/v0/deployNftFractionsMarket.routes.js +52 -0
  174. package/dist/fractions/nftfractions/v0/deployNftFractionsMarket.schema.d.ts +70 -0
  175. package/dist/fractions/nftfractions/v0/deployNftFractionsMarket.schema.d.ts.map +1 -0
  176. package/dist/fractions/nftfractions/v0/deployNftFractionsMarket.schema.js +28 -0
  177. package/dist/fractions/nftfractions/v0/initCompilot.routes.d.ts +74 -0
  178. package/dist/fractions/nftfractions/v0/initCompilot.routes.d.ts.map +1 -0
  179. package/dist/fractions/nftfractions/v0/initCompilot.routes.js +41 -0
  180. package/dist/fractions/platforms/deployMarket.routes.d.ts +158 -0
  181. package/dist/fractions/platforms/deployMarket.routes.d.ts.map +1 -0
  182. package/dist/fractions/platforms/deployMarket.routes.js +131 -0
  183. package/dist/fractions/platforms/deployMarket.schema.d.ts +33 -0
  184. package/dist/fractions/platforms/deployMarket.schema.d.ts.map +1 -0
  185. package/dist/fractions/platforms/deployMarket.schema.js +28 -0
  186. package/dist/fractions/platforms/deployNftFractionsMarket.routes.d.ts +96 -0
  187. package/dist/fractions/platforms/deployNftFractionsMarket.routes.d.ts.map +1 -0
  188. package/dist/fractions/platforms/deployNftFractionsMarket.routes.js +52 -0
  189. package/dist/fractions/platforms/deployNftFractionsMarket.schema.d.ts +30 -0
  190. package/dist/fractions/platforms/deployNftFractionsMarket.schema.d.ts.map +1 -0
  191. package/dist/fractions/platforms/deployNftFractionsMarket.schema.js +29 -0
  192. package/dist/fractions/platforms/index.d.ts +196 -0
  193. package/dist/fractions/platforms/index.d.ts.map +1 -0
  194. package/dist/fractions/platforms/index.js +15 -0
  195. package/dist/fractions/platforms/initCompilot.routes.d.ts +36 -0
  196. package/dist/fractions/platforms/initCompilot.routes.d.ts.map +1 -0
  197. package/dist/fractions/platforms/initCompilot.routes.js +40 -0
  198. package/dist/fractions/platforms/initNid.route.d.ts +28 -0
  199. package/dist/fractions/platforms/initNid.route.d.ts.map +1 -0
  200. package/dist/fractions/platforms/initNid.route.js +32 -0
  201. package/dist/fractions/purchase/v0/purchase.route.d.ts +7 -7
  202. package/dist/fractions/purchase/v0/purchase.route.js +2 -2
  203. package/dist/fractions/purchase/v0/statistics.route.d.ts +7 -7
  204. package/dist/fractions/purchase/v0/statistics.route.js +2 -2
  205. package/dist/fractions/roles/getRoles.d.ts +23 -0
  206. package/dist/fractions/roles/getRoles.d.ts.map +1 -0
  207. package/dist/fractions/roles/getRoles.js +42 -0
  208. package/dist/fractions/roles/grantRole.route.d.ts +27 -0
  209. package/dist/fractions/roles/grantRole.route.d.ts.map +1 -0
  210. package/dist/fractions/roles/grantRole.route.js +34 -0
  211. package/dist/fractions/roles/grantRole.schema.d.ts +16 -0
  212. package/dist/fractions/roles/grantRole.schema.d.ts.map +1 -0
  213. package/dist/fractions/roles/grantRole.schema.js +14 -0
  214. package/dist/fractions/roles/index.d.ts +48 -0
  215. package/dist/fractions/roles/index.d.ts.map +1 -0
  216. package/dist/fractions/roles/index.js +9 -0
  217. package/dist/fractions/sales/activityUtils.d.ts +49 -0
  218. package/dist/fractions/sales/activityUtils.d.ts.map +1 -0
  219. package/dist/fractions/sales/activityUtils.js +68 -0
  220. package/dist/fractions/sales/approveSale.route.d.ts +30 -0
  221. package/dist/fractions/sales/approveSale.route.d.ts.map +1 -0
  222. package/dist/fractions/sales/approveSale.route.js +35 -0
  223. package/dist/fractions/sales/common/fractionsSale.d.ts +50 -326
  224. package/dist/fractions/sales/common/fractionsSale.d.ts.map +1 -1
  225. package/dist/fractions/sales/common/fractionsSale.js +64 -79
  226. package/dist/fractions/sales/completeSale.route.d.ts +30 -0
  227. package/dist/fractions/sales/completeSale.route.d.ts.map +1 -0
  228. package/dist/fractions/sales/completeSale.route.js +35 -0
  229. package/dist/fractions/sales/createFractions.route.d.ts +71 -0
  230. package/dist/fractions/sales/createFractions.route.d.ts.map +1 -0
  231. package/dist/fractions/sales/createFractions.route.js +51 -0
  232. package/dist/fractions/sales/createFractions.schema.d.ts +123 -0
  233. package/dist/fractions/sales/createFractions.schema.d.ts.map +1 -0
  234. package/dist/fractions/sales/createFractions.schema.js +80 -0
  235. package/dist/fractions/sales/createNftFractions.routes.d.ts +180 -0
  236. package/dist/fractions/sales/createNftFractions.routes.d.ts.map +1 -0
  237. package/dist/fractions/sales/createNftFractions.routes.js +58 -0
  238. package/dist/fractions/sales/createNftFractions.schema.d.ts +85 -0
  239. package/dist/fractions/sales/createNftFractions.schema.d.ts.map +1 -0
  240. package/dist/fractions/sales/createNftFractions.schema.js +67 -0
  241. package/dist/fractions/sales/getFractionSaleStatistics.route.d.ts +31 -92
  242. package/dist/fractions/sales/getFractionSaleStatistics.route.d.ts.map +1 -1
  243. package/dist/fractions/sales/getFractionSaleStatistics.route.js +12 -13
  244. package/dist/fractions/sales/getVaultAddress.d.ts +31 -49
  245. package/dist/fractions/sales/getVaultAddress.d.ts.map +1 -1
  246. package/dist/fractions/sales/getVaultAddress.js +11 -10
  247. package/dist/fractions/sales/getWithdrawEvent.d.ts +17 -39
  248. package/dist/fractions/sales/getWithdrawEvent.d.ts.map +1 -1
  249. package/dist/fractions/sales/getWithdrawEvent.js +13 -11
  250. package/dist/fractions/sales/index.d.ts +760 -0
  251. package/dist/fractions/sales/index.d.ts.map +1 -0
  252. package/dist/fractions/sales/index.js +52 -0
  253. package/dist/fractions/sales/parseFractionsCreatedEvent.d.ts +23 -0
  254. package/dist/fractions/sales/parseFractionsCreatedEvent.d.ts.map +1 -0
  255. package/dist/fractions/sales/parseFractionsCreatedEvent.js +59 -0
  256. package/dist/fractions/sales/purchase.route.d.ts +36 -0
  257. package/dist/fractions/sales/purchase.route.d.ts.map +1 -0
  258. package/dist/fractions/sales/purchase.route.js +42 -0
  259. package/dist/fractions/sales/purchaseStatistics.route.d.ts +27 -0
  260. package/dist/fractions/sales/purchaseStatistics.route.d.ts.map +1 -0
  261. package/dist/fractions/sales/purchaseStatistics.route.js +53 -0
  262. package/dist/fractions/sales/receiveFundsAfterNonFunded.route.d.ts +56 -140
  263. package/dist/fractions/sales/receiveFundsAfterNonFunded.route.d.ts.map +1 -1
  264. package/dist/fractions/sales/receiveFundsAfterNonFunded.route.js +19 -15
  265. package/dist/fractions/sales/receiveNonPurchasedWrappedAssets.route.d.ts +22 -54
  266. package/dist/fractions/sales/receiveNonPurchasedWrappedAssets.route.d.ts.map +1 -1
  267. package/dist/fractions/sales/receiveNonPurchasedWrappedAssets.route.js +6 -5
  268. package/dist/fractions/sales/recoverFractions.d.ts +65 -103
  269. package/dist/fractions/sales/recoverFractions.d.ts.map +1 -1
  270. package/dist/fractions/sales/recoverFractions.js +13 -11
  271. package/dist/fractions/sales/rejectFractions.d.ts +49 -75
  272. package/dist/fractions/sales/rejectFractions.d.ts.map +1 -1
  273. package/dist/fractions/sales/rejectFractions.js +12 -8
  274. package/dist/fractions/sales/searchActivity.route.d.ts +67 -86
  275. package/dist/fractions/sales/searchActivity.route.d.ts.map +1 -1
  276. package/dist/fractions/sales/searchActivity.route.js +27 -37
  277. package/dist/fractions/sales/searchSales/searchSales.d.ts +24 -0
  278. package/dist/fractions/sales/searchSales/searchSales.d.ts.map +1 -0
  279. package/dist/fractions/sales/searchSales/searchSales.js +50 -0
  280. package/dist/fractions/sales/searchSales/v0/searchSales.d.ts +16 -16
  281. package/dist/fractions/sales/searchSales/v0/searchSales.js +2 -2
  282. package/dist/fractions/sales/searchWithdrawal.route.d.ts +20 -55
  283. package/dist/fractions/sales/searchWithdrawal.route.d.ts.map +1 -1
  284. package/dist/fractions/sales/searchWithdrawal.route.js +10 -9
  285. package/dist/fractions/sales/setFeeCapLimit.d.ts +27 -70
  286. package/dist/fractions/sales/setFeeCapLimit.d.ts.map +1 -1
  287. package/dist/fractions/sales/setFeeCapLimit.js +12 -8
  288. package/dist/fractions/sales/unlockWrappedAssets.route.d.ts +26 -65
  289. package/dist/fractions/sales/unlockWrappedAssets.route.d.ts.map +1 -1
  290. package/dist/fractions/sales/unlockWrappedAssets.route.js +10 -11
  291. package/dist/fractions/sales/vesting/claimStatistics.route.d.ts +36 -0
  292. package/dist/fractions/sales/vesting/claimStatistics.route.d.ts.map +1 -0
  293. package/dist/fractions/sales/vesting/claimStatistics.route.js +87 -0
  294. package/dist/fractions/sales/vesting/claimVestedTokens.route.d.ts +62 -0
  295. package/dist/fractions/sales/vesting/claimVestedTokens.route.d.ts.map +1 -0
  296. package/dist/fractions/sales/vesting/claimVestedTokens.route.js +45 -0
  297. package/dist/fractions/sales/vesting/editCliff.route.d.ts +58 -0
  298. package/dist/fractions/sales/vesting/editCliff.route.d.ts.map +1 -0
  299. package/dist/fractions/sales/vesting/editCliff.route.js +45 -0
  300. package/dist/fractions/sales/vesting/parseClaimVestedTokensEvent.d.ts +22 -0
  301. package/dist/fractions/sales/vesting/parseClaimVestedTokensEvent.d.ts.map +1 -0
  302. package/dist/fractions/sales/vesting/parseClaimVestedTokensEvent.js +58 -0
  303. package/dist/fractions/sales/vesting/v0/claimStatistics.route.d.ts +10 -10
  304. package/dist/fractions/sales/vesting/v0/claimStatistics.route.js +3 -3
  305. package/dist/fractions/sales/vesting/v0/parseClaimVestedTokensEvent.d.ts +2 -2
  306. package/dist/fractions/sales/withdraw.route.d.ts +29 -0
  307. package/dist/fractions/sales/withdraw.route.d.ts.map +1 -0
  308. package/dist/fractions/sales/withdraw.route.js +30 -0
  309. package/dist/fractions/sig/getAuthData.d.ts +40 -0
  310. package/dist/fractions/sig/getAuthData.d.ts.map +1 -0
  311. package/dist/fractions/sig/getAuthData.js +52 -0
  312. package/dist/fractions/sig/getNonce.route.d.ts +25 -0
  313. package/dist/fractions/sig/getNonce.route.d.ts.map +1 -0
  314. package/dist/fractions/sig/getNonce.route.js +43 -0
  315. package/dist/fractions/sig/index.d.ts +40 -0
  316. package/dist/fractions/sig/index.d.ts.map +1 -0
  317. package/dist/fractions/sig/index.js +6 -0
  318. package/dist/fractions/statistics/index.d.ts +107 -0
  319. package/dist/fractions/statistics/index.d.ts.map +1 -0
  320. package/dist/fractions/statistics/index.js +10 -0
  321. package/dist/fractions/statistics/networkStatistics.route.d.ts +121 -0
  322. package/dist/fractions/statistics/networkStatistics.route.d.ts.map +1 -0
  323. package/dist/fractions/statistics/networkStatistics.route.js +222 -0
  324. package/dist/general/balanceClient.d.ts +19 -58
  325. package/dist/general/balanceClient.d.ts.map +1 -1
  326. package/dist/general/balanceClient.js +3 -3
  327. package/dist/general/common.d.ts +11 -74
  328. package/dist/general/common.d.ts.map +1 -1
  329. package/dist/general/common.js +7 -11
  330. package/dist/general/estimateGas.d.ts +18 -45
  331. package/dist/general/estimateGas.d.ts.map +1 -1
  332. package/dist/general/estimateGas.js +32 -30
  333. package/dist/general/getBalance.d.ts +16 -37
  334. package/dist/general/getBalance.d.ts.map +1 -1
  335. package/dist/general/getBalance.js +30 -26
  336. package/dist/general/getBalancesBatch.d.ts +22 -56
  337. package/dist/general/getBalancesBatch.d.ts.map +1 -1
  338. package/dist/general/getBalancesBatch.js +24 -20
  339. package/dist/general/index.d.ts +74 -83
  340. package/dist/general/index.d.ts.map +1 -1
  341. package/dist/general/index.js +14 -19
  342. package/dist/general/searchBalances.d.ts +27 -67
  343. package/dist/general/searchBalances.d.ts.map +1 -1
  344. package/dist/general/searchBalances.js +25 -21
  345. package/dist/general/utils/tokenBalance/tokenBalance.d.ts +17 -33
  346. package/dist/general/utils/tokenBalance/tokenBalance.d.ts.map +1 -1
  347. package/dist/general/utils/tokenBalance/tokenBalance.js +5 -5
  348. package/dist/issuance/approve.js +1 -1
  349. package/dist/issuance/burn.js +1 -1
  350. package/dist/issuance/common/exports.d.ts +2 -0
  351. package/dist/issuance/common/exports.d.ts.map +1 -0
  352. package/dist/issuance/common/exports.js +1 -0
  353. package/dist/issuance/common/factories.d.ts +167 -0
  354. package/dist/issuance/common/factories.d.ts.map +1 -0
  355. package/dist/issuance/common/factories.js +15 -0
  356. package/dist/issuance/deploy.d.ts +12 -12
  357. package/dist/issuance/deploy.d.ts.map +1 -1
  358. package/dist/issuance/deploy.js +21 -8
  359. package/dist/issuance/erc20/approve.d.ts +32 -0
  360. package/dist/issuance/erc20/approve.d.ts.map +1 -0
  361. package/dist/issuance/erc20/approve.js +38 -0
  362. package/dist/issuance/erc20/burn.d.ts +32 -0
  363. package/dist/issuance/erc20/burn.d.ts.map +1 -0
  364. package/dist/issuance/erc20/burn.js +38 -0
  365. package/dist/issuance/erc20/deploy.d.ts +38 -0
  366. package/dist/issuance/erc20/deploy.d.ts.map +1 -0
  367. package/dist/issuance/erc20/deploy.js +52 -0
  368. package/dist/issuance/erc20/deployGated.d.ts +40 -0
  369. package/dist/issuance/erc20/deployGated.d.ts.map +1 -0
  370. package/dist/issuance/erc20/deployGated.js +58 -0
  371. package/dist/issuance/erc20/getInitData.d.ts +59 -0
  372. package/dist/issuance/erc20/getInitData.d.ts.map +1 -0
  373. package/dist/issuance/erc20/getInitData.js +49 -0
  374. package/dist/issuance/erc20/grantRole.d.ts +33 -0
  375. package/dist/issuance/erc20/grantRole.d.ts.map +1 -0
  376. package/dist/issuance/erc20/grantRole.js +41 -0
  377. package/dist/issuance/erc20/index.d.ts +324 -0
  378. package/dist/issuance/erc20/index.d.ts.map +1 -0
  379. package/dist/issuance/erc20/index.js +31 -0
  380. package/dist/issuance/erc20/initialize.d.ts +40 -0
  381. package/dist/issuance/erc20/initialize.d.ts.map +1 -0
  382. package/dist/issuance/erc20/initialize.js +45 -0
  383. package/dist/issuance/erc20/mint.d.ts +32 -0
  384. package/dist/issuance/erc20/mint.d.ts.map +1 -0
  385. package/dist/issuance/erc20/mint.js +38 -0
  386. package/dist/issuance/erc20/parseErc20DeployEvent.d.ts +23 -0
  387. package/dist/issuance/erc20/parseErc20DeployEvent.d.ts.map +1 -0
  388. package/dist/issuance/erc20/parseErc20DeployEvent.js +79 -0
  389. package/dist/issuance/erc20/recover.d.ts +34 -0
  390. package/dist/issuance/erc20/recover.d.ts.map +1 -0
  391. package/dist/issuance/erc20/recover.js +39 -0
  392. package/dist/issuance/erc20/renounceRole.d.ts +33 -0
  393. package/dist/issuance/erc20/renounceRole.d.ts.map +1 -0
  394. package/dist/issuance/erc20/renounceRole.js +41 -0
  395. package/dist/issuance/erc20/revokeRole.d.ts +33 -0
  396. package/dist/issuance/erc20/revokeRole.d.ts.map +1 -0
  397. package/dist/issuance/erc20/revokeRole.js +41 -0
  398. package/dist/issuance/erc20/transfer.d.ts +32 -0
  399. package/dist/issuance/erc20/transfer.d.ts.map +1 -0
  400. package/dist/issuance/erc20/transfer.js +38 -0
  401. package/dist/issuance/erc20/transferFrom.d.ts +34 -0
  402. package/dist/issuance/erc20/transferFrom.d.ts.map +1 -0
  403. package/dist/issuance/erc20/transferFrom.js +39 -0
  404. package/dist/issuance/erc721/approve.d.ts +32 -0
  405. package/dist/issuance/erc721/approve.d.ts.map +1 -0
  406. package/dist/issuance/erc721/approve.js +38 -0
  407. package/dist/issuance/erc721/burn.d.ts +30 -0
  408. package/dist/issuance/erc721/burn.d.ts.map +1 -0
  409. package/dist/issuance/erc721/burn.js +37 -0
  410. package/dist/issuance/erc721/deploy.d.ts +38 -0
  411. package/dist/issuance/erc721/deploy.d.ts.map +1 -0
  412. package/dist/issuance/erc721/deploy.js +51 -0
  413. package/dist/issuance/erc721/deployGated.d.ts +40 -0
  414. package/dist/issuance/erc721/deployGated.d.ts.map +1 -0
  415. package/dist/issuance/erc721/deployGated.js +58 -0
  416. package/dist/issuance/erc721/getInitData.d.ts +49 -0
  417. package/dist/issuance/erc721/getInitData.d.ts.map +1 -0
  418. package/dist/issuance/erc721/getInitData.js +51 -0
  419. package/dist/issuance/erc721/grantRole.d.ts +33 -0
  420. package/dist/issuance/erc721/grantRole.d.ts.map +1 -0
  421. package/dist/issuance/erc721/grantRole.js +41 -0
  422. package/dist/issuance/erc721/index.d.ts +345 -0
  423. package/dist/issuance/erc721/index.d.ts.map +1 -0
  424. package/dist/issuance/erc721/index.js +33 -0
  425. package/dist/issuance/erc721/initialize.d.ts +38 -0
  426. package/dist/issuance/erc721/initialize.d.ts.map +1 -0
  427. package/dist/issuance/erc721/initialize.js +40 -0
  428. package/dist/issuance/erc721/mint.d.ts +32 -0
  429. package/dist/issuance/erc721/mint.d.ts.map +1 -0
  430. package/dist/issuance/erc721/mint.js +38 -0
  431. package/dist/issuance/erc721/parseErc721DeployEvent.d.ts +23 -0
  432. package/dist/issuance/erc721/parseErc721DeployEvent.d.ts.map +1 -0
  433. package/dist/issuance/erc721/parseErc721DeployEvent.js +78 -0
  434. package/dist/issuance/erc721/recover.d.ts +34 -0
  435. package/dist/issuance/erc721/recover.d.ts.map +1 -0
  436. package/dist/issuance/erc721/recover.js +39 -0
  437. package/dist/issuance/erc721/renounceRole.d.ts +33 -0
  438. package/dist/issuance/erc721/renounceRole.d.ts.map +1 -0
  439. package/dist/issuance/erc721/renounceRole.js +41 -0
  440. package/dist/issuance/erc721/revokeRole.d.ts +33 -0
  441. package/dist/issuance/erc721/revokeRole.d.ts.map +1 -0
  442. package/dist/issuance/erc721/revokeRole.js +41 -0
  443. package/dist/issuance/erc721/setBaseURI.d.ts +30 -0
  444. package/dist/issuance/erc721/setBaseURI.d.ts.map +1 -0
  445. package/dist/issuance/erc721/setBaseURI.js +36 -0
  446. package/dist/issuance/erc721/setTokenURI.d.ts +32 -0
  447. package/dist/issuance/erc721/setTokenURI.d.ts.map +1 -0
  448. package/dist/issuance/erc721/setTokenURI.js +38 -0
  449. package/dist/issuance/erc721/transferFrom.d.ts +34 -0
  450. package/dist/issuance/erc721/transferFrom.d.ts.map +1 -0
  451. package/dist/issuance/erc721/transferFrom.js +39 -0
  452. package/dist/issuance/exports.d.ts +2 -0
  453. package/dist/issuance/exports.d.ts.map +1 -0
  454. package/dist/issuance/exports.js +1 -0
  455. package/dist/issuance/getInitData.d.ts +67 -10
  456. package/dist/issuance/getInitData.d.ts.map +1 -1
  457. package/dist/issuance/getInitData.js +52 -1
  458. package/dist/issuance/grantRole.js +1 -1
  459. package/dist/issuance/index.d.ts +682 -259
  460. package/dist/issuance/index.d.ts.map +1 -1
  461. package/dist/issuance/index.js +12 -33
  462. package/dist/issuance/mint.js +1 -1
  463. package/dist/issuance/proxy/deploy.d.ts +41 -0
  464. package/dist/issuance/proxy/deploy.d.ts.map +1 -0
  465. package/dist/issuance/proxy/deploy.js +68 -0
  466. package/dist/issuance/proxy/index.d.ts +59 -0
  467. package/dist/issuance/proxy/index.d.ts.map +1 -0
  468. package/dist/issuance/proxy/index.js +10 -0
  469. package/dist/issuance/proxy/upgrade.d.ts +34 -0
  470. package/dist/issuance/proxy/upgrade.d.ts.map +1 -0
  471. package/dist/issuance/proxy/upgrade.js +46 -0
  472. package/dist/issuance/recover.js +1 -1
  473. package/dist/issuance/renounceRole.js +1 -1
  474. package/dist/issuance/transfer.js +1 -1
  475. package/dist/next/fractions/index.d.ts +275 -0
  476. package/dist/next/fractions/index.d.ts.map +1 -0
  477. package/dist/next/fractions/index.js +13 -0
  478. package/dist/next/fractions/lending/buyback/buyback.routes.d.ts +27 -0
  479. package/dist/next/fractions/lending/buyback/buyback.routes.d.ts.map +1 -0
  480. package/dist/next/fractions/lending/buyback/buyback.routes.js +28 -0
  481. package/dist/next/fractions/lending/buyback/buyback.schema.d.ts +8 -0
  482. package/dist/next/fractions/lending/buyback/buyback.schema.d.ts.map +1 -0
  483. package/dist/next/fractions/lending/buyback/buyback.schema.js +13 -0
  484. package/dist/next/fractions/lending/createLendingSale.d.ts +130 -0
  485. package/dist/next/fractions/lending/createLendingSale.d.ts.map +1 -0
  486. package/dist/next/fractions/lending/createLendingSale.js +82 -0
  487. package/dist/next/fractions/lending/deployMarket/lending.routes.d.ts +44 -0
  488. package/dist/next/fractions/lending/deployMarket/lending.routes.d.ts.map +1 -0
  489. package/dist/next/fractions/lending/deployMarket/lending.routes.js +40 -0
  490. package/dist/next/fractions/lending/index.d.ts +188 -0
  491. package/dist/next/fractions/lending/index.d.ts.map +1 -0
  492. package/dist/next/fractions/lending/index.js +15 -0
  493. package/dist/next/fractions/lending/purchase/directPurchase.route.d.ts +33 -0
  494. package/dist/next/fractions/lending/purchase/directPurchase.route.d.ts.map +1 -0
  495. package/dist/next/fractions/lending/purchase/directPurchase.route.js +34 -0
  496. package/dist/next/fractions/lending/schemas.d.ts +25 -0
  497. package/dist/next/fractions/lending/schemas.d.ts.map +1 -0
  498. package/dist/next/fractions/lending/schemas.js +21 -0
  499. package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.routes.d.ts +26 -0
  500. package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.routes.d.ts.map +1 -0
  501. package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.routes.js +28 -0
  502. package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.schema.d.ts +7 -0
  503. package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.schema.d.ts.map +1 -0
  504. package/dist/next/fractions/lending/setCollateralPrice/setCollateralPrice.schema.js +11 -0
  505. package/dist/next/fractions/platforms/deployNftFractionsMarket.routes.d.ts +39 -0
  506. package/dist/next/fractions/platforms/deployNftFractionsMarket.routes.d.ts.map +1 -0
  507. package/dist/next/fractions/platforms/deployNftFractionsMarket.routes.js +40 -0
  508. package/dist/next/fractions/platforms/deployNftFractionsMarket.schema.d.ts +26 -0
  509. package/dist/next/fractions/platforms/deployNftFractionsMarket.schema.d.ts.map +1 -0
  510. package/dist/next/fractions/platforms/deployNftFractionsMarket.schema.js +24 -0
  511. package/dist/next/fractions/platforms/index.d.ts +36 -0
  512. package/dist/next/fractions/platforms/index.d.ts.map +1 -0
  513. package/dist/next/fractions/platforms/index.js +5 -0
  514. package/dist/next/fractions/sales/createNftFractions.routes.d.ts +58 -0
  515. package/dist/next/fractions/sales/createNftFractions.routes.d.ts.map +1 -0
  516. package/dist/next/fractions/sales/createNftFractions.routes.js +59 -0
  517. package/dist/next/fractions/sales/createNftFractions.schema.d.ts +85 -0
  518. package/dist/next/fractions/sales/createNftFractions.schema.d.ts.map +1 -0
  519. package/dist/next/fractions/sales/createNftFractions.schema.js +67 -0
  520. package/dist/next/fractions/sales/index.d.ts +55 -0
  521. package/dist/next/fractions/sales/index.d.ts.map +1 -0
  522. package/dist/next/fractions/sales/index.js +5 -0
  523. package/dist/staking/index.d.ts +193 -202
  524. package/dist/staking/index.d.ts.map +1 -1
  525. package/dist/staking/index.js +14 -19
  526. package/dist/staking/platforms/common/platform.d.ts +7 -21
  527. package/dist/staking/platforms/common/platform.d.ts.map +1 -1
  528. package/dist/staking/platforms/common/platform.js +6 -8
  529. package/dist/staking/platforms/getPlatform/index.d.ts +9 -12
  530. package/dist/staking/platforms/getPlatform/index.d.ts.map +1 -1
  531. package/dist/staking/platforms/getPlatform/index.js +5 -4
  532. package/dist/staking/platforms/getPlatform/v0/getPlatform.d.ts +21 -49
  533. package/dist/staking/platforms/getPlatform/v0/getPlatform.d.ts.map +1 -1
  534. package/dist/staking/platforms/getPlatform/v0/getPlatform.js +20 -10
  535. package/dist/staking/platforms/index.d.ts +19 -21
  536. package/dist/staking/platforms/index.d.ts.map +1 -1
  537. package/dist/staking/platforms/index.js +8 -9
  538. package/dist/staking/platforms/searchPlatforms/index.d.ts +11 -14
  539. package/dist/staking/platforms/searchPlatforms/index.d.ts.map +1 -1
  540. package/dist/staking/platforms/searchPlatforms/index.js +5 -4
  541. package/dist/staking/platforms/searchPlatforms/v0/searchPlatforms.d.ts +27 -73
  542. package/dist/staking/platforms/searchPlatforms/v0/searchPlatforms.d.ts.map +1 -1
  543. package/dist/staking/platforms/searchPlatforms/v0/searchPlatforms.js +12 -9
  544. package/dist/staking/pools/common/pool.d.ts +9 -25
  545. package/dist/staking/pools/common/pool.d.ts.map +1 -1
  546. package/dist/staking/pools/common/pool.js +5 -7
  547. package/dist/staking/pools/getPool/index.d.ts +4 -7
  548. package/dist/staking/pools/getPool/index.d.ts.map +1 -1
  549. package/dist/staking/pools/getPool/index.js +5 -4
  550. package/dist/staking/pools/getPool/v0/getPool.d.ts +14 -32
  551. package/dist/staking/pools/getPool/v0/getPool.d.ts.map +1 -1
  552. package/dist/staking/pools/getPool/v0/getPool.js +20 -9
  553. package/dist/staking/pools/index.d.ts +10 -12
  554. package/dist/staking/pools/index.d.ts.map +1 -1
  555. package/dist/staking/pools/index.js +8 -9
  556. package/dist/staking/pools/searchPools/index.d.ts +7 -10
  557. package/dist/staking/pools/searchPools/index.d.ts.map +1 -1
  558. package/dist/staking/pools/searchPools/index.js +5 -4
  559. package/dist/staking/pools/searchPools/v0/searchPools.d.ts +19 -52
  560. package/dist/staking/pools/searchPools/v0/searchPools.d.ts.map +1 -1
  561. package/dist/staking/pools/searchPools/v0/searchPools.js +11 -8
  562. package/dist/staking/roles/common/role.d.ts +4 -10
  563. package/dist/staking/roles/common/role.d.ts.map +1 -1
  564. package/dist/staking/roles/common/role.js +2 -4
  565. package/dist/staking/roles/common/roleAssignment.d.ts +9 -25
  566. package/dist/staking/roles/common/roleAssignment.d.ts.map +1 -1
  567. package/dist/staking/roles/common/roleAssignment.js +5 -7
  568. package/dist/staking/roles/common/roleEvent.d.ts +8 -26
  569. package/dist/staking/roles/common/roleEvent.d.ts.map +1 -1
  570. package/dist/staking/roles/common/roleEvent.js +3 -5
  571. package/dist/staking/roles/getRoles/index.d.ts +3 -6
  572. package/dist/staking/roles/getRoles/index.d.ts.map +1 -1
  573. package/dist/staking/roles/getRoles/index.js +5 -4
  574. package/dist/staking/roles/getRoles/v0/getRoles.d.ts +22 -28
  575. package/dist/staking/roles/getRoles/v0/getRoles.d.ts.map +1 -1
  576. package/dist/staking/roles/getRoles/v0/getRoles.js +9 -6
  577. package/dist/staking/roles/grantRole/index.d.ts +7 -10
  578. package/dist/staking/roles/grantRole/index.d.ts.map +1 -1
  579. package/dist/staking/roles/grantRole/index.js +5 -4
  580. package/dist/staking/roles/grantRole/v0/grantRole.d.ts +23 -60
  581. package/dist/staking/roles/grantRole/v0/grantRole.d.ts.map +1 -1
  582. package/dist/staking/roles/grantRole/v0/grantRole.js +9 -6
  583. package/dist/staking/roles/index.d.ts +25 -27
  584. package/dist/staking/roles/index.d.ts.map +1 -1
  585. package/dist/staking/roles/index.js +12 -13
  586. package/dist/staking/roles/searchRoleEvents/index.d.ts +9 -12
  587. package/dist/staking/roles/searchRoleEvents/index.d.ts.map +1 -1
  588. package/dist/staking/roles/searchRoleEvents/index.js +5 -4
  589. package/dist/staking/roles/searchRoleEvents/v0/searchRoleEvents.d.ts +21 -60
  590. package/dist/staking/roles/searchRoleEvents/v0/searchRoleEvents.d.ts.map +1 -1
  591. package/dist/staking/roles/searchRoleEvents/v0/searchRoleEvents.js +11 -8
  592. package/dist/staking/roles/searchRoles/index.d.ts +9 -12
  593. package/dist/staking/roles/searchRoles/index.d.ts.map +1 -1
  594. package/dist/staking/roles/searchRoles/index.js +5 -4
  595. package/dist/staking/roles/searchRoles/v0/searchRoles.d.ts +21 -60
  596. package/dist/staking/roles/searchRoles/v0/searchRoles.d.ts.map +1 -1
  597. package/dist/staking/roles/searchRoles/v0/searchRoles.js +17 -11
  598. package/dist/staking/stakes/common/stake.d.ts +14 -40
  599. package/dist/staking/stakes/common/stake.d.ts.map +1 -1
  600. package/dist/staking/stakes/common/stake.js +18 -20
  601. package/dist/staking/stakes/common/stakeEvent.d.ts +9 -27
  602. package/dist/staking/stakes/common/stakeEvent.d.ts.map +1 -1
  603. package/dist/staking/stakes/common/stakeEvent.js +4 -6
  604. package/dist/staking/stakes/getStake/index.d.ts +4 -7
  605. package/dist/staking/stakes/getStake/index.d.ts.map +1 -1
  606. package/dist/staking/stakes/getStake/index.js +5 -4
  607. package/dist/staking/stakes/getStake/v0/getStake.d.ts +14 -32
  608. package/dist/staking/stakes/getStake/v0/getStake.d.ts.map +1 -1
  609. package/dist/staking/stakes/getStake/v0/getStake.js +19 -9
  610. package/dist/staking/stakes/index.d.ts +20 -22
  611. package/dist/staking/stakes/index.d.ts.map +1 -1
  612. package/dist/staking/stakes/index.js +10 -11
  613. package/dist/staking/stakes/searchStakeEvents/index.d.ts +9 -12
  614. package/dist/staking/stakes/searchStakeEvents/index.d.ts.map +1 -1
  615. package/dist/staking/stakes/searchStakeEvents/index.js +5 -4
  616. package/dist/staking/stakes/searchStakeEvents/v0/searchStakeEvents.d.ts +21 -60
  617. package/dist/staking/stakes/searchStakeEvents/v0/searchStakeEvents.d.ts.map +1 -1
  618. package/dist/staking/stakes/searchStakeEvents/v0/searchStakeEvents.js +13 -9
  619. package/dist/staking/stakes/searchStakes/index.d.ts +9 -12
  620. package/dist/staking/stakes/searchStakes/index.d.ts.map +1 -1
  621. package/dist/staking/stakes/searchStakes/index.js +5 -4
  622. package/dist/staking/stakes/searchStakes/v0/searchStakes.d.ts +21 -60
  623. package/dist/staking/stakes/searchStakes/v0/searchStakes.d.ts.map +1 -1
  624. package/dist/staking/stakes/searchStakes/v0/searchStakes.js +13 -27
  625. package/dist/staking-templates/index.d.ts +100 -100
  626. package/dist/staking-templates/index.js +1 -1
  627. package/dist/staking-templates/templates/common/amount.d.ts +5 -11
  628. package/dist/staking-templates/templates/common/amount.d.ts.map +1 -1
  629. package/dist/staking-templates/templates/common/amount.js +6 -8
  630. package/dist/staking-templates/templates/common/amountMult.d.ts +2 -2
  631. package/dist/staking-templates/templates/common/amountMult.d.ts.map +1 -1
  632. package/dist/staking-templates/templates/common/amountMult.js +3 -4
  633. package/dist/staking-templates/templates/common/erc20Input.d.ts +4 -10
  634. package/dist/staking-templates/templates/common/erc20Input.d.ts.map +1 -1
  635. package/dist/staking-templates/templates/common/erc20Input.js +4 -6
  636. package/dist/staking-templates/templates/common/erc20Reward.d.ts +4 -10
  637. package/dist/staking-templates/templates/common/erc20Reward.d.ts.map +1 -1
  638. package/dist/staking-templates/templates/common/erc20Reward.js +4 -7
  639. package/dist/staking-templates/templates/common/getCreatePoolEvent.d.ts +2 -2
  640. package/dist/staking-templates/templates/common/getCreatePoolEvent.d.ts.map +1 -1
  641. package/dist/staking-templates/templates/common/getCreatePoolEvent.js +3 -3
  642. package/dist/staking-templates/templates/common/getPlatformDeployEvent.d.ts +2 -2
  643. package/dist/staking-templates/templates/common/getPlatformDeployEvent.js +4 -4
  644. package/dist/staking-templates/templates/common/getReward.d.ts +10 -10
  645. package/dist/staking-templates/templates/common/getReward.d.ts.map +1 -1
  646. package/dist/staking-templates/templates/common/getReward.js +2 -2
  647. package/dist/staking-templates/templates/common/getStakeEvent.d.ts +3 -3
  648. package/dist/staking-templates/templates/common/getStakeEvent.d.ts.map +1 -1
  649. package/dist/staking-templates/templates/common/getStakeEvent.js +4 -4
  650. package/dist/staking-templates/templates/common/lock.d.ts +4 -10
  651. package/dist/staking-templates/templates/common/lock.d.ts.map +1 -1
  652. package/dist/staking-templates/templates/common/lock.js +5 -7
  653. package/dist/staking-templates/templates/common/lockMult.d.ts +2 -2
  654. package/dist/staking-templates/templates/common/lockMult.d.ts.map +1 -1
  655. package/dist/staking-templates/templates/common/lockMult.js +3 -4
  656. package/dist/staking-templates/templates/common/partialUnstake.d.ts +12 -12
  657. package/dist/staking-templates/templates/common/partialUnstake.d.ts.map +1 -1
  658. package/dist/staking-templates/templates/common/partialUnstake.js +4 -4
  659. package/dist/staking-templates/templates/common/rewardDistribution.d.ts +5 -11
  660. package/dist/staking-templates/templates/common/rewardDistribution.d.ts.map +1 -1
  661. package/dist/staking-templates/templates/common/rewardDistribution.js +5 -8
  662. package/dist/staking-templates/templates/common/time.d.ts +1 -1
  663. package/dist/staking-templates/templates/common/time.d.ts.map +1 -1
  664. package/dist/staking-templates/templates/common/time.js +2 -2
  665. package/dist/staking-templates/templates/common/unstake.d.ts +10 -10
  666. package/dist/staking-templates/templates/common/unstake.d.ts.map +1 -1
  667. package/dist/staking-templates/templates/common/unstake.js +2 -2
  668. package/dist/staking-templates/templates/reputation/index.d.ts +30 -30
  669. package/dist/staking-templates/templates/reputation/v0/createPlatform.d.ts +11 -11
  670. package/dist/staking-templates/templates/reputation/v0/createPlatform.js +3 -3
  671. package/dist/staking-templates/templates/reputation/v0/createPool.d.ts +24 -24
  672. package/dist/staking-templates/templates/reputation/v0/createPool.d.ts.map +1 -1
  673. package/dist/staking-templates/templates/reputation/v0/createPool.js +6 -6
  674. package/dist/staking-templates/templates/reputation/v0/index.d.ts +30 -30
  675. package/dist/staking-templates/templates/reputation/v0/index.js +5 -5
  676. package/dist/staking-templates/templates/reputation/v0/restake.d.ts +11 -11
  677. package/dist/staking-templates/templates/reputation/v0/restake.js +4 -4
  678. package/dist/staking-templates/templates/reputation/v0/stake.d.ts +12 -12
  679. package/dist/staking-templates/templates/reputation/v0/stake.d.ts.map +1 -1
  680. package/dist/staking-templates/templates/reputation/v0/stake.js +5 -5
  681. package/dist/staking-templates/templates/reputationLock/index.d.ts +37 -37
  682. package/dist/staking-templates/templates/reputationLock/v0/createPlatform.d.ts +11 -11
  683. package/dist/staking-templates/templates/reputationLock/v0/createPlatform.js +3 -3
  684. package/dist/staking-templates/templates/reputationLock/v0/createPool.d.ts +36 -36
  685. package/dist/staking-templates/templates/reputationLock/v0/createPool.d.ts.map +1 -1
  686. package/dist/staking-templates/templates/reputationLock/v0/createPool.js +7 -7
  687. package/dist/staking-templates/templates/reputationLock/v0/index.d.ts +37 -37
  688. package/dist/staking-templates/templates/reputationLock/v0/index.js +5 -5
  689. package/dist/staking-templates/templates/reputationLock/v0/restake.d.ts +13 -13
  690. package/dist/staking-templates/templates/reputationLock/v0/restake.js +5 -5
  691. package/dist/staking-templates/templates/reputationLock/v0/stake.d.ts +14 -14
  692. package/dist/staking-templates/templates/reputationLock/v0/stake.d.ts.map +1 -1
  693. package/dist/staking-templates/templates/reputationLock/v0/stake.js +5 -5
  694. package/dist/staking-templates/templates/rwa/index.d.ts +33 -33
  695. package/dist/staking-templates/templates/rwa/v0/createPlatform.d.ts +11 -11
  696. package/dist/staking-templates/templates/rwa/v0/createPlatform.js +3 -3
  697. package/dist/staking-templates/templates/rwa/v0/createPool.d.ts +20 -20
  698. package/dist/staking-templates/templates/rwa/v0/createPool.d.ts.map +1 -1
  699. package/dist/staking-templates/templates/rwa/v0/createPool.js +4 -4
  700. package/dist/staking-templates/templates/rwa/v0/distributeRewards.d.ts +12 -12
  701. package/dist/staking-templates/templates/rwa/v0/distributeRewards.d.ts.map +1 -1
  702. package/dist/staking-templates/templates/rwa/v0/distributeRewards.js +4 -4
  703. package/dist/staking-templates/templates/rwa/v0/index.d.ts +33 -33
  704. package/dist/staking-templates/templates/rwa/v0/index.js +5 -5
  705. package/dist/staking-templates/templates/rwa/v0/restake.d.ts +11 -11
  706. package/dist/staking-templates/templates/rwa/v0/restake.js +4 -4
  707. package/dist/staking-templates/templates/rwa/v0/stake.d.ts +12 -12
  708. package/dist/staking-templates/templates/rwa/v0/stake.d.ts.map +1 -1
  709. package/dist/staking-templates/templates/rwa/v0/stake.js +5 -5
  710. package/dist/stakingTemplates/index.d.ts +723 -0
  711. package/dist/stakingTemplates/index.d.ts.map +1 -0
  712. package/dist/stakingTemplates/index.js +13 -0
  713. package/dist/stakingTemplates/templates/common/amount.d.ts +7 -0
  714. package/dist/stakingTemplates/templates/common/amount.d.ts.map +1 -0
  715. package/dist/stakingTemplates/templates/common/amount.js +15 -0
  716. package/dist/stakingTemplates/templates/common/amountMult.d.ts +3 -0
  717. package/dist/stakingTemplates/templates/common/amountMult.d.ts.map +1 -0
  718. package/dist/stakingTemplates/templates/common/amountMult.js +24 -0
  719. package/dist/stakingTemplates/templates/common/erc20Input.d.ts +6 -0
  720. package/dist/stakingTemplates/templates/common/erc20Input.d.ts.map +1 -0
  721. package/dist/stakingTemplates/templates/common/erc20Input.js +16 -0
  722. package/dist/stakingTemplates/templates/common/erc20Reward.d.ts +6 -0
  723. package/dist/stakingTemplates/templates/common/erc20Reward.d.ts.map +1 -0
  724. package/dist/stakingTemplates/templates/common/erc20Reward.js +15 -0
  725. package/dist/stakingTemplates/templates/common/getCreatePoolEvent.d.ts +17 -0
  726. package/dist/stakingTemplates/templates/common/getCreatePoolEvent.d.ts.map +1 -0
  727. package/dist/stakingTemplates/templates/common/getCreatePoolEvent.js +51 -0
  728. package/dist/stakingTemplates/templates/common/getPlatformDeployEvent.d.ts +20 -0
  729. package/dist/stakingTemplates/templates/common/getPlatformDeployEvent.d.ts.map +1 -0
  730. package/dist/stakingTemplates/templates/common/getPlatformDeployEvent.js +49 -0
  731. package/dist/stakingTemplates/templates/common/getReward.d.ts +26 -0
  732. package/dist/stakingTemplates/templates/common/getReward.d.ts.map +1 -0
  733. package/dist/stakingTemplates/templates/common/getReward.js +37 -0
  734. package/dist/stakingTemplates/templates/common/getStakeEvent.d.ts +17 -0
  735. package/dist/stakingTemplates/templates/common/getStakeEvent.d.ts.map +1 -0
  736. package/dist/stakingTemplates/templates/common/getStakeEvent.js +55 -0
  737. package/dist/stakingTemplates/templates/common/lock.d.ts +6 -0
  738. package/dist/stakingTemplates/templates/common/lock.d.ts.map +1 -0
  739. package/dist/stakingTemplates/templates/common/lock.js +18 -0
  740. package/dist/stakingTemplates/templates/common/lockMult.d.ts +3 -0
  741. package/dist/stakingTemplates/templates/common/lockMult.d.ts.map +1 -0
  742. package/dist/stakingTemplates/templates/common/lockMult.js +16 -0
  743. package/dist/stakingTemplates/templates/common/partialUnstake.d.ts +27 -0
  744. package/dist/stakingTemplates/templates/common/partialUnstake.d.ts.map +1 -0
  745. package/dist/stakingTemplates/templates/common/partialUnstake.js +42 -0
  746. package/dist/stakingTemplates/templates/common/rewardDistribution.d.ts +7 -0
  747. package/dist/stakingTemplates/templates/common/rewardDistribution.d.ts.map +1 -0
  748. package/dist/stakingTemplates/templates/common/rewardDistribution.js +16 -0
  749. package/dist/stakingTemplates/templates/common/templates.d.ts +61 -0
  750. package/dist/stakingTemplates/templates/common/templates.d.ts.map +1 -0
  751. package/dist/stakingTemplates/templates/common/templates.js +8 -0
  752. package/dist/stakingTemplates/templates/common/time.d.ts +2 -0
  753. package/dist/stakingTemplates/templates/common/time.d.ts.map +1 -0
  754. package/dist/stakingTemplates/templates/common/time.js +4 -0
  755. package/dist/stakingTemplates/templates/common/unstake.d.ts +26 -0
  756. package/dist/stakingTemplates/templates/common/unstake.d.ts.map +1 -0
  757. package/dist/stakingTemplates/templates/common/unstake.js +37 -0
  758. package/dist/stakingTemplates/templates/reputation/common.d.ts +23 -0
  759. package/dist/stakingTemplates/templates/reputation/common.d.ts.map +1 -0
  760. package/dist/stakingTemplates/templates/reputation/common.js +3 -0
  761. package/dist/stakingTemplates/templates/reputation/index.d.ts +231 -0
  762. package/dist/stakingTemplates/templates/reputation/index.d.ts.map +1 -0
  763. package/dist/stakingTemplates/templates/reputation/index.js +5 -0
  764. package/dist/stakingTemplates/templates/reputation/v0/createPlatform.d.ts +31 -0
  765. package/dist/stakingTemplates/templates/reputation/v0/createPlatform.d.ts.map +1 -0
  766. package/dist/stakingTemplates/templates/reputation/v0/createPlatform.js +57 -0
  767. package/dist/stakingTemplates/templates/reputation/v0/createPool.d.ts +39 -0
  768. package/dist/stakingTemplates/templates/reputation/v0/createPool.d.ts.map +1 -0
  769. package/dist/stakingTemplates/templates/reputation/v0/createPool.js +86 -0
  770. package/dist/stakingTemplates/templates/reputation/v0/index.d.ts +231 -0
  771. package/dist/stakingTemplates/templates/reputation/v0/index.d.ts.map +1 -0
  772. package/dist/stakingTemplates/templates/reputation/v0/index.js +26 -0
  773. package/dist/stakingTemplates/templates/reputation/v0/restake.d.ts +26 -0
  774. package/dist/stakingTemplates/templates/reputation/v0/restake.d.ts.map +1 -0
  775. package/dist/stakingTemplates/templates/reputation/v0/restake.js +41 -0
  776. package/dist/stakingTemplates/templates/reputation/v0/stake.d.ts +26 -0
  777. package/dist/stakingTemplates/templates/reputation/v0/stake.d.ts.map +1 -0
  778. package/dist/stakingTemplates/templates/reputation/v0/stake.js +46 -0
  779. package/dist/stakingTemplates/templates/reputationLock/common.d.ts +23 -0
  780. package/dist/stakingTemplates/templates/reputationLock/common.d.ts.map +1 -0
  781. package/dist/stakingTemplates/templates/reputationLock/common.js +3 -0
  782. package/dist/stakingTemplates/templates/reputationLock/index.d.ts +242 -0
  783. package/dist/stakingTemplates/templates/reputationLock/index.d.ts.map +1 -0
  784. package/dist/stakingTemplates/templates/reputationLock/index.js +5 -0
  785. package/dist/stakingTemplates/templates/reputationLock/v0/createPlatform.d.ts +31 -0
  786. package/dist/stakingTemplates/templates/reputationLock/v0/createPlatform.d.ts.map +1 -0
  787. package/dist/stakingTemplates/templates/reputationLock/v0/createPlatform.js +57 -0
  788. package/dist/stakingTemplates/templates/reputationLock/v0/createPool.d.ts +48 -0
  789. package/dist/stakingTemplates/templates/reputationLock/v0/createPool.d.ts.map +1 -0
  790. package/dist/stakingTemplates/templates/reputationLock/v0/createPool.js +100 -0
  791. package/dist/stakingTemplates/templates/reputationLock/v0/index.d.ts +242 -0
  792. package/dist/stakingTemplates/templates/reputationLock/v0/index.d.ts.map +1 -0
  793. package/dist/stakingTemplates/templates/reputationLock/v0/index.js +26 -0
  794. package/dist/stakingTemplates/templates/reputationLock/v0/restake.d.ts +27 -0
  795. package/dist/stakingTemplates/templates/reputationLock/v0/restake.d.ts.map +1 -0
  796. package/dist/stakingTemplates/templates/reputationLock/v0/restake.js +45 -0
  797. package/dist/stakingTemplates/templates/reputationLock/v0/stake.d.ts +27 -0
  798. package/dist/stakingTemplates/templates/reputationLock/v0/stake.d.ts.map +1 -0
  799. package/dist/stakingTemplates/templates/reputationLock/v0/stake.js +47 -0
  800. package/dist/stakingTemplates/templates/rwa/common.d.ts +23 -0
  801. package/dist/stakingTemplates/templates/rwa/common.d.ts.map +1 -0
  802. package/dist/stakingTemplates/templates/rwa/common.js +3 -0
  803. package/dist/stakingTemplates/templates/rwa/index.d.ts +254 -0
  804. package/dist/stakingTemplates/templates/rwa/index.d.ts.map +1 -0
  805. package/dist/stakingTemplates/templates/rwa/index.js +5 -0
  806. package/dist/stakingTemplates/templates/rwa/v0/createPlatform.d.ts +31 -0
  807. package/dist/stakingTemplates/templates/rwa/v0/createPlatform.d.ts.map +1 -0
  808. package/dist/stakingTemplates/templates/rwa/v0/createPlatform.js +57 -0
  809. package/dist/stakingTemplates/templates/rwa/v0/createPool.d.ts +38 -0
  810. package/dist/stakingTemplates/templates/rwa/v0/createPool.d.ts.map +1 -0
  811. package/dist/stakingTemplates/templates/rwa/v0/createPool.js +80 -0
  812. package/dist/stakingTemplates/templates/rwa/v0/distributeRewards.d.ts +26 -0
  813. package/dist/stakingTemplates/templates/rwa/v0/distributeRewards.d.ts.map +1 -0
  814. package/dist/stakingTemplates/templates/rwa/v0/distributeRewards.js +42 -0
  815. package/dist/stakingTemplates/templates/rwa/v0/index.d.ts +254 -0
  816. package/dist/stakingTemplates/templates/rwa/v0/index.d.ts.map +1 -0
  817. package/dist/stakingTemplates/templates/rwa/v0/index.js +28 -0
  818. package/dist/stakingTemplates/templates/rwa/v0/restake.d.ts +26 -0
  819. package/dist/stakingTemplates/templates/rwa/v0/restake.d.ts.map +1 -0
  820. package/dist/stakingTemplates/templates/rwa/v0/restake.js +41 -0
  821. package/dist/stakingTemplates/templates/rwa/v0/stake.d.ts +26 -0
  822. package/dist/stakingTemplates/templates/rwa/v0/stake.d.ts.map +1 -0
  823. package/dist/stakingTemplates/templates/rwa/v0/stake.js +46 -0
  824. package/dist/v0/fractions/index.d.ts +76 -15
  825. package/dist/v0/fractions/index.d.ts.map +1 -1
  826. package/dist/v0/fractions/networkStatistics.route.d.ts +208 -87
  827. package/dist/v0/fractions/networkStatistics.route.d.ts.map +1 -1
  828. package/dist/v0/fractions/networkStatistics.route.js +99 -228
  829. package/dist/v1/fractions/lending/buyback/buyback.routes.d.ts +17 -17
  830. package/dist/v1/fractions/lending/buyback/buyback.routes.js +2 -2
  831. package/dist/v1/fractions/lending/buyback/buyback.schema.d.ts +5 -16
  832. package/dist/v1/fractions/lending/buyback/buyback.schema.d.ts.map +1 -1
  833. package/dist/v1/fractions/lending/buyback/buyback.schema.js +5 -4
  834. package/dist/v1/fractions/lending/createLendingSale.d.ts +124 -406
  835. package/dist/v1/fractions/lending/createLendingSale.d.ts.map +1 -1
  836. package/dist/v1/fractions/lending/createLendingSale.js +20 -22
  837. package/dist/v1/fractions/lending/deployMarket/lending.routes.d.ts +37 -41
  838. package/dist/v1/fractions/lending/deployMarket/lending.routes.d.ts.map +1 -1
  839. package/dist/v1/fractions/lending/deployMarket/lending.routes.js +13 -7
  840. package/dist/v1/fractions/lending/index.d.ts +55 -72
  841. package/dist/v1/fractions/lending/index.d.ts.map +1 -1
  842. package/dist/v1/fractions/lending/index.js +2 -2
  843. package/dist/v1/fractions/lending/purchase/directPurchase.route.d.ts +23 -34
  844. package/dist/v1/fractions/lending/purchase/directPurchase.route.d.ts.map +1 -1
  845. package/dist/v1/fractions/lending/purchase/directPurchase.route.js +9 -12
  846. package/dist/v1/fractions/lending/setCollateralPrice/setCollateralPrice.routes.d.ts +13 -13
  847. package/dist/v1/fractions/lending/setCollateralPrice/setCollateralPrice.routes.js +2 -2
  848. package/dist/v1/fractions/lending/setCollateralPrice/setCollateralPrice.schema.d.ts +4 -13
  849. package/dist/v1/fractions/lending/setCollateralPrice/setCollateralPrice.schema.d.ts.map +1 -1
  850. package/dist/v1/fractions/lending/setCollateralPrice/setCollateralPrice.schema.js +3 -2
  851. package/dist/v1/fractions/schemas.d.ts +14 -102
  852. package/dist/v1/fractions/schemas.d.ts.map +1 -1
  853. package/dist/v1/fractions/schemas.js +13 -28
  854. package/package.json +23 -19
@@ -0,0 +1,35 @@
1
+ import { describeRoute } from "hono-openapi";
2
+ import { resolver, validator } from "hono-openapi";
3
+ import { z } from "zod";
4
+ import { buildFinishSaleTx } from "@evergonlabs/tmi-protocol-fractions-sdk";
5
+ import { createController } from "../../common/controller.js";
6
+ import { AddressSchema, toTransaction, TransactionSchema } from "../../common/index.js";
7
+ import { Int256BigInt } from "../../common/int256.js";
8
+ export const CompleteSaleRequestSchema = z.object({
9
+ marketAddress: AddressSchema,
10
+ campaignId: Int256BigInt(z.bigint().nonnegative()),
11
+ });
12
+ const route = describeRoute({
13
+ summary: "Complete a sale",
14
+ description: "Returns transaction data for completing a sale",
15
+ tags: ["Fractions"],
16
+ responses: {
17
+ 200: {
18
+ description: "Returns transaction data for completing a sale",
19
+ content: {
20
+ "application/json": {
21
+ schema: resolver(TransactionSchema),
22
+ },
23
+ },
24
+ },
25
+ },
26
+ });
27
+ export const CompleteSaleV0 = createController({
28
+ build: (factory) => factory
29
+ .createApp()
30
+ .post("/", route, validator("json", CompleteSaleRequestSchema.openapi("CompleteSaleRequestSchema")), async (c) => {
31
+ const { marketAddress, campaignId } = c.req.valid("json");
32
+ const tx = buildFinishSaleTx({ market: marketAddress, campaignId: campaignId });
33
+ return c.json(toTransaction(tx));
34
+ }),
35
+ });
@@ -0,0 +1,71 @@
1
+ export declare const CreateFractionsV0: import("../../common/controller.js").IController<import("hono/hono-base").HonoBase<import("../../common/context.js").AppContext, {
2
+ "/": {
3
+ $post: {
4
+ input: {
5
+ json: {
6
+ chainId: unknown;
7
+ market: string;
8
+ fractions: {
9
+ symbol: string;
10
+ name: string;
11
+ amount: string;
12
+ token?: string | undefined;
13
+ };
14
+ timeBoundary: {
15
+ start: string;
16
+ end: string;
17
+ };
18
+ cap: {
19
+ soft: string;
20
+ hard: string;
21
+ softPerAccount?: string | undefined;
22
+ hardPerAccount?: string | undefined;
23
+ };
24
+ wrapped: ({
25
+ type: "ERC20";
26
+ address: string;
27
+ values: string[];
28
+ } | {
29
+ type: "ERC721";
30
+ address: string;
31
+ tokenIds: string[];
32
+ } | {
33
+ type: "ERC1155";
34
+ address: string;
35
+ tokenIds: string[];
36
+ values: string[];
37
+ })[];
38
+ funding: {
39
+ token: string;
40
+ amountPerPacket: string;
41
+ }[];
42
+ refundAddress: string;
43
+ amountOfPacketsPerFraction: string;
44
+ discounts?: {
45
+ burnableTokenAddress: string;
46
+ amountToBurn: string;
47
+ percentDiscount: number;
48
+ } | undefined;
49
+ vesting?: {
50
+ cliff: string;
51
+ totalVestingPeriod: number;
52
+ portionPeriod: number;
53
+ } | undefined;
54
+ };
55
+ };
56
+ output: {
57
+ data: `0x${string}`;
58
+ to: `0x${string}`;
59
+ details: {
60
+ functionName: string;
61
+ address: `0x${string}`;
62
+ abi: any[];
63
+ args: any[];
64
+ };
65
+ };
66
+ outputFormat: "json";
67
+ status: import("hono/utils/http-status").ContentfulStatusCode;
68
+ };
69
+ };
70
+ }, "/">>;
71
+ //# sourceMappingURL=createFractions.route.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createFractions.route.d.ts","sourceRoot":"","sources":["../../../src/fractions/sales/createFractions.route.ts"],"names":[],"mappings":"AAuBA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAmD5B,CAAC"}
@@ -0,0 +1,51 @@
1
+ import { describeRoute } from "hono-openapi";
2
+ import { resolver, validator } from "hono-openapi";
3
+ import { buildCreateFractionsTx } from "@evergonlabs/tmi-protocol-fractions-sdk";
4
+ import { createController } from "../../common/controller.js";
5
+ import { toTransaction, TransactionSchema } from "../../common/index.js";
6
+ import { CreateFractionsRequestSchema, createWrapped } from "./createFractions.schema.js";
7
+ const route = describeRoute({
8
+ summary: "Create fractions",
9
+ description: "Returns transaction data for creating fractions",
10
+ tags: ["Fractions"],
11
+ responses: {
12
+ 200: {
13
+ description: "Returns transaction data for creating fractions",
14
+ content: {
15
+ "application/json": {
16
+ schema: resolver(TransactionSchema),
17
+ },
18
+ },
19
+ },
20
+ },
21
+ });
22
+ export const CreateFractionsV0 = createController({
23
+ build: (factory) => factory
24
+ .createApp()
25
+ .post("/", route, validator("json", CreateFractionsRequestSchema.openapi("CreateFractionsRequestSchema")), async (c) => {
26
+ const { chainId, market, wrapped, funding, fractions, timeBoundary, cap, vesting, amountOfPacketsPerFraction, refundAddress, discounts, } = c.req.valid("json");
27
+ const wrappedTokens = wrapped.map(createWrapped);
28
+ const fractionsConfig = {
29
+ chainId: chainId,
30
+ market: market,
31
+ wrapped: wrappedTokens,
32
+ funding: funding,
33
+ fractions: {
34
+ name: fractions.name,
35
+ symbol: fractions.symbol,
36
+ amount: fractions.amount,
37
+ },
38
+ timeBoundary: {
39
+ start: new Date(timeBoundary.start),
40
+ end: new Date(timeBoundary.end),
41
+ },
42
+ discounts: discounts,
43
+ cap: cap,
44
+ amountOfPacketsPerFraction: amountOfPacketsPerFraction,
45
+ refundAddress: refundAddress,
46
+ vesting: vesting,
47
+ };
48
+ const tx = buildCreateFractionsTx(fractionsConfig);
49
+ return c.json(toTransaction(tx));
50
+ }),
51
+ });
@@ -0,0 +1,123 @@
1
+ import { z } from "zod";
2
+ export declare const TimeBoundarySchema: z.ZodObject<{
3
+ start: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "ISO", "out">, z.ZodTransform<Date, string & z.core.$brand<"ISO">>>;
4
+ end: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "ISO", "out">, z.ZodTransform<Date, string & z.core.$brand<"ISO">>>;
5
+ }, z.core.$strip>;
6
+ export declare const CapitalizationSchema: z.ZodObject<{
7
+ soft: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
8
+ hard: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
9
+ softPerAccount: z.ZodOptional<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
10
+ hardPerAccount: z.ZodOptional<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
11
+ }, z.core.$strip>;
12
+ export declare const ERC20TokenSchema: z.ZodObject<{
13
+ type: z.ZodLiteral<"ERC20">;
14
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
15
+ values: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
16
+ }, z.core.$strip>;
17
+ export declare const ERC721TokenSchema: z.ZodObject<{
18
+ type: z.ZodLiteral<"ERC721">;
19
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
20
+ tokenIds: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
21
+ }, z.core.$strip>;
22
+ export declare const ERC1155TokenSchema: z.ZodObject<{
23
+ type: z.ZodLiteral<"ERC1155">;
24
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
25
+ tokenIds: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
26
+ values: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
27
+ }, z.core.$strip>;
28
+ export declare const WrappedTokenTypeSchema: z.ZodUnion<readonly [z.ZodObject<{
29
+ type: z.ZodLiteral<"ERC20">;
30
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
31
+ values: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
32
+ }, z.core.$strip>, z.ZodObject<{
33
+ type: z.ZodLiteral<"ERC721">;
34
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
35
+ tokenIds: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
36
+ }, z.core.$strip>, z.ZodObject<{
37
+ type: z.ZodLiteral<"ERC1155">;
38
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
39
+ tokenIds: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
40
+ values: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
41
+ }, z.core.$strip>]>;
42
+ export declare const FundingSchema: z.ZodObject<{
43
+ token: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
44
+ amountPerPacket: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
45
+ }, z.core.$strip>;
46
+ export declare const FractionSchema: z.ZodObject<{
47
+ token: z.ZodOptional<z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>>;
48
+ symbol: z.ZodString;
49
+ name: z.ZodString;
50
+ amount: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
51
+ }, z.core.$strip>;
52
+ export declare const BurnForDiscountSchema: z.ZodObject<{
53
+ burnableTokenAddress: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
54
+ amountToBurn: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
55
+ percentDiscount: z.ZodNumber;
56
+ }, z.core.$strip>;
57
+ export declare const VestingSchema: z.ZodObject<{
58
+ cliff: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "ISO", "out">, z.ZodTransform<Date, string & z.core.$brand<"ISO">>>;
59
+ totalVestingPeriod: z.ZodNumber;
60
+ portionPeriod: z.ZodNumber;
61
+ }, z.core.$strip>;
62
+ export declare const CreateFractionsRequestSchema: z.ZodObject<{
63
+ chainId: z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodUnion<[z.ZodLiteral<1 | 11155111 | 31337 | 72080>, z.ZodLiteral<1 | 11155111 | 31337 | 72080>, ...z.ZodLiteral<1 | 11155111 | 31337 | 72080>[]]>>;
64
+ market: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
65
+ fractions: z.ZodObject<{
66
+ token: z.ZodOptional<z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>>;
67
+ symbol: z.ZodString;
68
+ name: z.ZodString;
69
+ amount: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
70
+ }, z.core.$strip>;
71
+ timeBoundary: z.ZodObject<{
72
+ start: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "ISO", "out">, z.ZodTransform<Date, string & z.core.$brand<"ISO">>>;
73
+ end: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "ISO", "out">, z.ZodTransform<Date, string & z.core.$brand<"ISO">>>;
74
+ }, z.core.$strip>;
75
+ cap: z.ZodObject<{
76
+ soft: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
77
+ hard: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
78
+ softPerAccount: z.ZodOptional<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
79
+ hardPerAccount: z.ZodOptional<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
80
+ }, z.core.$strip>;
81
+ wrapped: z.ZodArray<z.ZodUnion<readonly [z.ZodObject<{
82
+ type: z.ZodLiteral<"ERC20">;
83
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
84
+ values: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
85
+ }, z.core.$strip>, z.ZodObject<{
86
+ type: z.ZodLiteral<"ERC721">;
87
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
88
+ tokenIds: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
89
+ }, z.core.$strip>, z.ZodObject<{
90
+ type: z.ZodLiteral<"ERC1155">;
91
+ address: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
92
+ tokenIds: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
93
+ values: z.ZodArray<z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>>;
94
+ }, z.core.$strip>]>>;
95
+ funding: z.ZodArray<z.ZodObject<{
96
+ token: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
97
+ amountPerPacket: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
98
+ }, z.core.$strip>>;
99
+ discounts: z.ZodOptional<z.ZodObject<{
100
+ burnableTokenAddress: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
101
+ amountToBurn: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
102
+ percentDiscount: z.ZodNumber;
103
+ }, z.core.$strip>>;
104
+ vesting: z.ZodOptional<z.ZodObject<{
105
+ cliff: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "ISO", "out">, z.ZodTransform<Date, string & z.core.$brand<"ISO">>>;
106
+ totalVestingPeriod: z.ZodNumber;
107
+ portionPeriod: z.ZodNumber;
108
+ }, z.core.$strip>>;
109
+ refundAddress: z.ZodPipe<z.ZodString & z.ZodType<`0x${string}`, string, z.core.$ZodTypeInternals<`0x${string}`, string>>, z.ZodTransform<`0x${string}`, `0x${string}`>>;
110
+ amountOfPacketsPerFraction: z.ZodPipe<z.core.$ZodBranded<z.ZodString, "Int256", "out">, z.ZodTransform<bigint, string & z.core.$brand<"Int256">>>;
111
+ }, z.core.$strip>;
112
+ export declare function createWrapped(token: z.infer<typeof WrappedTokenTypeSchema>): {
113
+ type: import("@evergonlabs/tmi-protocol-types/evm").TokenTypeEnum;
114
+ tokenAddress: `0x${string}`;
115
+ amount: bigint;
116
+ toParams: () => readonly [readonly [`0x${string}`], readonly [bigint], readonly [bigint], readonly [bigint]];
117
+ } | {
118
+ type: import("@evergonlabs/tmi-protocol-types/evm").TokenTypeEnum;
119
+ tokenAddress: `0x${string}`;
120
+ tokenIds: bigint[];
121
+ toParams: () => readonly [`0x${string}`[], bigint[], bigint[], bigint[]];
122
+ };
123
+ //# sourceMappingURL=createFractions.schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createFractions.schema.d.ts","sourceRoot":"","sources":["../../../src/fractions/sales/createFractions.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,eAAO,MAAM,kBAAkB;;;iBAG7B,CAAC;AAGH,eAAO,MAAM,oBAAoB;;;;;iBAK/B,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;iBAI3B,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;iBAI5B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;iBAK7B,CAAC;AAGH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;mBAAqE,CAAC;AAGzG,eAAO,MAAM,aAAa;;;iBAGxB,CAAC;AAEH,eAAO,MAAM,cAAc;;;;;iBAKzB,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;iBAIhC,CAAC;AAEH,eAAO,MAAM,aAAa;;;;iBAIxB,CAAC;AAEH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAYvC,CAAC;AAEH,wBAAgB,aAAa,CAAC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC;;;;;;;;;;EAS1E"}
@@ -0,0 +1,80 @@
1
+ import { z } from "zod";
2
+ import { createWrappedErc20, createWrappedErc721, createWrappedErc1155 } from "@evergonlabs/tmi-protocol-fractions-sdk";
3
+ import { AddressSchema, FractionsChainId } from "../../common/index.js";
4
+ import { Int256BigInt } from "../../common/int256.js";
5
+ import { ISODate } from "../../common/models/date.js";
6
+ import { PercentageSchema } from "../../common/models/index.js";
7
+ // TimeBoundarySchema: Represents a time range with start and end dates
8
+ export const TimeBoundarySchema = z.object({
9
+ start: ISODate(),
10
+ end: ISODate(),
11
+ });
12
+ // CapitalizationSchema: Represents the capitalization details of a market
13
+ export const CapitalizationSchema = z.object({
14
+ soft: Int256BigInt(z.bigint().positive()),
15
+ hard: Int256BigInt(z.bigint().positive()),
16
+ softPerAccount: Int256BigInt(z.bigint().positive()).optional(),
17
+ hardPerAccount: Int256BigInt(z.bigint().positive()).optional(),
18
+ });
19
+ export const ERC20TokenSchema = z.object({
20
+ type: z.literal("ERC20"),
21
+ address: AddressSchema,
22
+ values: Int256BigInt().array().nonempty(),
23
+ });
24
+ export const ERC721TokenSchema = z.object({
25
+ type: z.literal("ERC721"),
26
+ address: AddressSchema,
27
+ tokenIds: Int256BigInt().array().nonempty(),
28
+ });
29
+ export const ERC1155TokenSchema = z.object({
30
+ type: z.literal("ERC1155"),
31
+ address: AddressSchema,
32
+ tokenIds: Int256BigInt().array().nonempty(),
33
+ values: Int256BigInt().array().nonempty(),
34
+ });
35
+ // Union schema to represent any of the three token types
36
+ export const WrappedTokenTypeSchema = z.union([ERC20TokenSchema, ERC721TokenSchema, ERC1155TokenSchema]);
37
+ // FundingSchema: Represents funding details for a market
38
+ export const FundingSchema = z.object({
39
+ token: AddressSchema,
40
+ amountPerPacket: Int256BigInt(z.bigint().positive()),
41
+ });
42
+ export const FractionSchema = z.object({
43
+ token: AddressSchema.optional().describe("DO NOT USE. This field will be removed"),
44
+ symbol: z.string(),
45
+ name: z.string(),
46
+ amount: Int256BigInt(z.bigint().positive()),
47
+ });
48
+ export const BurnForDiscountSchema = z.object({
49
+ burnableTokenAddress: AddressSchema,
50
+ amountToBurn: Int256BigInt(z.bigint().positive()),
51
+ percentDiscount: PercentageSchema,
52
+ });
53
+ export const VestingSchema = z.object({
54
+ cliff: ISODate(),
55
+ totalVestingPeriod: z.number().positive(),
56
+ portionPeriod: z.number().positive(),
57
+ });
58
+ export const CreateFractionsRequestSchema = z.object({
59
+ chainId: FractionsChainId,
60
+ market: AddressSchema,
61
+ fractions: FractionSchema,
62
+ timeBoundary: TimeBoundarySchema,
63
+ cap: CapitalizationSchema,
64
+ wrapped: z.array(WrappedTokenTypeSchema).nonempty(),
65
+ funding: z.array(FundingSchema).nonempty(),
66
+ discounts: BurnForDiscountSchema.optional(),
67
+ vesting: VestingSchema.optional(),
68
+ refundAddress: AddressSchema,
69
+ amountOfPacketsPerFraction: Int256BigInt(z.bigint().positive()),
70
+ });
71
+ export function createWrapped(token) {
72
+ switch (token.type) {
73
+ case "ERC20":
74
+ return createWrappedErc20(token.address, token.values[0]);
75
+ case "ERC721":
76
+ return createWrappedErc721(token.address, token.tokenIds);
77
+ case "ERC1155":
78
+ return createWrappedErc1155(token.address, token.tokenIds, token.values);
79
+ }
80
+ }
@@ -0,0 +1,180 @@
1
+ import { Env } from "hono";
2
+ import { Factory } from "hono/factory";
3
+ /**
4
+ * Creates handlers for the create NFT fractions endpoint
5
+ */
6
+ export declare function createNftFractionsTransactionV0<E extends Env>(factory: Factory<E>): [import("hono/types").H<any, string, {}, Promise<Response & import("hono").TypedResponse<{
7
+ data: `0x${string}`;
8
+ to: `0x${string}`;
9
+ details: {
10
+ functionName: string;
11
+ address: `0x${string}`;
12
+ abi: any[];
13
+ args: any[];
14
+ };
15
+ }, import("hono/utils/http-status").ContentfulStatusCode, "json">>>, import("hono/types").H<Env, string, {
16
+ in: {
17
+ json: {
18
+ chainId: unknown;
19
+ market: string;
20
+ nft: {
21
+ contractAddress: string;
22
+ tokenIds: string[];
23
+ };
24
+ fractions: {
25
+ name: string;
26
+ symbol: string;
27
+ amount: string;
28
+ };
29
+ timeBoundary: {
30
+ start: string;
31
+ end: string;
32
+ };
33
+ cap: {
34
+ soft: string;
35
+ hard: string;
36
+ softPerAccount?: string | undefined;
37
+ hardPerAccount?: string | undefined;
38
+ };
39
+ funding: {
40
+ token: string;
41
+ amountPerPacket: string;
42
+ }[];
43
+ amountOfPacketsPerFraction: string;
44
+ refundAddress: string;
45
+ vesting?: {
46
+ cliff: string;
47
+ totalVestingPeriod: number;
48
+ portionPeriod: number;
49
+ } | undefined;
50
+ };
51
+ };
52
+ out: {
53
+ json: {
54
+ chainId: 1 | 11155111 | 31337 | 72080;
55
+ market: `0x${string}`;
56
+ nft: {
57
+ contractAddress: `0x${string}`;
58
+ tokenIds: bigint[];
59
+ };
60
+ fractions: {
61
+ name: string;
62
+ symbol: string;
63
+ amount: bigint;
64
+ };
65
+ timeBoundary: {
66
+ start: Date;
67
+ end: Date;
68
+ };
69
+ cap: {
70
+ soft: bigint;
71
+ hard: bigint;
72
+ softPerAccount?: bigint | undefined;
73
+ hardPerAccount?: bigint | undefined;
74
+ };
75
+ funding: {
76
+ token: `0x${string}`;
77
+ amountPerPacket: bigint;
78
+ }[];
79
+ amountOfPacketsPerFraction: bigint;
80
+ refundAddress: `0x${string}`;
81
+ vesting?: {
82
+ cliff: Date;
83
+ totalVestingPeriod: number;
84
+ portionPeriod: number;
85
+ } | undefined;
86
+ };
87
+ };
88
+ }, Promise<Response & import("hono").TypedResponse<{
89
+ data: `0x${string}`;
90
+ to: `0x${string}`;
91
+ details: {
92
+ functionName: string;
93
+ address: `0x${string}`;
94
+ abi: any[];
95
+ args: any[];
96
+ };
97
+ }, import("hono/utils/http-status").ContentfulStatusCode, "json">>>, import("hono/types").H<import("hono/utils/types").IfAnyThenEmptyObject<E extends Env ? Env extends E ? {} : E : E> & {}, string, {
98
+ in: {
99
+ json: {
100
+ chainId: unknown;
101
+ market: string;
102
+ nft: {
103
+ contractAddress: string;
104
+ tokenIds: string[];
105
+ };
106
+ fractions: {
107
+ name: string;
108
+ symbol: string;
109
+ amount: string;
110
+ };
111
+ timeBoundary: {
112
+ start: string;
113
+ end: string;
114
+ };
115
+ cap: {
116
+ soft: string;
117
+ hard: string;
118
+ softPerAccount?: string | undefined;
119
+ hardPerAccount?: string | undefined;
120
+ };
121
+ funding: {
122
+ token: string;
123
+ amountPerPacket: string;
124
+ }[];
125
+ amountOfPacketsPerFraction: string;
126
+ refundAddress: string;
127
+ vesting?: {
128
+ cliff: string;
129
+ totalVestingPeriod: number;
130
+ portionPeriod: number;
131
+ } | undefined;
132
+ };
133
+ };
134
+ out: {
135
+ json: {
136
+ chainId: 1 | 11155111 | 31337 | 72080;
137
+ market: `0x${string}`;
138
+ nft: {
139
+ contractAddress: `0x${string}`;
140
+ tokenIds: bigint[];
141
+ };
142
+ fractions: {
143
+ name: string;
144
+ symbol: string;
145
+ amount: bigint;
146
+ };
147
+ timeBoundary: {
148
+ start: Date;
149
+ end: Date;
150
+ };
151
+ cap: {
152
+ soft: bigint;
153
+ hard: bigint;
154
+ softPerAccount?: bigint | undefined;
155
+ hardPerAccount?: bigint | undefined;
156
+ };
157
+ funding: {
158
+ token: `0x${string}`;
159
+ amountPerPacket: bigint;
160
+ }[];
161
+ amountOfPacketsPerFraction: bigint;
162
+ refundAddress: `0x${string}`;
163
+ vesting?: {
164
+ cliff: Date;
165
+ totalVestingPeriod: number;
166
+ portionPeriod: number;
167
+ } | undefined;
168
+ };
169
+ };
170
+ }, Promise<Response & import("hono").TypedResponse<{
171
+ data: `0x${string}`;
172
+ to: `0x${string}`;
173
+ details: {
174
+ functionName: string;
175
+ address: `0x${string}`;
176
+ abi: any[];
177
+ args: any[];
178
+ };
179
+ }, import("hono/utils/http-status").ContentfulStatusCode, "json">>>];
180
+ //# sourceMappingURL=createNftFractions.routes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createNftFractions.routes.d.ts","sourceRoot":"","sources":["../../../src/fractions/sales/createNftFractions.routes.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAC3B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAyBvC;;GAEG;AACH,wBAAgB,+BAA+B,CAAC,CAAC,SAAS,GAAG,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qEA8CjF"}
@@ -0,0 +1,58 @@
1
+ import { describeRoute } from "hono-openapi";
2
+ import { resolver, validator } from "hono-openapi";
3
+ import { buildCreateNftFractionsTx } from "@evergonlabs/tmi-protocol-fractions-sdk/next";
4
+ import { toTransaction, TransactionSchema } from "../../common/index.js";
5
+ import { CreateNftFractionsRequestSchema } from "./createNftFractions.schema.js";
6
+ const route = describeRoute({
7
+ summary: "Create NFT fractions",
8
+ description: "Returns transaction data for wrapping ERC-721 tokens (NFTs) and creating ERC-20 compatible fractions. " +
9
+ "The NFT owner must first approve the market contract to transfer their NFTs.",
10
+ tags: ["NFT Fractions"],
11
+ responses: {
12
+ 200: {
13
+ description: "Returns transaction data for creating NFT fractions",
14
+ content: {
15
+ "application/json": {
16
+ schema: resolver(TransactionSchema),
17
+ },
18
+ },
19
+ },
20
+ },
21
+ });
22
+ /**
23
+ * Creates handlers for the create NFT fractions endpoint
24
+ */
25
+ export function createNftFractionsTransactionV0(factory) {
26
+ return factory.createHandlers(route, validator("json", CreateNftFractionsRequestSchema), async (c) => {
27
+ const { chainId, market, nft, fractions, timeBoundary, cap, funding, amountOfPacketsPerFraction, vesting, refundAddress, } = c.req.valid("json");
28
+ const tx = buildCreateNftFractionsTx({
29
+ chainId: chainId,
30
+ market: market,
31
+ nft: {
32
+ contractAddress: nft.contractAddress,
33
+ tokenIds: nft.tokenIds,
34
+ },
35
+ fractions: {
36
+ name: fractions.name,
37
+ symbol: fractions.symbol,
38
+ amount: fractions.amount,
39
+ },
40
+ timeBoundary: {
41
+ start: new Date(timeBoundary.start),
42
+ end: new Date(timeBoundary.end),
43
+ },
44
+ cap: cap,
45
+ funding: funding,
46
+ amountOfPacketsPerFraction: amountOfPacketsPerFraction,
47
+ vesting: vesting
48
+ ? {
49
+ cliff: new Date(vesting.cliff),
50
+ totalVestingPeriod: vesting.totalVestingPeriod,
51
+ portionPeriod: vesting.portionPeriod,
52
+ }
53
+ : undefined,
54
+ refundAddress: refundAddress,
55
+ });
56
+ return c.json(toTransaction(tx));
57
+ });
58
+ }