@etherisc/gif-next 0.0.2-f7b8c9f-518 → 0.0.2-f7eda15-119

Sign up to get free protection for your applications and to get access to all the features.
Files changed (394) hide show
  1. package/README.md +171 -2
  2. package/artifacts/contracts/components/Component.sol/Component.dbg.json +4 -0
  3. package/artifacts/contracts/components/Component.sol/Component.json +656 -0
  4. package/artifacts/contracts/components/Distribution.sol/Distribution.dbg.json +1 -1
  5. package/artifacts/contracts/components/Distribution.sol/Distribution.json +396 -104
  6. package/artifacts/contracts/components/IComponent.sol/IComponent.dbg.json +4 -0
  7. package/artifacts/contracts/{instance/base/ServiceBase.sol/ServiceBase.json → components/IComponent.sol/IComponent.json} +152 -165
  8. package/artifacts/contracts/components/IDistributionComponent.sol/IDistributionComponent.dbg.json +1 -1
  9. package/artifacts/contracts/components/IDistributionComponent.sol/IDistributionComponent.json +480 -9
  10. package/artifacts/contracts/components/IPoolComponent.sol/IPoolComponent.dbg.json +1 -1
  11. package/artifacts/contracts/components/IPoolComponent.sol/IPoolComponent.json +526 -65
  12. package/artifacts/contracts/components/IProductComponent.sol/IProductComponent.dbg.json +1 -1
  13. package/artifacts/contracts/components/IProductComponent.sol/IProductComponent.json +571 -30
  14. package/artifacts/contracts/components/Pool.sol/Pool.dbg.json +1 -1
  15. package/artifacts/contracts/components/Pool.sol/Pool.json +455 -201
  16. package/artifacts/contracts/components/Product.sol/Product.dbg.json +1 -1
  17. package/artifacts/contracts/components/Product.sol/Product.json +474 -139
  18. package/artifacts/contracts/experiment/cloning/Cloner.sol/Cloner.dbg.json +4 -0
  19. package/artifacts/contracts/experiment/cloning/Cloner.sol/Cloner.json +66 -0
  20. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock1.dbg.json +4 -0
  21. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock1.json +24 -0
  22. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock2.dbg.json +4 -0
  23. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock2.json +42 -0
  24. package/artifacts/contracts/experiment/errors/Require.sol/Require.dbg.json +1 -1
  25. package/artifacts/contracts/experiment/errors/Revert.sol/Revert.dbg.json +1 -1
  26. package/artifacts/contracts/experiment/inheritance/A.sol/A.dbg.json +1 -1
  27. package/artifacts/contracts/experiment/inheritance/A.sol/AShared.dbg.json +1 -1
  28. package/artifacts/contracts/experiment/inheritance/B.sol/B.dbg.json +1 -1
  29. package/artifacts/contracts/experiment/inheritance/C.sol/C.dbg.json +1 -1
  30. package/artifacts/contracts/experiment/inheritance/IA.sol/IA.dbg.json +1 -1
  31. package/artifacts/contracts/experiment/inheritance/IA.sol/ISharedA.dbg.json +1 -1
  32. package/artifacts/contracts/experiment/inheritance/IB.sol/IB.dbg.json +1 -1
  33. package/artifacts/contracts/experiment/inheritance/IC.sol/IC.dbg.json +1 -1
  34. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.dbg.json +1 -1
  35. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.json +2 -2
  36. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISM.dbg.json +1 -1
  37. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISMEE.dbg.json +1 -1
  38. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.dbg.json +1 -1
  39. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.json +2 -2
  40. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.dbg.json +1 -1
  41. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.json +2 -2
  42. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.dbg.json +1 -1
  43. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.dbg.json +1 -1
  44. package/artifacts/contracts/instance/BundleManager.sol/BundleManager.dbg.json +4 -0
  45. package/artifacts/contracts/instance/BundleManager.sol/BundleManager.json +764 -0
  46. package/artifacts/contracts/instance/Cloneable.sol/Cloneable.dbg.json +4 -0
  47. package/artifacts/contracts/instance/Cloneable.sol/Cloneable.json +185 -0
  48. package/artifacts/contracts/instance/IInstance.sol/IInstance.dbg.json +1 -1
  49. package/artifacts/contracts/instance/IInstance.sol/IInstance.json +1085 -1354
  50. package/artifacts/contracts/instance/IInstanceService.sol/IInstanceService.dbg.json +4 -0
  51. package/artifacts/contracts/instance/{service/IComponentOwnerService.sol/IComponentOwnerService.json → IInstanceService.sol/IInstanceService.json} +176 -56
  52. package/artifacts/contracts/instance/Instance.sol/Instance.dbg.json +1 -1
  53. package/artifacts/contracts/instance/Instance.sol/Instance.json +1731 -1355
  54. package/artifacts/contracts/instance/InstanceAccessManager.sol/InstanceAccessManager.dbg.json +4 -0
  55. package/artifacts/contracts/instance/InstanceAccessManager.sol/InstanceAccessManager.json +1034 -0
  56. package/artifacts/contracts/instance/InstanceReader.sol/InstanceReader.dbg.json +4 -0
  57. package/artifacts/contracts/instance/InstanceReader.sol/InstanceReader.json +1381 -0
  58. package/artifacts/contracts/instance/InstanceService.sol/InstanceService.dbg.json +4 -0
  59. package/artifacts/contracts/instance/InstanceService.sol/InstanceService.json +1024 -0
  60. package/artifacts/contracts/instance/InstanceServiceManager.sol/InstanceServiceManager.dbg.json +4 -0
  61. package/artifacts/contracts/instance/InstanceServiceManager.sol/InstanceServiceManager.json +473 -0
  62. package/artifacts/contracts/instance/ObjectManager.sol/ObjectManager.dbg.json +4 -0
  63. package/artifacts/contracts/instance/ObjectManager.sol/ObjectManager.json +261 -0
  64. package/artifacts/contracts/instance/base/ComponentService.sol/ComponentService.dbg.json +4 -0
  65. package/artifacts/contracts/instance/base/{InstanceBase.sol/InstanceBase.json → ComponentService.sol/ComponentService.json} +134 -75
  66. package/artifacts/contracts/instance/base/IKeyValueStore.sol/IKeyValueStore.dbg.json +1 -1
  67. package/artifacts/contracts/instance/base/IKeyValueStore.sol/IKeyValueStore.json +27 -158
  68. package/artifacts/contracts/instance/base/ILifecycle.sol/ILifecycle.dbg.json +1 -1
  69. package/artifacts/contracts/instance/base/KeyValueStore.sol/KeyValueStore.dbg.json +1 -1
  70. package/artifacts/contracts/instance/base/KeyValueStore.sol/KeyValueStore.json +37 -245
  71. package/artifacts/contracts/instance/base/Lifecycle.sol/Lifecycle.dbg.json +1 -1
  72. package/artifacts/contracts/instance/base/Lifecycle.sol/Lifecycle.json +2 -2
  73. package/artifacts/contracts/instance/module/IAccess.sol/IAccess.dbg.json +4 -0
  74. package/artifacts/contracts/instance/module/IAccess.sol/IAccess.json +254 -0
  75. package/artifacts/contracts/instance/module/IBundle.sol/IBundle.dbg.json +4 -0
  76. package/artifacts/contracts/instance/module/{bundle/IBundle.sol → IBundle.sol}/IBundle.json +1 -1
  77. package/artifacts/contracts/instance/module/IDistribution.sol/IDistribution.dbg.json +4 -0
  78. package/artifacts/contracts/instance/module/{distribution/IDistribution.sol → IDistribution.sol}/IDistribution.json +1 -1
  79. package/artifacts/contracts/instance/module/IPolicy.sol/IPolicy.dbg.json +4 -0
  80. package/artifacts/contracts/instance/module/{policy/IPolicy.sol → IPolicy.sol}/IPolicy.json +1 -1
  81. package/artifacts/contracts/instance/module/IRisk.sol/IRisk.dbg.json +4 -0
  82. package/artifacts/contracts/instance/module/{risk/IRisk.sol → IRisk.sol}/IRisk.json +1 -1
  83. package/artifacts/contracts/instance/module/ISetup.sol/ISetup.dbg.json +4 -0
  84. package/artifacts/contracts/instance/{base/ModuleBase.sol/ModuleBase.json → module/ISetup.sol/ISetup.json} +2 -2
  85. package/artifacts/contracts/instance/module/ITreasury.sol/ITreasury.dbg.json +4 -0
  86. package/artifacts/contracts/instance/module/{treasury/ITreasury.sol → ITreasury.sol}/ITreasury.json +1 -1
  87. package/artifacts/contracts/instance/service/BundleService.sol/BundleService.dbg.json +4 -0
  88. package/artifacts/contracts/instance/service/BundleService.sol/BundleService.json +1102 -0
  89. package/artifacts/contracts/instance/service/BundleServiceManager.sol/BundleServiceManager.dbg.json +4 -0
  90. package/artifacts/contracts/instance/service/BundleServiceManager.sol/BundleServiceManager.json +449 -0
  91. package/artifacts/contracts/instance/service/DistributionService.sol/DistributionService.dbg.json +1 -1
  92. package/artifacts/contracts/instance/service/DistributionService.sol/DistributionService.json +194 -52
  93. package/artifacts/contracts/instance/service/DistributionServiceManager.sol/DistributionServiceManager.dbg.json +4 -0
  94. package/artifacts/contracts/instance/service/DistributionServiceManager.sol/DistributionServiceManager.json +437 -0
  95. package/artifacts/contracts/instance/service/IBundleService.sol/IBundleService.dbg.json +4 -0
  96. package/artifacts/contracts/instance/service/IBundleService.sol/IBundleService.json +715 -0
  97. package/artifacts/contracts/instance/service/IDistributionService.sol/IDistributionService.dbg.json +1 -1
  98. package/artifacts/contracts/instance/service/IDistributionService.sol/IDistributionService.json +13 -18
  99. package/artifacts/contracts/instance/service/IPolicyService.sol/IPolicyService.dbg.json +4 -0
  100. package/artifacts/contracts/instance/service/IPolicyService.sol/IPolicyService.json +766 -0
  101. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.dbg.json +1 -1
  102. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.json +15 -82
  103. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.dbg.json +1 -1
  104. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.json +25 -245
  105. package/artifacts/contracts/instance/service/PolicyService.sol/PolicyService.dbg.json +4 -0
  106. package/artifacts/contracts/instance/service/PolicyService.sol/PolicyService.json +1227 -0
  107. package/artifacts/contracts/instance/service/PolicyServiceManager.sol/PolicyServiceManager.dbg.json +4 -0
  108. package/artifacts/contracts/instance/service/PolicyServiceManager.sol/PolicyServiceManager.json +505 -0
  109. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.dbg.json +1 -1
  110. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.json +181 -128
  111. package/artifacts/contracts/instance/service/PoolServiceManager.sol/PoolServiceManager.dbg.json +4 -0
  112. package/artifacts/contracts/instance/service/PoolServiceManager.sol/PoolServiceManager.json +437 -0
  113. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.dbg.json +1 -1
  114. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.json +174 -386
  115. package/artifacts/contracts/instance/service/ProductServiceManager.sol/ProductServiceManager.dbg.json +4 -0
  116. package/artifacts/contracts/instance/service/ProductServiceManager.sol/ProductServiceManager.json +437 -0
  117. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.dbg.json +1 -1
  118. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.json +47 -2
  119. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.dbg.json +1 -1
  120. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.json +223 -63
  121. package/artifacts/contracts/registry/IRegistryService.sol/IRegistryService.dbg.json +1 -1
  122. package/artifacts/contracts/registry/IRegistryService.sol/IRegistryService.json +285 -49
  123. package/artifacts/contracts/registry/ITransferInterceptor.sol/ITransferInterceptor.dbg.json +1 -1
  124. package/artifacts/contracts/registry/Registry.sol/Registry.dbg.json +1 -1
  125. package/artifacts/contracts/registry/Registry.sol/Registry.json +196 -211
  126. package/artifacts/contracts/registry/RegistryAccessManager.sol/RegistryAccessManager.dbg.json +4 -0
  127. package/artifacts/contracts/registry/RegistryAccessManager.sol/RegistryAccessManager.json +285 -0
  128. package/artifacts/contracts/registry/RegistryService.sol/RegistryService.dbg.json +1 -1
  129. package/artifacts/contracts/registry/RegistryService.sol/RegistryService.json +314 -111
  130. package/artifacts/contracts/registry/RegistryServiceManager.sol/RegistryServiceManager.dbg.json +1 -1
  131. package/artifacts/contracts/registry/RegistryServiceManager.sol/RegistryServiceManager.json +72 -76
  132. package/artifacts/contracts/registry/ReleaseManager.sol/ReleaseManager.dbg.json +4 -0
  133. package/artifacts/contracts/registry/ReleaseManager.sol/ReleaseManager.json +547 -0
  134. package/artifacts/contracts/registry/TokenRegistry.sol/TokenRegistry.dbg.json +4 -0
  135. package/artifacts/contracts/registry/TokenRegistry.sol/TokenRegistry.json +394 -0
  136. package/artifacts/contracts/shared/ContractDeployerLib.sol/ContractDeployerLib.dbg.json +1 -1
  137. package/artifacts/contracts/shared/ERC165.sol/ERC165.dbg.json +1 -1
  138. package/artifacts/contracts/shared/ERC165.sol/ERC165.json +2 -2
  139. package/artifacts/contracts/shared/INftOwnable.sol/INftOwnable.dbg.json +1 -1
  140. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.dbg.json +1 -1
  141. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.json +0 -5
  142. package/artifacts/contracts/shared/IService.sol/IService.dbg.json +4 -0
  143. package/artifacts/contracts/{instance/base → shared}/IService.sol/IService.json +14 -19
  144. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.dbg.json +1 -1
  145. package/artifacts/contracts/shared/NftOwnable.sol/NftOwnable.dbg.json +1 -1
  146. package/artifacts/contracts/shared/NftOwnable.sol/NftOwnable.json +19 -6
  147. package/artifacts/contracts/shared/ProxyManager.sol/ProxyManager.dbg.json +1 -1
  148. package/artifacts/contracts/shared/ProxyManager.sol/ProxyManager.json +19 -6
  149. package/artifacts/contracts/shared/Registerable.sol/Registerable.dbg.json +1 -1
  150. package/artifacts/contracts/shared/Registerable.sol/Registerable.json +19 -11
  151. package/artifacts/contracts/shared/Service.sol/Service.dbg.json +4 -0
  152. package/artifacts/contracts/{instance/base/ComponentServiceBase.sol/ComponentServiceBase.json → shared/Service.sol/Service.json} +28 -33
  153. package/artifacts/contracts/shared/TokenHandler.sol/TokenHandler.dbg.json +4 -0
  154. package/artifacts/contracts/shared/TokenHandler.sol/TokenHandler.json +96 -0
  155. package/artifacts/contracts/shared/UpgradableProxyWithAdmin.sol/UpgradableProxyWithAdmin.dbg.json +1 -1
  156. package/artifacts/contracts/shared/UpgradableProxyWithAdmin.sol/UpgradableProxyWithAdmin.json +2 -2
  157. package/artifacts/contracts/shared/Versionable.sol/Versionable.dbg.json +1 -1
  158. package/artifacts/contracts/test/TestFee.sol/TestFee.dbg.json +1 -1
  159. package/artifacts/contracts/test/TestFee.sol/TestFee.json +4 -4
  160. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.dbg.json +1 -1
  161. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.json +19 -11
  162. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.dbg.json +1 -1
  163. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.json +14 -14
  164. package/artifacts/contracts/test/TestService.sol/TestService.dbg.json +1 -1
  165. package/artifacts/contracts/test/TestService.sol/TestService.json +58 -34
  166. package/artifacts/contracts/test/TestToken.sol/TestUsdc.dbg.json +1 -1
  167. package/artifacts/contracts/test/TestToken.sol/TestUsdc.json +91 -53
  168. package/artifacts/contracts/test/TestVersion.sol/TestVersion.dbg.json +1 -1
  169. package/artifacts/contracts/test/TestVersion.sol/TestVersion.json +2 -2
  170. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.dbg.json +1 -1
  171. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.json +18 -2
  172. package/artifacts/contracts/test/Usdc.sol/USDC.dbg.json +1 -1
  173. package/artifacts/contracts/test/Usdc.sol/USDC.json +91 -53
  174. package/artifacts/contracts/types/AddressSet.sol/LibAddressSet.dbg.json +1 -1
  175. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.dbg.json +1 -1
  176. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.dbg.json +1 -1
  177. package/artifacts/contracts/types/DistributorType.sol/DistributorTypeLib.dbg.json +4 -0
  178. package/artifacts/contracts/types/DistributorType.sol/DistributorTypeLib.json +104 -0
  179. package/artifacts/contracts/types/Fee.sol/FeeLib.dbg.json +1 -1
  180. package/artifacts/contracts/types/Fee.sol/FeeLib.json +4 -4
  181. package/artifacts/contracts/types/Key32.sol/Key32Lib.dbg.json +1 -1
  182. package/artifacts/contracts/types/Key32.sol/Key32Lib.json +31 -17
  183. package/artifacts/contracts/types/NftId.sol/NftIdLib.dbg.json +1 -1
  184. package/artifacts/contracts/types/NftId.sol/NftIdLib.json +2 -2
  185. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.dbg.json +1 -1
  186. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.json +26 -3
  187. package/artifacts/contracts/types/NumberId.sol/NumberIdLib.dbg.json +4 -0
  188. package/artifacts/contracts/types/NumberId.sol/NumberIdLib.json +100 -0
  189. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.dbg.json +1 -1
  190. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.json +2 -2
  191. package/artifacts/contracts/types/Referral.sol/ReferralLib.dbg.json +4 -0
  192. package/artifacts/contracts/types/Referral.sol/ReferralLib.json +123 -0
  193. package/artifacts/contracts/types/RiskId.sol/RiskIdLib.dbg.json +1 -1
  194. package/artifacts/contracts/types/RiskId.sol/RiskIdLib.json +2 -2
  195. package/artifacts/contracts/types/RoleId.sol/RoleIdLib.dbg.json +1 -1
  196. package/artifacts/contracts/types/RoleId.sol/RoleIdLib.json +134 -8
  197. package/artifacts/contracts/types/StateId.sol/StateIdLib.dbg.json +1 -1
  198. package/artifacts/contracts/types/StateId.sol/StateIdLib.json +2 -2
  199. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.dbg.json +1 -1
  200. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.json +15 -2
  201. package/artifacts/contracts/types/UFixed.sol/MathLib.dbg.json +4 -0
  202. package/artifacts/contracts/types/UFixed.sol/MathLib.json +10 -0
  203. package/artifacts/contracts/types/UFixed.sol/UFixedLib.dbg.json +4 -0
  204. package/artifacts/contracts/types/UFixed.sol/{UFixedMathLib.json → UFixedLib.json} +3 -3
  205. package/artifacts/contracts/types/Version.sol/VersionLib.dbg.json +1 -1
  206. package/artifacts/contracts/types/Version.sol/VersionLib.json +2 -2
  207. package/artifacts/contracts/types/Version.sol/VersionPartLib.dbg.json +1 -1
  208. package/artifacts/contracts/types/Version.sol/VersionPartLib.json +22 -3
  209. package/contracts/components/Component.sol +216 -0
  210. package/contracts/components/Distribution.sol +48 -53
  211. package/contracts/components/IComponent.sol +43 -0
  212. package/contracts/components/IDistributionComponent.sol +6 -5
  213. package/contracts/components/IPoolComponent.sol +11 -15
  214. package/contracts/components/IProductComponent.sol +9 -7
  215. package/contracts/components/Pool.sol +77 -96
  216. package/contracts/components/Product.sol +83 -117
  217. package/contracts/experiment/cloning/Cloner.sol +47 -0
  218. package/contracts/instance/BundleManager.sol +125 -0
  219. package/contracts/instance/Cloneable.sol +46 -0
  220. package/contracts/instance/IInstance.sol +64 -46
  221. package/contracts/instance/IInstanceService.sol +41 -0
  222. package/contracts/instance/Instance.sol +251 -69
  223. package/contracts/instance/InstanceAccessManager.sol +298 -0
  224. package/contracts/instance/InstanceReader.sol +293 -0
  225. package/contracts/instance/InstanceService.sol +435 -0
  226. package/contracts/instance/InstanceServiceManager.sol +54 -0
  227. package/contracts/instance/ObjectManager.sol +84 -0
  228. package/contracts/instance/base/ComponentService.sol +134 -0
  229. package/contracts/instance/base/IKeyValueStore.sol +13 -14
  230. package/contracts/instance/base/ILifecycle.sol +3 -3
  231. package/contracts/instance/base/KeyValueStore.sol +49 -38
  232. package/contracts/instance/base/Lifecycle.sol +1 -1
  233. package/contracts/instance/module/IAccess.sol +48 -0
  234. package/contracts/instance/module/IBundle.sol +20 -0
  235. package/contracts/instance/module/IDistribution.sol +39 -0
  236. package/contracts/instance/module/IPolicy.sol +45 -0
  237. package/contracts/instance/module/IRisk.sol +11 -0
  238. package/contracts/instance/module/ISetup.sol +46 -0
  239. package/contracts/instance/module/ITreasury.sol +23 -0
  240. package/contracts/instance/service/BundleService.sol +293 -0
  241. package/contracts/instance/service/BundleServiceManager.sol +51 -0
  242. package/contracts/instance/service/DistributionService.sol +72 -20
  243. package/contracts/instance/service/DistributionServiceManager.sol +51 -0
  244. package/contracts/instance/service/IBundleService.sol +44 -0
  245. package/contracts/instance/service/IDistributionService.sol +1 -1
  246. package/contracts/instance/service/IPolicyService.sol +94 -0
  247. package/contracts/instance/service/IPoolService.sol +7 -24
  248. package/contracts/instance/service/IProductService.sol +9 -76
  249. package/contracts/instance/service/PolicyService.sol +538 -0
  250. package/contracts/instance/service/PolicyServiceManager.sol +54 -0
  251. package/contracts/instance/service/PoolService.sol +77 -116
  252. package/contracts/instance/service/PoolServiceManager.sol +51 -0
  253. package/contracts/instance/service/ProductService.sol +157 -433
  254. package/contracts/instance/service/ProductServiceManager.sol +54 -0
  255. package/contracts/registry/ChainNft.sol +41 -26
  256. package/contracts/registry/IRegistry.sol +50 -25
  257. package/contracts/registry/IRegistryService.sol +52 -16
  258. package/contracts/registry/Registry.sol +266 -305
  259. package/contracts/registry/RegistryAccessManager.sol +216 -0
  260. package/contracts/registry/RegistryService.sol +130 -236
  261. package/contracts/registry/RegistryServiceManager.sol +28 -9
  262. package/contracts/registry/ReleaseManager.sol +332 -0
  263. package/contracts/registry/TokenRegistry.sol +112 -0
  264. package/contracts/shared/ERC165.sol +7 -3
  265. package/contracts/shared/IRegisterable.sol +2 -4
  266. package/contracts/shared/IService.sol +16 -0
  267. package/contracts/shared/NftOwnable.sol +7 -4
  268. package/contracts/shared/ProxyManager.sol +4 -4
  269. package/contracts/shared/Registerable.sol +12 -15
  270. package/contracts/shared/Service.sol +60 -0
  271. package/contracts/shared/TokenHandler.sol +27 -0
  272. package/contracts/shared/UpgradableProxyWithAdmin.sol +2 -2
  273. package/contracts/shared/Versionable.sol +3 -3
  274. package/contracts/test/TestFee.sol +2 -2
  275. package/contracts/test/TestRoleId.sol +1 -1
  276. package/contracts/test/TestService.sol +6 -7
  277. package/contracts/types/DistributorType.sol +55 -0
  278. package/contracts/types/Fee.sol +3 -3
  279. package/contracts/types/Key32.sol +8 -3
  280. package/contracts/types/NftIdSet.sol +26 -24
  281. package/contracts/types/NumberId.sol +52 -0
  282. package/contracts/types/ObjectType.sol +35 -14
  283. package/contracts/types/Referral.sol +85 -0
  284. package/contracts/types/RoleId.sol +61 -9
  285. package/contracts/types/StateId.sol +5 -1
  286. package/contracts/types/Timestamp.sol +7 -3
  287. package/contracts/types/UFixed.sol +128 -12
  288. package/contracts/types/Version.sol +4 -1
  289. package/package.json +4 -3
  290. package/artifacts/contracts/components/BaseComponent.sol/BaseComponent.dbg.json +0 -4
  291. package/artifacts/contracts/components/BaseComponent.sol/BaseComponent.json +0 -301
  292. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.dbg.json +0 -4
  293. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.json +0 -254
  294. package/artifacts/contracts/instance/IInstanceLinked.sol/IInstanceLinked.dbg.json +0 -4
  295. package/artifacts/contracts/instance/IInstanceLinked.sol/IInstanceLinked.json +0 -24
  296. package/artifacts/contracts/instance/base/ComponentServiceBase.sol/ComponentServiceBase.dbg.json +0 -4
  297. package/artifacts/contracts/instance/base/IInstanceBase.sol/IInstanceBase.dbg.json +0 -4
  298. package/artifacts/contracts/instance/base/IInstanceBase.sol/IInstanceBase.json +0 -113
  299. package/artifacts/contracts/instance/base/IService.sol/IService.dbg.json +0 -4
  300. package/artifacts/contracts/instance/base/InstanceBase.sol/InstanceBase.dbg.json +0 -4
  301. package/artifacts/contracts/instance/base/ModuleBase.sol/ModuleBase.dbg.json +0 -4
  302. package/artifacts/contracts/instance/base/ServiceBase.sol/ServiceBase.dbg.json +0 -4
  303. package/artifacts/contracts/instance/module/access/Access.sol/AccessModule.dbg.json +0 -4
  304. package/artifacts/contracts/instance/module/access/Access.sol/AccessModule.json +0 -333
  305. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccess.dbg.json +0 -4
  306. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccess.json +0 -10
  307. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccessModule.dbg.json +0 -4
  308. package/artifacts/contracts/instance/module/access/IAccess.sol/IAccessModule.json +0 -333
  309. package/artifacts/contracts/instance/module/bundle/BundleModule.sol/BundleModule.dbg.json +0 -4
  310. package/artifacts/contracts/instance/module/bundle/BundleModule.sol/BundleModule.json +0 -297
  311. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundle.dbg.json +0 -4
  312. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundleModule.dbg.json +0 -4
  313. package/artifacts/contracts/instance/module/bundle/IBundle.sol/IBundleModule.json +0 -297
  314. package/artifacts/contracts/instance/module/component/ComponentModule.sol/ComponentModule.dbg.json +0 -4
  315. package/artifacts/contracts/instance/module/component/ComponentModule.sol/ComponentModule.json +0 -117
  316. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponent.dbg.json +0 -4
  317. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponent.json +0 -10
  318. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponentModule.dbg.json +0 -4
  319. package/artifacts/contracts/instance/module/component/IComponent.sol/IComponentModule.json +0 -117
  320. package/artifacts/contracts/instance/module/distribution/DistributionModule.sol/DistributionModule.dbg.json +0 -4
  321. package/artifacts/contracts/instance/module/distribution/DistributionModule.sol/DistributionModule.json +0 -10
  322. package/artifacts/contracts/instance/module/distribution/IDistribution.sol/IDistribution.dbg.json +0 -4
  323. package/artifacts/contracts/instance/module/distribution/IDistribution.sol/IDistributionModule.dbg.json +0 -4
  324. package/artifacts/contracts/instance/module/distribution/IDistribution.sol/IDistributionModule.json +0 -10
  325. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicy.dbg.json +0 -4
  326. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicyModule.dbg.json +0 -4
  327. package/artifacts/contracts/instance/module/policy/IPolicy.sol/IPolicyModule.json +0 -271
  328. package/artifacts/contracts/instance/module/policy/PolicyModule.sol/PolicyModule.dbg.json +0 -4
  329. package/artifacts/contracts/instance/module/policy/PolicyModule.sol/PolicyModule.json +0 -271
  330. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPool.dbg.json +0 -4
  331. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPool.json +0 -10
  332. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPoolModule.dbg.json +0 -4
  333. package/artifacts/contracts/instance/module/pool/IPoolModule.sol/IPoolModule.json +0 -164
  334. package/artifacts/contracts/instance/module/pool/PoolModule.sol/PoolModule.dbg.json +0 -4
  335. package/artifacts/contracts/instance/module/pool/PoolModule.sol/PoolModule.json +0 -164
  336. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRisk.dbg.json +0 -4
  337. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRiskModule.dbg.json +0 -4
  338. package/artifacts/contracts/instance/module/risk/IRisk.sol/IRiskModule.json +0 -113
  339. package/artifacts/contracts/instance/module/risk/RiskModule.sol/RiskModule.dbg.json +0 -4
  340. package/artifacts/contracts/instance/module/risk/RiskModule.sol/RiskModule.json +0 -131
  341. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasury.dbg.json +0 -4
  342. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasuryModule.dbg.json +0 -4
  343. package/artifacts/contracts/instance/module/treasury/ITreasury.sol/ITreasuryModule.json +0 -638
  344. package/artifacts/contracts/instance/module/treasury/TokenHandler.sol/TokenHandler.dbg.json +0 -4
  345. package/artifacts/contracts/instance/module/treasury/TokenHandler.sol/TokenHandler.json +0 -76
  346. package/artifacts/contracts/instance/module/treasury/TreasuryModule.sol/TreasuryModule.dbg.json +0 -4
  347. package/artifacts/contracts/instance/module/treasury/TreasuryModule.sol/TreasuryModule.json +0 -638
  348. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.dbg.json +0 -4
  349. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.json +0 -794
  350. package/artifacts/contracts/instance/service/IComponentOwnerService.sol/IComponentOwnerService.dbg.json +0 -4
  351. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.dbg.json +0 -4
  352. package/artifacts/contracts/registry/IChainNft.sol/IChainNft.json +0 -457
  353. package/artifacts/contracts/test/TestDistribution.sol/TestDistribution.dbg.json +0 -4
  354. package/artifacts/contracts/test/TestDistribution.sol/TestDistribution.json +0 -557
  355. package/artifacts/contracts/test/TestPool.sol/TestPool.dbg.json +0 -4
  356. package/artifacts/contracts/test/TestPool.sol/TestPool.json +0 -716
  357. package/artifacts/contracts/test/TestProduct.sol/TestProduct.dbg.json +0 -4
  358. package/artifacts/contracts/test/TestProduct.sol/TestProduct.json +0 -744
  359. package/artifacts/contracts/types/ReferralId.sol/ReferralIdLib.dbg.json +0 -4
  360. package/artifacts/contracts/types/ReferralId.sol/ReferralIdLib.json +0 -99
  361. package/artifacts/contracts/types/UFixed.sol/UFixedMathLib.dbg.json +0 -4
  362. package/contracts/components/BaseComponent.sol +0 -79
  363. package/contracts/components/IBaseComponent.sol +0 -19
  364. package/contracts/instance/IInstanceLinked.sol +0 -8
  365. package/contracts/instance/base/ComponentServiceBase.sol +0 -49
  366. package/contracts/instance/base/IInstanceBase.sol +0 -23
  367. package/contracts/instance/base/IService.sol +0 -15
  368. package/contracts/instance/base/InstanceBase.sol +0 -89
  369. package/contracts/instance/base/ModuleBase.sol +0 -57
  370. package/contracts/instance/base/ServiceBase.sol +0 -44
  371. package/contracts/instance/module/access/Access.sol +0 -149
  372. package/contracts/instance/module/access/IAccess.sol +0 -53
  373. package/contracts/instance/module/bundle/BundleModule.sol +0 -134
  374. package/contracts/instance/module/bundle/IBundle.sol +0 -53
  375. package/contracts/instance/module/component/ComponentModule.sol +0 -71
  376. package/contracts/instance/module/component/IComponent.sol +0 -28
  377. package/contracts/instance/module/distribution/DistributionModule.sol +0 -17
  378. package/contracts/instance/module/distribution/IDistribution.sol +0 -10
  379. package/contracts/instance/module/policy/IPolicy.sol +0 -63
  380. package/contracts/instance/module/policy/PolicyModule.sol +0 -91
  381. package/contracts/instance/module/pool/IPoolModule.sol +0 -41
  382. package/contracts/instance/module/pool/PoolModule.sol +0 -95
  383. package/contracts/instance/module/risk/IRisk.sol +0 -26
  384. package/contracts/instance/module/risk/RiskModule.sol +0 -62
  385. package/contracts/instance/module/treasury/ITreasury.sol +0 -84
  386. package/contracts/instance/module/treasury/TokenHandler.sol +0 -48
  387. package/contracts/instance/module/treasury/TreasuryModule.sol +0 -131
  388. package/contracts/instance/service/ComponentOwnerService.sol +0 -275
  389. package/contracts/instance/service/IComponentOwnerService.sol +0 -20
  390. package/contracts/registry/IChainNft.sol +0 -22
  391. package/contracts/test/TestDistribution.sol +0 -22
  392. package/contracts/test/TestPool.sol +0 -27
  393. package/contracts/test/TestProduct.sol +0 -74
  394. package/contracts/types/ReferralId.sol +0 -48
@@ -3,6 +3,44 @@
3
3
  "contractName": "IInstance",
4
4
  "sourceName": "contracts/instance/IInstance.sol",
5
5
  "abi": [
6
+ {
7
+ "inputs": [
8
+ {
9
+ "internalType": "address",
10
+ "name": "authority",
11
+ "type": "address"
12
+ }
13
+ ],
14
+ "name": "AccessManagedInvalidAuthority",
15
+ "type": "error"
16
+ },
17
+ {
18
+ "inputs": [
19
+ {
20
+ "internalType": "address",
21
+ "name": "caller",
22
+ "type": "address"
23
+ },
24
+ {
25
+ "internalType": "uint32",
26
+ "name": "delay",
27
+ "type": "uint32"
28
+ }
29
+ ],
30
+ "name": "AccessManagedRequiredDelay",
31
+ "type": "error"
32
+ },
33
+ {
34
+ "inputs": [
35
+ {
36
+ "internalType": "address",
37
+ "name": "caller",
38
+ "type": "address"
39
+ }
40
+ ],
41
+ "name": "AccessManagedUnauthorized",
42
+ "type": "error"
43
+ },
6
44
  {
7
45
  "inputs": [
8
46
  {
@@ -30,6 +68,43 @@
30
68
  "name": "ErrorContractNotRegistered",
31
69
  "type": "error"
32
70
  },
71
+ {
72
+ "inputs": [
73
+ {
74
+ "internalType": "ObjectType",
75
+ "name": "objectType",
76
+ "type": "uint8"
77
+ },
78
+ {
79
+ "internalType": "StateId",
80
+ "name": "fromStateId",
81
+ "type": "uint8"
82
+ },
83
+ {
84
+ "internalType": "StateId",
85
+ "name": "toStateId",
86
+ "type": "uint8"
87
+ }
88
+ ],
89
+ "name": "ErrorInvalidStateTransition",
90
+ "type": "error"
91
+ },
92
+ {
93
+ "inputs": [
94
+ {
95
+ "internalType": "NftId",
96
+ "name": "nftId",
97
+ "type": "uint96"
98
+ },
99
+ {
100
+ "internalType": "ObjectType",
101
+ "name": "objectType",
102
+ "type": "uint8"
103
+ }
104
+ ],
105
+ "name": "ErrorNoLifecycle",
106
+ "type": "error"
107
+ },
33
108
  {
34
109
  "inputs": [
35
110
  {
@@ -78,18 +153,12 @@
78
153
  "inputs": [
79
154
  {
80
155
  "indexed": false,
81
- "internalType": "RoleId",
82
- "name": "role",
83
- "type": "bytes8"
84
- },
85
- {
86
- "indexed": false,
87
- "internalType": "string",
88
- "name": "roleName",
89
- "type": "string"
156
+ "internalType": "address",
157
+ "name": "authority",
158
+ "type": "address"
90
159
  }
91
160
  ],
92
- "name": "LogAccessRoleCreated",
161
+ "name": "AuthorityUpdated",
93
162
  "type": "event"
94
163
  },
95
164
  {
@@ -97,24 +166,36 @@
97
166
  "inputs": [
98
167
  {
99
168
  "indexed": false,
100
- "internalType": "RoleId",
101
- "name": "role",
102
- "type": "bytes8"
169
+ "internalType": "ObjectType",
170
+ "name": "objectType",
171
+ "type": "uint8"
172
+ },
173
+ {
174
+ "indexed": false,
175
+ "internalType": "KeyId",
176
+ "name": "keyId",
177
+ "type": "bytes31"
178
+ },
179
+ {
180
+ "indexed": false,
181
+ "internalType": "StateId",
182
+ "name": "state",
183
+ "type": "uint8"
103
184
  },
104
185
  {
105
186
  "indexed": false,
106
187
  "internalType": "address",
107
- "name": "member",
188
+ "name": "createdBy",
108
189
  "type": "address"
109
190
  },
110
191
  {
111
192
  "indexed": false,
112
- "internalType": "bool",
113
- "name": "isMember",
114
- "type": "bool"
193
+ "internalType": "address",
194
+ "name": "txOrigin",
195
+ "type": "address"
115
196
  }
116
197
  ],
117
- "name": "LogAccessRoleGranted",
198
+ "name": "LogInfoCreated",
118
199
  "type": "event"
119
200
  },
120
201
  {
@@ -122,18 +203,42 @@
122
203
  "inputs": [
123
204
  {
124
205
  "indexed": false,
125
- "internalType": "RoleId",
126
- "name": "role",
127
- "type": "bytes8"
206
+ "internalType": "ObjectType",
207
+ "name": "objectType",
208
+ "type": "uint8"
128
209
  },
129
210
  {
130
211
  "indexed": false,
131
- "internalType": "bool",
132
- "name": "active",
133
- "type": "bool"
212
+ "internalType": "KeyId",
213
+ "name": "keyId",
214
+ "type": "bytes31"
215
+ },
216
+ {
217
+ "indexed": false,
218
+ "internalType": "StateId",
219
+ "name": "state",
220
+ "type": "uint8"
221
+ },
222
+ {
223
+ "indexed": false,
224
+ "internalType": "address",
225
+ "name": "updatedBy",
226
+ "type": "address"
227
+ },
228
+ {
229
+ "indexed": false,
230
+ "internalType": "address",
231
+ "name": "txOrigin",
232
+ "type": "address"
233
+ },
234
+ {
235
+ "indexed": false,
236
+ "internalType": "Blocknumber",
237
+ "name": "lastUpdatedIn",
238
+ "type": "uint32"
134
239
  }
135
240
  ],
136
- "name": "LogAccessRoleStateSet",
241
+ "name": "LogInfoUpdated",
137
242
  "type": "event"
138
243
  },
139
244
  {
@@ -141,109 +246,193 @@
141
246
  "inputs": [
142
247
  {
143
248
  "indexed": false,
144
- "internalType": "Version",
145
- "name": "version",
146
- "type": "uint24"
249
+ "internalType": "ObjectType",
250
+ "name": "objectType",
251
+ "type": "uint8"
252
+ },
253
+ {
254
+ "indexed": false,
255
+ "internalType": "KeyId",
256
+ "name": "keyId",
257
+ "type": "bytes31"
258
+ },
259
+ {
260
+ "indexed": false,
261
+ "internalType": "StateId",
262
+ "name": "stateOld",
263
+ "type": "uint8"
264
+ },
265
+ {
266
+ "indexed": false,
267
+ "internalType": "StateId",
268
+ "name": "stateNew",
269
+ "type": "uint8"
147
270
  },
148
271
  {
149
272
  "indexed": false,
150
273
  "internalType": "address",
151
- "name": "implementation",
274
+ "name": "updatedBy",
152
275
  "type": "address"
153
276
  },
154
277
  {
155
278
  "indexed": false,
156
279
  "internalType": "address",
157
- "name": "activatedBy",
280
+ "name": "txOrigin",
158
281
  "type": "address"
282
+ },
283
+ {
284
+ "indexed": false,
285
+ "internalType": "Blocknumber",
286
+ "name": "lastUpdatedIn",
287
+ "type": "uint32"
159
288
  }
160
289
  ],
161
- "name": "LogVersionableInitialized",
290
+ "name": "LogStateUpdated",
162
291
  "type": "event"
163
292
  },
164
293
  {
165
- "inputs": [
166
- {
167
- "internalType": "NftId",
168
- "name": "bundleNftId",
169
- "type": "uint96"
170
- },
171
- {
172
- "internalType": "NftId",
173
- "name": "poolNftId",
174
- "type": "uint96"
175
- },
294
+ "inputs": [],
295
+ "name": "authority",
296
+ "outputs": [
176
297
  {
177
- "internalType": "uint256",
178
- "name": "amount",
179
- "type": "uint256"
298
+ "internalType": "address",
299
+ "name": "",
300
+ "type": "address"
180
301
  }
181
302
  ],
182
- "name": "addBundleToPool",
183
- "outputs": [],
184
- "stateMutability": "nonpayable",
303
+ "stateMutability": "view",
185
304
  "type": "function"
186
305
  },
187
306
  {
188
307
  "inputs": [
189
308
  {
190
- "internalType": "uint256",
191
- "name": "amount",
192
- "type": "uint256"
309
+ "internalType": "NftId",
310
+ "name": "bundleNftId",
311
+ "type": "uint96"
193
312
  },
194
313
  {
195
314
  "components": [
196
315
  {
197
- "internalType": "UFixed",
198
- "name": "fractionalFee",
316
+ "internalType": "NftId",
317
+ "name": "poolNftId",
318
+ "type": "uint96"
319
+ },
320
+ {
321
+ "components": [
322
+ {
323
+ "internalType": "UFixed",
324
+ "name": "fractionalFee",
325
+ "type": "uint256"
326
+ },
327
+ {
328
+ "internalType": "uint256",
329
+ "name": "fixedFee",
330
+ "type": "uint256"
331
+ }
332
+ ],
333
+ "internalType": "struct Fee",
334
+ "name": "fee",
335
+ "type": "tuple"
336
+ },
337
+ {
338
+ "internalType": "bytes",
339
+ "name": "filter",
340
+ "type": "bytes"
341
+ },
342
+ {
343
+ "internalType": "uint256",
344
+ "name": "capitalAmount",
345
+ "type": "uint256"
346
+ },
347
+ {
348
+ "internalType": "uint256",
349
+ "name": "lockedAmount",
199
350
  "type": "uint256"
200
351
  },
201
352
  {
202
353
  "internalType": "uint256",
203
- "name": "fixedFee",
354
+ "name": "balanceAmount",
355
+ "type": "uint256"
356
+ },
357
+ {
358
+ "internalType": "uint256",
359
+ "name": "lifetime",
204
360
  "type": "uint256"
361
+ },
362
+ {
363
+ "internalType": "Timestamp",
364
+ "name": "expiredAt",
365
+ "type": "uint40"
366
+ },
367
+ {
368
+ "internalType": "Timestamp",
369
+ "name": "closedAt",
370
+ "type": "uint40"
205
371
  }
206
372
  ],
207
- "internalType": "struct Fee",
208
- "name": "fee",
373
+ "internalType": "struct IBundle.BundleInfo",
374
+ "name": "bundle",
209
375
  "type": "tuple"
210
376
  }
211
377
  ],
212
- "name": "calculateFeeAmount",
213
- "outputs": [
214
- {
215
- "internalType": "uint256",
216
- "name": "feeAmount",
217
- "type": "uint256"
218
- },
219
- {
220
- "internalType": "uint256",
221
- "name": "netAmount",
222
- "type": "uint256"
223
- }
224
- ],
225
- "stateMutability": "pure",
378
+ "name": "createBundle",
379
+ "outputs": [],
380
+ "stateMutability": "nonpayable",
226
381
  "type": "function"
227
382
  },
228
383
  {
229
384
  "inputs": [
230
385
  {
231
386
  "internalType": "NftId",
232
- "name": "bundleNftId",
233
- "type": "uint96"
234
- },
235
- {
236
- "internalType": "NftId",
237
- "name": "policyNftId",
387
+ "name": "distributionNftId",
238
388
  "type": "uint96"
239
389
  },
240
390
  {
241
- "internalType": "uint256",
242
- "name": "amount",
243
- "type": "uint256"
391
+ "components": [
392
+ {
393
+ "internalType": "NftId",
394
+ "name": "productNftId",
395
+ "type": "uint96"
396
+ },
397
+ {
398
+ "internalType": "contract TokenHandler",
399
+ "name": "tokenHandler",
400
+ "type": "address"
401
+ },
402
+ {
403
+ "components": [
404
+ {
405
+ "internalType": "UFixed",
406
+ "name": "fractionalFee",
407
+ "type": "uint256"
408
+ },
409
+ {
410
+ "internalType": "uint256",
411
+ "name": "fixedFee",
412
+ "type": "uint256"
413
+ }
414
+ ],
415
+ "internalType": "struct Fee",
416
+ "name": "distributionFee",
417
+ "type": "tuple"
418
+ },
419
+ {
420
+ "internalType": "bool",
421
+ "name": "isIntercepting",
422
+ "type": "bool"
423
+ },
424
+ {
425
+ "internalType": "address",
426
+ "name": "wallet",
427
+ "type": "address"
428
+ }
429
+ ],
430
+ "internalType": "struct ISetup.DistributionSetupInfo",
431
+ "name": "setup",
432
+ "type": "tuple"
244
433
  }
245
434
  ],
246
- "name": "collateralizePolicy",
435
+ "name": "createDistributionSetup",
247
436
  "outputs": [],
248
437
  "stateMutability": "nonpayable",
249
438
  "type": "function"
@@ -252,513 +441,15 @@
252
441
  "inputs": [
253
442
  {
254
443
  "internalType": "NftId",
255
- "name": "bundleNftId",
256
- "type": "uint96"
257
- },
258
- {
259
- "internalType": "NftId",
260
- "name": "poolNftId",
444
+ "name": "policyNftId",
261
445
  "type": "uint96"
262
446
  },
263
447
  {
264
448
  "components": [
265
449
  {
266
- "internalType": "UFixed",
267
- "name": "fractionalFee",
268
- "type": "uint256"
269
- },
270
- {
271
- "internalType": "uint256",
272
- "name": "fixedFee",
273
- "type": "uint256"
274
- }
275
- ],
276
- "internalType": "struct Fee",
277
- "name": "fee",
278
- "type": "tuple"
279
- },
280
- {
281
- "internalType": "uint256",
282
- "name": "amount",
283
- "type": "uint256"
284
- },
285
- {
286
- "internalType": "uint256",
287
- "name": "lifetime",
288
- "type": "uint256"
289
- },
290
- {
291
- "internalType": "bytes",
292
- "name": "filter",
293
- "type": "bytes"
294
- }
295
- ],
296
- "name": "createBundleInfo",
297
- "outputs": [],
298
- "stateMutability": "nonpayable",
299
- "type": "function"
300
- },
301
- {
302
- "inputs": [
303
- {
304
- "internalType": "NftId",
305
- "name": "policyNftId",
306
- "type": "uint96"
307
- },
308
- {
309
- "internalType": "NftId",
310
- "name": "productNftId",
311
- "type": "uint96"
312
- },
313
- {
314
- "internalType": "ReferralId",
315
- "name": "referralId",
316
- "type": "bytes8"
317
- },
318
- {
319
- "internalType": "RiskId",
320
- "name": "riskId",
321
- "type": "bytes8"
322
- },
323
- {
324
- "internalType": "uint256",
325
- "name": "sumInsuredAmount",
326
- "type": "uint256"
327
- },
328
- {
329
- "internalType": "uint256",
330
- "name": "premiumAmount",
331
- "type": "uint256"
332
- },
333
- {
334
- "internalType": "uint256",
335
- "name": "lifetime",
336
- "type": "uint256"
337
- },
338
- {
339
- "internalType": "NftId",
340
- "name": "bundleNftId",
341
- "type": "uint96"
342
- }
343
- ],
344
- "name": "createPolicyInfo",
345
- "outputs": [],
346
- "stateMutability": "nonpayable",
347
- "type": "function"
348
- },
349
- {
350
- "inputs": [
351
- {
352
- "internalType": "RiskId",
353
- "name": "riskId",
354
- "type": "bytes8"
355
- },
356
- {
357
- "internalType": "NftId",
358
- "name": "productNftId",
359
- "type": "uint96"
360
- },
361
- {
362
- "internalType": "bytes",
363
- "name": "data",
364
- "type": "bytes"
365
- }
366
- ],
367
- "name": "createRisk",
368
- "outputs": [],
369
- "stateMutability": "nonpayable",
370
- "type": "function"
371
- },
372
- {
373
- "inputs": [
374
- {
375
- "internalType": "string",
376
- "name": "roleName",
377
- "type": "string"
378
- }
379
- ],
380
- "name": "createRole",
381
- "outputs": [
382
- {
383
- "internalType": "RoleId",
384
- "name": "role",
385
- "type": "bytes8"
386
- }
387
- ],
388
- "stateMutability": "nonpayable",
389
- "type": "function"
390
- },
391
- {
392
- "inputs": [
393
- {
394
- "internalType": "NftId",
395
- "name": "poolNftId",
396
- "type": "uint96"
397
- }
398
- ],
399
- "name": "getBundleCount",
400
- "outputs": [
401
- {
402
- "internalType": "uint256",
403
- "name": "bundleCount",
404
- "type": "uint256"
405
- }
406
- ],
407
- "stateMutability": "view",
408
- "type": "function"
409
- },
410
- {
411
- "inputs": [
412
- {
413
- "internalType": "NftId",
414
- "name": "nftId",
415
- "type": "uint96"
416
- }
417
- ],
418
- "name": "getBundleInfo",
419
- "outputs": [
420
- {
421
- "components": [
422
- {
423
- "internalType": "NftId",
424
- "name": "poolNftId",
425
- "type": "uint96"
426
- },
427
- {
428
- "components": [
429
- {
430
- "internalType": "UFixed",
431
- "name": "fractionalFee",
432
- "type": "uint256"
433
- },
434
- {
435
- "internalType": "uint256",
436
- "name": "fixedFee",
437
- "type": "uint256"
438
- }
439
- ],
440
- "internalType": "struct Fee",
441
- "name": "fee",
442
- "type": "tuple"
443
- },
444
- {
445
- "internalType": "bytes",
446
- "name": "filter",
447
- "type": "bytes"
448
- },
449
- {
450
- "internalType": "uint256",
451
- "name": "capitalAmount",
452
- "type": "uint256"
453
- },
454
- {
455
- "internalType": "uint256",
456
- "name": "lockedAmount",
457
- "type": "uint256"
458
- },
459
- {
460
- "internalType": "uint256",
461
- "name": "balanceAmount",
462
- "type": "uint256"
463
- },
464
- {
465
- "internalType": "Timestamp",
466
- "name": "expiredAt",
467
- "type": "uint40"
468
- },
469
- {
470
- "internalType": "Timestamp",
471
- "name": "closedAt",
472
- "type": "uint40"
473
- }
474
- ],
475
- "internalType": "struct IBundle.BundleInfo",
476
- "name": "bundleInfo",
477
- "type": "tuple"
478
- }
479
- ],
480
- "stateMutability": "view",
481
- "type": "function"
482
- },
483
- {
484
- "inputs": [
485
- {
486
- "internalType": "NftId",
487
- "name": "poolNftId",
488
- "type": "uint96"
489
- },
490
- {
491
- "internalType": "uint256",
492
- "name": "index",
493
- "type": "uint256"
494
- }
495
- ],
496
- "name": "getBundleNftId",
497
- "outputs": [
498
- {
499
- "internalType": "NftId",
500
- "name": "bundleNftId",
501
- "type": "uint96"
502
- }
503
- ],
504
- "stateMutability": "view",
505
- "type": "function"
506
- },
507
- {
508
- "inputs": [],
509
- "name": "getComponentCount",
510
- "outputs": [
511
- {
512
- "internalType": "uint256",
513
- "name": "numberOfCompnents",
514
- "type": "uint256"
515
- }
516
- ],
517
- "stateMutability": "view",
518
- "type": "function"
519
- },
520
- {
521
- "inputs": [
522
- {
523
- "internalType": "uint256",
524
- "name": "idx",
525
- "type": "uint256"
526
- }
527
- ],
528
- "name": "getComponentId",
529
- "outputs": [
530
- {
531
- "internalType": "NftId",
532
- "name": "nftId",
533
- "type": "uint96"
534
- }
535
- ],
536
- "stateMutability": "view",
537
- "type": "function"
538
- },
539
- {
540
- "inputs": [],
541
- "name": "getComponentOwnerService",
542
- "outputs": [
543
- {
544
- "internalType": "contract IComponentOwnerService",
545
- "name": "",
546
- "type": "address"
547
- }
548
- ],
549
- "stateMutability": "view",
550
- "type": "function"
551
- },
552
- {
553
- "inputs": [
554
- {
555
- "internalType": "NftId",
556
- "name": "nftId",
557
- "type": "uint96"
558
- }
559
- ],
560
- "name": "getComponentToken",
561
- "outputs": [
562
- {
563
- "internalType": "contract IERC20Metadata",
564
- "name": "token",
565
- "type": "address"
566
- }
567
- ],
568
- "stateMutability": "view",
569
- "type": "function"
570
- },
571
- {
572
- "inputs": [
573
- {
574
- "internalType": "NftId",
575
- "name": "nftId",
576
- "type": "uint96"
577
- }
578
- ],
579
- "name": "getComponentWallet",
580
- "outputs": [
581
- {
582
- "internalType": "address",
583
- "name": "wallet",
584
- "type": "address"
585
- }
586
- ],
587
- "stateMutability": "view",
588
- "type": "function"
589
- },
590
- {
591
- "inputs": [],
592
- "name": "getDistributionService",
593
- "outputs": [
594
- {
595
- "internalType": "contract IDistributionService",
596
- "name": "",
597
- "type": "address"
598
- }
599
- ],
600
- "stateMutability": "view",
601
- "type": "function"
602
- },
603
- {
604
- "inputs": [
605
- {
606
- "internalType": "UFixed",
607
- "name": "fractionalFee",
608
- "type": "uint256"
609
- },
610
- {
611
- "internalType": "uint256",
612
- "name": "fixedFee",
613
- "type": "uint256"
614
- }
615
- ],
616
- "name": "getFee",
617
- "outputs": [
618
- {
619
- "components": [
620
- {
621
- "internalType": "UFixed",
622
- "name": "fractionalFee",
623
- "type": "uint256"
624
- },
625
- {
626
- "internalType": "uint256",
627
- "name": "fixedFee",
628
- "type": "uint256"
629
- }
630
- ],
631
- "internalType": "struct Fee",
632
- "name": "fee",
633
- "type": "tuple"
634
- }
635
- ],
636
- "stateMutability": "pure",
637
- "type": "function"
638
- },
639
- {
640
- "inputs": [],
641
- "name": "getInitialInfo",
642
- "outputs": [
643
- {
644
- "components": [
645
- {
646
- "internalType": "NftId",
647
- "name": "nftId",
648
- "type": "uint96"
649
- },
650
- {
651
- "internalType": "NftId",
652
- "name": "parentNftId",
653
- "type": "uint96"
654
- },
655
- {
656
- "internalType": "ObjectType",
657
- "name": "objectType",
658
- "type": "uint8"
659
- },
660
- {
661
- "internalType": "bool",
662
- "name": "isInterceptor",
663
- "type": "bool"
664
- },
665
- {
666
- "internalType": "address",
667
- "name": "objectAddress",
668
- "type": "address"
669
- },
670
- {
671
- "internalType": "address",
672
- "name": "initialOwner",
673
- "type": "address"
674
- },
675
- {
676
- "internalType": "bytes",
677
- "name": "data",
678
- "type": "bytes"
679
- }
680
- ],
681
- "internalType": "struct IRegistry.ObjectInfo",
682
- "name": "",
683
- "type": "tuple"
684
- },
685
- {
686
- "internalType": "bytes",
687
- "name": "data",
688
- "type": "bytes"
689
- }
690
- ],
691
- "stateMutability": "view",
692
- "type": "function"
693
- },
694
- {
695
- "inputs": [],
696
- "name": "getInitializedVersion",
697
- "outputs": [
698
- {
699
- "internalType": "uint64",
700
- "name": "",
701
- "type": "uint64"
702
- }
703
- ],
704
- "stateMutability": "view",
705
- "type": "function"
706
- },
707
- {
708
- "inputs": [],
709
- "name": "getKeyValueStore",
710
- "outputs": [
711
- {
712
- "internalType": "contract IKeyValueStore",
713
- "name": "keyValueStore",
714
- "type": "address"
715
- }
716
- ],
717
- "stateMutability": "view",
718
- "type": "function"
719
- },
720
- {
721
- "inputs": [],
722
- "name": "getNftId",
723
- "outputs": [
724
- {
725
- "internalType": "NftId",
726
- "name": "",
727
- "type": "uint96"
728
- }
729
- ],
730
- "stateMutability": "view",
731
- "type": "function"
732
- },
733
- {
734
- "inputs": [],
735
- "name": "getOwner",
736
- "outputs": [
737
- {
738
- "internalType": "address",
739
- "name": "owner",
740
- "type": "address"
741
- }
742
- ],
743
- "stateMutability": "view",
744
- "type": "function"
745
- },
746
- {
747
- "inputs": [
748
- {
749
- "internalType": "NftId",
750
- "name": "nftId",
751
- "type": "uint96"
752
- }
753
- ],
754
- "name": "getPolicyInfo",
755
- "outputs": [
756
- {
757
- "components": [
758
- {
759
- "internalType": "NftId",
760
- "name": "productNftId",
761
- "type": "uint96"
450
+ "internalType": "NftId",
451
+ "name": "productNftId",
452
+ "type": "uint96"
762
453
  },
763
454
  {
764
455
  "internalType": "NftId",
@@ -768,12 +459,7 @@
768
459
  {
769
460
  "internalType": "ReferralId",
770
461
  "name": "referralId",
771
- "type": "bytes8"
772
- },
773
- {
774
- "internalType": "address",
775
- "name": "beneficiary",
776
- "type": "address"
462
+ "type": "bytes8"
777
463
  },
778
464
  {
779
465
  "internalType": "RiskId",
@@ -794,332 +480,162 @@
794
480
  "internalType": "uint256",
795
481
  "name": "premiumPaidAmount",
796
482
  "type": "uint256"
797
- },
798
- {
799
- "internalType": "uint256",
800
- "name": "lifetime",
801
- "type": "uint256"
802
- },
803
- {
804
- "internalType": "bytes",
805
- "name": "applicationData",
806
- "type": "bytes"
807
- },
808
- {
809
- "internalType": "bytes",
810
- "name": "policyData",
811
- "type": "bytes"
812
- },
813
- {
814
- "internalType": "Timestamp",
815
- "name": "activatedAt",
816
- "type": "uint40"
817
- },
818
- {
819
- "internalType": "Timestamp",
820
- "name": "expiredAt",
821
- "type": "uint40"
822
- },
823
- {
824
- "internalType": "Timestamp",
825
- "name": "closedAt",
826
- "type": "uint40"
827
- }
828
- ],
829
- "internalType": "struct IPolicy.PolicyInfo",
830
- "name": "info",
831
- "type": "tuple"
832
- }
833
- ],
834
- "stateMutability": "view",
835
- "type": "function"
836
- },
837
- {
838
- "inputs": [
839
- {
840
- "internalType": "NftId",
841
- "name": "nftId",
842
- "type": "uint96"
843
- }
844
- ],
845
- "name": "getPoolInfo",
846
- "outputs": [
847
- {
848
- "components": [
849
- {
850
- "internalType": "bool",
851
- "name": "isVerifying",
852
- "type": "bool"
853
- },
854
- {
855
- "internalType": "UFixed",
856
- "name": "collateralizationLevel",
857
- "type": "uint256"
858
- }
859
- ],
860
- "internalType": "struct IPool.PoolInfo",
861
- "name": "info",
862
- "type": "tuple"
863
- }
864
- ],
865
- "stateMutability": "view",
866
- "type": "function"
867
- },
868
- {
869
- "inputs": [],
870
- "name": "getPoolService",
871
- "outputs": [
872
- {
873
- "internalType": "contract IPoolService",
874
- "name": "",
875
- "type": "address"
876
- }
877
- ],
878
- "stateMutability": "view",
879
- "type": "function"
880
- },
881
- {
882
- "inputs": [
883
- {
884
- "internalType": "NftId",
885
- "name": "componentNftId",
886
- "type": "uint96"
887
- }
888
- ],
889
- "name": "getProductNftId",
890
- "outputs": [
891
- {
892
- "internalType": "NftId",
893
- "name": "productNftId",
894
- "type": "uint96"
895
- }
896
- ],
897
- "stateMutability": "view",
898
- "type": "function"
899
- },
900
- {
901
- "inputs": [],
902
- "name": "getProductService",
903
- "outputs": [
904
- {
905
- "internalType": "contract IProductService",
906
- "name": "",
907
- "type": "address"
908
- }
909
- ],
910
- "stateMutability": "view",
911
- "type": "function"
912
- },
913
- {
914
- "inputs": [],
915
- "name": "getRegistry",
916
- "outputs": [
917
- {
918
- "internalType": "contract IRegistry",
919
- "name": "registry",
920
- "type": "address"
921
- }
922
- ],
923
- "stateMutability": "view",
924
- "type": "function"
925
- },
926
- {
927
- "inputs": [
928
- {
929
- "internalType": "RiskId",
930
- "name": "riskId",
931
- "type": "bytes8"
932
- }
933
- ],
934
- "name": "getRiskInfo",
935
- "outputs": [
936
- {
937
- "components": [
938
- {
939
- "internalType": "NftId",
940
- "name": "productNftId",
941
- "type": "uint96"
942
- },
943
- {
944
- "internalType": "bytes",
945
- "name": "data",
946
- "type": "bytes"
947
- }
948
- ],
949
- "internalType": "struct IRisk.RiskInfo",
950
- "name": "info",
951
- "type": "tuple"
952
- }
953
- ],
954
- "stateMutability": "view",
955
- "type": "function"
956
- },
957
- {
958
- "inputs": [
959
- {
960
- "internalType": "uint256",
961
- "name": "idx",
962
- "type": "uint256"
963
- }
964
- ],
965
- "name": "getRole",
966
- "outputs": [
967
- {
968
- "internalType": "RoleId",
969
- "name": "role",
970
- "type": "bytes8"
971
- }
972
- ],
973
- "stateMutability": "view",
974
- "type": "function"
975
- },
976
- {
977
- "inputs": [],
978
- "name": "getRoleCount",
979
- "outputs": [
980
- {
981
- "internalType": "uint256",
982
- "name": "roles",
983
- "type": "uint256"
984
- }
985
- ],
986
- "stateMutability": "view",
987
- "type": "function"
988
- },
989
- {
990
- "inputs": [
991
- {
992
- "internalType": "string",
993
- "name": "roleName",
994
- "type": "string"
995
- }
996
- ],
997
- "name": "getRoleId",
998
- "outputs": [
999
- {
1000
- "internalType": "RoleId",
1001
- "name": "role",
1002
- "type": "bytes8"
1003
- }
1004
- ],
1005
- "stateMutability": "pure",
1006
- "type": "function"
1007
- },
1008
- {
1009
- "inputs": [
1010
- {
1011
- "internalType": "RoleId",
1012
- "name": "role",
1013
- "type": "bytes8"
1014
- }
1015
- ],
1016
- "name": "getRoleInfo",
1017
- "outputs": [
1018
- {
1019
- "components": [
1020
- {
1021
- "internalType": "RoleId",
1022
- "name": "id",
1023
- "type": "bytes8"
1024
- },
1025
- {
1026
- "internalType": "string",
1027
- "name": "name",
1028
- "type": "string"
1029
- },
1030
- {
1031
- "internalType": "bool",
1032
- "name": "isActive",
1033
- "type": "bool"
1034
- }
1035
- ],
1036
- "internalType": "struct IAccess.RoleInfo",
1037
- "name": "info",
1038
- "type": "tuple"
1039
- }
1040
- ],
1041
- "stateMutability": "view",
1042
- "type": "function"
1043
- },
1044
- {
1045
- "inputs": [
1046
- {
1047
- "internalType": "RoleId",
1048
- "name": "role",
1049
- "type": "bytes8"
1050
- },
1051
- {
1052
- "internalType": "uint256",
1053
- "name": "idx",
1054
- "type": "uint256"
1055
- }
1056
- ],
1057
- "name": "getRoleMember",
1058
- "outputs": [
1059
- {
1060
- "internalType": "address",
1061
- "name": "roleMember",
1062
- "type": "address"
1063
- }
1064
- ],
1065
- "stateMutability": "view",
1066
- "type": "function"
1067
- },
1068
- {
1069
- "inputs": [
1070
- {
1071
- "internalType": "RoleId",
1072
- "name": "role",
1073
- "type": "bytes8"
1074
- }
1075
- ],
1076
- "name": "getRoleMemberCount",
1077
- "outputs": [
1078
- {
1079
- "internalType": "uint256",
1080
- "name": "roleMembers",
1081
- "type": "uint256"
1082
- }
1083
- ],
1084
- "stateMutability": "view",
1085
- "type": "function"
1086
- },
1087
- {
1088
- "inputs": [
1089
- {
1090
- "internalType": "Key32",
1091
- "name": "key",
1092
- "type": "bytes32"
1093
- }
1094
- ],
1095
- "name": "getState",
1096
- "outputs": [
1097
- {
1098
- "internalType": "StateId",
1099
- "name": "state",
1100
- "type": "uint8"
483
+ },
484
+ {
485
+ "internalType": "uint256",
486
+ "name": "lifetime",
487
+ "type": "uint256"
488
+ },
489
+ {
490
+ "internalType": "bytes",
491
+ "name": "applicationData",
492
+ "type": "bytes"
493
+ },
494
+ {
495
+ "internalType": "bytes",
496
+ "name": "policyData",
497
+ "type": "bytes"
498
+ },
499
+ {
500
+ "internalType": "uint16",
501
+ "name": "claimsCount",
502
+ "type": "uint16"
503
+ },
504
+ {
505
+ "internalType": "uint16",
506
+ "name": "openClaimsCount",
507
+ "type": "uint16"
508
+ },
509
+ {
510
+ "internalType": "uint256",
511
+ "name": "payoutAmount",
512
+ "type": "uint256"
513
+ },
514
+ {
515
+ "internalType": "Timestamp",
516
+ "name": "activatedAt",
517
+ "type": "uint40"
518
+ },
519
+ {
520
+ "internalType": "Timestamp",
521
+ "name": "expiredAt",
522
+ "type": "uint40"
523
+ },
524
+ {
525
+ "internalType": "Timestamp",
526
+ "name": "closedAt",
527
+ "type": "uint40"
528
+ }
529
+ ],
530
+ "internalType": "struct IPolicy.PolicyInfo",
531
+ "name": "policy",
532
+ "type": "tuple"
1101
533
  }
1102
534
  ],
1103
- "stateMutability": "view",
535
+ "name": "createPolicy",
536
+ "outputs": [],
537
+ "stateMutability": "nonpayable",
1104
538
  "type": "function"
1105
539
  },
1106
540
  {
1107
541
  "inputs": [
1108
542
  {
1109
543
  "internalType": "NftId",
1110
- "name": "componentNftId",
544
+ "name": "poolNftId",
1111
545
  "type": "uint96"
1112
- }
1113
- ],
1114
- "name": "getTokenHandler",
1115
- "outputs": [
546
+ },
1116
547
  {
1117
- "internalType": "contract TokenHandler",
1118
- "name": "tokenHandler",
1119
- "type": "address"
548
+ "components": [
549
+ {
550
+ "internalType": "NftId",
551
+ "name": "productNftId",
552
+ "type": "uint96"
553
+ },
554
+ {
555
+ "internalType": "contract TokenHandler",
556
+ "name": "tokenHandler",
557
+ "type": "address"
558
+ },
559
+ {
560
+ "internalType": "UFixed",
561
+ "name": "collateralizationLevel",
562
+ "type": "uint256"
563
+ },
564
+ {
565
+ "components": [
566
+ {
567
+ "internalType": "UFixed",
568
+ "name": "fractionalFee",
569
+ "type": "uint256"
570
+ },
571
+ {
572
+ "internalType": "uint256",
573
+ "name": "fixedFee",
574
+ "type": "uint256"
575
+ }
576
+ ],
577
+ "internalType": "struct Fee",
578
+ "name": "poolFee",
579
+ "type": "tuple"
580
+ },
581
+ {
582
+ "components": [
583
+ {
584
+ "internalType": "UFixed",
585
+ "name": "fractionalFee",
586
+ "type": "uint256"
587
+ },
588
+ {
589
+ "internalType": "uint256",
590
+ "name": "fixedFee",
591
+ "type": "uint256"
592
+ }
593
+ ],
594
+ "internalType": "struct Fee",
595
+ "name": "stakingFee",
596
+ "type": "tuple"
597
+ },
598
+ {
599
+ "components": [
600
+ {
601
+ "internalType": "UFixed",
602
+ "name": "fractionalFee",
603
+ "type": "uint256"
604
+ },
605
+ {
606
+ "internalType": "uint256",
607
+ "name": "fixedFee",
608
+ "type": "uint256"
609
+ }
610
+ ],
611
+ "internalType": "struct Fee",
612
+ "name": "performanceFee",
613
+ "type": "tuple"
614
+ },
615
+ {
616
+ "internalType": "bool",
617
+ "name": "isIntercepting",
618
+ "type": "bool"
619
+ },
620
+ {
621
+ "internalType": "bool",
622
+ "name": "isConfirmingApplication",
623
+ "type": "bool"
624
+ },
625
+ {
626
+ "internalType": "address",
627
+ "name": "wallet",
628
+ "type": "address"
629
+ }
630
+ ],
631
+ "internalType": "struct ISetup.PoolSetupInfo",
632
+ "name": "setup",
633
+ "type": "tuple"
1120
634
  }
1121
635
  ],
1122
- "stateMutability": "view",
636
+ "name": "createPoolSetup",
637
+ "outputs": [],
638
+ "stateMutability": "nonpayable",
1123
639
  "type": "function"
1124
640
  },
1125
641
  {
@@ -1128,26 +644,45 @@
1128
644
  "internalType": "NftId",
1129
645
  "name": "productNftId",
1130
646
  "type": "uint96"
1131
- }
1132
- ],
1133
- "name": "getTreasuryInfo",
1134
- "outputs": [
647
+ },
1135
648
  {
1136
649
  "components": [
650
+ {
651
+ "internalType": "contract IERC20Metadata",
652
+ "name": "token",
653
+ "type": "address"
654
+ },
655
+ {
656
+ "internalType": "contract TokenHandler",
657
+ "name": "tokenHandler",
658
+ "type": "address"
659
+ },
1137
660
  {
1138
661
  "internalType": "NftId",
1139
- "name": "poolNftId",
662
+ "name": "distributionNftId",
1140
663
  "type": "uint96"
1141
664
  },
1142
665
  {
1143
666
  "internalType": "NftId",
1144
- "name": "distributionNftId",
667
+ "name": "poolNftId",
1145
668
  "type": "uint96"
1146
669
  },
1147
670
  {
1148
- "internalType": "contract IERC20Metadata",
1149
- "name": "token",
1150
- "type": "address"
671
+ "components": [
672
+ {
673
+ "internalType": "UFixed",
674
+ "name": "fractionalFee",
675
+ "type": "uint256"
676
+ },
677
+ {
678
+ "internalType": "uint256",
679
+ "name": "fixedFee",
680
+ "type": "uint256"
681
+ }
682
+ ],
683
+ "internalType": "struct Fee",
684
+ "name": "distributionFee",
685
+ "type": "tuple"
1151
686
  },
1152
687
  {
1153
688
  "components": [
@@ -1220,40 +755,142 @@
1220
755
  {
1221
756
  "components": [
1222
757
  {
1223
- "internalType": "UFixed",
1224
- "name": "fractionalFee",
1225
- "type": "uint256"
758
+ "internalType": "UFixed",
759
+ "name": "fractionalFee",
760
+ "type": "uint256"
761
+ },
762
+ {
763
+ "internalType": "uint256",
764
+ "name": "fixedFee",
765
+ "type": "uint256"
766
+ }
767
+ ],
768
+ "internalType": "struct Fee",
769
+ "name": "performanceFee",
770
+ "type": "tuple"
771
+ },
772
+ {
773
+ "internalType": "bool",
774
+ "name": "isIntercepting",
775
+ "type": "bool"
776
+ },
777
+ {
778
+ "internalType": "address",
779
+ "name": "wallet",
780
+ "type": "address"
781
+ }
782
+ ],
783
+ "internalType": "struct ISetup.ProductSetupInfo",
784
+ "name": "setup",
785
+ "type": "tuple"
786
+ }
787
+ ],
788
+ "name": "createProductSetup",
789
+ "outputs": [],
790
+ "stateMutability": "nonpayable",
791
+ "type": "function"
792
+ },
793
+ {
794
+ "inputs": [
795
+ {
796
+ "internalType": "RiskId",
797
+ "name": "riskId",
798
+ "type": "bytes8"
799
+ },
800
+ {
801
+ "components": [
802
+ {
803
+ "internalType": "NftId",
804
+ "name": "productNftId",
805
+ "type": "uint96"
806
+ },
807
+ {
808
+ "internalType": "bytes",
809
+ "name": "data",
810
+ "type": "bytes"
811
+ }
812
+ ],
813
+ "internalType": "struct IRisk.RiskInfo",
814
+ "name": "risk",
815
+ "type": "tuple"
816
+ }
817
+ ],
818
+ "name": "createRisk",
819
+ "outputs": [],
820
+ "stateMutability": "nonpayable",
821
+ "type": "function"
822
+ },
823
+ {
824
+ "inputs": [
825
+ {
826
+ "internalType": "Key32",
827
+ "name": "key",
828
+ "type": "bytes32"
829
+ }
830
+ ],
831
+ "name": "exists",
832
+ "outputs": [
833
+ {
834
+ "internalType": "bool",
835
+ "name": "",
836
+ "type": "bool"
837
+ }
838
+ ],
839
+ "stateMutability": "view",
840
+ "type": "function"
841
+ },
842
+ {
843
+ "inputs": [
844
+ {
845
+ "internalType": "Key32",
846
+ "name": "key",
847
+ "type": "bytes32"
848
+ }
849
+ ],
850
+ "name": "get",
851
+ "outputs": [
852
+ {
853
+ "components": [
854
+ {
855
+ "components": [
856
+ {
857
+ "internalType": "ObjectType",
858
+ "name": "objectType",
859
+ "type": "uint8"
1226
860
  },
1227
861
  {
1228
- "internalType": "uint256",
1229
- "name": "fixedFee",
1230
- "type": "uint256"
1231
- }
1232
- ],
1233
- "internalType": "struct Fee",
1234
- "name": "performanceFee",
1235
- "type": "tuple"
1236
- },
1237
- {
1238
- "components": [
862
+ "internalType": "StateId",
863
+ "name": "state",
864
+ "type": "uint8"
865
+ },
1239
866
  {
1240
- "internalType": "UFixed",
1241
- "name": "fractionalFee",
1242
- "type": "uint256"
867
+ "internalType": "address",
868
+ "name": "updatedBy",
869
+ "type": "address"
1243
870
  },
1244
871
  {
1245
- "internalType": "uint256",
1246
- "name": "fixedFee",
1247
- "type": "uint256"
872
+ "internalType": "Blocknumber",
873
+ "name": "updatedIn",
874
+ "type": "uint32"
875
+ },
876
+ {
877
+ "internalType": "Blocknumber",
878
+ "name": "createdIn",
879
+ "type": "uint32"
1248
880
  }
1249
881
  ],
1250
- "internalType": "struct Fee",
1251
- "name": "distributionFee",
882
+ "internalType": "struct IKeyValueStore.Metadata",
883
+ "name": "metadata",
1252
884
  "type": "tuple"
885
+ },
886
+ {
887
+ "internalType": "bytes",
888
+ "name": "data",
889
+ "type": "bytes"
1253
890
  }
1254
891
  ],
1255
- "internalType": "struct ITreasury.TreasuryInfo",
1256
- "name": "info",
892
+ "internalType": "struct IKeyValueStore.Value",
893
+ "name": "value",
1257
894
  "type": "tuple"
1258
895
  }
1259
896
  ],
@@ -1261,75 +898,127 @@
1261
898
  "type": "function"
1262
899
  },
1263
900
  {
1264
- "inputs": [
1265
- {
1266
- "internalType": "uint256",
1267
- "name": "a",
1268
- "type": "uint256"
1269
- },
901
+ "inputs": [],
902
+ "name": "getBundleManager",
903
+ "outputs": [
1270
904
  {
1271
- "internalType": "int8",
1272
- "name": "exp",
1273
- "type": "int8"
905
+ "internalType": "contract BundleManager",
906
+ "name": "",
907
+ "type": "address"
1274
908
  }
1275
909
  ],
1276
- "name": "getUFixed",
910
+ "stateMutability": "view",
911
+ "type": "function"
912
+ },
913
+ {
914
+ "inputs": [],
915
+ "name": "getBundleService",
1277
916
  "outputs": [
1278
917
  {
1279
- "internalType": "UFixed",
918
+ "internalType": "contract IBundleService",
1280
919
  "name": "",
1281
- "type": "uint256"
920
+ "type": "address"
1282
921
  }
1283
922
  ],
1284
- "stateMutability": "pure",
923
+ "stateMutability": "view",
1285
924
  "type": "function"
1286
925
  },
1287
926
  {
1288
927
  "inputs": [
1289
928
  {
1290
- "internalType": "uint256",
1291
- "name": "a",
1292
- "type": "uint256"
929
+ "internalType": "Key32",
930
+ "name": "key",
931
+ "type": "bytes32"
932
+ }
933
+ ],
934
+ "name": "getData",
935
+ "outputs": [
936
+ {
937
+ "internalType": "bytes",
938
+ "name": "data",
939
+ "type": "bytes"
1293
940
  }
1294
941
  ],
1295
- "name": "getUFixed",
942
+ "stateMutability": "view",
943
+ "type": "function"
944
+ },
945
+ {
946
+ "inputs": [],
947
+ "name": "getDistributionService",
1296
948
  "outputs": [
1297
949
  {
1298
- "internalType": "UFixed",
950
+ "internalType": "contract IDistributionService",
1299
951
  "name": "",
1300
- "type": "uint256"
952
+ "type": "address"
1301
953
  }
1302
954
  ],
1303
- "stateMutability": "pure",
955
+ "stateMutability": "view",
1304
956
  "type": "function"
1305
957
  },
1306
958
  {
1307
959
  "inputs": [],
1308
- "name": "getVersion",
960
+ "name": "getInitialInfo",
1309
961
  "outputs": [
1310
962
  {
1311
- "internalType": "Version",
963
+ "components": [
964
+ {
965
+ "internalType": "NftId",
966
+ "name": "nftId",
967
+ "type": "uint96"
968
+ },
969
+ {
970
+ "internalType": "NftId",
971
+ "name": "parentNftId",
972
+ "type": "uint96"
973
+ },
974
+ {
975
+ "internalType": "ObjectType",
976
+ "name": "objectType",
977
+ "type": "uint8"
978
+ },
979
+ {
980
+ "internalType": "bool",
981
+ "name": "isInterceptor",
982
+ "type": "bool"
983
+ },
984
+ {
985
+ "internalType": "address",
986
+ "name": "objectAddress",
987
+ "type": "address"
988
+ },
989
+ {
990
+ "internalType": "address",
991
+ "name": "initialOwner",
992
+ "type": "address"
993
+ },
994
+ {
995
+ "internalType": "bytes",
996
+ "name": "data",
997
+ "type": "bytes"
998
+ }
999
+ ],
1000
+ "internalType": "struct IRegistry.ObjectInfo",
1312
1001
  "name": "",
1313
- "type": "uint24"
1002
+ "type": "tuple"
1314
1003
  }
1315
1004
  ],
1316
- "stateMutability": "pure",
1005
+ "stateMutability": "view",
1317
1006
  "type": "function"
1318
1007
  },
1319
1008
  {
1320
1009
  "inputs": [
1321
1010
  {
1322
- "internalType": "uint256",
1323
- "name": "index",
1324
- "type": "uint256"
1011
+ "internalType": "ObjectType",
1012
+ "name": "objectType",
1013
+ "type": "uint8"
1325
1014
  }
1326
1015
  ],
1327
- "name": "getVersion",
1016
+ "name": "getInitialState",
1328
1017
  "outputs": [
1329
1018
  {
1330
- "internalType": "Version",
1331
- "name": "version",
1332
- "type": "uint24"
1019
+ "internalType": "StateId",
1020
+ "name": "",
1021
+ "type": "uint8"
1333
1022
  }
1334
1023
  ],
1335
1024
  "stateMutability": "view",
@@ -1337,57 +1026,70 @@
1337
1026
  },
1338
1027
  {
1339
1028
  "inputs": [],
1340
- "name": "getVersionCount",
1029
+ "name": "getInstanceReader",
1341
1030
  "outputs": [
1342
1031
  {
1343
- "internalType": "uint256",
1344
- "name": "numberOfVersions",
1345
- "type": "uint256"
1032
+ "internalType": "contract InstanceReader",
1033
+ "name": "",
1034
+ "type": "address"
1346
1035
  }
1347
1036
  ],
1348
1037
  "stateMutability": "view",
1349
1038
  "type": "function"
1350
1039
  },
1040
+ {
1041
+ "inputs": [],
1042
+ "name": "getMajorVersion",
1043
+ "outputs": [
1044
+ {
1045
+ "internalType": "VersionPart",
1046
+ "name": "majorVersion",
1047
+ "type": "uint8"
1048
+ }
1049
+ ],
1050
+ "stateMutability": "pure",
1051
+ "type": "function"
1052
+ },
1351
1053
  {
1352
1054
  "inputs": [
1353
1055
  {
1354
- "internalType": "Version",
1355
- "name": "version",
1356
- "type": "uint24"
1056
+ "internalType": "Key32",
1057
+ "name": "key",
1058
+ "type": "bytes32"
1357
1059
  }
1358
1060
  ],
1359
- "name": "getVersionInfo",
1061
+ "name": "getMetadata",
1360
1062
  "outputs": [
1361
1063
  {
1362
1064
  "components": [
1363
1065
  {
1364
- "internalType": "Version",
1365
- "name": "version",
1366
- "type": "uint24"
1066
+ "internalType": "ObjectType",
1067
+ "name": "objectType",
1068
+ "type": "uint8"
1367
1069
  },
1368
1070
  {
1369
- "internalType": "address",
1370
- "name": "implementation",
1371
- "type": "address"
1071
+ "internalType": "StateId",
1072
+ "name": "state",
1073
+ "type": "uint8"
1372
1074
  },
1373
1075
  {
1374
1076
  "internalType": "address",
1375
- "name": "activatedBy",
1077
+ "name": "updatedBy",
1376
1078
  "type": "address"
1377
1079
  },
1378
1080
  {
1379
- "internalType": "Timestamp",
1380
- "name": "activatedAt",
1381
- "type": "uint40"
1081
+ "internalType": "Blocknumber",
1082
+ "name": "updatedIn",
1083
+ "type": "uint32"
1382
1084
  },
1383
1085
  {
1384
1086
  "internalType": "Blocknumber",
1385
- "name": "activatedIn",
1087
+ "name": "createdIn",
1386
1088
  "type": "uint32"
1387
1089
  }
1388
1090
  ],
1389
- "internalType": "struct IVersionable.VersionInfo",
1390
- "name": "versionInfo",
1091
+ "internalType": "struct IKeyValueStore.Metadata",
1092
+ "name": "metadata",
1391
1093
  "type": "tuple"
1392
1094
  }
1393
1095
  ],
@@ -1396,66 +1098,77 @@
1396
1098
  },
1397
1099
  {
1398
1100
  "inputs": [],
1399
- "name": "getZeroFee",
1101
+ "name": "getNftId",
1400
1102
  "outputs": [
1401
1103
  {
1402
- "components": [
1403
- {
1404
- "internalType": "UFixed",
1405
- "name": "fractionalFee",
1406
- "type": "uint256"
1407
- },
1408
- {
1409
- "internalType": "uint256",
1410
- "name": "fixedFee",
1411
- "type": "uint256"
1412
- }
1413
- ],
1414
- "internalType": "struct Fee",
1415
- "name": "fee",
1416
- "type": "tuple"
1104
+ "internalType": "NftId",
1105
+ "name": "",
1106
+ "type": "uint96"
1417
1107
  }
1418
1108
  ],
1419
1109
  "stateMutability": "view",
1420
1110
  "type": "function"
1421
1111
  },
1422
1112
  {
1423
- "inputs": [
1424
- {
1425
- "internalType": "RoleId",
1426
- "name": "role",
1427
- "type": "bytes8"
1428
- },
1113
+ "inputs": [],
1114
+ "name": "getOwner",
1115
+ "outputs": [
1429
1116
  {
1430
1117
  "internalType": "address",
1431
- "name": "member",
1118
+ "name": "",
1432
1119
  "type": "address"
1433
1120
  }
1434
1121
  ],
1435
- "name": "grantRole",
1436
- "outputs": [],
1437
- "stateMutability": "nonpayable",
1122
+ "stateMutability": "view",
1438
1123
  "type": "function"
1439
1124
  },
1440
1125
  {
1441
- "inputs": [
1126
+ "inputs": [],
1127
+ "name": "getPolicyService",
1128
+ "outputs": [
1442
1129
  {
1443
- "internalType": "RoleId",
1444
- "name": "role",
1445
- "type": "bytes8"
1446
- },
1130
+ "internalType": "contract IPolicyService",
1131
+ "name": "",
1132
+ "type": "address"
1133
+ }
1134
+ ],
1135
+ "stateMutability": "view",
1136
+ "type": "function"
1137
+ },
1138
+ {
1139
+ "inputs": [],
1140
+ "name": "getPoolService",
1141
+ "outputs": [
1447
1142
  {
1448
- "internalType": "address",
1449
- "name": "member",
1143
+ "internalType": "contract IPoolService",
1144
+ "name": "",
1450
1145
  "type": "address"
1451
1146
  }
1452
1147
  ],
1453
- "name": "hasRole",
1148
+ "stateMutability": "view",
1149
+ "type": "function"
1150
+ },
1151
+ {
1152
+ "inputs": [],
1153
+ "name": "getProductService",
1454
1154
  "outputs": [
1455
1155
  {
1456
- "internalType": "bool",
1156
+ "internalType": "contract IProductService",
1457
1157
  "name": "",
1458
- "type": "bool"
1158
+ "type": "address"
1159
+ }
1160
+ ],
1161
+ "stateMutability": "view",
1162
+ "type": "function"
1163
+ },
1164
+ {
1165
+ "inputs": [],
1166
+ "name": "getRegistry",
1167
+ "outputs": [
1168
+ {
1169
+ "internalType": "contract IRegistry",
1170
+ "name": "",
1171
+ "type": "address"
1459
1172
  }
1460
1173
  ],
1461
1174
  "stateMutability": "view",
@@ -1464,17 +1177,17 @@
1464
1177
  {
1465
1178
  "inputs": [
1466
1179
  {
1467
- "internalType": "NftId",
1468
- "name": "productNftId",
1469
- "type": "uint96"
1180
+ "internalType": "Key32",
1181
+ "name": "key",
1182
+ "type": "bytes32"
1470
1183
  }
1471
1184
  ],
1472
- "name": "hasTreasuryInfo",
1185
+ "name": "getState",
1473
1186
  "outputs": [
1474
1187
  {
1475
- "internalType": "bool",
1476
- "name": "hasInfo",
1477
- "type": "bool"
1188
+ "internalType": "StateId",
1189
+ "name": "state",
1190
+ "type": "uint8"
1478
1191
  }
1479
1192
  ],
1480
1193
  "stateMutability": "view",
@@ -1483,35 +1196,54 @@
1483
1196
  {
1484
1197
  "inputs": [
1485
1198
  {
1486
- "internalType": "address",
1487
- "name": "implementation",
1488
- "type": "address"
1489
- },
1199
+ "internalType": "ObjectType",
1200
+ "name": "objectType",
1201
+ "type": "uint8"
1202
+ }
1203
+ ],
1204
+ "name": "hasLifecycle",
1205
+ "outputs": [
1490
1206
  {
1491
- "internalType": "address",
1492
- "name": "activatedBy",
1493
- "type": "address"
1494
- },
1207
+ "internalType": "bool",
1208
+ "name": "",
1209
+ "type": "bool"
1210
+ }
1211
+ ],
1212
+ "stateMutability": "view",
1213
+ "type": "function"
1214
+ },
1215
+ {
1216
+ "inputs": [],
1217
+ "name": "isConsumingScheduledOp",
1218
+ "outputs": [
1495
1219
  {
1496
- "internalType": "bytes",
1497
- "name": "activationData",
1498
- "type": "bytes"
1220
+ "internalType": "bytes4",
1221
+ "name": "",
1222
+ "type": "bytes4"
1499
1223
  }
1500
1224
  ],
1501
- "name": "initialize",
1502
- "outputs": [],
1503
- "stateMutability": "nonpayable",
1225
+ "stateMutability": "view",
1504
1226
  "type": "function"
1505
1227
  },
1506
1228
  {
1507
1229
  "inputs": [
1508
1230
  {
1509
- "internalType": "Version",
1510
- "name": "version",
1511
- "type": "uint24"
1231
+ "internalType": "ObjectType",
1232
+ "name": "objectType",
1233
+ "type": "uint8"
1234
+ },
1235
+ {
1236
+ "internalType": "StateId",
1237
+ "name": "fromId",
1238
+ "type": "uint8"
1239
+ },
1240
+ {
1241
+ "internalType": "StateId",
1242
+ "name": "toId",
1243
+ "type": "uint8"
1512
1244
  }
1513
1245
  ],
1514
- "name": "isInitialized",
1246
+ "name": "isValidTransition",
1515
1247
  "outputs": [
1516
1248
  {
1517
1249
  "internalType": "bool",
@@ -1531,23 +1263,13 @@
1531
1263
  },
1532
1264
  {
1533
1265
  "inputs": [
1534
- {
1535
- "internalType": "NftId",
1536
- "name": "nftId",
1537
- "type": "uint96"
1538
- },
1539
- {
1540
- "internalType": "contract IERC20Metadata",
1541
- "name": "token",
1542
- "type": "address"
1543
- },
1544
1266
  {
1545
1267
  "internalType": "address",
1546
- "name": "wallet",
1268
+ "name": "",
1547
1269
  "type": "address"
1548
1270
  }
1549
1271
  ],
1550
- "name": "registerComponent",
1272
+ "name": "setAuthority",
1551
1273
  "outputs": [],
1552
1274
  "stateMutability": "nonpayable",
1553
1275
  "type": "function"
@@ -1555,38 +1277,51 @@
1555
1277
  {
1556
1278
  "inputs": [
1557
1279
  {
1558
- "internalType": "NftId",
1559
- "name": "nftId",
1560
- "type": "uint96"
1280
+ "internalType": "bytes4",
1281
+ "name": "interfaceId",
1282
+ "type": "bytes4"
1283
+ }
1284
+ ],
1285
+ "name": "supportsInterface",
1286
+ "outputs": [
1287
+ {
1288
+ "internalType": "bool",
1289
+ "name": "",
1290
+ "type": "bool"
1291
+ }
1292
+ ],
1293
+ "stateMutability": "view",
1294
+ "type": "function"
1295
+ },
1296
+ {
1297
+ "inputs": [
1298
+ {
1299
+ "internalType": "ObjectType",
1300
+ "name": "objectType",
1301
+ "type": "uint8"
1561
1302
  },
1562
1303
  {
1563
- "components": [
1564
- {
1565
- "internalType": "bool",
1566
- "name": "isVerifying",
1567
- "type": "bool"
1568
- },
1569
- {
1570
- "internalType": "UFixed",
1571
- "name": "collateralizationLevel",
1572
- "type": "uint256"
1573
- }
1574
- ],
1575
- "internalType": "struct IPool.PoolInfo",
1576
- "name": "info",
1577
- "type": "tuple"
1304
+ "internalType": "KeyId",
1305
+ "name": "id",
1306
+ "type": "bytes31"
1578
1307
  }
1579
1308
  ],
1580
- "name": "registerPool",
1581
- "outputs": [],
1582
- "stateMutability": "nonpayable",
1309
+ "name": "toKey32",
1310
+ "outputs": [
1311
+ {
1312
+ "internalType": "Key32",
1313
+ "name": "",
1314
+ "type": "bytes32"
1315
+ }
1316
+ ],
1317
+ "stateMutability": "pure",
1583
1318
  "type": "function"
1584
1319
  },
1585
1320
  {
1586
1321
  "inputs": [
1587
1322
  {
1588
1323
  "internalType": "NftId",
1589
- "name": "productNftId",
1324
+ "name": "bundleNftId",
1590
1325
  "type": "uint96"
1591
1326
  },
1592
1327
  {
@@ -1596,16 +1331,6 @@
1596
1331
  "name": "poolNftId",
1597
1332
  "type": "uint96"
1598
1333
  },
1599
- {
1600
- "internalType": "NftId",
1601
- "name": "distributionNftId",
1602
- "type": "uint96"
1603
- },
1604
- {
1605
- "internalType": "contract IERC20Metadata",
1606
- "name": "token",
1607
- "type": "address"
1608
- },
1609
1334
  {
1610
1335
  "components": [
1611
1336
  {
@@ -1620,101 +1345,56 @@
1620
1345
  }
1621
1346
  ],
1622
1347
  "internalType": "struct Fee",
1623
- "name": "productFee",
1348
+ "name": "fee",
1624
1349
  "type": "tuple"
1625
1350
  },
1626
1351
  {
1627
- "components": [
1628
- {
1629
- "internalType": "UFixed",
1630
- "name": "fractionalFee",
1631
- "type": "uint256"
1632
- },
1633
- {
1634
- "internalType": "uint256",
1635
- "name": "fixedFee",
1636
- "type": "uint256"
1637
- }
1638
- ],
1639
- "internalType": "struct Fee",
1640
- "name": "processingFee",
1641
- "type": "tuple"
1352
+ "internalType": "bytes",
1353
+ "name": "filter",
1354
+ "type": "bytes"
1642
1355
  },
1643
1356
  {
1644
- "components": [
1645
- {
1646
- "internalType": "UFixed",
1647
- "name": "fractionalFee",
1648
- "type": "uint256"
1649
- },
1650
- {
1651
- "internalType": "uint256",
1652
- "name": "fixedFee",
1653
- "type": "uint256"
1654
- }
1655
- ],
1656
- "internalType": "struct Fee",
1657
- "name": "poolFee",
1658
- "type": "tuple"
1357
+ "internalType": "uint256",
1358
+ "name": "capitalAmount",
1359
+ "type": "uint256"
1659
1360
  },
1660
1361
  {
1661
- "components": [
1662
- {
1663
- "internalType": "UFixed",
1664
- "name": "fractionalFee",
1665
- "type": "uint256"
1666
- },
1667
- {
1668
- "internalType": "uint256",
1669
- "name": "fixedFee",
1670
- "type": "uint256"
1671
- }
1672
- ],
1673
- "internalType": "struct Fee",
1674
- "name": "stakingFee",
1675
- "type": "tuple"
1362
+ "internalType": "uint256",
1363
+ "name": "lockedAmount",
1364
+ "type": "uint256"
1676
1365
  },
1677
1366
  {
1678
- "components": [
1679
- {
1680
- "internalType": "UFixed",
1681
- "name": "fractionalFee",
1682
- "type": "uint256"
1683
- },
1684
- {
1685
- "internalType": "uint256",
1686
- "name": "fixedFee",
1687
- "type": "uint256"
1688
- }
1689
- ],
1690
- "internalType": "struct Fee",
1691
- "name": "performanceFee",
1692
- "type": "tuple"
1367
+ "internalType": "uint256",
1368
+ "name": "balanceAmount",
1369
+ "type": "uint256"
1693
1370
  },
1694
1371
  {
1695
- "components": [
1696
- {
1697
- "internalType": "UFixed",
1698
- "name": "fractionalFee",
1699
- "type": "uint256"
1700
- },
1701
- {
1702
- "internalType": "uint256",
1703
- "name": "fixedFee",
1704
- "type": "uint256"
1705
- }
1706
- ],
1707
- "internalType": "struct Fee",
1708
- "name": "distributionFee",
1709
- "type": "tuple"
1372
+ "internalType": "uint256",
1373
+ "name": "lifetime",
1374
+ "type": "uint256"
1375
+ },
1376
+ {
1377
+ "internalType": "Timestamp",
1378
+ "name": "expiredAt",
1379
+ "type": "uint40"
1380
+ },
1381
+ {
1382
+ "internalType": "Timestamp",
1383
+ "name": "closedAt",
1384
+ "type": "uint40"
1710
1385
  }
1711
1386
  ],
1712
- "internalType": "struct ITreasury.TreasuryInfo",
1713
- "name": "info",
1387
+ "internalType": "struct IBundle.BundleInfo",
1388
+ "name": "bundle",
1714
1389
  "type": "tuple"
1390
+ },
1391
+ {
1392
+ "internalType": "StateId",
1393
+ "name": "newState",
1394
+ "type": "uint8"
1715
1395
  }
1716
1396
  ],
1717
- "name": "registerProductSetup",
1397
+ "name": "updateBundle",
1718
1398
  "outputs": [],
1719
1399
  "stateMutability": "nonpayable",
1720
1400
  "type": "function"
@@ -1727,73 +1407,35 @@
1727
1407
  "type": "uint96"
1728
1408
  },
1729
1409
  {
1730
- "internalType": "NftId",
1731
- "name": "policyNftId",
1732
- "type": "uint96"
1733
- }
1734
- ],
1735
- "name": "releasePolicy",
1736
- "outputs": [
1737
- {
1738
- "internalType": "uint256",
1739
- "name": "collateralAmount",
1740
- "type": "uint256"
1741
- }
1742
- ],
1743
- "stateMutability": "nonpayable",
1744
- "type": "function"
1745
- },
1746
- {
1747
- "inputs": [
1748
- {
1749
- "internalType": "RoleId",
1750
- "name": "role",
1751
- "type": "bytes8"
1752
- },
1753
- {
1754
- "internalType": "address",
1755
- "name": "member",
1756
- "type": "address"
1410
+ "internalType": "StateId",
1411
+ "name": "newState",
1412
+ "type": "uint8"
1757
1413
  }
1758
1414
  ],
1759
- "name": "revokeRole",
1415
+ "name": "updateBundleState",
1760
1416
  "outputs": [],
1761
1417
  "stateMutability": "nonpayable",
1762
1418
  "type": "function"
1763
1419
  },
1764
- {
1765
- "inputs": [
1766
- {
1767
- "internalType": "RoleId",
1768
- "name": "role",
1769
- "type": "bytes8"
1770
- }
1771
- ],
1772
- "name": "roleExists",
1773
- "outputs": [
1774
- {
1775
- "internalType": "bool",
1776
- "name": "",
1777
- "type": "bool"
1778
- }
1779
- ],
1780
- "stateMutability": "view",
1781
- "type": "function"
1782
- },
1783
1420
  {
1784
1421
  "inputs": [
1785
1422
  {
1786
1423
  "internalType": "NftId",
1787
- "name": "nftId",
1424
+ "name": "distributionNftId",
1788
1425
  "type": "uint96"
1789
1426
  },
1790
1427
  {
1791
1428
  "components": [
1792
1429
  {
1793
1430
  "internalType": "NftId",
1794
- "name": "poolNftId",
1431
+ "name": "productNftId",
1795
1432
  "type": "uint96"
1796
1433
  },
1434
+ {
1435
+ "internalType": "contract TokenHandler",
1436
+ "name": "tokenHandler",
1437
+ "type": "address"
1438
+ },
1797
1439
  {
1798
1440
  "components": [
1799
1441
  {
@@ -1808,46 +1450,49 @@
1808
1450
  }
1809
1451
  ],
1810
1452
  "internalType": "struct Fee",
1811
- "name": "fee",
1453
+ "name": "distributionFee",
1812
1454
  "type": "tuple"
1813
1455
  },
1814
1456
  {
1815
- "internalType": "bytes",
1816
- "name": "filter",
1817
- "type": "bytes"
1818
- },
1819
- {
1820
- "internalType": "uint256",
1821
- "name": "capitalAmount",
1822
- "type": "uint256"
1823
- },
1824
- {
1825
- "internalType": "uint256",
1826
- "name": "lockedAmount",
1827
- "type": "uint256"
1828
- },
1829
- {
1830
- "internalType": "uint256",
1831
- "name": "balanceAmount",
1832
- "type": "uint256"
1833
- },
1834
- {
1835
- "internalType": "Timestamp",
1836
- "name": "expiredAt",
1837
- "type": "uint40"
1457
+ "internalType": "bool",
1458
+ "name": "isIntercepting",
1459
+ "type": "bool"
1838
1460
  },
1839
1461
  {
1840
- "internalType": "Timestamp",
1841
- "name": "closedAt",
1842
- "type": "uint40"
1462
+ "internalType": "address",
1463
+ "name": "wallet",
1464
+ "type": "address"
1843
1465
  }
1844
1466
  ],
1845
- "internalType": "struct IBundle.BundleInfo",
1846
- "name": "bundleInfo",
1467
+ "internalType": "struct ISetup.DistributionSetupInfo",
1468
+ "name": "setup",
1847
1469
  "type": "tuple"
1470
+ },
1471
+ {
1472
+ "internalType": "StateId",
1473
+ "name": "newState",
1474
+ "type": "uint8"
1848
1475
  }
1849
1476
  ],
1850
- "name": "setBundleInfo",
1477
+ "name": "updateDistributionSetup",
1478
+ "outputs": [],
1479
+ "stateMutability": "nonpayable",
1480
+ "type": "function"
1481
+ },
1482
+ {
1483
+ "inputs": [
1484
+ {
1485
+ "internalType": "NftId",
1486
+ "name": "distributionNftId",
1487
+ "type": "uint96"
1488
+ },
1489
+ {
1490
+ "internalType": "StateId",
1491
+ "name": "newState",
1492
+ "type": "uint8"
1493
+ }
1494
+ ],
1495
+ "name": "updateDistributionSetupState",
1851
1496
  "outputs": [],
1852
1497
  "stateMutability": "nonpayable",
1853
1498
  "type": "function"
@@ -1876,11 +1521,6 @@
1876
1521
  "name": "referralId",
1877
1522
  "type": "bytes8"
1878
1523
  },
1879
- {
1880
- "internalType": "address",
1881
- "name": "beneficiary",
1882
- "type": "address"
1883
- },
1884
1524
  {
1885
1525
  "internalType": "RiskId",
1886
1526
  "name": "riskId",
@@ -1916,6 +1556,21 @@
1916
1556
  "name": "policyData",
1917
1557
  "type": "bytes"
1918
1558
  },
1559
+ {
1560
+ "internalType": "uint16",
1561
+ "name": "claimsCount",
1562
+ "type": "uint16"
1563
+ },
1564
+ {
1565
+ "internalType": "uint16",
1566
+ "name": "openClaimsCount",
1567
+ "type": "uint16"
1568
+ },
1569
+ {
1570
+ "internalType": "uint256",
1571
+ "name": "payoutAmount",
1572
+ "type": "uint256"
1573
+ },
1919
1574
  {
1920
1575
  "internalType": "Timestamp",
1921
1576
  "name": "activatedAt",
@@ -1933,11 +1588,16 @@
1933
1588
  }
1934
1589
  ],
1935
1590
  "internalType": "struct IPolicy.PolicyInfo",
1936
- "name": "info",
1591
+ "name": "policy",
1937
1592
  "type": "tuple"
1593
+ },
1594
+ {
1595
+ "internalType": "StateId",
1596
+ "name": "newState",
1597
+ "type": "uint8"
1938
1598
  }
1939
1599
  ],
1940
- "name": "setPolicyInfo",
1600
+ "name": "updatePolicy",
1941
1601
  "outputs": [],
1942
1602
  "stateMutability": "nonpayable",
1943
1603
  "type": "function"
@@ -1945,9 +1605,27 @@
1945
1605
  {
1946
1606
  "inputs": [
1947
1607
  {
1948
- "internalType": "RiskId",
1949
- "name": "riskId",
1950
- "type": "bytes8"
1608
+ "internalType": "NftId",
1609
+ "name": "policyNftId",
1610
+ "type": "uint96"
1611
+ },
1612
+ {
1613
+ "internalType": "StateId",
1614
+ "name": "newState",
1615
+ "type": "uint8"
1616
+ }
1617
+ ],
1618
+ "name": "updatePolicyState",
1619
+ "outputs": [],
1620
+ "stateMutability": "nonpayable",
1621
+ "type": "function"
1622
+ },
1623
+ {
1624
+ "inputs": [
1625
+ {
1626
+ "internalType": "NftId",
1627
+ "name": "poolNftId",
1628
+ "type": "uint96"
1951
1629
  },
1952
1630
  {
1953
1631
  "components": [
@@ -1957,17 +1635,93 @@
1957
1635
  "type": "uint96"
1958
1636
  },
1959
1637
  {
1960
- "internalType": "bytes",
1961
- "name": "data",
1962
- "type": "bytes"
1638
+ "internalType": "contract TokenHandler",
1639
+ "name": "tokenHandler",
1640
+ "type": "address"
1641
+ },
1642
+ {
1643
+ "internalType": "UFixed",
1644
+ "name": "collateralizationLevel",
1645
+ "type": "uint256"
1646
+ },
1647
+ {
1648
+ "components": [
1649
+ {
1650
+ "internalType": "UFixed",
1651
+ "name": "fractionalFee",
1652
+ "type": "uint256"
1653
+ },
1654
+ {
1655
+ "internalType": "uint256",
1656
+ "name": "fixedFee",
1657
+ "type": "uint256"
1658
+ }
1659
+ ],
1660
+ "internalType": "struct Fee",
1661
+ "name": "poolFee",
1662
+ "type": "tuple"
1663
+ },
1664
+ {
1665
+ "components": [
1666
+ {
1667
+ "internalType": "UFixed",
1668
+ "name": "fractionalFee",
1669
+ "type": "uint256"
1670
+ },
1671
+ {
1672
+ "internalType": "uint256",
1673
+ "name": "fixedFee",
1674
+ "type": "uint256"
1675
+ }
1676
+ ],
1677
+ "internalType": "struct Fee",
1678
+ "name": "stakingFee",
1679
+ "type": "tuple"
1680
+ },
1681
+ {
1682
+ "components": [
1683
+ {
1684
+ "internalType": "UFixed",
1685
+ "name": "fractionalFee",
1686
+ "type": "uint256"
1687
+ },
1688
+ {
1689
+ "internalType": "uint256",
1690
+ "name": "fixedFee",
1691
+ "type": "uint256"
1692
+ }
1693
+ ],
1694
+ "internalType": "struct Fee",
1695
+ "name": "performanceFee",
1696
+ "type": "tuple"
1697
+ },
1698
+ {
1699
+ "internalType": "bool",
1700
+ "name": "isIntercepting",
1701
+ "type": "bool"
1702
+ },
1703
+ {
1704
+ "internalType": "bool",
1705
+ "name": "isConfirmingApplication",
1706
+ "type": "bool"
1707
+ },
1708
+ {
1709
+ "internalType": "address",
1710
+ "name": "wallet",
1711
+ "type": "address"
1963
1712
  }
1964
1713
  ],
1965
- "internalType": "struct IRisk.RiskInfo",
1966
- "name": "info",
1714
+ "internalType": "struct ISetup.PoolSetupInfo",
1715
+ "name": "setup",
1967
1716
  "type": "tuple"
1717
+ },
1718
+ {
1719
+ "internalType": "StateId",
1720
+ "name": "newState",
1721
+ "type": "uint8"
1968
1722
  }
1969
1723
  ],
1970
- "name": "setRiskInfo",
1724
+ "name": "updatePoolSetup",
1971
1725
  "outputs": [],
1972
1726
  "stateMutability": "nonpayable",
1973
1727
  "type": "function"
@@ -1975,17 +1729,17 @@
1975
1729
  {
1976
1730
  "inputs": [
1977
1731
  {
1978
- "internalType": "RoleId",
1979
- "name": "role",
1980
- "type": "bytes8"
1732
+ "internalType": "NftId",
1733
+ "name": "poolNftId",
1734
+ "type": "uint96"
1981
1735
  },
1982
1736
  {
1983
- "internalType": "bool",
1984
- "name": "active",
1985
- "type": "bool"
1737
+ "internalType": "StateId",
1738
+ "name": "newState",
1739
+ "type": "uint8"
1986
1740
  }
1987
1741
  ],
1988
- "name": "setRoleState",
1742
+ "name": "updatePoolSetupState",
1989
1743
  "outputs": [],
1990
1744
  "stateMutability": "nonpayable",
1991
1745
  "type": "function"
@@ -2000,9 +1754,14 @@
2000
1754
  {
2001
1755
  "components": [
2002
1756
  {
2003
- "internalType": "NftId",
2004
- "name": "poolNftId",
2005
- "type": "uint96"
1757
+ "internalType": "contract IERC20Metadata",
1758
+ "name": "token",
1759
+ "type": "address"
1760
+ },
1761
+ {
1762
+ "internalType": "contract TokenHandler",
1763
+ "name": "tokenHandler",
1764
+ "type": "address"
2006
1765
  },
2007
1766
  {
2008
1767
  "internalType": "NftId",
@@ -2010,9 +1769,9 @@
2010
1769
  "type": "uint96"
2011
1770
  },
2012
1771
  {
2013
- "internalType": "contract IERC20Metadata",
2014
- "name": "token",
2015
- "type": "address"
1772
+ "internalType": "NftId",
1773
+ "name": "poolNftId",
1774
+ "type": "uint96"
2016
1775
  },
2017
1776
  {
2018
1777
  "components": [
@@ -2028,7 +1787,7 @@
2028
1787
  }
2029
1788
  ],
2030
1789
  "internalType": "struct Fee",
2031
- "name": "productFee",
1790
+ "name": "distributionFee",
2032
1791
  "type": "tuple"
2033
1792
  },
2034
1793
  {
@@ -2045,7 +1804,7 @@
2045
1804
  }
2046
1805
  ],
2047
1806
  "internalType": "struct Fee",
2048
- "name": "processingFee",
1807
+ "name": "productFee",
2049
1808
  "type": "tuple"
2050
1809
  },
2051
1810
  {
@@ -2062,7 +1821,7 @@
2062
1821
  }
2063
1822
  ],
2064
1823
  "internalType": "struct Fee",
2065
- "name": "poolFee",
1824
+ "name": "processingFee",
2066
1825
  "type": "tuple"
2067
1826
  },
2068
1827
  {
@@ -2079,7 +1838,7 @@
2079
1838
  }
2080
1839
  ],
2081
1840
  "internalType": "struct Fee",
2082
- "name": "stakingFee",
1841
+ "name": "poolFee",
2083
1842
  "type": "tuple"
2084
1843
  },
2085
1844
  {
@@ -2096,7 +1855,7 @@
2096
1855
  }
2097
1856
  ],
2098
1857
  "internalType": "struct Fee",
2099
- "name": "performanceFee",
1858
+ "name": "stakingFee",
2100
1859
  "type": "tuple"
2101
1860
  },
2102
1861
  {
@@ -2113,53 +1872,31 @@
2113
1872
  }
2114
1873
  ],
2115
1874
  "internalType": "struct Fee",
2116
- "name": "distributionFee",
1875
+ "name": "performanceFee",
2117
1876
  "type": "tuple"
1877
+ },
1878
+ {
1879
+ "internalType": "bool",
1880
+ "name": "isIntercepting",
1881
+ "type": "bool"
1882
+ },
1883
+ {
1884
+ "internalType": "address",
1885
+ "name": "wallet",
1886
+ "type": "address"
2118
1887
  }
2119
1888
  ],
2120
- "internalType": "struct ITreasury.TreasuryInfo",
2121
- "name": "info",
1889
+ "internalType": "struct ISetup.ProductSetupInfo",
1890
+ "name": "setup",
2122
1891
  "type": "tuple"
2123
- }
2124
- ],
2125
- "name": "setTreasuryInfo",
2126
- "outputs": [],
2127
- "stateMutability": "nonpayable",
2128
- "type": "function"
2129
- },
2130
- {
2131
- "inputs": [
2132
- {
2133
- "internalType": "bytes4",
2134
- "name": "interfaceId",
2135
- "type": "bytes4"
2136
- }
2137
- ],
2138
- "name": "supportsInterface",
2139
- "outputs": [
2140
- {
2141
- "internalType": "bool",
2142
- "name": "",
2143
- "type": "bool"
2144
- }
2145
- ],
2146
- "stateMutability": "view",
2147
- "type": "function"
2148
- },
2149
- {
2150
- "inputs": [
2151
- {
2152
- "internalType": "NftId",
2153
- "name": "nftId",
2154
- "type": "uint96"
2155
1892
  },
2156
1893
  {
2157
1894
  "internalType": "StateId",
2158
- "name": "state",
1895
+ "name": "newState",
2159
1896
  "type": "uint8"
2160
1897
  }
2161
1898
  ],
2162
- "name": "updateBundleState",
1899
+ "name": "updateProductSetup",
2163
1900
  "outputs": [],
2164
1901
  "stateMutability": "nonpayable",
2165
1902
  "type": "function"
@@ -2168,16 +1905,16 @@
2168
1905
  "inputs": [
2169
1906
  {
2170
1907
  "internalType": "NftId",
2171
- "name": "nftId",
1908
+ "name": "productNftId",
2172
1909
  "type": "uint96"
2173
1910
  },
2174
1911
  {
2175
1912
  "internalType": "StateId",
2176
- "name": "state",
1913
+ "name": "newState",
2177
1914
  "type": "uint8"
2178
1915
  }
2179
1916
  ],
2180
- "name": "updatePolicyState",
1917
+ "name": "updateProductSetupState",
2181
1918
  "outputs": [],
2182
1919
  "stateMutability": "nonpayable",
2183
1920
  "type": "function"
@@ -2190,30 +1927,29 @@
2190
1927
  "type": "bytes8"
2191
1928
  },
2192
1929
  {
2193
- "internalType": "StateId",
2194
- "name": "state",
2195
- "type": "uint8"
2196
- }
2197
- ],
2198
- "name": "updateRiskState",
2199
- "outputs": [],
2200
- "stateMutability": "nonpayable",
2201
- "type": "function"
2202
- },
2203
- {
2204
- "inputs": [
2205
- {
2206
- "internalType": "Key32",
2207
- "name": "key",
2208
- "type": "bytes32"
1930
+ "components": [
1931
+ {
1932
+ "internalType": "NftId",
1933
+ "name": "productNftId",
1934
+ "type": "uint96"
1935
+ },
1936
+ {
1937
+ "internalType": "bytes",
1938
+ "name": "data",
1939
+ "type": "bytes"
1940
+ }
1941
+ ],
1942
+ "internalType": "struct IRisk.RiskInfo",
1943
+ "name": "risk",
1944
+ "type": "tuple"
2209
1945
  },
2210
1946
  {
2211
1947
  "internalType": "StateId",
2212
- "name": "state",
1948
+ "name": "newState",
2213
1949
  "type": "uint8"
2214
1950
  }
2215
1951
  ],
2216
- "name": "updateState",
1952
+ "name": "updateRisk",
2217
1953
  "outputs": [],
2218
1954
  "stateMutability": "nonpayable",
2219
1955
  "type": "function"
@@ -2221,22 +1957,17 @@
2221
1957
  {
2222
1958
  "inputs": [
2223
1959
  {
2224
- "internalType": "address",
2225
- "name": "implementation",
2226
- "type": "address"
2227
- },
2228
- {
2229
- "internalType": "address",
2230
- "name": "activatedBy",
2231
- "type": "address"
1960
+ "internalType": "RiskId",
1961
+ "name": "riskId",
1962
+ "type": "bytes8"
2232
1963
  },
2233
1964
  {
2234
- "internalType": "bytes",
2235
- "name": "upgradeData",
2236
- "type": "bytes"
1965
+ "internalType": "StateId",
1966
+ "name": "newState",
1967
+ "type": "uint8"
2237
1968
  }
2238
1969
  ],
2239
- "name": "upgrade",
1970
+ "name": "updateRiskState",
2240
1971
  "outputs": [],
2241
1972
  "stateMutability": "nonpayable",
2242
1973
  "type": "function"