@etherisc/gif-next 0.0.2-fe88ad7-208 → 0.0.2-ff8087d-237

Sign up to get free protection for your applications and to get access to all the features.
Files changed (378) hide show
  1. package/README.md +8 -13
  2. package/artifacts/contracts/components/Component.sol/Component.dbg.json +4 -0
  3. package/artifacts/contracts/components/Component.sol/Component.json +873 -0
  4. package/artifacts/contracts/components/Distribution.sol/Distribution.dbg.json +1 -1
  5. package/artifacts/contracts/components/Distribution.sol/Distribution.json +903 -202
  6. package/artifacts/contracts/components/IComponent.sol/IComponent.dbg.json +4 -0
  7. package/artifacts/contracts/components/{BaseComponent.sol/BaseComponent.json → IComponent.sol/IComponent.json} +237 -83
  8. package/artifacts/contracts/components/IDistributionComponent.sol/IDistributionComponent.dbg.json +1 -1
  9. package/artifacts/contracts/components/IDistributionComponent.sol/IDistributionComponent.json +879 -31
  10. package/artifacts/contracts/components/IPoolComponent.sol/IPoolComponent.dbg.json +1 -1
  11. package/artifacts/contracts/components/IPoolComponent.sol/IPoolComponent.json +879 -59
  12. package/artifacts/contracts/components/IProductComponent.sol/IProductComponent.dbg.json +1 -1
  13. package/artifacts/contracts/components/IProductComponent.sol/IProductComponent.json +720 -16
  14. package/artifacts/contracts/components/Pool.sol/Pool.dbg.json +1 -1
  15. package/artifacts/contracts/components/Pool.sol/Pool.json +760 -195
  16. package/artifacts/contracts/components/Product.sol/Product.dbg.json +1 -1
  17. package/artifacts/contracts/components/Product.sol/Product.json +564 -141
  18. package/artifacts/contracts/instance/AccessManagerUpgradeableInitializeable.sol/AccessManagerUpgradeableInitializeable.dbg.json +1 -1
  19. package/artifacts/contracts/instance/AccessManagerUpgradeableInitializeable.sol/AccessManagerUpgradeableInitializeable.json +15 -15
  20. package/artifacts/contracts/instance/BundleManager.sol/BundleManager.dbg.json +1 -1
  21. package/artifacts/contracts/instance/BundleManager.sol/BundleManager.json +69 -79
  22. package/artifacts/contracts/instance/Cloneable.sol/Cloneable.dbg.json +1 -1
  23. package/artifacts/contracts/instance/Cloneable.sol/Cloneable.json +5 -0
  24. package/artifacts/contracts/instance/IInstance.sol/IInstance.dbg.json +1 -1
  25. package/artifacts/contracts/instance/IInstance.sol/IInstance.json +1474 -483
  26. package/artifacts/contracts/instance/IInstanceService.sol/IInstanceService.dbg.json +1 -1
  27. package/artifacts/contracts/instance/IInstanceService.sol/IInstanceService.json +248 -218
  28. package/artifacts/contracts/instance/Instance.sol/Instance.dbg.json +1 -1
  29. package/artifacts/contracts/instance/Instance.sol/Instance.json +1152 -794
  30. package/artifacts/contracts/instance/InstanceAccessManager.sol/InstanceAccessManager.dbg.json +1 -1
  31. package/artifacts/contracts/instance/InstanceAccessManager.sol/InstanceAccessManager.json +462 -179
  32. package/artifacts/contracts/instance/InstanceReader.sol/InstanceReader.dbg.json +1 -1
  33. package/artifacts/contracts/instance/InstanceReader.sol/InstanceReader.json +414 -267
  34. package/artifacts/contracts/instance/InstanceService.sol/InstanceService.dbg.json +1 -1
  35. package/artifacts/contracts/instance/InstanceService.sol/InstanceService.json +482 -346
  36. package/artifacts/contracts/instance/InstanceServiceManager.sol/InstanceServiceManager.dbg.json +1 -1
  37. package/artifacts/contracts/instance/InstanceServiceManager.sol/InstanceServiceManager.json +355 -91
  38. package/artifacts/contracts/instance/ObjectManager.sol/ObjectManager.dbg.json +1 -1
  39. package/artifacts/contracts/instance/ObjectManager.sol/ObjectManager.json +11 -40
  40. package/artifacts/contracts/instance/base/ComponentService.sol/ComponentService.dbg.json +4 -0
  41. package/artifacts/contracts/instance/base/{ComponentServiceBase.sol/ComponentServiceBase.json → ComponentService.sol/ComponentService.json} +263 -164
  42. package/artifacts/contracts/instance/base/IKeyValueStore.sol/IKeyValueStore.dbg.json +1 -1
  43. package/artifacts/contracts/instance/base/ILifecycle.sol/ILifecycle.dbg.json +1 -1
  44. package/artifacts/contracts/instance/base/KeyValueStore.sol/KeyValueStore.dbg.json +1 -1
  45. package/artifacts/contracts/instance/base/KeyValueStore.sol/KeyValueStore.json +40 -10
  46. package/artifacts/contracts/instance/base/Lifecycle.sol/Lifecycle.dbg.json +1 -1
  47. package/artifacts/contracts/instance/base/Lifecycle.sol/Lifecycle.json +36 -11
  48. package/artifacts/contracts/instance/module/IAccess.sol/IAccess.dbg.json +1 -1
  49. package/artifacts/contracts/instance/module/IAccess.sol/IAccess.json +58 -75
  50. package/artifacts/contracts/instance/module/IBundle.sol/IBundle.dbg.json +1 -1
  51. package/artifacts/contracts/instance/module/IComponents.sol/IComponents.dbg.json +4 -0
  52. package/artifacts/contracts/instance/module/IComponents.sol/IComponents.json +10 -0
  53. package/artifacts/contracts/instance/module/IDistribution.sol/IDistribution.dbg.json +1 -1
  54. package/artifacts/contracts/instance/module/IPolicy.sol/IPolicy.dbg.json +1 -1
  55. package/artifacts/contracts/instance/module/IRisk.sol/IRisk.dbg.json +1 -1
  56. package/artifacts/contracts/instance/module/ISetup.sol/ISetup.dbg.json +1 -1
  57. package/artifacts/contracts/instance/module/ITreasury.sol/ITreasury.dbg.json +1 -1
  58. package/artifacts/contracts/instance/service/ApplicationService.sol/ApplicationService.dbg.json +4 -0
  59. package/artifacts/contracts/instance/service/ApplicationService.sol/ApplicationService.json +1124 -0
  60. package/artifacts/contracts/instance/service/ApplicationServiceManager.sol/ApplicationServiceManager.dbg.json +4 -0
  61. package/artifacts/contracts/instance/service/ApplicationServiceManager.sol/ApplicationServiceManager.json +688 -0
  62. package/artifacts/contracts/instance/service/BundleService.sol/BundleService.dbg.json +1 -1
  63. package/artifacts/contracts/instance/service/BundleService.sol/BundleService.json +641 -303
  64. package/artifacts/contracts/instance/service/BundleServiceManager.sol/BundleServiceManager.dbg.json +1 -1
  65. package/artifacts/contracts/instance/service/BundleServiceManager.sol/BundleServiceManager.json +343 -79
  66. package/artifacts/contracts/instance/service/ClaimService.sol/ClaimService.dbg.json +4 -0
  67. package/artifacts/contracts/instance/service/ClaimService.sol/ClaimService.json +1384 -0
  68. package/artifacts/contracts/instance/service/ClaimServiceManager.sol/ClaimServiceManager.dbg.json +4 -0
  69. package/artifacts/contracts/instance/service/ClaimServiceManager.sol/ClaimServiceManager.json +752 -0
  70. package/artifacts/contracts/instance/service/DistributionService.sol/DistributionService.dbg.json +1 -1
  71. package/artifacts/contracts/instance/service/DistributionService.sol/DistributionService.json +1434 -280
  72. package/artifacts/contracts/instance/service/DistributionServiceManager.sol/DistributionServiceManager.dbg.json +1 -1
  73. package/artifacts/contracts/instance/service/DistributionServiceManager.sol/DistributionServiceManager.json +469 -73
  74. package/artifacts/contracts/instance/service/IApplicationService.sol/IApplicationService.dbg.json +4 -0
  75. package/artifacts/contracts/instance/service/{IComponentOwnerService.sol/IComponentOwnerService.json → IApplicationService.sol/IApplicationService.json} +342 -189
  76. package/artifacts/contracts/instance/service/IBundleService.sol/IBundleService.dbg.json +1 -1
  77. package/artifacts/contracts/instance/service/IBundleService.sol/IBundleService.json +310 -249
  78. package/artifacts/contracts/instance/service/IClaimService.sol/IClaimService.dbg.json +4 -0
  79. package/artifacts/contracts/instance/service/IClaimService.sol/IClaimService.json +743 -0
  80. package/artifacts/contracts/instance/service/IDistributionService.sol/IDistributionService.dbg.json +1 -1
  81. package/artifacts/contracts/instance/service/IDistributionService.sol/IDistributionService.json +757 -144
  82. package/artifacts/contracts/instance/service/IPolicyService.sol/IPolicyService.dbg.json +1 -1
  83. package/artifacts/contracts/instance/service/IPolicyService.sol/IPolicyService.json +262 -275
  84. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.dbg.json +1 -1
  85. package/artifacts/contracts/instance/service/IPoolService.sol/IPoolService.json +703 -125
  86. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.dbg.json +1 -1
  87. package/artifacts/contracts/instance/service/IProductService.sol/IProductService.json +71 -165
  88. package/artifacts/contracts/instance/service/PolicyService.sol/PolicyService.dbg.json +1 -1
  89. package/artifacts/contracts/instance/service/PolicyService.sol/PolicyService.json +632 -344
  90. package/artifacts/contracts/instance/service/PolicyServiceManager.sol/PolicyServiceManager.dbg.json +1 -1
  91. package/artifacts/contracts/instance/service/PolicyServiceManager.sol/PolicyServiceManager.json +367 -91
  92. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.dbg.json +1 -1
  93. package/artifacts/contracts/instance/service/PoolService.sol/PoolService.json +1119 -224
  94. package/artifacts/contracts/instance/service/PoolServiceManager.sol/PoolServiceManager.dbg.json +1 -1
  95. package/artifacts/contracts/instance/service/PoolServiceManager.sol/PoolServiceManager.json +361 -73
  96. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.dbg.json +1 -1
  97. package/artifacts/contracts/instance/service/ProductService.sol/ProductService.json +297 -210
  98. package/artifacts/contracts/instance/service/ProductServiceManager.sol/ProductServiceManager.dbg.json +1 -1
  99. package/artifacts/contracts/instance/service/ProductServiceManager.sol/ProductServiceManager.json +298 -78
  100. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.dbg.json +1 -1
  101. package/artifacts/contracts/registry/ChainNft.sol/ChainNft.json +15 -2
  102. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.dbg.json +1 -1
  103. package/artifacts/contracts/registry/IRegistry.sol/IRegistry.json +117 -5
  104. package/artifacts/contracts/registry/IRegistryService.sol/IRegistryService.dbg.json +1 -1
  105. package/artifacts/contracts/registry/IRegistryService.sol/IRegistryService.json +99 -217
  106. package/artifacts/contracts/registry/ITransferInterceptor.sol/ITransferInterceptor.dbg.json +1 -1
  107. package/artifacts/contracts/registry/ITransferInterceptor.sol/ITransferInterceptor.json +18 -0
  108. package/artifacts/contracts/registry/Registry.sol/Registry.dbg.json +1 -1
  109. package/artifacts/contracts/registry/Registry.sol/Registry.json +131 -27
  110. package/artifacts/contracts/registry/RegistryAccessManager.sol/RegistryAccessManager.dbg.json +1 -1
  111. package/artifacts/contracts/registry/RegistryAccessManager.sol/RegistryAccessManager.json +18 -18
  112. package/artifacts/contracts/registry/RegistryService.sol/RegistryService.dbg.json +1 -1
  113. package/artifacts/contracts/registry/RegistryService.sol/RegistryService.json +205 -250
  114. package/artifacts/contracts/registry/RegistryServiceManager.sol/RegistryServiceManager.dbg.json +1 -1
  115. package/artifacts/contracts/registry/RegistryServiceManager.sol/RegistryServiceManager.json +287 -81
  116. package/artifacts/contracts/registry/ReleaseManager.sol/ReleaseManager.dbg.json +1 -1
  117. package/artifacts/contracts/registry/ReleaseManager.sol/ReleaseManager.json +81 -68
  118. package/artifacts/contracts/registry/TokenRegistry.sol/TokenRegistry.dbg.json +1 -1
  119. package/artifacts/contracts/registry/TokenRegistry.sol/TokenRegistry.json +138 -50
  120. package/artifacts/contracts/shared/ContractDeployerLib.sol/ContractDeployerLib.dbg.json +1 -1
  121. package/artifacts/contracts/shared/ERC165.sol/ERC165.dbg.json +1 -1
  122. package/artifacts/contracts/shared/ERC165.sol/ERC165.json +41 -3
  123. package/artifacts/contracts/shared/INftOwnable.sol/INftOwnable.dbg.json +1 -1
  124. package/artifacts/contracts/shared/INftOwnable.sol/INftOwnable.json +27 -29
  125. package/artifacts/contracts/shared/IPolicyHolder.sol/IPolicyHolder.dbg.json +4 -0
  126. package/artifacts/contracts/shared/IPolicyHolder.sol/IPolicyHolder.json +189 -0
  127. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.dbg.json +1 -1
  128. package/artifacts/contracts/shared/IRegisterable.sol/IRegisterable.json +8 -34
  129. package/artifacts/contracts/shared/IRegistryLinked.sol/IRegistryLinked.dbg.json +4 -0
  130. package/artifacts/contracts/{experiment/inheritance/IA.sol/ISharedA.json → shared/IRegistryLinked.sol/IRegistryLinked.json} +15 -17
  131. package/artifacts/contracts/shared/IService.sol/IService.dbg.json +1 -1
  132. package/artifacts/contracts/shared/IService.sol/IService.json +71 -165
  133. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.dbg.json +1 -1
  134. package/artifacts/contracts/shared/IVersionable.sol/IVersionable.json +2 -152
  135. package/artifacts/contracts/shared/NftOwnable.sol/NftOwnable.dbg.json +1 -1
  136. package/artifacts/contracts/shared/NftOwnable.sol/NftOwnable.json +107 -27
  137. package/artifacts/contracts/shared/PolicyHolder.sol/PolicyHolder.dbg.json +4 -0
  138. package/artifacts/contracts/shared/PolicyHolder.sol/PolicyHolder.json +302 -0
  139. package/artifacts/contracts/shared/ProxyManager.sol/ProxyManager.dbg.json +1 -1
  140. package/artifacts/contracts/shared/ProxyManager.sol/ProxyManager.json +283 -63
  141. package/artifacts/contracts/shared/Registerable.sol/Registerable.dbg.json +1 -1
  142. package/artifacts/contracts/shared/Registerable.sol/Registerable.json +116 -51
  143. package/artifacts/contracts/shared/RegistryLinked.sol/RegistryLinked.dbg.json +4 -0
  144. package/artifacts/contracts/shared/RegistryLinked.sol/RegistryLinked.json +71 -0
  145. package/artifacts/contracts/shared/Service.sol/Service.dbg.json +1 -1
  146. package/artifacts/contracts/shared/Service.sol/Service.json +173 -153
  147. package/artifacts/contracts/shared/TokenHandler.sol/TokenHandler.dbg.json +1 -1
  148. package/artifacts/contracts/shared/TokenHandler.sol/TokenHandler.json +24 -6
  149. package/artifacts/contracts/shared/UpgradableProxyWithAdmin.sol/UpgradableProxyWithAdmin.dbg.json +1 -1
  150. package/artifacts/contracts/shared/UpgradableProxyWithAdmin.sol/UpgradableProxyWithAdmin.json +2 -2
  151. package/artifacts/contracts/shared/Versionable.sol/Versionable.dbg.json +1 -1
  152. package/artifacts/contracts/shared/Versionable.sol/Versionable.json +2 -152
  153. package/artifacts/contracts/test/TestFee.sol/TestFee.dbg.json +1 -1
  154. package/artifacts/contracts/test/TestFee.sol/TestFee.json +2 -2
  155. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.dbg.json +1 -1
  156. package/artifacts/contracts/test/TestRegisterable.sol/TestRegisterable.json +116 -51
  157. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.dbg.json +1 -1
  158. package/artifacts/contracts/test/TestRoleId.sol/TestRoleId.json +6 -6
  159. package/artifacts/contracts/test/TestService.sol/TestService.dbg.json +1 -1
  160. package/artifacts/contracts/test/TestService.sol/TestService.json +191 -203
  161. package/artifacts/contracts/test/TestToken.sol/TestUsdc.dbg.json +1 -1
  162. package/artifacts/contracts/test/TestVersion.sol/TestVersion.dbg.json +1 -1
  163. package/artifacts/contracts/test/TestVersion.sol/TestVersion.json +2 -2
  164. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.dbg.json +1 -1
  165. package/artifacts/contracts/test/TestVersionable.sol/TestVersionable.json +8 -190
  166. package/artifacts/contracts/test/Usdc.sol/USDC.dbg.json +1 -1
  167. package/artifacts/contracts/types/AddressSet.sol/LibAddressSet.dbg.json +1 -1
  168. package/artifacts/contracts/types/Amount.sol/AmountLib.dbg.json +4 -0
  169. package/artifacts/contracts/types/Amount.sol/AmountLib.json +281 -0
  170. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.dbg.json +1 -1
  171. package/artifacts/contracts/types/Blocknumber.sol/BlocknumberLib.json +2 -2
  172. package/artifacts/contracts/types/ChainId.sol/ChainIdLib.dbg.json +1 -1
  173. package/artifacts/contracts/types/ClaimId.sol/ClaimIdLib.dbg.json +4 -0
  174. package/artifacts/contracts/types/ClaimId.sol/ClaimIdLib.json +179 -0
  175. package/artifacts/contracts/types/DistributorType.sol/DistributorTypeLib.dbg.json +1 -1
  176. package/artifacts/contracts/types/DistributorType.sol/DistributorTypeLib.json +2 -2
  177. package/artifacts/contracts/types/Fee.sol/FeeLib.dbg.json +1 -1
  178. package/artifacts/contracts/types/Fee.sol/FeeLib.json +74 -19
  179. package/artifacts/contracts/types/Key32.sol/Key32Lib.dbg.json +1 -1
  180. package/artifacts/contracts/types/Key32.sol/Key32Lib.json +2 -2
  181. package/artifacts/contracts/types/NftId.sol/NftIdLib.dbg.json +1 -1
  182. package/artifacts/contracts/types/NftId.sol/NftIdLib.json +17 -4
  183. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.dbg.json +1 -1
  184. package/artifacts/contracts/types/NftIdSet.sol/LibNftIdSet.json +2 -2
  185. package/artifacts/contracts/types/NumberId.sol/NumberIdLib.dbg.json +1 -1
  186. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.dbg.json +1 -1
  187. package/artifacts/contracts/types/ObjectType.sol/ObjectTypeLib.json +2 -2
  188. package/artifacts/contracts/types/PayoutId.sol/PayoutIdLib.dbg.json +4 -0
  189. package/artifacts/contracts/types/PayoutId.sol/PayoutIdLib.json +209 -0
  190. package/artifacts/contracts/types/Referral.sol/ReferralLib.dbg.json +1 -1
  191. package/artifacts/contracts/types/Referral.sol/ReferralLib.json +23 -4
  192. package/artifacts/contracts/types/RiskId.sol/RiskIdLib.dbg.json +1 -1
  193. package/artifacts/contracts/types/RiskId.sol/RiskIdLib.json +2 -2
  194. package/artifacts/contracts/types/RoleId.sol/RoleIdLib.dbg.json +1 -1
  195. package/artifacts/contracts/types/RoleId.sol/RoleIdLib.json +2 -2
  196. package/artifacts/contracts/types/Seconds.sol/SecondsLib.dbg.json +4 -0
  197. package/artifacts/contracts/types/Seconds.sol/SecondsLib.json +124 -0
  198. package/artifacts/contracts/types/StateId.sol/StateIdLib.dbg.json +1 -1
  199. package/artifacts/contracts/types/StateId.sol/StateIdLib.json +2 -2
  200. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.dbg.json +1 -1
  201. package/artifacts/contracts/types/Timestamp.sol/TimestampLib.json +38 -7
  202. package/artifacts/contracts/types/UFixed.sol/MathLib.dbg.json +1 -1
  203. package/artifacts/contracts/types/UFixed.sol/MathLib.json +2 -2
  204. package/artifacts/contracts/types/UFixed.sol/UFixedLib.dbg.json +1 -1
  205. package/artifacts/contracts/types/UFixed.sol/UFixedLib.json +2 -2
  206. package/artifacts/contracts/types/Version.sol/VersionLib.dbg.json +1 -1
  207. package/artifacts/contracts/types/Version.sol/VersionLib.json +2 -2
  208. package/artifacts/contracts/types/Version.sol/VersionPartLib.dbg.json +1 -1
  209. package/artifacts/contracts/types/Version.sol/VersionPartLib.json +2 -2
  210. package/contracts/components/Component.sol +272 -0
  211. package/contracts/components/Distribution.sol +204 -82
  212. package/contracts/components/IComponent.sol +90 -0
  213. package/contracts/components/IDistributionComponent.sol +44 -17
  214. package/contracts/components/IPoolComponent.sol +90 -42
  215. package/contracts/components/IProductComponent.sol +15 -9
  216. package/contracts/components/Pool.sol +217 -186
  217. package/contracts/components/Product.sol +246 -166
  218. package/contracts/instance/AccessManagerUpgradeableInitializeable.sol +2 -12
  219. package/contracts/instance/BundleManager.sol +17 -20
  220. package/contracts/instance/Cloneable.sol +7 -2
  221. package/contracts/instance/IInstance.sol +67 -25
  222. package/contracts/instance/IInstanceService.sol +34 -11
  223. package/contracts/instance/Instance.sol +158 -116
  224. package/contracts/instance/InstanceAccessManager.sol +389 -165
  225. package/contracts/instance/InstanceReader.sol +87 -36
  226. package/contracts/instance/InstanceService.sol +295 -161
  227. package/contracts/instance/InstanceServiceManager.sol +1 -1
  228. package/contracts/instance/ObjectManager.sol +10 -29
  229. package/contracts/instance/base/ComponentService.sol +130 -0
  230. package/contracts/instance/base/KeyValueStore.sol +13 -36
  231. package/contracts/instance/base/Lifecycle.sol +26 -6
  232. package/contracts/instance/module/IAccess.sol +22 -16
  233. package/contracts/instance/module/IBundle.sol +8 -5
  234. package/contracts/instance/module/IComponents.sol +41 -0
  235. package/contracts/instance/module/IDistribution.sol +3 -0
  236. package/contracts/instance/module/IPolicy.sol +43 -11
  237. package/contracts/instance/module/ISetup.sol +7 -20
  238. package/contracts/instance/service/ApplicationService.sol +356 -0
  239. package/contracts/instance/service/ApplicationServiceManager.sol +35 -0
  240. package/contracts/instance/service/BundleService.sol +244 -119
  241. package/contracts/instance/service/BundleServiceManager.sol +1 -1
  242. package/contracts/instance/service/ClaimService.sol +443 -0
  243. package/contracts/instance/service/ClaimServiceManager.sol +35 -0
  244. package/contracts/instance/service/DistributionService.sol +360 -41
  245. package/contracts/instance/service/DistributionServiceManager.sol +1 -1
  246. package/contracts/instance/service/IApplicationService.sol +79 -0
  247. package/contracts/instance/service/IBundleService.sol +93 -20
  248. package/contracts/instance/service/IClaimService.sol +90 -0
  249. package/contracts/instance/service/IDistributionService.sol +89 -0
  250. package/contracts/instance/service/IPolicyService.sol +44 -51
  251. package/contracts/instance/service/IPoolService.sol +97 -3
  252. package/contracts/instance/service/PolicyService.sol +233 -364
  253. package/contracts/instance/service/PolicyServiceManager.sol +2 -2
  254. package/contracts/instance/service/PoolService.sol +319 -40
  255. package/contracts/instance/service/PoolServiceManager.sol +1 -1
  256. package/contracts/instance/service/ProductService.sol +90 -50
  257. package/contracts/instance/service/ProductServiceManager.sol +2 -2
  258. package/contracts/registry/ChainNft.sol +8 -0
  259. package/contracts/registry/IRegistry.sol +18 -8
  260. package/contracts/registry/IRegistryService.sol +21 -13
  261. package/contracts/registry/ITransferInterceptor.sol +1 -0
  262. package/contracts/registry/Registry.sol +142 -71
  263. package/contracts/registry/RegistryAccessManager.sol +31 -25
  264. package/contracts/registry/RegistryService.sol +93 -134
  265. package/contracts/registry/RegistryServiceManager.sol +13 -13
  266. package/contracts/registry/ReleaseManager.sol +103 -127
  267. package/contracts/registry/TokenRegistry.sol +19 -13
  268. package/contracts/shared/ERC165.sol +14 -12
  269. package/contracts/shared/INftOwnable.sol +11 -10
  270. package/contracts/shared/IPolicyHolder.sol +40 -0
  271. package/contracts/shared/IRegisterable.sol +4 -6
  272. package/contracts/shared/IRegistryLinked.sol +11 -0
  273. package/contracts/shared/IService.sol +6 -4
  274. package/contracts/shared/IVersionable.sol +4 -47
  275. package/contracts/shared/NftOwnable.sol +64 -80
  276. package/contracts/shared/PolicyHolder.sol +94 -0
  277. package/contracts/shared/ProxyManager.sol +100 -25
  278. package/contracts/shared/Registerable.sol +24 -39
  279. package/contracts/shared/RegistryLinked.sol +43 -0
  280. package/contracts/shared/Service.sol +36 -22
  281. package/contracts/shared/TokenHandler.sol +14 -6
  282. package/contracts/shared/Versionable.sol +4 -92
  283. package/contracts/test/TestRegisterable.sol +1 -1
  284. package/contracts/test/TestService.sol +1 -1
  285. package/contracts/types/Amount.sol +109 -0
  286. package/contracts/types/Blocknumber.sol +1 -0
  287. package/contracts/types/ClaimId.sol +75 -0
  288. package/contracts/types/DistributorType.sol +2 -2
  289. package/contracts/types/Fee.sol +17 -8
  290. package/contracts/types/NftId.sol +8 -0
  291. package/contracts/types/ObjectType.sol +11 -6
  292. package/contracts/types/PayoutId.sol +82 -0
  293. package/contracts/types/Referral.sol +4 -0
  294. package/contracts/types/RoleId.sol +18 -11
  295. package/contracts/types/Seconds.sol +54 -0
  296. package/contracts/types/StateId.sol +7 -2
  297. package/contracts/types/Timestamp.sol +18 -13
  298. package/contracts/types/UFixed.sol +1 -0
  299. package/contracts/types/Version.sol +1 -0
  300. package/package.json +3 -3
  301. package/artifacts/contracts/components/BaseComponent.sol/BaseComponent.dbg.json +0 -4
  302. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.dbg.json +0 -4
  303. package/artifacts/contracts/components/IBaseComponent.sol/IBaseComponent.json +0 -397
  304. package/artifacts/contracts/experiment/cloning/Cloner.sol/Cloner.dbg.json +0 -4
  305. package/artifacts/contracts/experiment/cloning/Cloner.sol/Cloner.json +0 -66
  306. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock1.dbg.json +0 -4
  307. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock1.json +0 -24
  308. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock2.dbg.json +0 -4
  309. package/artifacts/contracts/experiment/cloning/Cloner.sol/Mock2.json +0 -42
  310. package/artifacts/contracts/experiment/errors/Require.sol/Require.dbg.json +0 -4
  311. package/artifacts/contracts/experiment/errors/Require.sol/Require.json +0 -105
  312. package/artifacts/contracts/experiment/errors/Revert.sol/Revert.dbg.json +0 -4
  313. package/artifacts/contracts/experiment/errors/Revert.sol/Revert.json +0 -105
  314. package/artifacts/contracts/experiment/inheritance/A.sol/A.dbg.json +0 -4
  315. package/artifacts/contracts/experiment/inheritance/A.sol/A.json +0 -128
  316. package/artifacts/contracts/experiment/inheritance/A.sol/AShared.dbg.json +0 -4
  317. package/artifacts/contracts/experiment/inheritance/A.sol/AShared.json +0 -42
  318. package/artifacts/contracts/experiment/inheritance/B.sol/B.dbg.json +0 -4
  319. package/artifacts/contracts/experiment/inheritance/B.sol/B.json +0 -76
  320. package/artifacts/contracts/experiment/inheritance/C.sol/C.dbg.json +0 -4
  321. package/artifacts/contracts/experiment/inheritance/C.sol/C.json +0 -89
  322. package/artifacts/contracts/experiment/inheritance/IA.sol/IA.dbg.json +0 -4
  323. package/artifacts/contracts/experiment/inheritance/IA.sol/IA.json +0 -128
  324. package/artifacts/contracts/experiment/inheritance/IA.sol/ISharedA.dbg.json +0 -4
  325. package/artifacts/contracts/experiment/inheritance/IB.sol/IB.dbg.json +0 -4
  326. package/artifacts/contracts/experiment/inheritance/IB.sol/IB.json +0 -50
  327. package/artifacts/contracts/experiment/inheritance/IC.sol/IC.dbg.json +0 -4
  328. package/artifacts/contracts/experiment/inheritance/IC.sol/IC.json +0 -63
  329. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.dbg.json +0 -4
  330. package/artifacts/contracts/experiment/statemachine/Dummy.sol/LifeCycleModule.json +0 -59
  331. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISM.dbg.json +0 -4
  332. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISM.json +0 -124
  333. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISMEE.dbg.json +0 -4
  334. package/artifacts/contracts/experiment/statemachine/ISM.sol/ISMEE.json +0 -74
  335. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.dbg.json +0 -4
  336. package/artifacts/contracts/experiment/statemachine/SM.sol/SM.json +0 -124
  337. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.dbg.json +0 -4
  338. package/artifacts/contracts/experiment/statemachine/SimpleStateMachine.sol/SimpleStateMachine.json +0 -207
  339. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.dbg.json +0 -4
  340. package/artifacts/contracts/experiment/types/TypeA.sol/TypeALib.json +0 -10
  341. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.dbg.json +0 -4
  342. package/artifacts/contracts/experiment/types/TypeB.sol/TypeBLib.json +0 -10
  343. package/artifacts/contracts/instance/IInstanceBase.sol/IInstanceBase.dbg.json +0 -4
  344. package/artifacts/contracts/instance/IInstanceBase.sol/IInstanceBase.json +0 -448
  345. package/artifacts/contracts/instance/InstanceBase.sol/InstanceBase.dbg.json +0 -4
  346. package/artifacts/contracts/instance/InstanceBase.sol/InstanceBase.json +0 -763
  347. package/artifacts/contracts/instance/base/ComponentServiceBase.sol/ComponentServiceBase.dbg.json +0 -4
  348. package/artifacts/contracts/instance/base/IInstanceBase.sol/IInstanceBase.dbg.json +0 -4
  349. package/artifacts/contracts/instance/base/IInstanceBase.sol/IInstanceBase.json +0 -113
  350. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.dbg.json +0 -4
  351. package/artifacts/contracts/instance/service/ComponentOwnerService.sol/ComponentOwnerService.json +0 -814
  352. package/artifacts/contracts/instance/service/IComponentOwnerService.sol/IComponentOwnerService.dbg.json +0 -4
  353. package/artifacts/contracts/shared/RegisterableUpgradable.sol/RegisterableUpgradable.dbg.json +0 -4
  354. package/artifacts/contracts/shared/RegisterableUpgradable.sol/RegisterableUpgradable.json +0 -442
  355. package/contracts/components/BaseComponent.sol +0 -159
  356. package/contracts/components/IBaseComponent.sol +0 -34
  357. package/contracts/experiment/cloning/Cloner.sol +0 -47
  358. package/contracts/experiment/errors/Require.sol +0 -38
  359. package/contracts/experiment/errors/Revert.sol +0 -44
  360. package/contracts/experiment/inheritance/A.sol +0 -53
  361. package/contracts/experiment/inheritance/B.sol +0 -28
  362. package/contracts/experiment/inheritance/C.sol +0 -34
  363. package/contracts/experiment/inheritance/IA.sol +0 -13
  364. package/contracts/experiment/inheritance/IB.sol +0 -10
  365. package/contracts/experiment/inheritance/IC.sol +0 -12
  366. package/contracts/experiment/statemachine/Dummy.sol +0 -27
  367. package/contracts/experiment/statemachine/ISM.sol +0 -25
  368. package/contracts/experiment/statemachine/SM.sol +0 -57
  369. package/contracts/experiment/statemachine/SimpleStateMachine.sol +0 -31
  370. package/contracts/experiment/types/TypeA.sol +0 -47
  371. package/contracts/experiment/types/TypeB.sol +0 -29
  372. package/contracts/instance/IInstanceBase.sol +0 -26
  373. package/contracts/instance/InstanceBase.sol +0 -41
  374. package/contracts/instance/base/ComponentServiceBase.sol +0 -82
  375. package/contracts/instance/base/IInstanceBase.sol +0 -23
  376. package/contracts/instance/service/ComponentOwnerService.sol +0 -315
  377. package/contracts/instance/service/IComponentOwnerService.sol +0 -20
  378. package/contracts/shared/RegisterableUpgradable.sol +0 -16
@@ -3,6 +3,115 @@
3
3
  "contractName": "IInstance",
4
4
  "sourceName": "contracts/instance/IInstance.sol",
5
5
  "abi": [
6
+ {
7
+ "inputs": [
8
+ {
9
+ "internalType": "address",
10
+ "name": "authority",
11
+ "type": "address"
12
+ }
13
+ ],
14
+ "name": "AccessManagedInvalidAuthority",
15
+ "type": "error"
16
+ },
17
+ {
18
+ "inputs": [
19
+ {
20
+ "internalType": "address",
21
+ "name": "caller",
22
+ "type": "address"
23
+ },
24
+ {
25
+ "internalType": "uint32",
26
+ "name": "delay",
27
+ "type": "uint32"
28
+ }
29
+ ],
30
+ "name": "AccessManagedRequiredDelay",
31
+ "type": "error"
32
+ },
33
+ {
34
+ "inputs": [
35
+ {
36
+ "internalType": "address",
37
+ "name": "caller",
38
+ "type": "address"
39
+ }
40
+ ],
41
+ "name": "AccessManagedUnauthorized",
42
+ "type": "error"
43
+ },
44
+ {
45
+ "inputs": [
46
+ {
47
+ "internalType": "address",
48
+ "name": "instanceBundleManager",
49
+ "type": "address"
50
+ }
51
+ ],
52
+ "name": "ErrorInstanceBundleManagerAlreadySet",
53
+ "type": "error"
54
+ },
55
+ {
56
+ "inputs": [
57
+ {
58
+ "internalType": "address",
59
+ "name": "instanceAuthority",
60
+ "type": "address"
61
+ }
62
+ ],
63
+ "name": "ErrorInstanceBundleManagerAuthorityMismatch",
64
+ "type": "error"
65
+ },
66
+ {
67
+ "inputs": [
68
+ {
69
+ "internalType": "address",
70
+ "name": "instance",
71
+ "type": "address"
72
+ }
73
+ ],
74
+ "name": "ErrorInstanceBundleManagerInstanceMismatch",
75
+ "type": "error"
76
+ },
77
+ {
78
+ "inputs": [
79
+ {
80
+ "internalType": "address",
81
+ "name": "instanceAccessManager",
82
+ "type": "address"
83
+ }
84
+ ],
85
+ "name": "ErrorInstanceInstanceAccessManagerAlreadySet",
86
+ "type": "error"
87
+ },
88
+ {
89
+ "inputs": [
90
+ {
91
+ "internalType": "address",
92
+ "name": "instanceAuthority",
93
+ "type": "address"
94
+ }
95
+ ],
96
+ "name": "ErrorInstanceInstanceAccessManagerAuthorityMismatch",
97
+ "type": "error"
98
+ },
99
+ {
100
+ "inputs": [],
101
+ "name": "ErrorInstanceInstanceAccessManagerZero",
102
+ "type": "error"
103
+ },
104
+ {
105
+ "inputs": [
106
+ {
107
+ "internalType": "address",
108
+ "name": "instanceAuthority",
109
+ "type": "address"
110
+ }
111
+ ],
112
+ "name": "ErrorInstanceInstanceReaderInstanceMismatch",
113
+ "type": "error"
114
+ },
6
115
  {
7
116
  "inputs": [
8
117
  {
@@ -24,6 +133,44 @@
24
133
  "name": "ErrorInvalidStateTransition",
25
134
  "type": "error"
26
135
  },
136
+ {
137
+ "inputs": [
138
+ {
139
+ "internalType": "NftId",
140
+ "name": "nftId",
141
+ "type": "uint96"
142
+ }
143
+ ],
144
+ "name": "ErrorNftOwnableAlreadyLinked",
145
+ "type": "error"
146
+ },
147
+ {
148
+ "inputs": [
149
+ {
150
+ "internalType": "address",
151
+ "name": "contractAddress",
152
+ "type": "address"
153
+ }
154
+ ],
155
+ "name": "ErrorNftOwnableContractNotRegistered",
156
+ "type": "error"
157
+ },
158
+ {
159
+ "inputs": [],
160
+ "name": "ErrorNftOwnableInitialOwnerZero",
161
+ "type": "error"
162
+ },
163
+ {
164
+ "inputs": [
165
+ {
166
+ "internalType": "address",
167
+ "name": "account",
168
+ "type": "address"
169
+ }
170
+ ],
171
+ "name": "ErrorNftOwnableNotOwner",
172
+ "type": "error"
173
+ },
27
174
  {
28
175
  "inputs": [
29
176
  {
@@ -40,6 +187,30 @@
40
187
  "name": "ErrorNoLifecycle",
41
188
  "type": "error"
42
189
  },
190
+ {
191
+ "inputs": [
192
+ {
193
+ "internalType": "address",
194
+ "name": "registryAddress",
195
+ "type": "address"
196
+ }
197
+ ],
198
+ "name": "ErrorNotRegistry",
199
+ "type": "error"
200
+ },
201
+ {
202
+ "anonymous": false,
203
+ "inputs": [
204
+ {
205
+ "indexed": false,
206
+ "internalType": "address",
207
+ "name": "authority",
208
+ "type": "address"
209
+ }
210
+ ],
211
+ "name": "AuthorityUpdated",
212
+ "type": "event"
213
+ },
43
214
  {
44
215
  "anonymous": false,
45
216
  "inputs": [
@@ -169,61 +340,102 @@
169
340
  "name": "LogStateUpdated",
170
341
  "type": "event"
171
342
  },
343
+ {
344
+ "inputs": [],
345
+ "name": "authority",
346
+ "outputs": [
347
+ {
348
+ "internalType": "address",
349
+ "name": "",
350
+ "type": "address"
351
+ }
352
+ ],
353
+ "stateMutability": "view",
354
+ "type": "function"
355
+ },
172
356
  {
173
357
  "inputs": [
174
358
  {
175
359
  "internalType": "NftId",
176
- "name": "bundleNftId",
360
+ "name": "applicationNftId",
177
361
  "type": "uint96"
178
362
  },
179
363
  {
180
364
  "components": [
181
365
  {
182
366
  "internalType": "NftId",
183
- "name": "poolNftId",
367
+ "name": "productNftId",
184
368
  "type": "uint96"
185
369
  },
186
370
  {
187
- "components": [
188
- {
189
- "internalType": "UFixed",
190
- "name": "fractionalFee",
191
- "type": "uint256"
192
- },
193
- {
194
- "internalType": "uint256",
195
- "name": "fixedFee",
196
- "type": "uint256"
197
- }
198
- ],
199
- "internalType": "struct Fee",
200
- "name": "fee",
201
- "type": "tuple"
371
+ "internalType": "NftId",
372
+ "name": "bundleNftId",
373
+ "type": "uint96"
374
+ },
375
+ {
376
+ "internalType": "ReferralId",
377
+ "name": "referralId",
378
+ "type": "bytes8"
379
+ },
380
+ {
381
+ "internalType": "RiskId",
382
+ "name": "riskId",
383
+ "type": "bytes8"
384
+ },
385
+ {
386
+ "internalType": "Amount",
387
+ "name": "sumInsuredAmount",
388
+ "type": "uint96"
389
+ },
390
+ {
391
+ "internalType": "Amount",
392
+ "name": "premiumAmount",
393
+ "type": "uint96"
394
+ },
395
+ {
396
+ "internalType": "Amount",
397
+ "name": "premiumPaidAmount",
398
+ "type": "uint96"
399
+ },
400
+ {
401
+ "internalType": "Seconds",
402
+ "name": "lifetime",
403
+ "type": "uint40"
202
404
  },
203
405
  {
204
406
  "internalType": "bytes",
205
- "name": "filter",
407
+ "name": "applicationData",
206
408
  "type": "bytes"
207
409
  },
208
410
  {
209
- "internalType": "uint256",
210
- "name": "capitalAmount",
211
- "type": "uint256"
411
+ "internalType": "bytes",
412
+ "name": "policyData",
413
+ "type": "bytes"
212
414
  },
213
415
  {
214
- "internalType": "uint256",
215
- "name": "lockedAmount",
216
- "type": "uint256"
416
+ "internalType": "uint16",
417
+ "name": "claimsCount",
418
+ "type": "uint16"
217
419
  },
218
420
  {
219
- "internalType": "uint256",
220
- "name": "balanceAmount",
221
- "type": "uint256"
421
+ "internalType": "uint16",
422
+ "name": "openClaimsCount",
423
+ "type": "uint16"
222
424
  },
223
425
  {
224
- "internalType": "uint256",
225
- "name": "lifetime",
226
- "type": "uint256"
426
+ "internalType": "Amount",
427
+ "name": "claimAmount",
428
+ "type": "uint96"
429
+ },
430
+ {
431
+ "internalType": "Amount",
432
+ "name": "payoutAmount",
433
+ "type": "uint96"
434
+ },
435
+ {
436
+ "internalType": "Timestamp",
437
+ "name": "activatedAt",
438
+ "type": "uint40"
227
439
  },
228
440
  {
229
441
  "internalType": "Timestamp",
@@ -236,12 +448,12 @@
236
448
  "type": "uint40"
237
449
  }
238
450
  ],
239
- "internalType": "struct IBundle.BundleInfo",
240
- "name": "bundle",
451
+ "internalType": "struct IPolicy.PolicyInfo",
452
+ "name": "policy",
241
453
  "type": "tuple"
242
454
  }
243
455
  ],
244
- "name": "createBundle",
456
+ "name": "createApplication",
245
457
  "outputs": [],
246
458
  "stateMutability": "nonpayable",
247
459
  "type": "function"
@@ -250,21 +462,16 @@
250
462
  "inputs": [
251
463
  {
252
464
  "internalType": "NftId",
253
- "name": "distributionNftId",
465
+ "name": "bundleNftId",
254
466
  "type": "uint96"
255
467
  },
256
468
  {
257
469
  "components": [
258
470
  {
259
471
  "internalType": "NftId",
260
- "name": "productNftId",
472
+ "name": "poolNftId",
261
473
  "type": "uint96"
262
474
  },
263
- {
264
- "internalType": "contract TokenHandler",
265
- "name": "tokenHandler",
266
- "type": "address"
267
- },
268
475
  {
269
476
  "components": [
270
477
  {
@@ -279,26 +486,51 @@
279
486
  }
280
487
  ],
281
488
  "internalType": "struct Fee",
282
- "name": "distributionFee",
489
+ "name": "fee",
283
490
  "type": "tuple"
284
491
  },
285
492
  {
286
- "internalType": "bool",
287
- "name": "isIntercepting",
288
- "type": "bool"
493
+ "internalType": "bytes",
494
+ "name": "filter",
495
+ "type": "bytes"
289
496
  },
290
497
  {
291
- "internalType": "address",
292
- "name": "wallet",
293
- "type": "address"
498
+ "internalType": "Amount",
499
+ "name": "capitalAmount",
500
+ "type": "uint96"
501
+ },
502
+ {
503
+ "internalType": "Amount",
504
+ "name": "lockedAmount",
505
+ "type": "uint96"
506
+ },
507
+ {
508
+ "internalType": "Amount",
509
+ "name": "feeAmount",
510
+ "type": "uint96"
511
+ },
512
+ {
513
+ "internalType": "Seconds",
514
+ "name": "lifetime",
515
+ "type": "uint40"
516
+ },
517
+ {
518
+ "internalType": "Timestamp",
519
+ "name": "expiredAt",
520
+ "type": "uint40"
521
+ },
522
+ {
523
+ "internalType": "Timestamp",
524
+ "name": "closedAt",
525
+ "type": "uint40"
294
526
  }
295
527
  ],
296
- "internalType": "struct ISetup.DistributionSetupInfo",
297
- "name": "setup",
528
+ "internalType": "struct IBundle.BundleInfo",
529
+ "name": "bundle",
298
530
  "type": "tuple"
299
531
  }
300
532
  ],
301
- "name": "createDistributionSetup",
533
+ "name": "createBundle",
302
534
  "outputs": [],
303
535
  "stateMutability": "nonpayable",
304
536
  "type": "function"
@@ -310,95 +542,50 @@
310
542
  "name": "policyNftId",
311
543
  "type": "uint96"
312
544
  },
545
+ {
546
+ "internalType": "ClaimId",
547
+ "name": "claimId",
548
+ "type": "uint16"
549
+ },
313
550
  {
314
551
  "components": [
315
552
  {
316
- "internalType": "NftId",
317
- "name": "productNftId",
553
+ "internalType": "Amount",
554
+ "name": "claimAmount",
318
555
  "type": "uint96"
319
556
  },
320
557
  {
321
- "internalType": "NftId",
322
- "name": "bundleNftId",
558
+ "internalType": "Amount",
559
+ "name": "paidAmount",
323
560
  "type": "uint96"
324
561
  },
325
562
  {
326
- "internalType": "ReferralId",
327
- "name": "referralId",
328
- "type": "bytes8"
329
- },
330
- {
331
- "internalType": "RiskId",
332
- "name": "riskId",
333
- "type": "bytes8"
334
- },
335
- {
336
- "internalType": "uint256",
337
- "name": "sumInsuredAmount",
338
- "type": "uint256"
339
- },
340
- {
341
- "internalType": "uint256",
342
- "name": "premiumAmount",
343
- "type": "uint256"
344
- },
345
- {
346
- "internalType": "uint256",
347
- "name": "premiumPaidAmount",
348
- "type": "uint256"
349
- },
350
- {
351
- "internalType": "uint256",
352
- "name": "lifetime",
353
- "type": "uint256"
563
+ "internalType": "uint8",
564
+ "name": "payoutsCount",
565
+ "type": "uint8"
354
566
  },
355
567
  {
356
- "internalType": "bytes",
357
- "name": "applicationData",
358
- "type": "bytes"
568
+ "internalType": "uint8",
569
+ "name": "openPayoutsCount",
570
+ "type": "uint8"
359
571
  },
360
572
  {
361
573
  "internalType": "bytes",
362
- "name": "policyData",
574
+ "name": "data",
363
575
  "type": "bytes"
364
576
  },
365
- {
366
- "internalType": "uint16",
367
- "name": "claimsCount",
368
- "type": "uint16"
369
- },
370
- {
371
- "internalType": "uint16",
372
- "name": "openClaimsCount",
373
- "type": "uint16"
374
- },
375
- {
376
- "internalType": "uint256",
377
- "name": "payoutAmount",
378
- "type": "uint256"
379
- },
380
- {
381
- "internalType": "Timestamp",
382
- "name": "activatedAt",
383
- "type": "uint40"
384
- },
385
- {
386
- "internalType": "Timestamp",
387
- "name": "expiredAt",
388
- "type": "uint40"
389
- },
390
577
  {
391
578
  "internalType": "Timestamp",
392
579
  "name": "closedAt",
393
580
  "type": "uint40"
394
581
  }
395
582
  ],
396
- "internalType": "struct IPolicy.PolicyInfo",
397
- "name": "policy",
583
+ "internalType": "struct IPolicy.ClaimInfo",
584
+ "name": "claim",
398
585
  "type": "tuple"
399
586
  }
400
587
  ],
401
- "name": "createPolicy",
588
+ "name": "createClaim",
402
589
  "outputs": [],
403
590
  "stateMutability": "nonpayable",
404
591
  "type": "function"
@@ -407,7 +594,7 @@
407
594
  "inputs": [
408
595
  {
409
596
  "internalType": "NftId",
410
- "name": "poolNftId",
597
+ "name": "distributionNftId",
411
598
  "type": "uint96"
412
599
  },
413
600
  {
@@ -422,11 +609,6 @@
422
609
  "name": "tokenHandler",
423
610
  "type": "address"
424
611
  },
425
- {
426
- "internalType": "UFixed",
427
- "name": "collateralizationLevel",
428
- "type": "uint256"
429
- },
430
612
  {
431
613
  "components": [
432
614
  {
@@ -441,7 +623,7 @@
441
623
  }
442
624
  ],
443
625
  "internalType": "struct Fee",
444
- "name": "poolFee",
626
+ "name": "minDistributionOwnerFee",
445
627
  "type": "tuple"
446
628
  },
447
629
  {
@@ -458,48 +640,136 @@
458
640
  }
459
641
  ],
460
642
  "internalType": "struct Fee",
461
- "name": "stakingFee",
643
+ "name": "distributionFee",
462
644
  "type": "tuple"
463
645
  },
464
646
  {
465
- "components": [
466
- {
467
- "internalType": "UFixed",
468
- "name": "fractionalFee",
469
- "type": "uint256"
470
- },
471
- {
472
- "internalType": "uint256",
473
- "name": "fixedFee",
474
- "type": "uint256"
475
- }
476
- ],
477
- "internalType": "struct Fee",
478
- "name": "performanceFee",
479
- "type": "tuple"
647
+ "internalType": "address",
648
+ "name": "wallet",
649
+ "type": "address"
650
+ },
651
+ {
652
+ "internalType": "uint256",
653
+ "name": "sumDistributionOwnerFees",
654
+ "type": "uint256"
655
+ }
656
+ ],
657
+ "internalType": "struct ISetup.DistributionSetupInfo",
658
+ "name": "setup",
659
+ "type": "tuple"
660
+ }
661
+ ],
662
+ "name": "createDistributionSetup",
663
+ "outputs": [],
664
+ "stateMutability": "nonpayable",
665
+ "type": "function"
666
+ },
667
+ {
668
+ "inputs": [
669
+ {
670
+ "internalType": "NftId",
671
+ "name": "nftId",
672
+ "type": "uint96"
673
+ },
674
+ {
675
+ "components": [
676
+ {
677
+ "internalType": "DistributorType",
678
+ "name": "distributorType",
679
+ "type": "bytes8"
480
680
  },
481
681
  {
482
682
  "internalType": "bool",
483
- "name": "isIntercepting",
683
+ "name": "active",
684
+ "type": "bool"
685
+ },
686
+ {
687
+ "internalType": "bytes",
688
+ "name": "data",
689
+ "type": "bytes"
690
+ },
691
+ {
692
+ "internalType": "Amount",
693
+ "name": "commissionAmount",
694
+ "type": "uint96"
695
+ },
696
+ {
697
+ "internalType": "uint32",
698
+ "name": "numPoliciesSold",
699
+ "type": "uint32"
700
+ }
701
+ ],
702
+ "internalType": "struct IDistribution.DistributorInfo",
703
+ "name": "info",
704
+ "type": "tuple"
705
+ }
706
+ ],
707
+ "name": "createDistributor",
708
+ "outputs": [],
709
+ "stateMutability": "nonpayable",
710
+ "type": "function"
711
+ },
712
+ {
713
+ "inputs": [
714
+ {
715
+ "internalType": "DistributorType",
716
+ "name": "distributorType",
717
+ "type": "bytes8"
718
+ },
719
+ {
720
+ "components": [
721
+ {
722
+ "internalType": "string",
723
+ "name": "name",
724
+ "type": "string"
725
+ },
726
+ {
727
+ "internalType": "UFixed",
728
+ "name": "minDiscountPercentage",
729
+ "type": "uint256"
730
+ },
731
+ {
732
+ "internalType": "UFixed",
733
+ "name": "maxDiscountPercentage",
734
+ "type": "uint256"
735
+ },
736
+ {
737
+ "internalType": "UFixed",
738
+ "name": "commissionPercentage",
739
+ "type": "uint256"
740
+ },
741
+ {
742
+ "internalType": "uint32",
743
+ "name": "maxReferralCount",
744
+ "type": "uint32"
745
+ },
746
+ {
747
+ "internalType": "uint32",
748
+ "name": "maxReferralLifetime",
749
+ "type": "uint32"
750
+ },
751
+ {
752
+ "internalType": "bool",
753
+ "name": "allowSelfReferrals",
484
754
  "type": "bool"
485
755
  },
486
756
  {
487
757
  "internalType": "bool",
488
- "name": "isConfirmingApplication",
758
+ "name": "allowRenewals",
489
759
  "type": "bool"
490
760
  },
491
761
  {
492
- "internalType": "address",
493
- "name": "wallet",
494
- "type": "address"
762
+ "internalType": "bytes",
763
+ "name": "data",
764
+ "type": "bytes"
495
765
  }
496
766
  ],
497
- "internalType": "struct ISetup.PoolSetupInfo",
498
- "name": "setup",
767
+ "internalType": "struct IDistribution.DistributorTypeInfo",
768
+ "name": "info",
499
769
  "type": "tuple"
500
770
  }
501
771
  ],
502
- "name": "createPoolSetup",
772
+ "name": "createDistributorType",
503
773
  "outputs": [],
504
774
  "stateMutability": "nonpayable",
505
775
  "type": "function"
@@ -508,11 +778,61 @@
508
778
  "inputs": [
509
779
  {
510
780
  "internalType": "NftId",
511
- "name": "productNftId",
781
+ "name": "policyNftId",
782
+ "type": "uint96"
783
+ },
784
+ {
785
+ "internalType": "PayoutId",
786
+ "name": "payoutId",
787
+ "type": "uint24"
788
+ },
789
+ {
790
+ "components": [
791
+ {
792
+ "internalType": "ClaimId",
793
+ "name": "claimId",
794
+ "type": "uint16"
795
+ },
796
+ {
797
+ "internalType": "Amount",
798
+ "name": "amount",
799
+ "type": "uint96"
800
+ },
801
+ {
802
+ "internalType": "bytes",
803
+ "name": "data",
804
+ "type": "bytes"
805
+ },
806
+ {
807
+ "internalType": "Timestamp",
808
+ "name": "paidAt",
809
+ "type": "uint40"
810
+ }
811
+ ],
812
+ "internalType": "struct IPolicy.PayoutInfo",
813
+ "name": "claim",
814
+ "type": "tuple"
815
+ }
816
+ ],
817
+ "name": "createPayout",
818
+ "outputs": [],
819
+ "stateMutability": "nonpayable",
820
+ "type": "function"
821
+ },
822
+ {
823
+ "inputs": [
824
+ {
825
+ "internalType": "NftId",
826
+ "name": "poolNftId",
512
827
  "type": "uint96"
513
828
  },
514
829
  {
515
830
  "components": [
831
+ {
832
+ "internalType": "string",
833
+ "name": "name",
834
+ "type": "string"
835
+ },
516
836
  {
517
837
  "internalType": "contract IERC20Metadata",
518
838
  "name": "token",
@@ -524,82 +844,64 @@
524
844
  "type": "address"
525
845
  },
526
846
  {
527
- "internalType": "NftId",
528
- "name": "distributionNftId",
847
+ "internalType": "address",
848
+ "name": "wallet",
849
+ "type": "address"
850
+ },
851
+ {
852
+ "internalType": "Amount",
853
+ "name": "balanceAmount",
529
854
  "type": "uint96"
530
855
  },
531
856
  {
532
- "internalType": "NftId",
533
- "name": "poolNftId",
857
+ "internalType": "Amount",
858
+ "name": "feeAmount",
534
859
  "type": "uint96"
535
860
  },
536
861
  {
537
- "components": [
538
- {
539
- "internalType": "UFixed",
540
- "name": "fractionalFee",
541
- "type": "uint256"
542
- },
543
- {
544
- "internalType": "uint256",
545
- "name": "fixedFee",
546
- "type": "uint256"
547
- }
548
- ],
549
- "internalType": "struct Fee",
550
- "name": "distributionFee",
551
- "type": "tuple"
862
+ "internalType": "bytes",
863
+ "name": "data",
864
+ "type": "bytes"
865
+ }
866
+ ],
867
+ "internalType": "struct IComponents.ComponentInfo",
868
+ "name": "info",
869
+ "type": "tuple"
870
+ }
871
+ ],
872
+ "name": "createPoolSetup",
873
+ "outputs": [],
874
+ "stateMutability": "nonpayable",
875
+ "type": "function"
876
+ },
877
+ {
878
+ "inputs": [
879
+ {
880
+ "internalType": "NftId",
881
+ "name": "productNftId",
882
+ "type": "uint96"
883
+ },
884
+ {
885
+ "components": [
886
+ {
887
+ "internalType": "contract IERC20Metadata",
888
+ "name": "token",
889
+ "type": "address"
552
890
  },
553
891
  {
554
- "components": [
555
- {
556
- "internalType": "UFixed",
557
- "name": "fractionalFee",
558
- "type": "uint256"
559
- },
560
- {
561
- "internalType": "uint256",
562
- "name": "fixedFee",
563
- "type": "uint256"
564
- }
565
- ],
566
- "internalType": "struct Fee",
567
- "name": "productFee",
568
- "type": "tuple"
892
+ "internalType": "contract TokenHandler",
893
+ "name": "tokenHandler",
894
+ "type": "address"
569
895
  },
570
896
  {
571
- "components": [
572
- {
573
- "internalType": "UFixed",
574
- "name": "fractionalFee",
575
- "type": "uint256"
576
- },
577
- {
578
- "internalType": "uint256",
579
- "name": "fixedFee",
580
- "type": "uint256"
581
- }
582
- ],
583
- "internalType": "struct Fee",
584
- "name": "processingFee",
585
- "type": "tuple"
897
+ "internalType": "NftId",
898
+ "name": "distributionNftId",
899
+ "type": "uint96"
586
900
  },
587
901
  {
588
- "components": [
589
- {
590
- "internalType": "UFixed",
591
- "name": "fractionalFee",
592
- "type": "uint256"
593
- },
594
- {
595
- "internalType": "uint256",
596
- "name": "fixedFee",
597
- "type": "uint256"
598
- }
599
- ],
600
- "internalType": "struct Fee",
601
- "name": "poolFee",
602
- "type": "tuple"
902
+ "internalType": "NftId",
903
+ "name": "poolNftId",
904
+ "type": "uint96"
603
905
  },
604
906
  {
605
907
  "components": [
@@ -615,7 +917,7 @@
615
917
  }
616
918
  ],
617
919
  "internalType": "struct Fee",
618
- "name": "stakingFee",
920
+ "name": "productFee",
619
921
  "type": "tuple"
620
922
  },
621
923
  {
@@ -632,7 +934,7 @@
632
934
  }
633
935
  ],
634
936
  "internalType": "struct Fee",
635
- "name": "performanceFee",
937
+ "name": "processingFee",
636
938
  "type": "tuple"
637
939
  },
638
940
  {
@@ -656,6 +958,61 @@
656
958
  "stateMutability": "nonpayable",
657
959
  "type": "function"
658
960
  },
961
+ {
962
+ "inputs": [
963
+ {
964
+ "internalType": "ReferralId",
965
+ "name": "referralId",
966
+ "type": "bytes8"
967
+ },
968
+ {
969
+ "components": [
970
+ {
971
+ "internalType": "NftId",
972
+ "name": "distributorNftId",
973
+ "type": "uint96"
974
+ },
975
+ {
976
+ "internalType": "string",
977
+ "name": "referralCode",
978
+ "type": "string"
979
+ },
980
+ {
981
+ "internalType": "UFixed",
982
+ "name": "discountPercentage",
983
+ "type": "uint256"
984
+ },
985
+ {
986
+ "internalType": "uint32",
987
+ "name": "maxReferrals",
988
+ "type": "uint32"
989
+ },
990
+ {
991
+ "internalType": "uint32",
992
+ "name": "usedReferrals",
993
+ "type": "uint32"
994
+ },
995
+ {
996
+ "internalType": "Timestamp",
997
+ "name": "expiryAt",
998
+ "type": "uint40"
999
+ },
1000
+ {
1001
+ "internalType": "bytes",
1002
+ "name": "data",
1003
+ "type": "bytes"
1004
+ }
1005
+ ],
1006
+ "internalType": "struct IDistribution.ReferralInfo",
1007
+ "name": "referralInfo",
1008
+ "type": "tuple"
1009
+ }
1010
+ ],
1011
+ "name": "createReferral",
1012
+ "outputs": [],
1013
+ "stateMutability": "nonpayable",
1014
+ "type": "function"
1015
+ },
659
1016
  {
660
1017
  "inputs": [
661
1018
  {
@@ -776,32 +1133,6 @@
776
1133
  "stateMutability": "view",
777
1134
  "type": "function"
778
1135
  },
779
- {
780
- "inputs": [],
781
- "name": "getBundleService",
782
- "outputs": [
783
- {
784
- "internalType": "contract IBundleService",
785
- "name": "",
786
- "type": "address"
787
- }
788
- ],
789
- "stateMutability": "view",
790
- "type": "function"
791
- },
792
- {
793
- "inputs": [],
794
- "name": "getComponentOwnerService",
795
- "outputs": [
796
- {
797
- "internalType": "contract IComponentOwnerService",
798
- "name": "",
799
- "type": "address"
800
- }
801
- ],
802
- "stateMutability": "view",
803
- "type": "function"
804
- },
805
1136
  {
806
1137
  "inputs": [
807
1138
  {
@@ -823,12 +1154,49 @@
823
1154
  },
824
1155
  {
825
1156
  "inputs": [],
826
- "name": "getDistributionService",
1157
+ "name": "getInitialInfo",
827
1158
  "outputs": [
828
1159
  {
829
- "internalType": "contract IDistributionService",
1160
+ "components": [
1161
+ {
1162
+ "internalType": "NftId",
1163
+ "name": "nftId",
1164
+ "type": "uint96"
1165
+ },
1166
+ {
1167
+ "internalType": "NftId",
1168
+ "name": "parentNftId",
1169
+ "type": "uint96"
1170
+ },
1171
+ {
1172
+ "internalType": "ObjectType",
1173
+ "name": "objectType",
1174
+ "type": "uint8"
1175
+ },
1176
+ {
1177
+ "internalType": "bool",
1178
+ "name": "isInterceptor",
1179
+ "type": "bool"
1180
+ },
1181
+ {
1182
+ "internalType": "address",
1183
+ "name": "objectAddress",
1184
+ "type": "address"
1185
+ },
1186
+ {
1187
+ "internalType": "address",
1188
+ "name": "initialOwner",
1189
+ "type": "address"
1190
+ },
1191
+ {
1192
+ "internalType": "bytes",
1193
+ "name": "data",
1194
+ "type": "bytes"
1195
+ }
1196
+ ],
1197
+ "internalType": "struct IRegistry.ObjectInfo",
830
1198
  "name": "",
831
- "type": "address"
1199
+ "type": "tuple"
832
1200
  }
833
1201
  ],
834
1202
  "stateMutability": "view",
@@ -879,6 +1247,19 @@
879
1247
  "stateMutability": "view",
880
1248
  "type": "function"
881
1249
  },
1250
+ {
1251
+ "inputs": [],
1252
+ "name": "getMajorVersion",
1253
+ "outputs": [
1254
+ {
1255
+ "internalType": "VersionPart",
1256
+ "name": "majorVersion",
1257
+ "type": "uint8"
1258
+ }
1259
+ ],
1260
+ "stateMutability": "pure",
1261
+ "type": "function"
1262
+ },
882
1263
  {
883
1264
  "inputs": [
884
1265
  {
@@ -927,12 +1308,12 @@
927
1308
  },
928
1309
  {
929
1310
  "inputs": [],
930
- "name": "getPolicyService",
1311
+ "name": "getNftId",
931
1312
  "outputs": [
932
1313
  {
933
- "internalType": "contract IPolicyService",
1314
+ "internalType": "NftId",
934
1315
  "name": "",
935
- "type": "address"
1316
+ "type": "uint96"
936
1317
  }
937
1318
  ],
938
1319
  "stateMutability": "view",
@@ -940,10 +1321,10 @@
940
1321
  },
941
1322
  {
942
1323
  "inputs": [],
943
- "name": "getPoolService",
1324
+ "name": "getOwner",
944
1325
  "outputs": [
945
1326
  {
946
- "internalType": "contract IPoolService",
1327
+ "internalType": "address",
947
1328
  "name": "",
948
1329
  "type": "address"
949
1330
  }
@@ -953,10 +1334,10 @@
953
1334
  },
954
1335
  {
955
1336
  "inputs": [],
956
- "name": "getProductService",
1337
+ "name": "getRegistry",
957
1338
  "outputs": [
958
1339
  {
959
- "internalType": "contract IProductService",
1340
+ "internalType": "contract IRegistry",
960
1341
  "name": "",
961
1342
  "type": "address"
962
1343
  }
@@ -1002,6 +1383,19 @@
1002
1383
  "stateMutability": "view",
1003
1384
  "type": "function"
1004
1385
  },
1386
+ {
1387
+ "inputs": [],
1388
+ "name": "isConsumingScheduledOp",
1389
+ "outputs": [
1390
+ {
1391
+ "internalType": "bytes4",
1392
+ "name": "",
1393
+ "type": "bytes4"
1394
+ }
1395
+ ],
1396
+ "stateMutability": "view",
1397
+ "type": "function"
1398
+ },
1005
1399
  {
1006
1400
  "inputs": [
1007
1401
  {
@@ -1032,46 +1426,235 @@
1032
1426
  "type": "function"
1033
1427
  },
1034
1428
  {
1035
- "inputs": [
1036
- {
1037
- "internalType": "bytes4",
1038
- "name": "interfaceId",
1039
- "type": "bytes4"
1040
- }
1041
- ],
1042
- "name": "supportsInterface",
1043
- "outputs": [
1044
- {
1045
- "internalType": "bool",
1046
- "name": "",
1047
- "type": "bool"
1048
- }
1049
- ],
1050
- "stateMutability": "view",
1429
+ "inputs": [],
1430
+ "name": "linkToRegisteredNftId",
1431
+ "outputs": [],
1432
+ "stateMutability": "nonpayable",
1051
1433
  "type": "function"
1052
1434
  },
1053
1435
  {
1054
1436
  "inputs": [
1055
1437
  {
1056
- "internalType": "ObjectType",
1057
- "name": "objectType",
1058
- "type": "uint8"
1438
+ "internalType": "address",
1439
+ "name": "to",
1440
+ "type": "address"
1059
1441
  },
1060
1442
  {
1061
- "internalType": "KeyId",
1062
- "name": "id",
1063
- "type": "bytes31"
1064
- }
1065
- ],
1066
- "name": "toKey32",
1067
- "outputs": [
1068
- {
1069
- "internalType": "Key32",
1070
- "name": "",
1071
- "type": "bytes32"
1443
+ "internalType": "uint256",
1444
+ "name": "tokenId",
1445
+ "type": "uint256"
1072
1446
  }
1073
1447
  ],
1074
- "stateMutability": "pure",
1448
+ "name": "nftMint",
1449
+ "outputs": [],
1450
+ "stateMutability": "nonpayable",
1451
+ "type": "function"
1452
+ },
1453
+ {
1454
+ "inputs": [
1455
+ {
1456
+ "internalType": "address",
1457
+ "name": "from",
1458
+ "type": "address"
1459
+ },
1460
+ {
1461
+ "internalType": "address",
1462
+ "name": "to",
1463
+ "type": "address"
1464
+ },
1465
+ {
1466
+ "internalType": "uint256",
1467
+ "name": "tokenId",
1468
+ "type": "uint256"
1469
+ }
1470
+ ],
1471
+ "name": "nftTransferFrom",
1472
+ "outputs": [],
1473
+ "stateMutability": "nonpayable",
1474
+ "type": "function"
1475
+ },
1476
+ {
1477
+ "inputs": [
1478
+ {
1479
+ "internalType": "address",
1480
+ "name": "",
1481
+ "type": "address"
1482
+ }
1483
+ ],
1484
+ "name": "setAuthority",
1485
+ "outputs": [],
1486
+ "stateMutability": "nonpayable",
1487
+ "type": "function"
1488
+ },
1489
+ {
1490
+ "inputs": [
1491
+ {
1492
+ "internalType": "bytes4",
1493
+ "name": "interfaceId",
1494
+ "type": "bytes4"
1495
+ }
1496
+ ],
1497
+ "name": "supportsInterface",
1498
+ "outputs": [
1499
+ {
1500
+ "internalType": "bool",
1501
+ "name": "",
1502
+ "type": "bool"
1503
+ }
1504
+ ],
1505
+ "stateMutability": "view",
1506
+ "type": "function"
1507
+ },
1508
+ {
1509
+ "inputs": [
1510
+ {
1511
+ "internalType": "ObjectType",
1512
+ "name": "objectType",
1513
+ "type": "uint8"
1514
+ },
1515
+ {
1516
+ "internalType": "KeyId",
1517
+ "name": "id",
1518
+ "type": "bytes31"
1519
+ }
1520
+ ],
1521
+ "name": "toKey32",
1522
+ "outputs": [
1523
+ {
1524
+ "internalType": "Key32",
1525
+ "name": "",
1526
+ "type": "bytes32"
1527
+ }
1528
+ ],
1529
+ "stateMutability": "pure",
1530
+ "type": "function"
1531
+ },
1532
+ {
1533
+ "inputs": [
1534
+ {
1535
+ "internalType": "NftId",
1536
+ "name": "applicationNftId",
1537
+ "type": "uint96"
1538
+ },
1539
+ {
1540
+ "components": [
1541
+ {
1542
+ "internalType": "NftId",
1543
+ "name": "productNftId",
1544
+ "type": "uint96"
1545
+ },
1546
+ {
1547
+ "internalType": "NftId",
1548
+ "name": "bundleNftId",
1549
+ "type": "uint96"
1550
+ },
1551
+ {
1552
+ "internalType": "ReferralId",
1553
+ "name": "referralId",
1554
+ "type": "bytes8"
1555
+ },
1556
+ {
1557
+ "internalType": "RiskId",
1558
+ "name": "riskId",
1559
+ "type": "bytes8"
1560
+ },
1561
+ {
1562
+ "internalType": "Amount",
1563
+ "name": "sumInsuredAmount",
1564
+ "type": "uint96"
1565
+ },
1566
+ {
1567
+ "internalType": "Amount",
1568
+ "name": "premiumAmount",
1569
+ "type": "uint96"
1570
+ },
1571
+ {
1572
+ "internalType": "Amount",
1573
+ "name": "premiumPaidAmount",
1574
+ "type": "uint96"
1575
+ },
1576
+ {
1577
+ "internalType": "Seconds",
1578
+ "name": "lifetime",
1579
+ "type": "uint40"
1580
+ },
1581
+ {
1582
+ "internalType": "bytes",
1583
+ "name": "applicationData",
1584
+ "type": "bytes"
1585
+ },
1586
+ {
1587
+ "internalType": "bytes",
1588
+ "name": "policyData",
1589
+ "type": "bytes"
1590
+ },
1591
+ {
1592
+ "internalType": "uint16",
1593
+ "name": "claimsCount",
1594
+ "type": "uint16"
1595
+ },
1596
+ {
1597
+ "internalType": "uint16",
1598
+ "name": "openClaimsCount",
1599
+ "type": "uint16"
1600
+ },
1601
+ {
1602
+ "internalType": "Amount",
1603
+ "name": "claimAmount",
1604
+ "type": "uint96"
1605
+ },
1606
+ {
1607
+ "internalType": "Amount",
1608
+ "name": "payoutAmount",
1609
+ "type": "uint96"
1610
+ },
1611
+ {
1612
+ "internalType": "Timestamp",
1613
+ "name": "activatedAt",
1614
+ "type": "uint40"
1615
+ },
1616
+ {
1617
+ "internalType": "Timestamp",
1618
+ "name": "expiredAt",
1619
+ "type": "uint40"
1620
+ },
1621
+ {
1622
+ "internalType": "Timestamp",
1623
+ "name": "closedAt",
1624
+ "type": "uint40"
1625
+ }
1626
+ ],
1627
+ "internalType": "struct IPolicy.PolicyInfo",
1628
+ "name": "policy",
1629
+ "type": "tuple"
1630
+ },
1631
+ {
1632
+ "internalType": "StateId",
1633
+ "name": "newState",
1634
+ "type": "uint8"
1635
+ }
1636
+ ],
1637
+ "name": "updateApplication",
1638
+ "outputs": [],
1639
+ "stateMutability": "nonpayable",
1640
+ "type": "function"
1641
+ },
1642
+ {
1643
+ "inputs": [
1644
+ {
1645
+ "internalType": "NftId",
1646
+ "name": "applicationNftId",
1647
+ "type": "uint96"
1648
+ },
1649
+ {
1650
+ "internalType": "StateId",
1651
+ "name": "newState",
1652
+ "type": "uint8"
1653
+ }
1654
+ ],
1655
+ "name": "updateApplicationState",
1656
+ "outputs": [],
1657
+ "stateMutability": "nonpayable",
1075
1658
  "type": "function"
1076
1659
  },
1077
1660
  {
@@ -1111,24 +1694,24 @@
1111
1694
  "type": "bytes"
1112
1695
  },
1113
1696
  {
1114
- "internalType": "uint256",
1697
+ "internalType": "Amount",
1115
1698
  "name": "capitalAmount",
1116
- "type": "uint256"
1699
+ "type": "uint96"
1117
1700
  },
1118
1701
  {
1119
- "internalType": "uint256",
1702
+ "internalType": "Amount",
1120
1703
  "name": "lockedAmount",
1121
- "type": "uint256"
1704
+ "type": "uint96"
1122
1705
  },
1123
1706
  {
1124
- "internalType": "uint256",
1125
- "name": "balanceAmount",
1126
- "type": "uint256"
1707
+ "internalType": "Amount",
1708
+ "name": "feeAmount",
1709
+ "type": "uint96"
1127
1710
  },
1128
1711
  {
1129
- "internalType": "uint256",
1712
+ "internalType": "Seconds",
1130
1713
  "name": "lifetime",
1131
- "type": "uint256"
1714
+ "type": "uint40"
1132
1715
  },
1133
1716
  {
1134
1717
  "internalType": "Timestamp",
@@ -1178,51 +1761,508 @@
1178
1761
  "inputs": [
1179
1762
  {
1180
1763
  "internalType": "NftId",
1181
- "name": "distributionNftId",
1764
+ "name": "policyNftId",
1182
1765
  "type": "uint96"
1183
1766
  },
1767
+ {
1768
+ "internalType": "ClaimId",
1769
+ "name": "claimId",
1770
+ "type": "uint16"
1771
+ },
1184
1772
  {
1185
1773
  "components": [
1186
1774
  {
1187
- "internalType": "NftId",
1188
- "name": "productNftId",
1775
+ "internalType": "Amount",
1776
+ "name": "claimAmount",
1189
1777
  "type": "uint96"
1190
1778
  },
1191
1779
  {
1192
- "internalType": "contract TokenHandler",
1193
- "name": "tokenHandler",
1194
- "type": "address"
1780
+ "internalType": "Amount",
1781
+ "name": "paidAmount",
1782
+ "type": "uint96"
1195
1783
  },
1196
1784
  {
1197
- "components": [
1198
- {
1199
- "internalType": "UFixed",
1200
- "name": "fractionalFee",
1201
- "type": "uint256"
1202
- },
1203
- {
1204
- "internalType": "uint256",
1205
- "name": "fixedFee",
1206
- "type": "uint256"
1207
- }
1208
- ],
1209
- "internalType": "struct Fee",
1210
- "name": "distributionFee",
1211
- "type": "tuple"
1785
+ "internalType": "uint8",
1786
+ "name": "payoutsCount",
1787
+ "type": "uint8"
1788
+ },
1789
+ {
1790
+ "internalType": "uint8",
1791
+ "name": "openPayoutsCount",
1792
+ "type": "uint8"
1793
+ },
1794
+ {
1795
+ "internalType": "bytes",
1796
+ "name": "data",
1797
+ "type": "bytes"
1798
+ },
1799
+ {
1800
+ "internalType": "Timestamp",
1801
+ "name": "closedAt",
1802
+ "type": "uint40"
1803
+ }
1804
+ ],
1805
+ "internalType": "struct IPolicy.ClaimInfo",
1806
+ "name": "claim",
1807
+ "type": "tuple"
1808
+ },
1809
+ {
1810
+ "internalType": "StateId",
1811
+ "name": "newState",
1812
+ "type": "uint8"
1813
+ }
1814
+ ],
1815
+ "name": "updateClaim",
1816
+ "outputs": [],
1817
+ "stateMutability": "nonpayable",
1818
+ "type": "function"
1819
+ },
1820
+ {
1821
+ "inputs": [
1822
+ {
1823
+ "internalType": "NftId",
1824
+ "name": "policyNftId",
1825
+ "type": "uint96"
1826
+ },
1827
+ {
1828
+ "internalType": "ClaimId",
1829
+ "name": "claimId",
1830
+ "type": "uint16"
1831
+ },
1832
+ {
1833
+ "internalType": "StateId",
1834
+ "name": "newState",
1835
+ "type": "uint8"
1836
+ }
1837
+ ],
1838
+ "name": "updateClaimState",
1839
+ "outputs": [],
1840
+ "stateMutability": "nonpayable",
1841
+ "type": "function"
1842
+ },
1843
+ {
1844
+ "inputs": [
1845
+ {
1846
+ "internalType": "NftId",
1847
+ "name": "distributionNftId",
1848
+ "type": "uint96"
1849
+ },
1850
+ {
1851
+ "components": [
1852
+ {
1853
+ "internalType": "NftId",
1854
+ "name": "productNftId",
1855
+ "type": "uint96"
1856
+ },
1857
+ {
1858
+ "internalType": "contract TokenHandler",
1859
+ "name": "tokenHandler",
1860
+ "type": "address"
1861
+ },
1862
+ {
1863
+ "components": [
1864
+ {
1865
+ "internalType": "UFixed",
1866
+ "name": "fractionalFee",
1867
+ "type": "uint256"
1868
+ },
1869
+ {
1870
+ "internalType": "uint256",
1871
+ "name": "fixedFee",
1872
+ "type": "uint256"
1873
+ }
1874
+ ],
1875
+ "internalType": "struct Fee",
1876
+ "name": "minDistributionOwnerFee",
1877
+ "type": "tuple"
1878
+ },
1879
+ {
1880
+ "components": [
1881
+ {
1882
+ "internalType": "UFixed",
1883
+ "name": "fractionalFee",
1884
+ "type": "uint256"
1885
+ },
1886
+ {
1887
+ "internalType": "uint256",
1888
+ "name": "fixedFee",
1889
+ "type": "uint256"
1890
+ }
1891
+ ],
1892
+ "internalType": "struct Fee",
1893
+ "name": "distributionFee",
1894
+ "type": "tuple"
1895
+ },
1896
+ {
1897
+ "internalType": "address",
1898
+ "name": "wallet",
1899
+ "type": "address"
1900
+ },
1901
+ {
1902
+ "internalType": "uint256",
1903
+ "name": "sumDistributionOwnerFees",
1904
+ "type": "uint256"
1905
+ }
1906
+ ],
1907
+ "internalType": "struct ISetup.DistributionSetupInfo",
1908
+ "name": "setup",
1909
+ "type": "tuple"
1910
+ },
1911
+ {
1912
+ "internalType": "StateId",
1913
+ "name": "newState",
1914
+ "type": "uint8"
1915
+ }
1916
+ ],
1917
+ "name": "updateDistributionSetup",
1918
+ "outputs": [],
1919
+ "stateMutability": "nonpayable",
1920
+ "type": "function"
1921
+ },
1922
+ {
1923
+ "inputs": [
1924
+ {
1925
+ "internalType": "NftId",
1926
+ "name": "distributionNftId",
1927
+ "type": "uint96"
1928
+ },
1929
+ {
1930
+ "internalType": "StateId",
1931
+ "name": "newState",
1932
+ "type": "uint8"
1933
+ }
1934
+ ],
1935
+ "name": "updateDistributionSetupState",
1936
+ "outputs": [],
1937
+ "stateMutability": "nonpayable",
1938
+ "type": "function"
1939
+ },
1940
+ {
1941
+ "inputs": [
1942
+ {
1943
+ "internalType": "NftId",
1944
+ "name": "nftId",
1945
+ "type": "uint96"
1946
+ },
1947
+ {
1948
+ "components": [
1949
+ {
1950
+ "internalType": "DistributorType",
1951
+ "name": "distributorType",
1952
+ "type": "bytes8"
1953
+ },
1954
+ {
1955
+ "internalType": "bool",
1956
+ "name": "active",
1957
+ "type": "bool"
1958
+ },
1959
+ {
1960
+ "internalType": "bytes",
1961
+ "name": "data",
1962
+ "type": "bytes"
1963
+ },
1964
+ {
1965
+ "internalType": "Amount",
1966
+ "name": "commissionAmount",
1967
+ "type": "uint96"
1968
+ },
1969
+ {
1970
+ "internalType": "uint32",
1971
+ "name": "numPoliciesSold",
1972
+ "type": "uint32"
1973
+ }
1974
+ ],
1975
+ "internalType": "struct IDistribution.DistributorInfo",
1976
+ "name": "info",
1977
+ "type": "tuple"
1978
+ },
1979
+ {
1980
+ "internalType": "StateId",
1981
+ "name": "newState",
1982
+ "type": "uint8"
1983
+ }
1984
+ ],
1985
+ "name": "updateDistributor",
1986
+ "outputs": [],
1987
+ "stateMutability": "nonpayable",
1988
+ "type": "function"
1989
+ },
1990
+ {
1991
+ "inputs": [
1992
+ {
1993
+ "internalType": "NftId",
1994
+ "name": "nftId",
1995
+ "type": "uint96"
1996
+ },
1997
+ {
1998
+ "internalType": "StateId",
1999
+ "name": "newState",
2000
+ "type": "uint8"
2001
+ }
2002
+ ],
2003
+ "name": "updateDistributorState",
2004
+ "outputs": [],
2005
+ "stateMutability": "nonpayable",
2006
+ "type": "function"
2007
+ },
2008
+ {
2009
+ "inputs": [
2010
+ {
2011
+ "internalType": "DistributorType",
2012
+ "name": "distributorType",
2013
+ "type": "bytes8"
2014
+ },
2015
+ {
2016
+ "components": [
2017
+ {
2018
+ "internalType": "string",
2019
+ "name": "name",
2020
+ "type": "string"
2021
+ },
2022
+ {
2023
+ "internalType": "UFixed",
2024
+ "name": "minDiscountPercentage",
2025
+ "type": "uint256"
2026
+ },
2027
+ {
2028
+ "internalType": "UFixed",
2029
+ "name": "maxDiscountPercentage",
2030
+ "type": "uint256"
2031
+ },
2032
+ {
2033
+ "internalType": "UFixed",
2034
+ "name": "commissionPercentage",
2035
+ "type": "uint256"
2036
+ },
2037
+ {
2038
+ "internalType": "uint32",
2039
+ "name": "maxReferralCount",
2040
+ "type": "uint32"
2041
+ },
2042
+ {
2043
+ "internalType": "uint32",
2044
+ "name": "maxReferralLifetime",
2045
+ "type": "uint32"
2046
+ },
2047
+ {
2048
+ "internalType": "bool",
2049
+ "name": "allowSelfReferrals",
2050
+ "type": "bool"
2051
+ },
2052
+ {
2053
+ "internalType": "bool",
2054
+ "name": "allowRenewals",
2055
+ "type": "bool"
2056
+ },
2057
+ {
2058
+ "internalType": "bytes",
2059
+ "name": "data",
2060
+ "type": "bytes"
2061
+ }
2062
+ ],
2063
+ "internalType": "struct IDistribution.DistributorTypeInfo",
2064
+ "name": "info",
2065
+ "type": "tuple"
2066
+ },
2067
+ {
2068
+ "internalType": "StateId",
2069
+ "name": "newState",
2070
+ "type": "uint8"
2071
+ }
2072
+ ],
2073
+ "name": "updateDistributorType",
2074
+ "outputs": [],
2075
+ "stateMutability": "nonpayable",
2076
+ "type": "function"
2077
+ },
2078
+ {
2079
+ "inputs": [
2080
+ {
2081
+ "internalType": "DistributorType",
2082
+ "name": "distributorType",
2083
+ "type": "bytes8"
2084
+ },
2085
+ {
2086
+ "internalType": "StateId",
2087
+ "name": "newState",
2088
+ "type": "uint8"
2089
+ }
2090
+ ],
2091
+ "name": "updateDistributorTypeState",
2092
+ "outputs": [],
2093
+ "stateMutability": "nonpayable",
2094
+ "type": "function"
2095
+ },
2096
+ {
2097
+ "inputs": [
2098
+ {
2099
+ "internalType": "NftId",
2100
+ "name": "policyNftId",
2101
+ "type": "uint96"
2102
+ },
2103
+ {
2104
+ "internalType": "PayoutId",
2105
+ "name": "payoutId",
2106
+ "type": "uint24"
2107
+ },
2108
+ {
2109
+ "components": [
2110
+ {
2111
+ "internalType": "ClaimId",
2112
+ "name": "claimId",
2113
+ "type": "uint16"
2114
+ },
2115
+ {
2116
+ "internalType": "Amount",
2117
+ "name": "amount",
2118
+ "type": "uint96"
2119
+ },
2120
+ {
2121
+ "internalType": "bytes",
2122
+ "name": "data",
2123
+ "type": "bytes"
2124
+ },
2125
+ {
2126
+ "internalType": "Timestamp",
2127
+ "name": "paidAt",
2128
+ "type": "uint40"
2129
+ }
2130
+ ],
2131
+ "internalType": "struct IPolicy.PayoutInfo",
2132
+ "name": "claim",
2133
+ "type": "tuple"
2134
+ },
2135
+ {
2136
+ "internalType": "StateId",
2137
+ "name": "newState",
2138
+ "type": "uint8"
2139
+ }
2140
+ ],
2141
+ "name": "updatePayout",
2142
+ "outputs": [],
2143
+ "stateMutability": "nonpayable",
2144
+ "type": "function"
2145
+ },
2146
+ {
2147
+ "inputs": [
2148
+ {
2149
+ "internalType": "NftId",
2150
+ "name": "policyNftId",
2151
+ "type": "uint96"
2152
+ },
2153
+ {
2154
+ "internalType": "PayoutId",
2155
+ "name": "payoutId",
2156
+ "type": "uint24"
2157
+ },
2158
+ {
2159
+ "internalType": "StateId",
2160
+ "name": "newState",
2161
+ "type": "uint8"
2162
+ }
2163
+ ],
2164
+ "name": "updatePayoutState",
2165
+ "outputs": [],
2166
+ "stateMutability": "nonpayable",
2167
+ "type": "function"
2168
+ },
2169
+ {
2170
+ "inputs": [
2171
+ {
2172
+ "internalType": "NftId",
2173
+ "name": "policyNftId",
2174
+ "type": "uint96"
2175
+ },
2176
+ {
2177
+ "components": [
2178
+ {
2179
+ "internalType": "NftId",
2180
+ "name": "productNftId",
2181
+ "type": "uint96"
2182
+ },
2183
+ {
2184
+ "internalType": "NftId",
2185
+ "name": "bundleNftId",
2186
+ "type": "uint96"
2187
+ },
2188
+ {
2189
+ "internalType": "ReferralId",
2190
+ "name": "referralId",
2191
+ "type": "bytes8"
2192
+ },
2193
+ {
2194
+ "internalType": "RiskId",
2195
+ "name": "riskId",
2196
+ "type": "bytes8"
2197
+ },
2198
+ {
2199
+ "internalType": "Amount",
2200
+ "name": "sumInsuredAmount",
2201
+ "type": "uint96"
2202
+ },
2203
+ {
2204
+ "internalType": "Amount",
2205
+ "name": "premiumAmount",
2206
+ "type": "uint96"
2207
+ },
2208
+ {
2209
+ "internalType": "Amount",
2210
+ "name": "premiumPaidAmount",
2211
+ "type": "uint96"
2212
+ },
2213
+ {
2214
+ "internalType": "Seconds",
2215
+ "name": "lifetime",
2216
+ "type": "uint40"
2217
+ },
2218
+ {
2219
+ "internalType": "bytes",
2220
+ "name": "applicationData",
2221
+ "type": "bytes"
2222
+ },
2223
+ {
2224
+ "internalType": "bytes",
2225
+ "name": "policyData",
2226
+ "type": "bytes"
2227
+ },
2228
+ {
2229
+ "internalType": "uint16",
2230
+ "name": "claimsCount",
2231
+ "type": "uint16"
2232
+ },
2233
+ {
2234
+ "internalType": "uint16",
2235
+ "name": "openClaimsCount",
2236
+ "type": "uint16"
2237
+ },
2238
+ {
2239
+ "internalType": "Amount",
2240
+ "name": "claimAmount",
2241
+ "type": "uint96"
2242
+ },
2243
+ {
2244
+ "internalType": "Amount",
2245
+ "name": "payoutAmount",
2246
+ "type": "uint96"
2247
+ },
2248
+ {
2249
+ "internalType": "Timestamp",
2250
+ "name": "activatedAt",
2251
+ "type": "uint40"
1212
2252
  },
1213
2253
  {
1214
- "internalType": "bool",
1215
- "name": "isIntercepting",
1216
- "type": "bool"
2254
+ "internalType": "Timestamp",
2255
+ "name": "expiredAt",
2256
+ "type": "uint40"
1217
2257
  },
1218
2258
  {
1219
- "internalType": "address",
1220
- "name": "wallet",
1221
- "type": "address"
2259
+ "internalType": "Timestamp",
2260
+ "name": "closedAt",
2261
+ "type": "uint40"
1222
2262
  }
1223
2263
  ],
1224
- "internalType": "struct ISetup.DistributionSetupInfo",
1225
- "name": "setup",
2264
+ "internalType": "struct IPolicy.PolicyInfo",
2265
+ "name": "policy",
1226
2266
  "type": "tuple"
1227
2267
  },
1228
2268
  {
@@ -1231,25 +2271,7 @@
1231
2271
  "type": "uint8"
1232
2272
  }
1233
2273
  ],
1234
- "name": "updateDistributionSetup",
1235
- "outputs": [],
1236
- "stateMutability": "nonpayable",
1237
- "type": "function"
1238
- },
1239
- {
1240
- "inputs": [
1241
- {
1242
- "internalType": "NftId",
1243
- "name": "distributionNftId",
1244
- "type": "uint96"
1245
- },
1246
- {
1247
- "internalType": "StateId",
1248
- "name": "newState",
1249
- "type": "uint8"
1250
- }
1251
- ],
1252
- "name": "updateDistributionSetupState",
2274
+ "name": "updatePolicy",
1253
2275
  "outputs": [],
1254
2276
  "stateMutability": "nonpayable",
1255
2277
  "type": "function"
@@ -1284,24 +2306,24 @@
1284
2306
  "type": "bytes8"
1285
2307
  },
1286
2308
  {
1287
- "internalType": "uint256",
2309
+ "internalType": "Amount",
1288
2310
  "name": "sumInsuredAmount",
1289
- "type": "uint256"
2311
+ "type": "uint96"
1290
2312
  },
1291
2313
  {
1292
- "internalType": "uint256",
2314
+ "internalType": "Amount",
1293
2315
  "name": "premiumAmount",
1294
- "type": "uint256"
2316
+ "type": "uint96"
1295
2317
  },
1296
2318
  {
1297
- "internalType": "uint256",
2319
+ "internalType": "Amount",
1298
2320
  "name": "premiumPaidAmount",
1299
- "type": "uint256"
2321
+ "type": "uint96"
1300
2322
  },
1301
2323
  {
1302
- "internalType": "uint256",
2324
+ "internalType": "Seconds",
1303
2325
  "name": "lifetime",
1304
- "type": "uint256"
2326
+ "type": "uint40"
1305
2327
  },
1306
2328
  {
1307
2329
  "internalType": "bytes",
@@ -1324,9 +2346,14 @@
1324
2346
  "type": "uint16"
1325
2347
  },
1326
2348
  {
1327
- "internalType": "uint256",
2349
+ "internalType": "Amount",
2350
+ "name": "claimAmount",
2351
+ "type": "uint96"
2352
+ },
2353
+ {
2354
+ "internalType": "Amount",
1328
2355
  "name": "payoutAmount",
1329
- "type": "uint256"
2356
+ "type": "uint96"
1330
2357
  },
1331
2358
  {
1332
2359
  "internalType": "Timestamp",
@@ -1354,7 +2381,7 @@
1354
2381
  "type": "uint8"
1355
2382
  }
1356
2383
  ],
1357
- "name": "updatePolicy",
2384
+ "name": "updatePolicyClaims",
1358
2385
  "outputs": [],
1359
2386
  "stateMutability": "nonpayable",
1360
2387
  "type": "function"
@@ -1387,89 +2414,43 @@
1387
2414
  {
1388
2415
  "components": [
1389
2416
  {
1390
- "internalType": "NftId",
1391
- "name": "productNftId",
1392
- "type": "uint96"
2417
+ "internalType": "string",
2418
+ "name": "name",
2419
+ "type": "string"
1393
2420
  },
1394
2421
  {
1395
- "internalType": "contract TokenHandler",
1396
- "name": "tokenHandler",
2422
+ "internalType": "contract IERC20Metadata",
2423
+ "name": "token",
1397
2424
  "type": "address"
1398
2425
  },
1399
2426
  {
1400
- "internalType": "UFixed",
1401
- "name": "collateralizationLevel",
1402
- "type": "uint256"
1403
- },
1404
- {
1405
- "components": [
1406
- {
1407
- "internalType": "UFixed",
1408
- "name": "fractionalFee",
1409
- "type": "uint256"
1410
- },
1411
- {
1412
- "internalType": "uint256",
1413
- "name": "fixedFee",
1414
- "type": "uint256"
1415
- }
1416
- ],
1417
- "internalType": "struct Fee",
1418
- "name": "poolFee",
1419
- "type": "tuple"
1420
- },
1421
- {
1422
- "components": [
1423
- {
1424
- "internalType": "UFixed",
1425
- "name": "fractionalFee",
1426
- "type": "uint256"
1427
- },
1428
- {
1429
- "internalType": "uint256",
1430
- "name": "fixedFee",
1431
- "type": "uint256"
1432
- }
1433
- ],
1434
- "internalType": "struct Fee",
1435
- "name": "stakingFee",
1436
- "type": "tuple"
2427
+ "internalType": "contract TokenHandler",
2428
+ "name": "tokenHandler",
2429
+ "type": "address"
1437
2430
  },
1438
2431
  {
1439
- "components": [
1440
- {
1441
- "internalType": "UFixed",
1442
- "name": "fractionalFee",
1443
- "type": "uint256"
1444
- },
1445
- {
1446
- "internalType": "uint256",
1447
- "name": "fixedFee",
1448
- "type": "uint256"
1449
- }
1450
- ],
1451
- "internalType": "struct Fee",
1452
- "name": "performanceFee",
1453
- "type": "tuple"
2432
+ "internalType": "address",
2433
+ "name": "wallet",
2434
+ "type": "address"
1454
2435
  },
1455
2436
  {
1456
- "internalType": "bool",
1457
- "name": "isIntercepting",
1458
- "type": "bool"
2437
+ "internalType": "Amount",
2438
+ "name": "balanceAmount",
2439
+ "type": "uint96"
1459
2440
  },
1460
2441
  {
1461
- "internalType": "bool",
1462
- "name": "isConfirmingApplication",
1463
- "type": "bool"
2442
+ "internalType": "Amount",
2443
+ "name": "feeAmount",
2444
+ "type": "uint96"
1464
2445
  },
1465
2446
  {
1466
- "internalType": "address",
1467
- "name": "wallet",
1468
- "type": "address"
2447
+ "internalType": "bytes",
2448
+ "name": "data",
2449
+ "type": "bytes"
1469
2450
  }
1470
2451
  ],
1471
- "internalType": "struct ISetup.PoolSetupInfo",
1472
- "name": "setup",
2452
+ "internalType": "struct IComponents.ComponentInfo",
2453
+ "name": "info",
1473
2454
  "type": "tuple"
1474
2455
  },
1475
2456
  {
@@ -1530,23 +2511,6 @@
1530
2511
  "name": "poolNftId",
1531
2512
  "type": "uint96"
1532
2513
  },
1533
- {
1534
- "components": [
1535
- {
1536
- "internalType": "UFixed",
1537
- "name": "fractionalFee",
1538
- "type": "uint256"
1539
- },
1540
- {
1541
- "internalType": "uint256",
1542
- "name": "fixedFee",
1543
- "type": "uint256"
1544
- }
1545
- ],
1546
- "internalType": "struct Fee",
1547
- "name": "distributionFee",
1548
- "type": "tuple"
1549
- },
1550
2514
  {
1551
2515
  "components": [
1552
2516
  {
@@ -1581,57 +2545,6 @@
1581
2545
  "name": "processingFee",
1582
2546
  "type": "tuple"
1583
2547
  },
1584
- {
1585
- "components": [
1586
- {
1587
- "internalType": "UFixed",
1588
- "name": "fractionalFee",
1589
- "type": "uint256"
1590
- },
1591
- {
1592
- "internalType": "uint256",
1593
- "name": "fixedFee",
1594
- "type": "uint256"
1595
- }
1596
- ],
1597
- "internalType": "struct Fee",
1598
- "name": "poolFee",
1599
- "type": "tuple"
1600
- },
1601
- {
1602
- "components": [
1603
- {
1604
- "internalType": "UFixed",
1605
- "name": "fractionalFee",
1606
- "type": "uint256"
1607
- },
1608
- {
1609
- "internalType": "uint256",
1610
- "name": "fixedFee",
1611
- "type": "uint256"
1612
- }
1613
- ],
1614
- "internalType": "struct Fee",
1615
- "name": "stakingFee",
1616
- "type": "tuple"
1617
- },
1618
- {
1619
- "components": [
1620
- {
1621
- "internalType": "UFixed",
1622
- "name": "fractionalFee",
1623
- "type": "uint256"
1624
- },
1625
- {
1626
- "internalType": "uint256",
1627
- "name": "fixedFee",
1628
- "type": "uint256"
1629
- }
1630
- ],
1631
- "internalType": "struct Fee",
1632
- "name": "performanceFee",
1633
- "type": "tuple"
1634
- },
1635
2548
  {
1636
2549
  "internalType": "bool",
1637
2550
  "name": "isIntercepting",
@@ -1676,6 +2589,84 @@
1676
2589
  "stateMutability": "nonpayable",
1677
2590
  "type": "function"
1678
2591
  },
2592
+ {
2593
+ "inputs": [
2594
+ {
2595
+ "internalType": "ReferralId",
2596
+ "name": "referralId",
2597
+ "type": "bytes8"
2598
+ },
2599
+ {
2600
+ "components": [
2601
+ {
2602
+ "internalType": "NftId",
2603
+ "name": "distributorNftId",
2604
+ "type": "uint96"
2605
+ },
2606
+ {
2607
+ "internalType": "string",
2608
+ "name": "referralCode",
2609
+ "type": "string"
2610
+ },
2611
+ {
2612
+ "internalType": "UFixed",
2613
+ "name": "discountPercentage",
2614
+ "type": "uint256"
2615
+ },
2616
+ {
2617
+ "internalType": "uint32",
2618
+ "name": "maxReferrals",
2619
+ "type": "uint32"
2620
+ },
2621
+ {
2622
+ "internalType": "uint32",
2623
+ "name": "usedReferrals",
2624
+ "type": "uint32"
2625
+ },
2626
+ {
2627
+ "internalType": "Timestamp",
2628
+ "name": "expiryAt",
2629
+ "type": "uint40"
2630
+ },
2631
+ {
2632
+ "internalType": "bytes",
2633
+ "name": "data",
2634
+ "type": "bytes"
2635
+ }
2636
+ ],
2637
+ "internalType": "struct IDistribution.ReferralInfo",
2638
+ "name": "referralInfo",
2639
+ "type": "tuple"
2640
+ },
2641
+ {
2642
+ "internalType": "StateId",
2643
+ "name": "newState",
2644
+ "type": "uint8"
2645
+ }
2646
+ ],
2647
+ "name": "updateReferral",
2648
+ "outputs": [],
2649
+ "stateMutability": "nonpayable",
2650
+ "type": "function"
2651
+ },
2652
+ {
2653
+ "inputs": [
2654
+ {
2655
+ "internalType": "ReferralId",
2656
+ "name": "referralId",
2657
+ "type": "bytes8"
2658
+ },
2659
+ {
2660
+ "internalType": "StateId",
2661
+ "name": "newState",
2662
+ "type": "uint8"
2663
+ }
2664
+ ],
2665
+ "name": "updateReferralState",
2666
+ "outputs": [],
2667
+ "stateMutability": "nonpayable",
2668
+ "type": "function"
2669
+ },
1679
2670
  {
1680
2671
  "inputs": [
1681
2672
  {