@etherisc/gif-next 0.0.2-d3ee0cc-268 → 0.0.2-d48ae55-246

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