@gearbox-protocol/sdk 14.12.0-next.80 → 14.12.0-next.82

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (221) hide show
  1. package/dist/cjs/model/filters.js +0 -4
  2. package/dist/cjs/model/filters.schema.js +10 -1
  3. package/dist/cjs/model/index.js +11 -0
  4. package/dist/cjs/model/liquidations.js +1 -1
  5. package/dist/cjs/model/liquidations.schema.js +1 -1
  6. package/dist/cjs/model/opportunities.js +1 -1
  7. package/dist/cjs/model/opportunities.schema.js +6 -13
  8. package/dist/cjs/model/positions.js +1 -1
  9. package/dist/cjs/model/positions.schema.js +33 -1
  10. package/dist/cjs/model/response.js +1 -0
  11. package/dist/cjs/model/response.schema.js +64 -0
  12. package/dist/cjs/new-sdk/AbstractNamespace.js +46 -128
  13. package/dist/cjs/new-sdk/GearboxSDK.js +55 -42
  14. package/dist/cjs/new-sdk/errors/AllSourcesFailedError.js +20 -0
  15. package/dist/cjs/new-sdk/errors/MissingSourceError.js +25 -0
  16. package/dist/cjs/new-sdk/errors/NoSourceServedError.js +20 -0
  17. package/dist/cjs/new-sdk/errors/SourceChainMismatchError.js +34 -0
  18. package/dist/cjs/new-sdk/errors/SourceUnavailableError.js +25 -0
  19. package/dist/cjs/new-sdk/errors/assertSameChains.js +12 -0
  20. package/dist/cjs/new-sdk/errors/everyChainFailed.js +11 -0
  21. package/dist/cjs/new-sdk/errors/index.js +15 -0
  22. package/dist/cjs/new-sdk/index.js +23 -3
  23. package/dist/cjs/new-sdk/opportunities/OpportunitiesNamespace.js +37 -89
  24. package/dist/cjs/new-sdk/positions/PositionsNamespace.js +27 -94
  25. package/dist/cjs/new-sdk/types.js +0 -21
  26. package/dist/cjs/new-sdk/utils/filterResponse.js +21 -0
  27. package/dist/cjs/new-sdk/utils/index.js +6 -0
  28. package/dist/cjs/new-sdk/utils/mergeChains.js +81 -0
  29. package/dist/cjs/new-sdk/utils/types.js +1 -0
  30. package/dist/cjs/offchain/AbstractOffchainNamespace.js +42 -65
  31. package/dist/cjs/offchain/GearboxAPI.js +12 -8
  32. package/dist/cjs/offchain/errors/OffchainInvalidJsonError.js +19 -0
  33. package/dist/cjs/offchain/errors/OffchainNotConfiguredError.js +20 -0
  34. package/dist/cjs/offchain/errors/OffchainNotImplementedError.js +19 -0
  35. package/dist/cjs/offchain/errors/OffchainRequestFailedError.js +24 -0
  36. package/dist/cjs/offchain/errors/OffchainStatusError.js +20 -0
  37. package/dist/cjs/offchain/errors/OffchainTransportError.js +31 -0
  38. package/dist/cjs/offchain/errors/OffchainValidationError.js +26 -0
  39. package/dist/cjs/offchain/errors/backendMessage.js +28 -0
  40. package/dist/cjs/offchain/errors/errorCause.js +12 -0
  41. package/dist/cjs/offchain/errors/index.js +21 -0
  42. package/dist/cjs/offchain/errors/readResponseBody.js +15 -0
  43. package/dist/cjs/offchain/index.js +22 -5
  44. package/dist/cjs/offchain/opportunities/OffchainOpportunities.js +6 -3
  45. package/dist/cjs/offchain/positions/OffchainPositions.js +15 -21
  46. package/dist/cjs/offchain/types.js +0 -75
  47. package/dist/cjs/sdk/MultichainSDK.js +1 -1
  48. package/dist/cjs/sdk/OnchainSDK.js +1 -1
  49. package/dist/cjs/sdk/accounts/credit-account-compressor/CreditAccountCompressor.js +6 -6
  50. package/dist/cjs/sdk/accounts/liquidations/LiquidationsService.js +26 -20
  51. package/dist/cjs/sdk/accounts/liquidations/MultichainLiquidationsService.js +38 -14
  52. package/dist/cjs/sdk/accounts/withdrawal-compressor/AbstractWithdrawalCompressorContract.js +7 -5
  53. package/dist/cjs/sdk/accounts/withdrawal-compressor/WithdrawalCompressorV313Contract.js +3 -2
  54. package/dist/cjs/sdk/base/MultichainConstruct.js +73 -34
  55. package/dist/cjs/sdk/chain/chains.js +11 -0
  56. package/dist/cjs/sdk/chain/index.js +1 -0
  57. package/dist/cjs/sdk/core/index.js +1 -1
  58. package/dist/cjs/sdk/index.js +2 -1
  59. package/dist/cjs/sdk/market/rwa/RWARegistry.js +4 -2
  60. package/dist/cjs/sdk/opportunities/MultichainOpportunitiesService.js +18 -32
  61. package/dist/cjs/sdk/opportunities/OpportunitiesService.js +1 -4
  62. package/dist/cjs/sdk/pools/PoolService.js +2 -1
  63. package/dist/cjs/sdk/positions/MultichainPositionsService.js +6 -29
  64. package/dist/cjs/sdk/positions/PositionsService.js +12 -6
  65. package/dist/esm/dev/AccountOpener.js +1 -1
  66. package/dist/esm/dev/withdrawalUtils.js +1 -1
  67. package/dist/esm/model/filters.js +0 -4
  68. package/dist/esm/model/filters.schema.js +10 -2
  69. package/dist/esm/model/index.js +5 -3
  70. package/dist/esm/model/liquidations.js +1 -1
  71. package/dist/esm/model/liquidations.schema.js +1 -1
  72. package/dist/esm/model/opportunities.js +1 -1
  73. package/dist/esm/model/opportunities.schema.js +4 -11
  74. package/dist/esm/model/positions.js +1 -1
  75. package/dist/esm/model/positions.schema.js +33 -3
  76. package/dist/esm/model/response.js +1 -0
  77. package/dist/esm/model/response.schema.js +58 -0
  78. package/dist/esm/new-sdk/AbstractNamespace.js +46 -128
  79. package/dist/esm/new-sdk/GearboxSDK.js +55 -42
  80. package/dist/esm/new-sdk/errors/AllSourcesFailedError.js +19 -0
  81. package/dist/esm/new-sdk/errors/MissingSourceError.js +24 -0
  82. package/dist/esm/new-sdk/errors/NoSourceServedError.js +19 -0
  83. package/dist/esm/new-sdk/errors/SourceChainMismatchError.js +33 -0
  84. package/dist/esm/new-sdk/errors/SourceUnavailableError.js +24 -0
  85. package/dist/esm/new-sdk/errors/assertSameChains.js +11 -0
  86. package/dist/esm/new-sdk/errors/everyChainFailed.js +10 -0
  87. package/dist/esm/new-sdk/errors/index.js +8 -0
  88. package/dist/esm/new-sdk/index.js +13 -3
  89. package/dist/esm/new-sdk/opportunities/OpportunitiesNamespace.js +38 -90
  90. package/dist/esm/new-sdk/positions/PositionsNamespace.js +28 -95
  91. package/dist/esm/new-sdk/types.js +1 -21
  92. package/dist/esm/new-sdk/utils/filterResponse.js +20 -0
  93. package/dist/esm/new-sdk/utils/index.js +3 -1
  94. package/dist/esm/new-sdk/utils/mergeChains.js +78 -0
  95. package/dist/esm/new-sdk/utils/types.js +1 -0
  96. package/dist/esm/offchain/AbstractOffchainNamespace.js +41 -64
  97. package/dist/esm/offchain/GearboxAPI.js +12 -8
  98. package/dist/esm/offchain/errors/OffchainInvalidJsonError.js +18 -0
  99. package/dist/esm/offchain/errors/OffchainNotConfiguredError.js +19 -0
  100. package/dist/esm/offchain/errors/OffchainNotImplementedError.js +18 -0
  101. package/dist/esm/offchain/errors/OffchainRequestFailedError.js +23 -0
  102. package/dist/esm/offchain/errors/OffchainStatusError.js +19 -0
  103. package/dist/esm/offchain/errors/OffchainTransportError.js +30 -0
  104. package/dist/esm/offchain/errors/OffchainValidationError.js +25 -0
  105. package/dist/esm/offchain/errors/backendMessage.js +27 -0
  106. package/dist/esm/offchain/errors/errorCause.js +11 -0
  107. package/dist/esm/offchain/errors/index.js +11 -0
  108. package/dist/esm/offchain/errors/readResponseBody.js +14 -0
  109. package/dist/esm/offchain/index.js +13 -2
  110. package/dist/esm/offchain/opportunities/OffchainOpportunities.js +6 -3
  111. package/dist/esm/offchain/positions/OffchainPositions.js +15 -21
  112. package/dist/esm/offchain/types.js +1 -72
  113. package/dist/esm/plugins/adapters/contracts/ERC4626AdapterContract.js +1 -1
  114. package/dist/esm/preview/simulate/simulatePoolOperation.js +1 -1
  115. package/dist/esm/preview/trace/extractTransfers.js +1 -1
  116. package/dist/esm/sdk/MultichainSDK.js +1 -1
  117. package/dist/esm/sdk/OnchainSDK.js +1 -1
  118. package/dist/esm/sdk/accounts/CreditAccountsServiceV310.js +2 -2
  119. package/dist/esm/sdk/accounts/credit-account-compressor/CreditAccountCompressor.js +6 -6
  120. package/dist/esm/sdk/accounts/liquidations/LiquidationsService.js +27 -21
  121. package/dist/esm/sdk/accounts/liquidations/MultichainLiquidationsService.js +38 -14
  122. package/dist/esm/sdk/accounts/withdrawal-compressor/AbstractWithdrawalCompressorContract.js +7 -5
  123. package/dist/esm/sdk/accounts/withdrawal-compressor/RedemptionLoggerV310Contract.js +1 -1
  124. package/dist/esm/sdk/accounts/withdrawal-compressor/WithdrawalCompressorV310Contract.js +1 -1
  125. package/dist/esm/sdk/accounts/withdrawal-compressor/WithdrawalCompressorV311Contract.js +1 -1
  126. package/dist/esm/sdk/accounts/withdrawal-compressor/WithdrawalCompressorV313Contract.js +4 -3
  127. package/dist/esm/sdk/base/MultichainConstruct.js +73 -34
  128. package/dist/esm/sdk/base/TokensMeta.js +2 -2
  129. package/dist/esm/sdk/chain/chains.js +11 -1
  130. package/dist/esm/sdk/chain/detectNetwork.js +1 -1
  131. package/dist/esm/sdk/chain/index.js +2 -2
  132. package/dist/esm/sdk/core/createAddressProvider.js +1 -1
  133. package/dist/esm/sdk/core/index.js +1 -1
  134. package/dist/esm/sdk/index.js +3 -3
  135. package/dist/esm/sdk/market/credit/CreditFacadeV310BaseContract.js +1 -1
  136. package/dist/esm/sdk/market/pool/PoolV310Contract.js +1 -1
  137. package/dist/esm/sdk/market/rwa/RWARegistry.js +4 -2
  138. package/dist/esm/sdk/market/zapper/IETHZapperContract.js +1 -1
  139. package/dist/esm/sdk/market/zapper/ZapperContract.js +1 -1
  140. package/dist/esm/sdk/opportunities/MultichainOpportunitiesService.js +18 -32
  141. package/dist/esm/sdk/opportunities/OpportunitiesService.js +1 -4
  142. package/dist/esm/sdk/pools/PoolService.js +3 -2
  143. package/dist/esm/sdk/positions/MultichainPositionsService.js +6 -29
  144. package/dist/esm/sdk/positions/PositionsService.js +12 -6
  145. package/dist/esm/sdk/utils/viem/simulateWithPriceUpdates.js +1 -1
  146. package/dist/types/model/filters.d.ts +9 -3
  147. package/dist/types/model/filters.schema.d.ts +7 -1
  148. package/dist/types/model/index.d.ts +7 -5
  149. package/dist/types/model/liquidations.d.ts +2 -6
  150. package/dist/types/model/liquidations.schema.d.ts +1 -1
  151. package/dist/types/model/opportunities.d.ts +3 -7
  152. package/dist/types/model/opportunities.schema.d.ts +2 -2
  153. package/dist/types/model/positions.d.ts +2 -6
  154. package/dist/types/model/positions.schema.d.ts +32 -2
  155. package/dist/types/model/response.d.ts +105 -0
  156. package/dist/types/model/response.schema.d.ts +98 -0
  157. package/dist/types/new-sdk/AbstractNamespace.d.ts +33 -98
  158. package/dist/types/new-sdk/GearboxSDK.d.ts +10 -25
  159. package/dist/types/new-sdk/errors/AllSourcesFailedError.d.ts +11 -0
  160. package/dist/types/new-sdk/errors/MissingSourceError.d.ts +23 -0
  161. package/dist/types/new-sdk/errors/NoSourceServedError.d.ts +17 -0
  162. package/dist/types/new-sdk/errors/SourceChainMismatchError.d.ts +35 -0
  163. package/dist/types/new-sdk/errors/SourceUnavailableError.d.ts +22 -0
  164. package/dist/types/new-sdk/errors/assertSameChains.d.ts +11 -0
  165. package/dist/types/new-sdk/errors/everyChainFailed.d.ts +10 -0
  166. package/dist/types/new-sdk/errors/index.d.ts +8 -0
  167. package/dist/types/new-sdk/index.d.ts +17 -6
  168. package/dist/types/new-sdk/opportunities/OpportunitiesNamespace.d.ts +19 -40
  169. package/dist/types/new-sdk/opportunities/index.d.ts +2 -2
  170. package/dist/types/new-sdk/opportunities/types.d.ts +80 -26
  171. package/dist/types/new-sdk/positions/PositionsNamespace.d.ts +17 -38
  172. package/dist/types/new-sdk/positions/index.d.ts +2 -2
  173. package/dist/types/new-sdk/positions/types.d.ts +74 -24
  174. package/dist/types/new-sdk/types.d.ts +24 -77
  175. package/dist/types/new-sdk/utils/filterResponse.d.ts +16 -0
  176. package/dist/types/new-sdk/utils/history.d.ts +6 -36
  177. package/dist/types/new-sdk/utils/index.d.ts +5 -2
  178. package/dist/types/new-sdk/utils/mergeChains.d.ts +20 -0
  179. package/dist/types/new-sdk/utils/types.d.ts +11 -0
  180. package/dist/types/offchain/AbstractOffchainNamespace.d.ts +21 -28
  181. package/dist/types/offchain/GearboxAPI.d.ts +13 -9
  182. package/dist/types/offchain/errors/OffchainInvalidJsonError.d.ts +16 -0
  183. package/dist/types/offchain/errors/OffchainNotConfiguredError.d.ts +16 -0
  184. package/dist/types/offchain/errors/OffchainNotImplementedError.d.ts +15 -0
  185. package/dist/types/offchain/errors/OffchainRequestFailedError.d.ts +12 -0
  186. package/dist/types/offchain/errors/OffchainStatusError.d.ts +16 -0
  187. package/dist/types/offchain/errors/OffchainTransportError.d.ts +43 -0
  188. package/dist/types/offchain/errors/OffchainValidationError.d.ts +21 -0
  189. package/dist/types/offchain/errors/backendMessage.d.ts +9 -0
  190. package/dist/types/offchain/errors/errorCause.d.ts +22 -0
  191. package/dist/types/offchain/errors/index.d.ts +11 -0
  192. package/dist/types/offchain/errors/readResponseBody.d.ts +8 -0
  193. package/dist/types/offchain/index.d.ts +13 -2
  194. package/dist/types/offchain/opportunities/OffchainOpportunities.d.ts +9 -8
  195. package/dist/types/offchain/positions/OffchainPositions.d.ts +9 -15
  196. package/dist/types/offchain/types.d.ts +7 -88
  197. package/dist/types/sdk/accounts/credit-account-compressor/types.d.ts +4 -0
  198. package/dist/types/sdk/accounts/index.d.ts +3 -3
  199. package/dist/types/sdk/accounts/liquidations/LiquidationsService.d.ts +2 -2
  200. package/dist/types/sdk/accounts/liquidations/MultichainLiquidationsService.d.ts +15 -14
  201. package/dist/types/sdk/accounts/liquidations/index.d.ts +2 -2
  202. package/dist/types/sdk/accounts/liquidations/types.d.ts +32 -16
  203. package/dist/types/sdk/accounts/withdrawal-compressor/AbstractWithdrawalCompressorContract.d.ts +4 -4
  204. package/dist/types/sdk/accounts/withdrawal-compressor/WithdrawalCompressorV313Contract.d.ts +2 -2
  205. package/dist/types/sdk/accounts/withdrawal-compressor/index.d.ts +2 -2
  206. package/dist/types/sdk/accounts/withdrawal-compressor/types.d.ts +26 -4
  207. package/dist/types/sdk/base/MultichainConstruct.d.ts +63 -14
  208. package/dist/types/sdk/base/index.d.ts +2 -2
  209. package/dist/types/sdk/chain/chains.d.ts +10 -2
  210. package/dist/types/sdk/chain/index.d.ts +2 -2
  211. package/dist/types/sdk/index.d.ts +7 -7
  212. package/dist/types/sdk/market/MarketSuite.d.ts +1 -1
  213. package/dist/types/sdk/market/rwa/RWARegistry.d.ts +2 -1
  214. package/dist/types/sdk/opportunities/MultichainOpportunitiesService.d.ts +13 -16
  215. package/dist/types/sdk/pools/types.d.ts +4 -0
  216. package/dist/types/sdk/positions/MultichainPositionsService.d.ts +2 -12
  217. package/dist/types/sdk/positions/index.d.ts +2 -2
  218. package/dist/types/sdk/positions/types.d.ts +14 -5
  219. package/dist/types/sdk/types/index.d.ts +2 -2
  220. package/dist/types/sdk/types/multichain.d.ts +16 -36
  221. package/package.json +1 -1
@@ -1,47 +1,48 @@
1
1
  import { TxCall } from "../../../model/primitives.js";
2
- import { MultichainResult } from "../../types/multichain.js";
3
2
  import { PluginsMap } from "../../plugins/types.js";
4
3
  import "../../plugins/index.js";
5
4
  import { LiquidatableAccount, LiquidationDetails, LiquidationPosition } from "../../../model/liquidations.js";
5
+ import { DataResponse } from "../../../model/response.js";
6
6
  import "../../../model/index.js";
7
- import "../../types/index.js";
8
7
  import { MultichainConstruct } from "../../base/MultichainConstruct.js";
9
8
  import "../../base/index.js";
10
9
  import { BuildLiquidationTxProps, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationPositionsProps, LoadRWALiquidatorsProps } from "./types.js";
11
10
  //#region src/sdk/accounts/liquidations/MultichainLiquidationsService.d.ts
12
11
  /**
13
- * Cross-chain counterpart of {@link LiquidationsService}.
14
- *
15
- * Fans out over all chains configured in {@link MultichainSDK} (optionally
16
- * restricted via {@link MultichainNetworksProps.networks}). A failed chain is
17
- * logged as a warning and skipped, so one dead RPC does not empty the whole
18
- * list; its failure is reported in {@link MultichainResult.meta}. Networks that
19
- * are not configured in the SDK are reported there the same way.
12
+ * Cross-chain counterpart of {@link LiquidationsService}. These reads are live,
13
+ * so each chain is pinned to its own freshly fetched head.
20
14
  **/
21
15
  declare class MultichainLiquidationsService<const Plugins extends PluginsMap = {}> extends MultichainConstruct<Plugins> {
22
16
  /**
23
17
  * Accounts of all queried chains, see
24
18
  * {@link LiquidationsService.getLiquidatableAccounts}.
25
19
  **/
26
- getLiquidatableAccounts(props?: GetLiquidatableAccountsProps<true>): Promise<MultichainResult<LiquidatableAccount[]>>;
20
+ getLiquidatableAccounts(props?: GetLiquidatableAccountsProps<true>): Promise<DataResponse<LiquidatableAccount[]>>;
27
21
  /**
28
22
  * {@inheritDoc LiquidationsService.getLiquidationDetails}
23
+ *
24
+ * Throws when the chain cannot answer.
29
25
  **/
30
- getLiquidationDetails(props: GetLiquidationDetailsProps<true>): Promise<LiquidationDetails>;
26
+ getLiquidationDetails(props: GetLiquidationDetailsProps<true>): Promise<DataResponse<LiquidationDetails>>;
31
27
  /**
32
28
  * {@inheritDoc LiquidationsService.buildLiquidationTx}
29
+ *
30
+ * The reported block is the one the transaction was built against.
33
31
  **/
34
- buildLiquidationTx(props: BuildLiquidationTxProps<true>): Promise<TxCall>;
32
+ buildLiquidationTx(props: BuildLiquidationTxProps<true>): Promise<DataResponse<TxCall>>;
35
33
  /**
36
34
  * Liquidation positions of all queried chains, see
37
35
  * {@link LiquidationsService.getLiquidationPositions}.
38
36
  **/
39
- getLiquidationPositions(props: GetLiquidationPositionsProps<true>): Promise<MultichainResult<LiquidationPosition[]>>;
37
+ getLiquidationPositions(props: GetLiquidationPositionsProps<true>): Promise<DataResponse<LiquidationPosition[]>>;
40
38
  /**
41
39
  * Loads the liquidators of all queried chains, see
42
40
  * {@link LiquidationsService.loadRWALiquidators}.
41
+ *
42
+ * Nothing consumes the block of a cache warm-up, so this one is left on the
43
+ * loaded snapshot.
43
44
  **/
44
- loadRWALiquidators(props?: LoadRWALiquidatorsProps<true>): Promise<MultichainResult<void>>;
45
+ loadRWALiquidators(props?: LoadRWALiquidatorsProps<true>): Promise<DataResponse<void>>;
45
46
  }
46
47
  //#endregion
47
48
  export { MultichainLiquidationsService };
@@ -1,5 +1,5 @@
1
1
  import { LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS } from "./constants.js";
2
- import { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LoadRWALiquidatorsProps, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo } from "./types.js";
2
+ import { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LoadRWALiquidatorsProps, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo } from "./types.js";
3
3
  import { LiquidationsService } from "./LiquidationsService.js";
4
4
  import { MultichainLiquidationsService } from "./MultichainLiquidationsService.js";
5
- export { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LiquidationsService, LoadRWALiquidatorsProps, MultichainLiquidationsService, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo };
5
+ export { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LiquidationsService, LoadRWALiquidatorsProps, MultichainLiquidationsService, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo };
@@ -1,5 +1,5 @@
1
1
  import { iLiquidationCompressorV313Abi } from "../../../abi/ILiquidationCompressorV313.js";
2
- import { MultichainNetworkProps, MultichainNetworksProps, WithMultichain } from "../../types/multichain.js";
2
+ import { MultichainChainIdsProps, MultichainNetworkProps, WithBlock, WithMultichain } from "../../types/multichain.js";
3
3
  import { LiquidatableAccountFilter } from "../../../model/liquidations.js";
4
4
  import "../../../model/index.js";
5
5
  import "../../types/index.js";
@@ -25,18 +25,15 @@ type OnchainLiquidationCall = OnchainLiquidationData["liquidationCall"];
25
25
  **/
26
26
  type RWALiquidatorInfo = ContractFunctionReturnType<typeof iLiquidationCompressorV313Abi, "view", "getRWALiquidators">[number];
27
27
  /**
28
- * Chain-independent part of {@link GetLiquidatableAccountsProps}.
28
+ * Props for {@link LiquidationsService.getLiquidatableAccounts}: the read
29
+ * model's {@link LiquidatableAccountFilter}, whose
30
+ * {@link ChainScopedFilter.chainIds} also narrow which chains the fan-out
31
+ * queries.
29
32
  *
30
- * The filter itself lives in the read model, so the chain and the backend
31
- * cannot disagree on what a condition selects. Chain scoping is expressed as
32
- * `networks` by {@link MultichainNetworksProps} rather than as the model's
33
- * `chainIds`, which is why it is omitted here.
33
+ * {@link BlockNumberProps.blockNumber} is only on the single-chain form: a
34
+ * height is not shared across the networks of the fan-out.
34
35
  **/
35
- type GetLiquidatableAccountsPropsBase = Omit<LiquidatableAccountFilter, "chainIds">;
36
- /**
37
- * Props for {@link LiquidationsService.getLiquidatableAccounts}.
38
- **/
39
- type GetLiquidatableAccountsProps<Multichain extends boolean = false> = GetLiquidatableAccountsPropsBase & WithMultichain<Multichain, MultichainNetworksProps>;
36
+ type GetLiquidatableAccountsProps<Multichain extends boolean = false> = LiquidatableAccountFilter & WithBlock<Multichain>;
40
37
  /**
41
38
  * Chain-independent part of {@link GetLiquidationDetailsProps}.
42
39
  **/
@@ -58,9 +55,16 @@ interface GetLiquidationDetailsPropsBase {
58
55
  * applied by the compressor before computing amounts.
59
56
  **/
60
57
  ignoreReservePrices?: boolean;
58
+ /**
59
+ * Block to read at. Defaults to the latest block.
60
+ **/
61
+ blockNumber?: bigint;
61
62
  }
62
63
  /**
63
64
  * Props for {@link LiquidationsService.getLiquidationDetails}.
65
+ *
66
+ * {@link BlockNumberProps.blockNumber} is kept on the multichain form because
67
+ * the method already targets a single {@link MultichainNetworkProps.network}.
64
68
  **/
65
69
  type GetLiquidationDetailsProps<Multichain extends boolean = false> = GetLiquidationDetailsPropsBase & WithMultichain<Multichain, MultichainNetworkProps>;
66
70
  /**
@@ -81,9 +85,16 @@ interface BuildLiquidationTxPropsBase {
81
85
  * applied by the compressor before building the transaction.
82
86
  **/
83
87
  ignoreReservePrices?: boolean;
88
+ /**
89
+ * Block to read at. Defaults to the latest block.
90
+ **/
91
+ blockNumber?: bigint;
84
92
  }
85
93
  /**
86
94
  * Props for {@link LiquidationsService.buildLiquidationTx}.
95
+ *
96
+ * {@link BlockNumberProps.blockNumber} is kept on the multichain form because
97
+ * the method already targets a single {@link MultichainNetworkProps.network}.
87
98
  **/
88
99
  type BuildLiquidationTxProps<Multichain extends boolean = false> = BuildLiquidationTxPropsBase & WithMultichain<Multichain, MultichainNetworkProps>;
89
100
  /**
@@ -98,12 +109,17 @@ interface GetLiquidationPositionsPropsBase {
98
109
  }
99
110
  /**
100
111
  * Props for {@link LiquidationsService.getLiquidationPositions}.
112
+ *
113
+ * {@link BlockNumberProps.blockNumber} is only on the single-chain form: a
114
+ * height is not shared across the networks of the fan-out.
101
115
  **/
102
- type GetLiquidationPositionsProps<Multichain extends boolean = false> = GetLiquidationPositionsPropsBase & WithMultichain<Multichain, MultichainNetworksProps>;
116
+ type GetLiquidationPositionsProps<Multichain extends boolean = false> = GetLiquidationPositionsPropsBase & WithBlock<Multichain> & WithMultichain<Multichain, MultichainChainIdsProps>;
103
117
  /**
104
- * Props for {@link MultichainLiquidationsService.loadRWALiquidators}. The
105
- * per-chain {@link LiquidationsService.loadRWALiquidators} takes no props.
118
+ * Props for {@link LiquidationsService.loadRWALiquidators}.
119
+ *
120
+ * {@link BlockNumberProps.blockNumber} is only on the single-chain form: a
121
+ * height is not shared across the networks of the fan-out.
106
122
  **/
107
- type LoadRWALiquidatorsProps<Multichain extends boolean = false> = WithMultichain<Multichain, MultichainNetworksProps>;
123
+ type LoadRWALiquidatorsProps<Multichain extends boolean = false> = WithBlock<Multichain> & WithMultichain<Multichain, MultichainChainIdsProps>;
108
124
  //#endregion
109
- export { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LoadRWALiquidatorsProps, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo };
125
+ export { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LoadRWALiquidatorsProps, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo };
@@ -1,5 +1,5 @@
1
1
  import { iWithdrawalCompressorV313Abi } from "../../../abi/IWithdrawalCompressorV313.js";
2
- import { ClaimableWithdrawal, CurrentWithdrawals, GetWithdrawalRequestResultProps, IWithdrawalCompressorContract, PendingWithdrawal, RequestableWithdrawal, WithdrawableAsset, WithdrawalStatus, WithdrawalsState } from "./types.js";
2
+ import { ClaimableWithdrawal, CurrentWithdrawals, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, IWithdrawalCompressorContract, PendingWithdrawal, RequestableWithdrawal, WithdrawableAsset, WithdrawalStatus, WithdrawalsState } from "./types.js";
3
3
  import { OnchainSDK } from "../../OnchainSDK.js";
4
4
  import { BaseContract, BaseContractArgs } from "../../base/BaseContract.js";
5
5
  import "../../base/index.js";
@@ -55,7 +55,7 @@ declare abstract class AbstractWithdrawalCompressorContract<abi extends Abi> ext
55
55
  /**
56
56
  * {@inheritDoc IWithdrawalCompressorContract.loadWithdrawableAssets}
57
57
  **/
58
- loadWithdrawableAssets(force?: boolean): Promise<WithdrawableAsset[]>;
58
+ loadWithdrawableAssets(force?: boolean, blockNumber?: bigint): Promise<WithdrawableAsset[]>;
59
59
  /**
60
60
  * {@inheritDoc IWithdrawalCompressorContract.findWithdrawableAssets}
61
61
  **/
@@ -75,11 +75,11 @@ declare abstract class AbstractWithdrawalCompressorContract<abi extends Abi> ext
75
75
  /**
76
76
  * {@inheritDoc IWithdrawalCompressorContract.getCurrentWithdrawals}
77
77
  **/
78
- getCurrentWithdrawals(creditAccount: Address): Promise<CurrentWithdrawals>;
78
+ getCurrentWithdrawals(creditAccount: Address, blockNumber?: bigint): Promise<CurrentWithdrawals>;
79
79
  /**
80
80
  * {@inheritDoc IWithdrawalCompressorContract.getExternalAccountCurrentWithdrawals}
81
81
  **/
82
- getExternalAccountCurrentWithdrawals(_account: Address, ..._withdrawalTokens: Address[]): Promise<CurrentWithdrawals>;
82
+ getExternalAccountCurrentWithdrawals(_props: GetExternalAccountCurrentWithdrawalsProps): Promise<CurrentWithdrawals>;
83
83
  /**
84
84
  * {@inheritDoc IWithdrawalCompressorContract.getWithdrawalStatus}
85
85
  **/
@@ -1,4 +1,4 @@
1
- import { CurrentWithdrawals, GetWithdrawalRequestResultProps, RequestableWithdrawal, WithdrawalStatus } from "./types.js";
1
+ import { CurrentWithdrawals, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, RequestableWithdrawal, WithdrawalStatus } from "./types.js";
2
2
  import { OnchainSDK } from "../../OnchainSDK.js";
3
3
  import { AbstractWithdrawalCompressorContract } from "./AbstractWithdrawalCompressorContract.js";
4
4
  import { Address } from "viem";
@@ -635,7 +635,7 @@ declare class WithdrawalCompressorV313Contract extends AbstractWithdrawalCompres
635
635
  /**
636
636
  * {@inheritDoc IWithdrawalCompressorContract.getExternalAccountCurrentWithdrawals}
637
637
  **/
638
- getExternalAccountCurrentWithdrawals(account: Address, ...withdrawalTokens: Address[]): Promise<CurrentWithdrawals>;
638
+ getExternalAccountCurrentWithdrawals({ account, withdrawalTokens, blockNumber }: GetExternalAccountCurrentWithdrawalsProps): Promise<CurrentWithdrawals>;
639
639
  /**
640
640
  * {@inheritDoc IWithdrawalCompressorContract.getWithdrawalStatus}
641
641
  **/
@@ -1,4 +1,4 @@
1
- import { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus } from "./types.js";
1
+ import { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus } from "./types.js";
2
2
  import { AbstractWithdrawalCompressorContract, OnchainRequestableWithdrawal, iCreditAccountAbi, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal } from "./AbstractWithdrawalCompressorContract.js";
3
3
  import { WithdrawalCompressorLocation, WithdrawalCompressorVersion, getWithdrawalCompressorAddress } from "./addresses.js";
4
4
  import { createRedemptionLogger } from "./createRedemptionLogger.js";
@@ -9,4 +9,4 @@ import { RedemptionLoggerV310Contract } from "./RedemptionLoggerV310Contract.js"
9
9
  import { WithdrawalCompressorV310Contract } from "./WithdrawalCompressorV310Contract.js";
10
10
  import { WithdrawalCompressorV311Contract } from "./WithdrawalCompressorV311Contract.js";
11
11
  import { WithdrawalCompressorV313Contract } from "./WithdrawalCompressorV313Contract.js";
12
- export { AbstractWithdrawalCompressorContract, ClaimableWithdrawal, CurrentWithdrawals, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, InvalidDelayedIntentError, OnchainRequestableWithdrawal, PendingWithdrawal, RedemptionLog, RedemptionLoggerV310Contract, RequestableWithdrawal, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, createRedemptionLogger, createWithdrawalCompressor, decodeDelayedIntent, encodeDelayedIntent, getWithdrawalCompressorAddress, iCreditAccountAbi, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toWithdrawalStatus };
12
+ export { AbstractWithdrawalCompressorContract, ClaimableWithdrawal, CurrentWithdrawals, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, InvalidDelayedIntentError, OnchainRequestableWithdrawal, PendingWithdrawal, RedemptionLog, RedemptionLoggerV310Contract, RequestableWithdrawal, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, createRedemptionLogger, createWithdrawalCompressor, decodeDelayedIntent, encodeDelayedIntent, getWithdrawalCompressorAddress, iCreditAccountAbi, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toWithdrawalStatus };
@@ -297,6 +297,24 @@ interface WithdrawalsState {
297
297
  **/
298
298
  withdrawableAssets: Record<Address, WithdrawableAsset[]>;
299
299
  }
300
+ /**
301
+ * Props for {@link IWithdrawalCompressorContract.getExternalAccountCurrentWithdrawals}.
302
+ **/
303
+ interface GetExternalAccountCurrentWithdrawalsProps {
304
+ /**
305
+ * External address (non-credit-account, e.g. liquidator EOA) that owns
306
+ * the redemption receipts.
307
+ **/
308
+ account: Address;
309
+ /**
310
+ * Withdrawal phantom tokens to query. Empty or omitted returns empty lists.
311
+ **/
312
+ withdrawalTokens?: Address[];
313
+ /**
314
+ * Block to read at. Defaults to the latest block.
315
+ **/
316
+ blockNumber?: bigint;
317
+ }
300
318
  /**
301
319
  * Props for {@link IWithdrawalCompressorContract.getWithdrawalRequestResult}.
302
320
  **/
@@ -345,8 +363,9 @@ interface IWithdrawalCompressorContract extends IBaseContract {
345
363
  * lifetime) and returns them. Failed per-manager calls are logged and
346
364
  * skipped.
347
365
  * @param force - Invalidate the cache and refetch even if already loaded.
366
+ * @param blockNumber - Block to read at. Defaults to the latest block.
348
367
  **/
349
- loadWithdrawableAssets(force?: boolean): Promise<WithdrawableAsset[]>;
368
+ loadWithdrawableAssets(force?: boolean, blockNumber?: bigint): Promise<WithdrawableAsset[]>;
350
369
  /**
351
370
  * Returns all withdrawal configs of a withdrawable source token
352
371
  * (e.g. a Mellow multivault share) of the given credit manager.
@@ -375,8 +394,11 @@ interface IWithdrawalCompressorContract extends IBaseContract {
375
394
  getWithdrawalSourceToken(withdrawalPhantomToken: Address): Address | undefined;
376
395
  /**
377
396
  * Returns claimable and pending delayed withdrawals of the given credit account.
397
+ *
398
+ * @param creditAccount - Credit account to query.
399
+ * @param blockNumber - Block to read at. Defaults to the latest block.
378
400
  **/
379
- getCurrentWithdrawals(creditAccount: Address): Promise<CurrentWithdrawals>;
401
+ getCurrentWithdrawals(creditAccount: Address, blockNumber?: bigint): Promise<CurrentWithdrawals>;
380
402
  /**
381
403
  * Returns claimable and pending delayed withdrawals of an external address
382
404
  * (non-credit-account, e.g. liquidator EOA) in the given withdrawal phantom
@@ -385,7 +407,7 @@ interface IWithdrawalCompressorContract extends IBaseContract {
385
407
  * `sdk.strictContractTypes` is `true`, otherwise logs a warning and
386
408
  * returns empty lists.
387
409
  **/
388
- getExternalAccountCurrentWithdrawals(account: Address, ...withdrawalTokens: Address[]): Promise<CurrentWithdrawals>;
410
+ getExternalAccountCurrentWithdrawals(props: GetExternalAccountCurrentWithdrawalsProps): Promise<CurrentWithdrawals>;
389
411
  /**
390
412
  * Returns statuses of the given redeemer contracts.
391
413
  * Only supported on v313+ compressors; on older versions throws if
@@ -455,4 +477,4 @@ interface IRedemptionLoggerContract extends IBaseContract {
455
477
  getDelayedIntent(redeemer: Address, blockNumber?: bigint): Promise<DelayedIntent | undefined>;
456
478
  }
457
479
  //#endregion
458
- export { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus };
480
+ export { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus };
@@ -1,11 +1,32 @@
1
+ import { ChainId } from "../../model/primitives.js";
1
2
  import { NetworkType } from "../chain/chains.js";
2
- import { MultichainResult } from "../types/multichain.js";
3
3
  import { PluginsMap } from "../plugins/types.js";
4
4
  import "../plugins/index.js";
5
+ import { DataResponse } from "../../model/response.js";
6
+ import "../../model/index.js";
5
7
  import { OnchainSDK } from "../OnchainSDK.js";
6
- import "../types/index.js";
7
8
  import { MultichainSDK } from "../MultichainSDK.js";
8
9
  //#region src/sdk/base/MultichainConstruct.d.ts
10
+ /**
11
+ * Block one chain's data was read at, and is reported at.
12
+ **/
13
+ interface ChainBlock {
14
+ blockNumber: bigint;
15
+ /**
16
+ * Unix seconds of {@link blockNumber}.
17
+ **/
18
+ timestamp: bigint;
19
+ }
20
+ /**
21
+ * Where the block a request is read at comes from: the SDK's loaded snapshot,
22
+ * or a freshly fetched head.
23
+ **/
24
+ type ChainBlockSource = "state" | "latest";
25
+ /**
26
+ * {@link ChainBlockSource}, or an explicit height. Only single-chain requests
27
+ * accept a height.
28
+ **/
29
+ type ChainBlockPin = ChainBlockSource | bigint;
9
30
  /**
10
31
  * Describes a request that is sent to every queried chain.
11
32
  *
@@ -14,27 +35,50 @@ import { MultichainSDK } from "../MultichainSDK.js";
14
35
  **/
15
36
  interface ChainQueryProps<T, Plugins extends PluginsMap = {}> {
16
37
  /**
17
- * Networks to query. All configured chains when omitted.
38
+ * Chains to query. All configured chains when omitted.
18
39
  **/
19
- networks?: NetworkType[];
40
+ chainIds?: ChainId[];
20
41
  /**
21
42
  * Action description used in warnings, e.g. `"get liquidatable accounts"`.
22
43
  **/
23
44
  label: string;
24
45
  /**
25
- * Request sent to a single chain.
46
+ * @defaultValue `"state"`
47
+ **/
48
+ block?: ChainBlockSource;
49
+ /**
50
+ * Request sent to a single chain, at the resolved block of that chain.
51
+ **/
52
+ run: (sdk: OnchainSDK<Plugins>, block: ChainBlock) => Promise<T>;
53
+ }
54
+ /**
55
+ * Describes a request that is sent to exactly one chain.
56
+ *
57
+ * @typeParam T - Payload returned by the chain.
58
+ * @typeParam Plugins - Map of attached plugin types.
59
+ **/
60
+ interface ChainQueryOneProps<T, Plugins extends PluginsMap = {}> {
61
+ /**
62
+ * Chain to query, as a network label or a chain id.
26
63
  **/
27
- run: (sdk: OnchainSDK<Plugins>) => Promise<T>;
64
+ network: NetworkType | ChainId;
65
+ /**
66
+ * @defaultValue `"state"`
67
+ **/
68
+ block?: ChainBlockPin;
69
+ /**
70
+ * Request sent to the chain, at its resolved block.
71
+ **/
72
+ run: (sdk: OnchainSDK<Plugins>, block: ChainBlock) => Promise<T>;
28
73
  }
29
74
  /**
30
75
  * @internal
31
76
  * Base class for services that fan out over the chains of a
32
77
  * {@link MultichainSDK}, the cross-chain counterpart of {@link SDKConstruct}.
33
78
  *
34
- * Requests are soft-failing: a chain that rejects (including a chain that is
35
- * not configured in the SDK) is logged as a warning and contributes no payload,
36
- * while the remaining chains still return their results. Every queried chain is
37
- * reported in {@link MultichainResult.meta}.
79
+ * A fan-out soft-fails: a chain that rejects is logged as a warning and
80
+ * contributes no payload, while the remaining chains still return their rows.
81
+ * A single-chain request throws instead.
38
82
  *
39
83
  * @typeParam Plugins - Map of attached plugin types.
40
84
  **/
@@ -46,12 +90,17 @@ declare abstract class MultichainConstruct<const Plugins extends PluginsMap = {}
46
90
  * Fans out a request that returns a list, concatenating the lists of all
47
91
  * chains that responded successfully.
48
92
  **/
49
- protected queryChains<T>(props: ChainQueryProps<T[], Plugins>): Promise<MultichainResult<T[]>>;
93
+ protected queryChains<T>(props: ChainQueryProps<T[], Plugins>): Promise<DataResponse<T[]>>;
50
94
  /**
51
95
  * Fans out a request with no payload, reporting the outcome of every queried
52
- * chain in {@link MultichainResult.meta}.
96
+ * chain in `meta.chains`.
97
+ **/
98
+ protected runChains(props: ChainQueryProps<void, Plugins>): Promise<DataResponse<void>>;
99
+ /**
100
+ * Runs a request against one chain and reports the block it was read at.
101
+ * Throws when the chain is not configured, not attached, or rejects the read.
53
102
  **/
54
- protected runChains(props: ChainQueryProps<void, Plugins>): Promise<MultichainResult<void>>;
103
+ protected queryChain<T>({ network, block, run }: ChainQueryOneProps<T, Plugins>): Promise<DataResponse<T>>;
55
104
  }
56
105
  //#endregion
57
- export { ChainQueryProps, MultichainConstruct };
106
+ export { ChainBlock, ChainBlockPin, ChainBlockSource, ChainQueryOneProps, ChainQueryProps, MultichainConstruct };
@@ -5,7 +5,7 @@ import { ChainContractsRegister, ContractOrInterface } from "./ChainContractsReg
5
5
  import { Construct, ConstructOptions } from "./Construct.js";
6
6
  import { BaseContract, BaseContractArgs, ContractParseError, ContractParseErrorOptions } from "./BaseContract.js";
7
7
  import { MissingSerializedParamsError } from "./errors.js";
8
- import { ChainQueryProps, MultichainConstruct } from "./MultichainConstruct.js";
8
+ import { ChainBlock, ChainBlockPin, ChainBlockSource, ChainQueryOneProps, ChainQueryProps, MultichainConstruct } from "./MultichainConstruct.js";
9
9
  import { PlaceholderContract } from "./PlaceholderContract.js";
10
10
  import { SDKConstruct } from "./SDKConstruct.js";
11
- export { AdapterData, AssertAssignable, Asset, BaseContract, BaseContractArgs, BaseParams, BaseState, ChainContractsRegister, ChainQueryProps, ConnectedBotData, Construct, ConstructOptions, ContractOrInterface, ContractParseError, ContractParseErrorOptions, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, FormatBNOptions, GaugeData, IBaseContract, LPMonopolizedPoolMeta, MarketData, MarketFilter, MissingSerializedParamsError, MultichainConstruct, PHANTOM_TOKEN_CONTRACT_TYPES, ParsedCall, ParsedCallArgs, ParsedCallV2, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PlaceholderContract, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RWADefaultTokenMeta, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWATokenMeta, RWAUnderlyingContractType, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RateKeeperState, RelaxedBaseParams, RewardInfo, SDKConstruct, SimpleTokenMeta, TokenInfo, TokenMetaData, TokensMeta, Unarray, VotingContractStatus };
11
+ export { AdapterData, AssertAssignable, Asset, BaseContract, BaseContractArgs, BaseParams, BaseState, ChainBlock, ChainBlockPin, ChainBlockSource, ChainContractsRegister, ChainQueryOneProps, ChainQueryProps, ConnectedBotData, Construct, ConstructOptions, ContractOrInterface, ContractParseError, ContractParseErrorOptions, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, FormatBNOptions, GaugeData, IBaseContract, LPMonopolizedPoolMeta, MarketData, MarketFilter, MissingSerializedParamsError, MultichainConstruct, PHANTOM_TOKEN_CONTRACT_TYPES, ParsedCall, ParsedCallArgs, ParsedCallV2, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PlaceholderContract, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RWADefaultTokenMeta, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWATokenMeta, RWAUnderlyingContractType, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RateKeeperState, RelaxedBaseParams, RewardInfo, SDKConstruct, SimpleTokenMeta, TokenInfo, TokenMetaData, TokensMeta, Unarray, VotingContractStatus };
@@ -1,5 +1,5 @@
1
+ import { AssetType, ChainId } from "../../model/primitives.js";
1
2
  import { CuratorName } from "../../model/curators.js";
2
- import { AssetType } from "../../model/primitives.js";
3
3
  import { Address, Chain } from "viem";
4
4
  import { z } from "zod/v4";
5
5
  //#region src/sdk/chain/chains.d.ts
@@ -128,6 +128,14 @@ declare function getChain(chainIdOrNetworkType: number | bigint | NetworkType):
128
128
  * @throws If the chain ID does not correspond to a supported network.
129
129
  **/
130
130
  declare function getNetworkType(chainId: number | bigint): NetworkType;
131
+ /**
132
+ * Chain IDs of chains named as {@link NetworkType} labels or as IDs already,
133
+ * e.g. `sdk.opportunities.list({ chainIds: toChainIds(["Mainnet"]) })`.
134
+ *
135
+ * @param scope - Chains as labels, or already as IDs.
136
+ * @throws If any entry is not a supported network.
137
+ **/
138
+ declare function toChainIds(scope: NetworkType[] | ChainId[]): ChainId[];
131
139
  /**
132
140
  * Type guard that checks whether a chain ID belongs to a supported Gearbox network.
133
141
  *
@@ -195,4 +203,4 @@ declare function isSunsetPool(pool: Address, network: NetworkType): boolean;
195
203
  **/
196
204
  declare function isSunsetStrategy(creditManager: Address, collateral: Address, network: NetworkType): boolean;
197
205
  //#endregion
198
- export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork };
206
+ export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds };
@@ -1,3 +1,3 @@
1
- import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork } from "./chains.js";
1
+ import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds } from "./chains.js";
2
2
  import { detectNetwork } from "./detectNetwork.js";
3
- export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, detectNetwork, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork };
3
+ export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, detectNetwork, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds };
@@ -1,7 +1,7 @@
1
1
  import { ILogger, LogFn } from "./types/logger.js";
2
- import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork } from "./chain/chains.js";
3
- import { MultichainNetworkMeta, MultichainNetworkProps, MultichainNetworksProps, MultichainResult, WithMultichain } from "./types/multichain.js";
4
- import { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus } from "./accounts/withdrawal-compressor/types.js";
2
+ import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, SunsetStrategy, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds } from "./chain/chains.js";
3
+ import { BlockNumberProps, MultichainChainIdsProps, MultichainNetworkProps, WithBlock, WithMultichain } from "./types/multichain.js";
4
+ import { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus } from "./accounts/withdrawal-compressor/types.js";
5
5
  import { detectNetwork } from "./chain/detectNetwork.js";
6
6
  import "./chain/index.js";
7
7
  import { SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulationError, SimulationErrorType, simulateCall } from "./utils/viem/simulateCall.js";
@@ -111,7 +111,7 @@ import { ContractMethod, IPriceUpdateTx, MultiCall, RawTx } from "./types/transa
111
111
  import { AddLiquidityProps, DepositMetadata, IPoolsService, ListPoolPositionsProps, MarketType, PoolServiceCall, PoolServiceCallResult, RemoveLiquidityProps, WithdrawalMetadata } from "./pools/types.js";
112
112
  import { PoolService } from "./pools/PoolService.js";
113
113
  import "./pools/index.js";
114
- import { ListPositionsProps } from "./positions/types.js";
114
+ import { ListPositionsProps, ListPositionsPropsBase } from "./positions/types.js";
115
115
  import { MultichainPositionsService } from "./positions/MultichainPositionsService.js";
116
116
  import { PositionsService } from "./positions/PositionsService.js";
117
117
  import "./positions/index.js";
@@ -141,7 +141,7 @@ import "./types/index.js";
141
141
  import { BaseContract, BaseContractArgs, ContractParseError, ContractParseErrorOptions } from "./base/BaseContract.js";
142
142
  import { MissingSerializedParamsError } from "./base/errors.js";
143
143
  import { ChainConfig, MultichainAttachOptions, MultichainHydrateOptions, MultichainSDK, MultichainSDKOptions, MultichainSyncStateOptions } from "./MultichainSDK.js";
144
- import { ChainQueryProps, MultichainConstruct } from "./base/MultichainConstruct.js";
144
+ import { ChainBlock, ChainBlockPin, ChainBlockSource, ChainQueryOneProps, ChainQueryProps, MultichainConstruct } from "./base/MultichainConstruct.js";
145
145
  import { PlaceholderContract } from "./base/PlaceholderContract.js";
146
146
  import { SDKConstruct } from "./base/SDKConstruct.js";
147
147
  import "./base/index.js";
@@ -167,9 +167,9 @@ import { CreditAccountSlice, IntentPreviewResult } from "./accounts/intents/type
167
167
  import { primaryInstantOutput } from "./accounts/intents/operations/claim-delayed/index.js";
168
168
  import { CreditAccountOperationsService } from "./accounts/intents/index.js";
169
169
  import { LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS } from "./accounts/liquidations/constants.js";
170
- import { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LoadRWALiquidatorsProps, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo } from "./accounts/liquidations/types.js";
170
+ import { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, LoadRWALiquidatorsProps, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, RWALiquidatorInfo } from "./accounts/liquidations/types.js";
171
171
  import { LiquidationsService } from "./accounts/liquidations/LiquidationsService.js";
172
172
  import { MultichainLiquidationsService } from "./accounts/liquidations/MultichainLiquidationsService.js";
173
173
  import "./accounts/index.js";
174
174
  import { SDKOptions, attachOptionsSchema, onchainSDKOptionsSchema } from "./options.js";
175
- export { ADDRESS_0X0, ADDRESS_PROVIDER_V310, AP_ACCOUNT_FACTORY, AP_ACL, AP_BOT_LIST, AP_BYTECODE_REPOSITORY, AP_CONTRACTS_REGISTER, AP_CONTROLLER_TIMELOCK, AP_CREDIT_ACCOUNT_COMPRESSOR, AP_CREDIT_SUITE_COMPRESSOR, AP_DATA_COMPRESSOR, AP_DELEVERAGE_BOT_HV, AP_DELEVERAGE_BOT_LV, AP_DELEVERAGE_BOT_PEGGED, AP_GAUGE_COMPRESSOR, AP_GEAR_STAKING, AP_GEAR_TOKEN, AP_INFLATION_ATTACK_BLOCKER, AP_INSOLVENCY_CHECKER, AP_MARKET_COMPRESSOR, AP_MARKET_CONFIGURATOR, AP_PARTIAL_LIQUIDATION_BOT, AP_PERIPHERY_COMPRESSOR, AP_PRICE_FEED_COMPRESSOR, AP_PRICE_FEED_STORE, AP_PRICE_ORACLE, AP_REDEMPTION_LOGGER, AP_REWARDS_COMPRESSOR, AP_ROUTER, AP_RWA_COMPRESSOR, AP_TOKEN_COMPRESSOR, AP_TREASURY, AP_WETH_GATEWAY, AP_WETH_TOKEN, AP_ZAPPER_REGISTER, AP_ZERO_PRICE_FEED, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountBotsService, AccountToCheck, AdapterData, AddLiquidityProps, AddressMap, AddressProviderAddresses, AddressProviderState, AddressProviderV310Contract, type AddressProviderV3StateHuman, AddressSet, type AliasLossPolicyStateHuman, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, AssertAssignable, Asset, type AssetPriceFeedStateHuman, AssetsMap, AttachOptions, BLOCKS_PER_WEEK_BY_NETWORK, BalanceDelta, BalancerStablePriceFeedContract, BalancerWeightedPriceFeedContract, type BalancerWeightedPriceFeedStateHuman, BaseContract, BaseContractArgs, type BaseContractStateHuman, BaseParams, BasePlugin, type BasePriceFeedStateHuman, BaseState, BigIntMath, type BotListStateHuman, BotPermissions, BotStatusCall, BotsDirectResponse, type BoundedOracleStateHuman, BoundedPriceFeedContract, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, CMSlice, ChainConfig, ChainContractsRegister, ChainNotConfiguredError, ChainQueryProps, ClaimFarmRewardsProps, ClaimableWithdrawal, ClientOptions, CloseCreditAccountResult, ClosePathBalances, CompositePriceFeedContract, ConnectedBotData, ConnectedBotsCall, ConnectedBotsPerAccount, type ConstantOracleStateHuman, Construct, ConstructOptions, type ContractMethod, ContractOrInterface, ContractParseError, ContractParseErrorOptions, type CoreStateHuman, CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountData, CreditAccountDataCall, CreditAccountDataPayload, CreditAccountFilter, CreditAccountOperationResult, CreditAccountOperationsService, CreditAccountReadOptions, type CreditAccountSlice, CreditAccountTokenQuota, CreditAccountTokensSlice, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsServiceV310, CreditAccountsTarget, CreditConfiguratorState, type CreditConfiguratorStateHuman, CreditConfiguratorV310Contract, CreditFacadeState, type CreditFacadeStateHuman, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerDebtParams, type CreditManagerDebtParamsHuman, CreditManagerFilter, CreditManagerOperationResult, CreditManagerState, type CreditManagerStateHuman, CreditManagerV310Contract, CreditSuite, CreditSuiteState, type CreditSuiteStateHuman, CurrentWithdrawals, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DStokenData, DUST_THRESHOLD, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, DelegatedMulticall, DepositMetadata, EncodableCreditAccountOperation, Erc4626PriceFeedContract, EstimateRawTxGasParameters, EtherscanURLParam, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, type FetchPythPayloadsOptions, type FetchRedstonePayloadsOptions, FilterDustUSDOptions, FindBestClosePathProps, FindClaimAllRewardsProps, FindManyToOnePathProps, FindOneTokenPathProps, FindOpenStrategyPathProps, FormatBNOptions, FullyLiquidateProps, FullyLiquidateResult, GaugeContract, GaugeData, GaugeParams, type GaugeParamsHuman, type GaugeStateHuman, type GearStakingV3StateHuman, GearboxChain, type GearboxState, type GearboxStateHuman, GetApprovalAddressProps, GetConnectedBotsResponse, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetWithdrawalRequestResultProps, HydrateOptions, IAdapterContract, IAddressProviderContract, IBaseContract, ICreditAccountsService, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, type ILogger, IOnchainSDKPlugin, IOnchainSDKPluginConstructor, IPluginState, IPoolContract, IPoolsService, IPriceFeedContract, IPriceOracleContract, type IPriceUpdateTx, IRWAFactory, IRateKeeperContract, IRedemptionLoggerContract, IRouterContract, IUpdatablePriceFeedContract, IWithdrawalCompressorContract, IZapperContract, type IntentPreviewResult, type InterestRateModelStateHuman, InterestRateModelType, InvalidDelayedIntentError, IsDustOptions, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LPMonopolizedPoolMeta, type LPPriceFeedStateHuman, LatestUpdate, LinearInterestRateModelContract, type LinearInterestRateModelStateHuman, LiquidationFees, LiquidationsService, ListPoolPositionsProps, ListPositionsProps, ListStrategyPositionsProps, LoadRWALiquidatorsProps, type LogFn, type LossPolicyStateHuman, MAX_INT, MAX_UINT16, MAX_UINT256, MIN_INT96, MULTICALL_ADDRESS, MarketData, MarketFilter, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, type MarketStateHuman, MarketSuite, MarketType, MellowLRTPriceFeedContract, Methods, MidasLiquidatorContract, MissingSerializedParamsError, type MultiCall, MulticallWithFailure, MultichainAttachOptions, MultichainConstruct, MultichainHydrateOptions, MultichainLiquidationsService, type MultichainNetworkMeta, type MultichainNetworkProps, type MultichainNetworksProps, MultichainOpportunitiesService, MultichainPositionsService, type MultichainResult, MultichainSDK, MultichainSDKOptions, type MultichainState, type MultichainStateHuman, MultichainSyncStateOptions, NATIVE_ADDRESS, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OnchainSDK, OnchainSDKOptions, OpenCAProps, OpenStrategyResult, OpportunitiesService, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PERCENTAGE_DECIMALS, PERCENTAGE_FACTOR, PERCENTAGE_FACTOR_1KK, PERIPHERY_CONTRACTS, PHANTOM_TOKEN_CONTRACT_TYPES, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, PRICE_DECIMALS, PRICE_DECIMALS_POW, ParsedCall, ParsedCallArgs, ParsedCallV2, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PartialRecord, PartiallyLiquidateProps, PendingWithdrawal, PendleTWAPPTPriceFeed, PeripheryCompressorV310Contract, PeripheryContract, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PickSomeRequired, PlaceholderAdapterContract, PlaceholderAdapterContractOptions, PlaceholderContract, PluginFactoriesMap, PluginFactory, PluginState, PluginStateVersionError, PluginStatesMap, PluginsMap, PoolQuotaKeeperContract, type PoolQuotaKeeperStateHuman, PoolService, PoolServiceCall, PoolServiceCallResult, PoolState, type PoolStateHuman, PoolSuite, type PoolSuiteStateHuman, PoolV310Contract, PositionsService, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, PriceFeedAnswer, PriceFeedConstructorArgs, PriceFeedContractType, PriceFeedMapEntry, PriceFeedRef, PriceFeedRegister, PriceFeedRegisterHooks, PriceFeedRegisterOptions, type PriceFeedStateHuman, PriceFeedTreeNode, PriceFeedUsageType, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions, PriceOracleData, type PriceOracleStateHuman, PriceOracleV310Contract, PriceUpdate, PythPriceFeed, QuotaKeeperState, type QuotaParamsHuman, QuotaState, RAMP_DURATION_BY_NETWORK, RAY, RAY_DECIMALS_POW, RWACompressorCall, RWACompressorInvestorData, RWACompressorResponse, RWADefaultTokenMeta, RWAFactoryData, RWAFactoryStateHuman, RWAFactoryType, RWAInvestorData, RWALiquidatorInfo, RWAMissingOpenAccountRequirements, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWAOpenAccountRequirements, RWAOperationArgs, RWARegistry, RWAState, RWAStateHuman, RWATokenMeta, RWAUnderlyingContractType, RWAUnderlyingData, RWA_FACTORY_SECURITIZE, RWA_FACTORY_TYPES, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RampEvent, RateKeeperState, type RateKeeperStateHuman, RateKeeperType, type RawTx, RedemptionLog, RedemptionLoggerV310Contract, RedstonePriceFeedContract, type RedstonePriceFeedStateHuman, RelaxedBaseParams, RemoveLiquidityProps, RequestableWithdrawal, RetryOptions, RewardInfo, Rewards, RouterCASlice, RouterCMSlice, RouterCloseResult, RouterResult, RouterRewardsResult, RouterV310Contract, SDKConstruct, SDKOptions, SECONDS_PER_YEAR, SECURITIZE_REGISTER_VAULT_TYPES, SLIPPAGE_DECIMALS, STATE_VERSION, SUPPORTED_NETWORKS, SdkAlreadyAttachedError, SdkChainMismatchError, SdkMissingChainStateError, SdkNotAttachedError, SdkStateVersionMismatchError, SdkSyncFailedError, SecuritizeCreditAccountData, SecuritizeInvestorData, SecuritizeLiquidatorContract, SecuritizeMissingOpenAccountRequirements, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, SendRawTxParameters, SetBotProps, SetBotResult, SimpleTokenMeta, SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulateMulticallParameters, SimulateMulticallReturnType, SimulateWithPriceUpdatesError, SimulateWithPriceUpdatesErrorParams, SimulateWithPriceUpdatesErrorType, SimulateWithPriceUpdatesParameters, SimulateWithPriceUpdatesReturnType, SimulationError, SimulationErrorType, StrategyRef, SunsetStrategy, SupportedValue, SwapOperation, SyncStateOptions, type TimestampedCalldata, TokenInfo, TokenMetaData, TokensMeta, type TumblerStateHuman, TypedObjectUtils, Unarray, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, VERSION_RANGE_310, VersionRange, VotingContractStatus, WAD, WAD_DECIMALS_POW, WatchBlocksAsyncParameters, WatchBlocksAsyncReturnType, type WithMultichain, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalMetadata, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, WstETHPriceFeedContract, YearnPriceFeedContract, ZapperContract, ZapperData, type ZapperStateHuman, ZeroPriceFeedContract, ZodAddress, ZodBigInt, ZodHex, additionalBorrowApyBps, assetsMap, attachOptionsSchema, borrowApyBps, botPermissionsToString, bytes32ToString, chains, childLogger, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, decodeDelayedIntent, detectNetwork, dominantCollateral, encodeDelayedIntent, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, expectedBalanceDeltas, fetchPythPayloads, fetchRedstonePayloads, filterDust, filterDustUSD, findCuratorMarketConfigurator, fmtBinaryMask, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, healthFactorBps, hexEq, hydrateAddressProvider, iCreditAccountAbi, isDust, isLPPriceFeed, isPublicNetwork, isRWAFactory, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, json_parse, json_stringify, maxLeverage, minSeizedAmount, mustGetDominantCollateral, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, percentFmt, positionLeverage, primaryInstantOutput, rayToBps, rayToNumber, retry, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, toAddress, toBN, toBigInt, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toSignificant, toWithdrawalStatus, usdToNumber, utilizationBps, watchBlocksAsync };
175
+ export { ADDRESS_0X0, ADDRESS_PROVIDER_V310, AP_ACCOUNT_FACTORY, AP_ACL, AP_BOT_LIST, AP_BYTECODE_REPOSITORY, AP_CONTRACTS_REGISTER, AP_CONTROLLER_TIMELOCK, AP_CREDIT_ACCOUNT_COMPRESSOR, AP_CREDIT_SUITE_COMPRESSOR, AP_DATA_COMPRESSOR, AP_DELEVERAGE_BOT_HV, AP_DELEVERAGE_BOT_LV, AP_DELEVERAGE_BOT_PEGGED, AP_GAUGE_COMPRESSOR, AP_GEAR_STAKING, AP_GEAR_TOKEN, AP_INFLATION_ATTACK_BLOCKER, AP_INSOLVENCY_CHECKER, AP_MARKET_COMPRESSOR, AP_MARKET_CONFIGURATOR, AP_PARTIAL_LIQUIDATION_BOT, AP_PERIPHERY_COMPRESSOR, AP_PRICE_FEED_COMPRESSOR, AP_PRICE_FEED_STORE, AP_PRICE_ORACLE, AP_REDEMPTION_LOGGER, AP_REWARDS_COMPRESSOR, AP_ROUTER, AP_RWA_COMPRESSOR, AP_TOKEN_COMPRESSOR, AP_TREASURY, AP_WETH_GATEWAY, AP_WETH_TOKEN, AP_ZAPPER_REGISTER, AP_ZERO_PRICE_FEED, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountBotsService, AccountToCheck, AdapterData, AddLiquidityProps, AddressMap, AddressProviderAddresses, AddressProviderState, AddressProviderV310Contract, type AddressProviderV3StateHuman, AddressSet, type AliasLossPolicyStateHuman, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, AssertAssignable, Asset, type AssetPriceFeedStateHuman, AssetsMap, AttachOptions, BLOCKS_PER_WEEK_BY_NETWORK, BalanceDelta, BalancerStablePriceFeedContract, BalancerWeightedPriceFeedContract, type BalancerWeightedPriceFeedStateHuman, BaseContract, BaseContractArgs, type BaseContractStateHuman, BaseParams, BasePlugin, type BasePriceFeedStateHuman, BaseState, BigIntMath, type BlockNumberProps, type BotListStateHuman, BotPermissions, BotStatusCall, BotsDirectResponse, type BoundedOracleStateHuman, BoundedPriceFeedContract, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, CMSlice, ChainBlock, ChainBlockPin, ChainBlockSource, ChainConfig, ChainContractsRegister, ChainNotConfiguredError, ChainQueryOneProps, ChainQueryProps, ClaimFarmRewardsProps, ClaimableWithdrawal, ClientOptions, CloseCreditAccountResult, ClosePathBalances, CompositePriceFeedContract, ConnectedBotData, ConnectedBotsCall, ConnectedBotsPerAccount, type ConstantOracleStateHuman, Construct, ConstructOptions, type ContractMethod, ContractOrInterface, ContractParseError, ContractParseErrorOptions, type CoreStateHuman, CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountData, CreditAccountDataCall, CreditAccountDataPayload, CreditAccountFilter, CreditAccountOperationResult, CreditAccountOperationsService, CreditAccountReadOptions, type CreditAccountSlice, CreditAccountTokenQuota, CreditAccountTokensSlice, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsServiceV310, CreditAccountsTarget, CreditConfiguratorState, type CreditConfiguratorStateHuman, CreditConfiguratorV310Contract, CreditFacadeState, type CreditFacadeStateHuman, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerDebtParams, type CreditManagerDebtParamsHuman, CreditManagerFilter, CreditManagerOperationResult, CreditManagerState, type CreditManagerStateHuman, CreditManagerV310Contract, CreditSuite, CreditSuiteState, type CreditSuiteStateHuman, CurrentWithdrawals, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DStokenData, DUST_THRESHOLD, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, DelegatedMulticall, DepositMetadata, EncodableCreditAccountOperation, Erc4626PriceFeedContract, EstimateRawTxGasParameters, EtherscanURLParam, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, type FetchPythPayloadsOptions, type FetchRedstonePayloadsOptions, FilterDustUSDOptions, FindBestClosePathProps, FindClaimAllRewardsProps, FindManyToOnePathProps, FindOneTokenPathProps, FindOpenStrategyPathProps, FormatBNOptions, FullyLiquidateProps, FullyLiquidateResult, GaugeContract, GaugeData, GaugeParams, type GaugeParamsHuman, type GaugeStateHuman, type GearStakingV3StateHuman, GearboxChain, type GearboxState, type GearboxStateHuman, GetApprovalAddressProps, GetConnectedBotsResponse, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetExternalAccountCurrentWithdrawalsProps, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetWithdrawalRequestResultProps, HydrateOptions, IAdapterContract, IAddressProviderContract, IBaseContract, ICreditAccountsService, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, type ILogger, IOnchainSDKPlugin, IOnchainSDKPluginConstructor, IPluginState, IPoolContract, IPoolsService, IPriceFeedContract, IPriceOracleContract, type IPriceUpdateTx, IRWAFactory, IRateKeeperContract, IRedemptionLoggerContract, IRouterContract, IUpdatablePriceFeedContract, IWithdrawalCompressorContract, IZapperContract, type IntentPreviewResult, type InterestRateModelStateHuman, InterestRateModelType, InvalidDelayedIntentError, IsDustOptions, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LPMonopolizedPoolMeta, type LPPriceFeedStateHuman, LatestUpdate, LinearInterestRateModelContract, type LinearInterestRateModelStateHuman, LiquidationFees, LiquidationsService, ListPoolPositionsProps, ListPositionsProps, ListPositionsPropsBase, ListStrategyPositionsProps, LoadRWALiquidatorsProps, type LogFn, type LossPolicyStateHuman, MAX_INT, MAX_UINT16, MAX_UINT256, MIN_INT96, MULTICALL_ADDRESS, MarketData, MarketFilter, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, type MarketStateHuman, MarketSuite, MarketType, MellowLRTPriceFeedContract, Methods, MidasLiquidatorContract, MissingSerializedParamsError, type MultiCall, MulticallWithFailure, MultichainAttachOptions, type MultichainChainIdsProps, MultichainConstruct, MultichainHydrateOptions, MultichainLiquidationsService, type MultichainNetworkProps, MultichainOpportunitiesService, MultichainPositionsService, MultichainSDK, MultichainSDKOptions, type MultichainState, type MultichainStateHuman, MultichainSyncStateOptions, NATIVE_ADDRESS, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OnchainSDK, OnchainSDKOptions, OpenCAProps, OpenStrategyResult, OpportunitiesService, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PERCENTAGE_DECIMALS, PERCENTAGE_FACTOR, PERCENTAGE_FACTOR_1KK, PERIPHERY_CONTRACTS, PHANTOM_TOKEN_CONTRACT_TYPES, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, PRICE_DECIMALS, PRICE_DECIMALS_POW, ParsedCall, ParsedCallArgs, ParsedCallV2, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PartialRecord, PartiallyLiquidateProps, PendingWithdrawal, PendleTWAPPTPriceFeed, PeripheryCompressorV310Contract, PeripheryContract, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PickSomeRequired, PlaceholderAdapterContract, PlaceholderAdapterContractOptions, PlaceholderContract, PluginFactoriesMap, PluginFactory, PluginState, PluginStateVersionError, PluginStatesMap, PluginsMap, PoolQuotaKeeperContract, type PoolQuotaKeeperStateHuman, PoolService, PoolServiceCall, PoolServiceCallResult, PoolState, type PoolStateHuman, PoolSuite, type PoolSuiteStateHuman, PoolV310Contract, PositionsService, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, PriceFeedAnswer, PriceFeedConstructorArgs, PriceFeedContractType, PriceFeedMapEntry, PriceFeedRef, PriceFeedRegister, PriceFeedRegisterHooks, PriceFeedRegisterOptions, type PriceFeedStateHuman, PriceFeedTreeNode, PriceFeedUsageType, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions, PriceOracleData, type PriceOracleStateHuman, PriceOracleV310Contract, PriceUpdate, PythPriceFeed, QuotaKeeperState, type QuotaParamsHuman, QuotaState, RAMP_DURATION_BY_NETWORK, RAY, RAY_DECIMALS_POW, RWACompressorCall, RWACompressorInvestorData, RWACompressorResponse, RWADefaultTokenMeta, RWAFactoryData, RWAFactoryStateHuman, RWAFactoryType, RWAInvestorData, RWALiquidatorInfo, RWAMissingOpenAccountRequirements, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWAOpenAccountRequirements, RWAOperationArgs, RWARegistry, RWAState, RWAStateHuman, RWATokenMeta, RWAUnderlyingContractType, RWAUnderlyingData, RWA_FACTORY_SECURITIZE, RWA_FACTORY_TYPES, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RampEvent, RateKeeperState, type RateKeeperStateHuman, RateKeeperType, type RawTx, RedemptionLog, RedemptionLoggerV310Contract, RedstonePriceFeedContract, type RedstonePriceFeedStateHuman, RelaxedBaseParams, RemoveLiquidityProps, RequestableWithdrawal, RetryOptions, RewardInfo, Rewards, RouterCASlice, RouterCMSlice, RouterCloseResult, RouterResult, RouterRewardsResult, RouterV310Contract, SDKConstruct, SDKOptions, SECONDS_PER_YEAR, SECURITIZE_REGISTER_VAULT_TYPES, SLIPPAGE_DECIMALS, STATE_VERSION, SUPPORTED_NETWORKS, SdkAlreadyAttachedError, SdkChainMismatchError, SdkMissingChainStateError, SdkNotAttachedError, SdkStateVersionMismatchError, SdkSyncFailedError, SecuritizeCreditAccountData, SecuritizeInvestorData, SecuritizeLiquidatorContract, SecuritizeMissingOpenAccountRequirements, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, SendRawTxParameters, SetBotProps, SetBotResult, SimpleTokenMeta, SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulateMulticallParameters, SimulateMulticallReturnType, SimulateWithPriceUpdatesError, SimulateWithPriceUpdatesErrorParams, SimulateWithPriceUpdatesErrorType, SimulateWithPriceUpdatesParameters, SimulateWithPriceUpdatesReturnType, SimulationError, SimulationErrorType, StrategyRef, SunsetStrategy, SupportedValue, SwapOperation, SyncStateOptions, type TimestampedCalldata, TokenInfo, TokenMetaData, TokensMeta, type TumblerStateHuman, TypedObjectUtils, Unarray, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, VERSION_RANGE_310, VersionRange, VotingContractStatus, WAD, WAD_DECIMALS_POW, WatchBlocksAsyncParameters, WatchBlocksAsyncReturnType, type WithBlock, type WithMultichain, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalMetadata, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, WstETHPriceFeedContract, YearnPriceFeedContract, ZapperContract, ZapperData, type ZapperStateHuman, ZeroPriceFeedContract, ZodAddress, ZodBigInt, ZodHex, additionalBorrowApyBps, assetsMap, attachOptionsSchema, borrowApyBps, botPermissionsToString, bytes32ToString, chains, childLogger, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, decodeDelayedIntent, detectNetwork, dominantCollateral, encodeDelayedIntent, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, expectedBalanceDeltas, fetchPythPayloads, fetchRedstonePayloads, filterDust, filterDustUSD, findCuratorMarketConfigurator, fmtBinaryMask, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, healthFactorBps, hexEq, hydrateAddressProvider, iCreditAccountAbi, isDust, isLPPriceFeed, isPublicNetwork, isRWAFactory, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, json_parse, json_stringify, maxLeverage, minSeizedAmount, mustGetDominantCollateral, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, percentFmt, positionLeverage, primaryInstantOutput, rayToBps, rayToNumber, retry, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, toAddress, toBN, toBigInt, toChainIds, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toSignificant, toWithdrawalStatus, usdToNumber, utilizationBps, watchBlocksAsync };
@@ -1,5 +1,5 @@
1
- import { Curator } from "../../model/curators.js";
2
1
  import { Token } from "../../model/primitives.js";
2
+ import { Curator } from "../../model/curators.js";
3
3
  import { MarketData } from "../base/types.js";
4
4
  import { Opportunity, OpportunityFilter, PoolOpportunity, PoolOpportunityDetail, PriceFeedSummary, QuotaAsset, StrategyOpportunityDetail } from "../../model/opportunities.js";
5
5
  import "../../model/index.js";
@@ -35,8 +35,9 @@ declare class RWARegistry extends SDKConstruct {
35
35
  * @param investor - Investor EOA address.
36
36
  * @param factories_ - Optional subset of factory addresses to query.
37
37
  * When omitted, all loaded factories are used.
38
+ * @param blockNumber - Block to read at, defaults to the latest block.
38
39
  */
39
- getInvestorData(investor: Address, factories_?: Address[]): Promise<RWAInvestorData[]>;
40
+ getInvestorData(investor: Address, factories_?: Address[], blockNumber?: bigint): Promise<RWAInvestorData[]>;
40
41
  /** All loaded RWA factory instances. */
41
42
  get factories(): SecuritizeRWAFactory[];
42
43
  /** Raw RWA compressor response, or `undefined` before attach/hydrate. */