@etherisc/gif-next 0.0.2-f7be756-963 → 0.0.2-f7c17b4-970

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