@etherisc/gif-next 0.0.2-f7b8c9f-518 → 0.0.2-f7c17b4-297

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