@gearbox-protocol/sdk 16.6.0-next.8 → 16.6.0-next.9

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 (115) hide show
  1. package/dist/cjs/onchain/OnchainSDK.js +3 -3
  2. package/dist/cjs/onchain/index.js +49 -38
  3. package/dist/cjs/onchain/market/index.js +49 -38
  4. package/dist/cjs/onchain/market/oracle/PriceOracleBaseContract.js +3 -3
  5. package/dist/cjs/onchain/market/pricefeeds/AbstractPriceFeed.js +0 -5
  6. package/dist/cjs/onchain/market/pricefeeds/PriceFeedRegistry.js +127 -0
  7. package/dist/cjs/onchain/market/pricefeeds/{BalancerStablePriceFeed.js → feeds/BalancerStablePriceFeed.js} +4 -4
  8. package/dist/cjs/onchain/market/pricefeeds/{BalancerWeightedPriceFeed.js → feeds/BalancerWeightedPriceFeed.js} +4 -4
  9. package/dist/cjs/onchain/market/pricefeeds/{BoundedPriceFeed.js → feeds/BoundedPriceFeed.js} +4 -4
  10. package/dist/cjs/onchain/market/pricefeeds/{CompositePriceFeed.js → feeds/CompositePriceFeed.js} +4 -4
  11. package/dist/cjs/onchain/market/pricefeeds/{ConstantPriceFeed.js → feeds/ConstantPriceFeed.js} +3 -3
  12. package/dist/cjs/onchain/market/pricefeeds/{CurveCryptoPriceFeed.js → feeds/CurveCryptoPriceFeed.js} +4 -4
  13. package/dist/cjs/onchain/market/pricefeeds/{CurveStablePriceFeed.js → feeds/CurveStablePriceFeed.js} +4 -4
  14. package/dist/cjs/onchain/market/pricefeeds/{CurveUSDPriceFeed.js → feeds/CurveUSDPriceFeed.js} +4 -4
  15. package/dist/cjs/onchain/market/pricefeeds/{Erc4626PriceFeed.js → feeds/Erc4626PriceFeed.js} +4 -4
  16. package/dist/cjs/onchain/market/pricefeeds/{ExternalPriceFeed.js → feeds/ExternalPriceFeed.js} +4 -4
  17. package/dist/cjs/onchain/market/pricefeeds/{MellowLRTPriceFeed.js → feeds/MellowLRTPriceFeed.js} +4 -4
  18. package/dist/cjs/onchain/market/pricefeeds/{PendleTWAPPTPriceFeed.js → feeds/PendleTWAPPTPriceFeed.js} +4 -4
  19. package/dist/cjs/onchain/market/pricefeeds/{PythPriceFeed.js → feeds/PythPriceFeed.js} +3 -3
  20. package/dist/cjs/onchain/market/pricefeeds/{RedstonePriceFeed.js → feeds/RedstonePriceFeed.js} +6 -6
  21. package/dist/cjs/onchain/market/pricefeeds/{WstETHPriceFeed.js → feeds/WstETHPriceFeed.js} +4 -4
  22. package/dist/cjs/onchain/market/pricefeeds/{YearnPriceFeed.js → feeds/YearnPriceFeed.js} +4 -4
  23. package/dist/cjs/onchain/market/pricefeeds/{ZeroPriceFeed.js → feeds/ZeroPriceFeed.js} +4 -4
  24. package/dist/cjs/onchain/market/pricefeeds/feeds/index.js +35 -0
  25. package/dist/cjs/onchain/market/pricefeeds/index.js +51 -39
  26. package/dist/cjs/onchain/market/pricefeeds/updates/UpdatablePriceFeedRegistry.js +189 -0
  27. package/dist/cjs/onchain/market/pricefeeds/{getRawPriceUpdates.js → updates/getRawPriceUpdates.js} +2 -2
  28. package/dist/cjs/onchain/market/pricefeeds/updates/index.js +8 -0
  29. package/dist/cjs/onchain/market/pricefeeds/{isUpdatablePriceFeed.js → updates/isUpdatablePriceFeed.js} +1 -1
  30. package/dist/cjs/onchain/market/pricefeeds/updates/updatableDependencies.js +14 -0
  31. package/dist/cjs/permissionless/utils/price-update/get-price-update-tx.js +2 -2
  32. package/dist/cjs/permissionless/utils/price-update/get-updatable-feeds.js +2 -2
  33. package/dist/esm/onchain/OnchainSDK.js +3 -3
  34. package/dist/esm/onchain/index.js +25 -20
  35. package/dist/esm/onchain/market/index.js +25 -20
  36. package/dist/esm/onchain/market/oracle/PriceOracleBaseContract.js +1 -1
  37. package/dist/esm/onchain/market/pricefeeds/AbstractPriceFeed.js +0 -5
  38. package/dist/esm/onchain/market/pricefeeds/PriceFeedRegistry.js +126 -0
  39. package/dist/esm/onchain/market/pricefeeds/{BalancerStablePriceFeed.js → feeds/BalancerStablePriceFeed.js} +4 -4
  40. package/dist/esm/onchain/market/pricefeeds/{BalancerWeightedPriceFeed.js → feeds/BalancerWeightedPriceFeed.js} +4 -4
  41. package/dist/esm/onchain/market/pricefeeds/{BoundedPriceFeed.js → feeds/BoundedPriceFeed.js} +4 -4
  42. package/dist/esm/onchain/market/pricefeeds/{CompositePriceFeed.js → feeds/CompositePriceFeed.js} +4 -4
  43. package/dist/esm/onchain/market/pricefeeds/{ConstantPriceFeed.js → feeds/ConstantPriceFeed.js} +3 -3
  44. package/dist/esm/onchain/market/pricefeeds/{CurveCryptoPriceFeed.js → feeds/CurveCryptoPriceFeed.js} +4 -4
  45. package/dist/esm/onchain/market/pricefeeds/{CurveStablePriceFeed.js → feeds/CurveStablePriceFeed.js} +4 -4
  46. package/dist/esm/onchain/market/pricefeeds/{CurveUSDPriceFeed.js → feeds/CurveUSDPriceFeed.js} +4 -4
  47. package/dist/esm/onchain/market/pricefeeds/{Erc4626PriceFeed.js → feeds/Erc4626PriceFeed.js} +4 -4
  48. package/dist/esm/onchain/market/pricefeeds/{ExternalPriceFeed.js → feeds/ExternalPriceFeed.js} +4 -4
  49. package/dist/esm/onchain/market/pricefeeds/{MellowLRTPriceFeed.js → feeds/MellowLRTPriceFeed.js} +4 -4
  50. package/dist/esm/onchain/market/pricefeeds/{PendleTWAPPTPriceFeed.js → feeds/PendleTWAPPTPriceFeed.js} +4 -4
  51. package/dist/esm/onchain/market/pricefeeds/{PythPriceFeed.js → feeds/PythPriceFeed.js} +3 -3
  52. package/dist/esm/onchain/market/pricefeeds/{RedstonePriceFeed.js → feeds/RedstonePriceFeed.js} +6 -6
  53. package/dist/esm/onchain/market/pricefeeds/{WstETHPriceFeed.js → feeds/WstETHPriceFeed.js} +4 -4
  54. package/dist/esm/onchain/market/pricefeeds/{YearnPriceFeed.js → feeds/YearnPriceFeed.js} +4 -4
  55. package/dist/esm/onchain/market/pricefeeds/{ZeroPriceFeed.js → feeds/ZeroPriceFeed.js} +4 -4
  56. package/dist/esm/onchain/market/pricefeeds/feeds/index.js +18 -0
  57. package/dist/esm/onchain/market/pricefeeds/index.js +27 -21
  58. package/dist/esm/onchain/market/pricefeeds/updates/UpdatablePriceFeedRegistry.js +188 -0
  59. package/dist/esm/onchain/market/pricefeeds/{getRawPriceUpdates.js → updates/getRawPriceUpdates.js} +2 -2
  60. package/dist/esm/onchain/market/pricefeeds/updates/index.js +5 -1
  61. package/dist/esm/onchain/market/pricefeeds/{isUpdatablePriceFeed.js → updates/isUpdatablePriceFeed.js} +1 -1
  62. package/dist/esm/onchain/market/pricefeeds/updates/updatableDependencies.js +13 -0
  63. package/dist/esm/permissionless/utils/price-update/get-price-update-tx.js +1 -1
  64. package/dist/esm/permissionless/utils/price-update/get-updatable-feeds.js +1 -1
  65. package/dist/types/onchain/OnchainSDK.d.ts +2 -2
  66. package/dist/types/onchain/index.d.ts +27 -22
  67. package/dist/types/onchain/market/index.d.ts +27 -22
  68. package/dist/types/onchain/market/oracle/PriceOracleBaseContract.d.ts +2 -1
  69. package/dist/types/onchain/market/oracle/types.d.ts +2 -1
  70. package/dist/types/onchain/market/pricefeeds/AbstractPriceFeed.d.ts +1 -2
  71. package/dist/types/onchain/market/pricefeeds/PriceFeedRegistry.d.ts +60 -0
  72. package/dist/types/onchain/market/pricefeeds/feeds/BalancerStablePriceFeed.d.ts +12 -0
  73. package/dist/types/onchain/market/pricefeeds/{BalancerWeightedPriceFeed.d.ts → feeds/BalancerWeightedPriceFeed.d.ts} +7 -7
  74. package/dist/types/onchain/market/pricefeeds/feeds/BoundedPriceFeed.d.ts +15 -0
  75. package/dist/types/onchain/market/pricefeeds/{CompositePriceFeed.d.ts → feeds/CompositePriceFeed.d.ts} +6 -6
  76. package/dist/types/onchain/market/pricefeeds/{ConstantPriceFeed.d.ts → feeds/ConstantPriceFeed.d.ts} +6 -6
  77. package/dist/types/onchain/market/pricefeeds/feeds/CurveCryptoPriceFeed.d.ts +12 -0
  78. package/dist/types/onchain/market/pricefeeds/feeds/CurveStablePriceFeed.d.ts +12 -0
  79. package/dist/types/onchain/market/pricefeeds/feeds/CurveUSDPriceFeed.d.ts +12 -0
  80. package/dist/types/onchain/market/pricefeeds/feeds/Erc4626PriceFeed.d.ts +12 -0
  81. package/dist/types/onchain/market/pricefeeds/feeds/ExternalPriceFeed.d.ts +11 -0
  82. package/dist/types/onchain/market/pricefeeds/feeds/MellowLRTPriceFeed.d.ts +12 -0
  83. package/dist/types/onchain/market/pricefeeds/{PendleTWAPPTPriceFeed.d.ts → feeds/PendleTWAPPTPriceFeed.d.ts} +3 -3
  84. package/dist/types/onchain/market/pricefeeds/{PythPriceFeed.d.ts → feeds/PythPriceFeed.d.ts} +3 -3
  85. package/dist/types/onchain/market/pricefeeds/{RedstonePriceFeed.d.ts → feeds/RedstonePriceFeed.d.ts} +9 -9
  86. package/dist/types/onchain/market/pricefeeds/feeds/WstETHPriceFeed.d.ts +12 -0
  87. package/dist/types/onchain/market/pricefeeds/feeds/YearnPriceFeed.d.ts +12 -0
  88. package/dist/types/onchain/market/pricefeeds/feeds/ZeroPriceFeed.d.ts +11 -0
  89. package/dist/types/onchain/market/pricefeeds/feeds/index.d.ts +18 -0
  90. package/dist/types/onchain/market/pricefeeds/index.d.ts +28 -22
  91. package/dist/types/onchain/market/pricefeeds/types.d.ts +1 -31
  92. package/dist/types/onchain/market/pricefeeds/updates/RedstoneUpdater.d.ts +1 -1
  93. package/dist/types/onchain/market/pricefeeds/updates/UpdatablePriceFeedRegistry.d.ts +106 -0
  94. package/dist/types/onchain/market/pricefeeds/updates/getRawPriceUpdates.d.ts +6 -0
  95. package/dist/types/onchain/market/pricefeeds/updates/index.d.ts +7 -3
  96. package/dist/types/onchain/market/pricefeeds/updates/isUpdatablePriceFeed.d.ts +6 -0
  97. package/dist/types/onchain/market/pricefeeds/updates/types.d.ts +56 -2
  98. package/dist/types/onchain/market/pricefeeds/updates/updatableDependencies.d.ts +10 -0
  99. package/package.json +1 -1
  100. package/dist/cjs/onchain/market/pricefeeds/PriceFeedsRegister.js +0 -301
  101. package/dist/esm/onchain/market/pricefeeds/PriceFeedsRegister.js +0 -300
  102. package/dist/types/onchain/market/pricefeeds/BalancerStablePriceFeed.d.ts +0 -12
  103. package/dist/types/onchain/market/pricefeeds/BoundedPriceFeed.d.ts +0 -15
  104. package/dist/types/onchain/market/pricefeeds/CurveCryptoPriceFeed.d.ts +0 -12
  105. package/dist/types/onchain/market/pricefeeds/CurveStablePriceFeed.d.ts +0 -12
  106. package/dist/types/onchain/market/pricefeeds/CurveUSDPriceFeed.d.ts +0 -12
  107. package/dist/types/onchain/market/pricefeeds/Erc4626PriceFeed.d.ts +0 -12
  108. package/dist/types/onchain/market/pricefeeds/ExternalPriceFeed.d.ts +0 -11
  109. package/dist/types/onchain/market/pricefeeds/MellowLRTPriceFeed.d.ts +0 -12
  110. package/dist/types/onchain/market/pricefeeds/PriceFeedsRegister.d.ts +0 -180
  111. package/dist/types/onchain/market/pricefeeds/WstETHPriceFeed.d.ts +0 -12
  112. package/dist/types/onchain/market/pricefeeds/YearnPriceFeed.d.ts +0 -12
  113. package/dist/types/onchain/market/pricefeeds/ZeroPriceFeed.d.ts +0 -11
  114. package/dist/types/onchain/market/pricefeeds/getRawPriceUpdates.d.ts +0 -5
  115. package/dist/types/onchain/market/pricefeeds/isUpdatablePriceFeed.d.ts +0 -5
@@ -0,0 +1,14 @@
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
+ const require_onchain_market_pricefeeds_updates_isUpdatablePriceFeed = require("./isUpdatablePriceFeed.js");
3
+ //#region src/onchain/market/pricefeeds/updates/updatableDependencies.ts
4
+ /**
5
+ * Collects updatable feeds in this feed's dependency tree, including this
6
+ * feed itself when it is updatable.
7
+ **/
8
+ function updatableDependencies(feed) {
9
+ if (!feed.loaded) return [feed];
10
+ const underlying = feed.underlyingPriceFeeds.flatMap((ref) => updatableDependencies(ref.priceFeed));
11
+ return require_onchain_market_pricefeeds_updates_isUpdatablePriceFeed.isUpdatablePriceFeed(feed) ? [feed, ...underlying] : underlying;
12
+ }
13
+ //#endregion
14
+ exports.updatableDependencies = updatableDependencies;
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_onchain_utils_createRawTx = require("../../../onchain/utils/createRawTx.js");
3
- const require_onchain_market_pricefeeds_getRawPriceUpdates = require("../../../onchain/market/pricefeeds/getRawPriceUpdates.js");
3
+ const require_onchain_market_pricefeeds_updates_getRawPriceUpdates = require("../../../onchain/market/pricefeeds/updates/getRawPriceUpdates.js");
4
4
  const require_onchain_OnchainSDK = require("../../../onchain/OnchainSDK.js");
5
5
  require("../../../onchain/index.js");
6
6
  require("../../deployment/addresses.js");
@@ -31,7 +31,7 @@ async function getPriceUpdateTx({ client, priceFeeds, useMulticall3 = false, gas
31
31
  args: [multicallCalls]
32
32
  });
33
33
  }
34
- const priceUpdates = require_onchain_market_pricefeeds_getRawPriceUpdates.getRawPriceUpdates(updateTxs);
34
+ const priceUpdates = require_onchain_market_pricefeeds_updates_getRawPriceUpdates.getRawPriceUpdates(updateTxs);
35
35
  if (priceUpdates.length === 0) return;
36
36
  return pfStore.updatePrices(priceUpdates);
37
37
  }
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_onchain_utils_bytes32ToString = require("../../../onchain/utils/bytes32ToString.js");
3
3
  const require_abi_compressors_priceFeedCompressor = require("../../../abi/compressors/priceFeedCompressor.js");
4
- const require_onchain_market_pricefeeds_RedstonePriceFeed = require("../../../onchain/market/pricefeeds/RedstonePriceFeed.js");
4
+ const require_onchain_market_pricefeeds_feeds_RedstonePriceFeed = require("../../../onchain/market/pricefeeds/feeds/RedstonePriceFeed.js");
5
5
  require("../../../onchain/index.js");
6
6
  let viem = require("viem");
7
7
  //#region src/permissionless/utils/price-update/get-updatable-feeds.ts
@@ -11,7 +11,7 @@ async function getUpdatablePriceFeeds(args) {
11
11
  address: pfCompressor,
12
12
  abi: require_abi_compressors_priceFeedCompressor.priceFeedCompressorAbi,
13
13
  client
14
- }).read.loadPriceFeedTree([priceFeeds])).filter((data) => require_onchain_utils_bytes32ToString.bytes32ToString(data.baseParams.contractType) === "PRICE_FEED::REDSTONE").map((data) => new require_onchain_market_pricefeeds_RedstonePriceFeed.RedstonePriceFeedContract(sdk, data));
14
+ }).read.loadPriceFeedTree([priceFeeds])).filter((data) => require_onchain_utils_bytes32ToString.bytes32ToString(data.baseParams.contractType) === "PRICE_FEED::REDSTONE").map((data) => new require_onchain_market_pricefeeds_feeds_RedstonePriceFeed.RedstonePriceFeedContract(sdk, data));
15
15
  }
16
16
  //#endregion
17
17
  exports.getUpdatablePriceFeeds = getUpdatablePriceFeeds;
@@ -13,7 +13,7 @@ import { ChainContractsRegister } from "./base/ChainContractsRegister.js";
13
13
  import "./base/index.js";
14
14
  import { executeDelegatedMulticalls } from "./utils/viem/executeDelegatedMulticalls.js";
15
15
  import "./utils/viem/index.js";
16
- import { PriceFeedRegister } from "./market/pricefeeds/PriceFeedsRegister.js";
16
+ import { UpdatablePriceFeedRegistry } from "./market/pricefeeds/updates/UpdatablePriceFeedRegistry.js";
17
17
  import "./market/pricefeeds/index.js";
18
18
  import { MarketRegister } from "./market/MarketRegister.js";
19
19
  import { RWARegistry } from "./market/rwa/RWARegistry.js";
@@ -167,7 +167,7 @@ var OnchainSDK = class extends ChainContractsRegister {
167
167
  this.#currentBlock = block.number;
168
168
  this.#timestamp = block.timestamp;
169
169
  if (blockNumber && !redstone?.historicTimestamp && time - Number(block.timestamp) * 1e3 > 6e4) this.logger?.warn("attaching to fixed block number, but redstone historicTimestamp is not set. price updates might fail");
170
- this.#priceFeeds = new PriceFeedRegister(this, { redstone });
170
+ this.#priceFeeds = new UpdatablePriceFeedRegistry(this, { redstone });
171
171
  this.logger?.debug(`attach block number ${this.currentBlock} timestamp ${this.timestamp}`);
172
172
  this.#addressProvider = await createAddressProvider(this, addressProvider);
173
173
  this.logger?.debug(`address provider version: ${this.#addressProvider.version}`);
@@ -262,7 +262,7 @@ var OnchainSDK = class extends ChainContractsRegister {
262
262
  this.logger?.info({ networkType: this.networkType }, "hydrating sdk state");
263
263
  this.#currentBlock = state.currentBlock;
264
264
  this.#timestamp = state.timestamp;
265
- this.#priceFeeds = new PriceFeedRegister(this, { redstone });
265
+ this.#priceFeeds = new UpdatablePriceFeedRegistry(this, { redstone });
266
266
  this.#addressProvider = hydrateAddressProvider(this, state.addressProvider);
267
267
  this.logger?.debug(`address provider version: ${this.#addressProvider.version}`);
268
268
  this.#marketRegister = new MarketRegister(this, ignoreMarkets);
@@ -149,29 +149,34 @@ import { estimateRawTxGas, sendRawTx } from "./utils/viem/sendRawTx.js";
149
149
  import { watchBlocksAsync } from "./utils/viem/watchBlocksAsync.js";
150
150
  import "./utils/viem/index.js";
151
151
  import { collateralPriceInUnderlying } from "./market/oracle/collateralPriceInUnderlying.js";
152
- import { isUpdatablePriceFeed } from "./market/pricefeeds/isUpdatablePriceFeed.js";
153
152
  import { PriceFeedRef } from "./market/pricefeeds/PriceFeedRef.js";
154
153
  import { AbstractPriceFeedContract, PartialPriceFeedInitError } from "./market/pricefeeds/AbstractPriceFeed.js";
155
154
  import { AbstractLPPriceFeedContract, isLPPriceFeed } from "./market/pricefeeds/AbstractLPPriceFeed.js";
156
- import { BalancerStablePriceFeedContract } from "./market/pricefeeds/BalancerStablePriceFeed.js";
157
- import { BalancerWeightedPriceFeedContract } from "./market/pricefeeds/BalancerWeightedPriceFeed.js";
158
- import { BoundedPriceFeedContract } from "./market/pricefeeds/BoundedPriceFeed.js";
159
- import { CompositePriceFeedContract } from "./market/pricefeeds/CompositePriceFeed.js";
160
- import { CurveCryptoPriceFeedContract } from "./market/pricefeeds/CurveCryptoPriceFeed.js";
161
- import { CurveStablePriceFeedContract } from "./market/pricefeeds/CurveStablePriceFeed.js";
162
- import { CurveUSDPriceFeedContract } from "./market/pricefeeds/CurveUSDPriceFeed.js";
163
- import { Erc4626PriceFeedContract } from "./market/pricefeeds/Erc4626PriceFeed.js";
164
- import { ExternalPriceFeedContract } from "./market/pricefeeds/ExternalPriceFeed.js";
165
- import { getRawPriceUpdates } from "./market/pricefeeds/getRawPriceUpdates.js";
166
- import { MellowLRTPriceFeedContract } from "./market/pricefeeds/MellowLRTPriceFeed.js";
167
- import { PendleTWAPPTPriceFeed } from "./market/pricefeeds/PendleTWAPPTPriceFeed.js";
168
- import { PythPriceFeed } from "./market/pricefeeds/PythPriceFeed.js";
169
- import { RedstonePriceFeedContract } from "./market/pricefeeds/RedstonePriceFeed.js";
155
+ import { BalancerStablePriceFeedContract } from "./market/pricefeeds/feeds/BalancerStablePriceFeed.js";
156
+ import { BalancerWeightedPriceFeedContract } from "./market/pricefeeds/feeds/BalancerWeightedPriceFeed.js";
157
+ import { BoundedPriceFeedContract } from "./market/pricefeeds/feeds/BoundedPriceFeed.js";
158
+ import { CompositePriceFeedContract } from "./market/pricefeeds/feeds/CompositePriceFeed.js";
159
+ import { ConstantPriceFeedContract } from "./market/pricefeeds/feeds/ConstantPriceFeed.js";
160
+ import { CurveCryptoPriceFeedContract } from "./market/pricefeeds/feeds/CurveCryptoPriceFeed.js";
161
+ import { CurveStablePriceFeedContract } from "./market/pricefeeds/feeds/CurveStablePriceFeed.js";
162
+ import { CurveUSDPriceFeedContract } from "./market/pricefeeds/feeds/CurveUSDPriceFeed.js";
163
+ import { Erc4626PriceFeedContract } from "./market/pricefeeds/feeds/Erc4626PriceFeed.js";
164
+ import { ExternalPriceFeedContract } from "./market/pricefeeds/feeds/ExternalPriceFeed.js";
165
+ import { MellowLRTPriceFeedContract } from "./market/pricefeeds/feeds/MellowLRTPriceFeed.js";
166
+ import { PendleTWAPPTPriceFeed } from "./market/pricefeeds/feeds/PendleTWAPPTPriceFeed.js";
167
+ import { PythPriceFeed } from "./market/pricefeeds/feeds/PythPriceFeed.js";
168
+ import { RedstonePriceFeedContract } from "./market/pricefeeds/feeds/RedstonePriceFeed.js";
169
+ import { WstETHPriceFeedContract } from "./market/pricefeeds/feeds/WstETHPriceFeed.js";
170
+ import { YearnPriceFeedContract } from "./market/pricefeeds/feeds/YearnPriceFeed.js";
171
+ import { ZeroPriceFeedContract } from "./market/pricefeeds/feeds/ZeroPriceFeed.js";
172
+ import { PriceFeedRegistry } from "./market/pricefeeds/PriceFeedRegistry.js";
170
173
  import { fetchRedstonePayloads } from "./market/pricefeeds/updates/fetchRedstonePayloads.js";
171
- import { WstETHPriceFeedContract } from "./market/pricefeeds/WstETHPriceFeed.js";
172
- import { YearnPriceFeedContract } from "./market/pricefeeds/YearnPriceFeed.js";
173
- import { ZeroPriceFeedContract } from "./market/pricefeeds/ZeroPriceFeed.js";
174
- import { PriceFeedRegister } from "./market/pricefeeds/PriceFeedsRegister.js";
174
+ import { getRawPriceUpdates } from "./market/pricefeeds/updates/getRawPriceUpdates.js";
175
+ import { isUpdatablePriceFeed } from "./market/pricefeeds/updates/isUpdatablePriceFeed.js";
176
+ import { PriceUpdatesCache } from "./market/pricefeeds/updates/PriceUpdatesCache.js";
177
+ import { RedstoneOptions, RedstoneUpdater } from "./market/pricefeeds/updates/RedstoneUpdater.js";
178
+ import { updatableDependencies } from "./market/pricefeeds/updates/updatableDependencies.js";
179
+ import { UpdatablePriceFeedRegistry } from "./market/pricefeeds/updates/UpdatablePriceFeedRegistry.js";
175
180
  import { PriceOracleV310Contract } from "./market/oracle/PriceOracleV310Contract.js";
176
181
  import { createPriceOracle } from "./market/oracle/createPriceOracle.js";
177
182
  import { GaugeContract } from "./market/pool/GaugeContract.js";
@@ -301,4 +306,4 @@ import { replayMulticall } from "./preview/preview/replayMulticall.js";
301
306
  import { previewOperation } from "./preview/preview/previewOperation.js";
302
307
  import "./preview/index.js";
303
308
  import "./types/index.js";
304
- 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_TOKEN_COMPRESSOR, AP_TREASURY, AP_WETH_GATEWAY, AP_WETH_TOKEN, AP_ZAPPER_REGISTER, AP_ZERO_PRICE_FEED, AbstractAdapterContract, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountBotsService, AccountMigratorAdapterContract, AdapterType, AddressMap, AddressProviderV310Contract, AddressSet, AssetsMap, BLOCKS_PER_WEEK_BY_NETWORK, BalancerStablePriceFeedContract, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, BaseContract, BasePlugin, BigIntMath, BotPermissions, BoundedPriceFeedContract, CamelotV3AdapterContract, ChainContractsRegister, ChainNotConfiguredError, CompositePriceFeedContract, Construct, ContractParseError, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountOperationsService, CreditAccountState, CreditAccountsServiceV310, CreditConfiguratorV310Contract, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, DEFAULT_QUOTA_BUFFER_BPS, DEGEN_NFT_MIDAS, DEGEN_NFT_SECURITIZE, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DUST_THRESHOLD, DaiUsdsAdapterContract, ERC4626AdapterContract, ERC4626ReferralAdapterContract, EXECUTE_BYTES_SELECTOR, Erc4626PriceFeedContract, ExternalPriceFeedContract, FluidDexAdapterContract, GaugeContract, IERC20ZapperContract, IETHZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LidoV1AdapterContract, LinearInterestRateModelContract, LiquidationsService, MAX_INT, MAX_LEVERAGE_BUFFER_BPS, MAX_UINT16, MAX_UINT256, MIN_HEALTH_FACTOR_FACADE, MIN_HEALTH_FACTOR_FORM, MIN_HF_LIMITED, MIN_INT96, MIN_SAFE_HEALTH_FACTOR_FORM, MULTICALL_ADDRESS, MarketRegister, MarketSuite, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasDegenNFT, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, MissingSerializedParamsError, MultichainConstruct, MultichainLiquidationsService, MultichainOpportunitiesService, MultichainPositionsService, MultichainSDK, NATIVE_ADDRESS, NON_STRATEGY_PHANTOM_TOKEN_TYPES, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainSDK, OpportunitiesService, 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, PartialPriceFeedInitError, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PeripheryCompressorV310Contract, PluginStateVersionError, PoolService, PoolSuite, PoolV310Contract, PositionsService, PriceFeedRef, PriceFeedRegister, PriceOracleV310Contract, PythPriceFeed, RAMP_DURATION_BY_NETWORK, RAY, RAY_DECIMALS_POW, RWARegistry, RWA_COMPRESSOR_ADDRESS, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RedemptionLoggerV310Contract, RedstonePriceFeedContract, RouterV310Contract, SDKConstruct, SECONDS_PER_YEAR, SLIPPAGE_DECIMALS, STATE_VERSION, SUPPORTED_NETWORKS, SdkAlreadyAttachedError, SdkChainMismatchError, SdkMissingChainStateError, SdkNotAttachedError, SdkRWADataNotLoadedError, SdkStateVersionMismatchError, SdkSyncFailedError, SecuritizeDegenNFT, SecuritizeLiquidatorContract, SecuritizeOnRampAdapterContract, SecuritizeRWAFactory, SecuritizeRedemptionGatewayAdapterContract, SimulateWithPriceUpdatesError, SimulationError, StakingRewardsAdapterContract, TokensMeta, TraderJoePoolVersion, TraderJoeRouterAdapterContract, TypedObjectUtils, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UpshiftVaultAdapterContract, VERSION_RANGE_310, VelodromeV2RouterAdapterContract, VotingContractStatus, WAD, WAD_DECIMALS_POW, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WstETHPriceFeedContract, WstETHV1AdapterContract, YearnPriceFeedContract, ZapperContract, ZeroPriceFeedContract, ZodAddress, ZodBigInt, ZodHex, accountSnapshotFromCreditAccountData, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, amountOf, assetsMap, attachOptionsSchema, botPermissionsToString, bpsToRay, buildDelayedStrategyPositionOperationPreview, bytes32ToString, calcBorrowApy, calcBorrowRate, calcDefaultQuota, calcEffectiveBorrowApy, calcHealthFactor, calcLiquidationPrice, calcLiquidationPriceForTarget, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcQuotaUpdate, calcRecommendedQuota, calcTimeToLiquidationMs, calcUtilization, calcUtilizationRaw, chains, checkAccountQuotas, checkBorrowLimit, checkCollateralFunding, checkCollateralised, checkCreditAccountFrozen, checkCreditManagerPaused, checkCreditOperation, checkDebtLimits, checkEmergencyLiquidator, checkForbiddenToken, checkHealthFactors, checkIncreaseDebt, checkIncreaseQuota, checkLeverage, checkLiquidation, checkLiquidationEligibility, checkLiquidationFunding, checkLiquidatorEligible, checkMarket, checkMarketExpired, checkMidasAccountGreenlist, checkObtained, checkOperation, checkPoolFunding, checkPoolLiquidity, checkPoolOperation, checkPoolPaused, checkPoolSunset, checkQuotaCount, checkQuotaLimit, checkRWAOpenRequirements, checkRWAOpening, checkReservePriceLimited, checkSimulation, checkWallet, checkWalletAllowance, checkWalletBalance, childLogger, classifyCloseOrRepay, classifyCurveOperation, classifyInnerOperations, collateralPriceInUnderlying, collectTraces, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, abi as creditFacadeV310Abi, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, decodeDelayedIntent, detectDelayedClaim, detectDelayedOperation, detectNetwork, dominantCollateral, encodeDelayedIntent, erc4626ReferralAdapterAbi, estimateClaimableAt, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, executeMulticallBatches, expectedBalanceDeltas, fetchCreditAccountSlice, fetchRedstonePayloads, filterDust, filterDustUSD, findCallTo, findCallWithInput, findCuratorMarketConfigurator, findExecuteBytes, fmtBinaryMask, fnSigToName, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAccountTargetCollateral, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getLegacyStrategyTarget, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, hasAdapterDeployParamsAbi, healthFactorBps, hexEq, hydrateAddressProvider, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCreditAccountAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isCloseOrRepay, isDust, isLPPriceFeed, isPhantomToken, isPoolOperation, isPublicNetwork, isRWAFactory, isRWAOperation, isRWAToken, isStrategyCollateral, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, isZeroBalance, iwstETHAbi, iwstEthv1AdapterAbi, json_parse, json_stringify, lidoV1_WETHGatewayAbi, makeReplayState, mellowDvvAdapterAbi, midasGreenlistsAccount, minSeizedAmount, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parseFacadeOperationCalldata, parseOperationCalldata, parsePoolOperationCalldata, parsePosNegAmount, parseRWAFactoryOperationCalldata, percentFmt, pickStrategyTargetCollateral, previewAdjustStrategyPosition, previewExitOrRepayStrategyPosition, previewOperation, raise, rayToBps, rayToNumber, replayInnerOperations, replayMulticall, resolveDelayedClaimIntent, resolveProtocolCall, retry, rewardsFromTransfers, roundUpQuota, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, soleNonUnderlyingCollateral, strategyName, swapFromTransfers, toAddress, toBN, toBigInt, toChainIds, toClaimableWithdrawal, toCreditAccountSlice, toNetTransfers, toPendingWithdrawal, toRequestableWithdrawal, toSignificant, toToken, toTokenAmount, toWithdrawalStatus, usdToNumber, watchBlocksAsync };
309
+ 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_TOKEN_COMPRESSOR, AP_TREASURY, AP_WETH_GATEWAY, AP_WETH_TOKEN, AP_ZAPPER_REGISTER, AP_ZERO_PRICE_FEED, AbstractAdapterContract, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountBotsService, AccountMigratorAdapterContract, AdapterType, AddressMap, AddressProviderV310Contract, AddressSet, AssetsMap, BLOCKS_PER_WEEK_BY_NETWORK, BalancerStablePriceFeedContract, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, BaseContract, BasePlugin, BigIntMath, BotPermissions, BoundedPriceFeedContract, CamelotV3AdapterContract, ChainContractsRegister, ChainNotConfiguredError, CompositePriceFeedContract, ConstantPriceFeedContract, Construct, ContractParseError, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountOperationsService, CreditAccountState, CreditAccountsServiceV310, CreditConfiguratorV310Contract, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, DEFAULT_QUOTA_BUFFER_BPS, DEGEN_NFT_MIDAS, DEGEN_NFT_SECURITIZE, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DUST_THRESHOLD, DaiUsdsAdapterContract, ERC4626AdapterContract, ERC4626ReferralAdapterContract, EXECUTE_BYTES_SELECTOR, Erc4626PriceFeedContract, ExternalPriceFeedContract, FluidDexAdapterContract, GaugeContract, IERC20ZapperContract, IETHZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LidoV1AdapterContract, LinearInterestRateModelContract, LiquidationsService, MAX_INT, MAX_LEVERAGE_BUFFER_BPS, MAX_UINT16, MAX_UINT256, MIN_HEALTH_FACTOR_FACADE, MIN_HEALTH_FACTOR_FORM, MIN_HF_LIMITED, MIN_INT96, MIN_SAFE_HEALTH_FACTOR_FORM, MULTICALL_ADDRESS, MarketRegister, MarketSuite, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasDegenNFT, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, MissingSerializedParamsError, MultichainConstruct, MultichainLiquidationsService, MultichainOpportunitiesService, MultichainPositionsService, MultichainSDK, NATIVE_ADDRESS, NON_STRATEGY_PHANTOM_TOKEN_TYPES, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainSDK, OpportunitiesService, 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, PartialPriceFeedInitError, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PeripheryCompressorV310Contract, PluginStateVersionError, PoolService, PoolSuite, PoolV310Contract, PositionsService, PriceFeedRef, PriceFeedRegistry, PriceOracleV310Contract, PriceUpdatesCache, PythPriceFeed, RAMP_DURATION_BY_NETWORK, RAY, RAY_DECIMALS_POW, RWARegistry, RWA_COMPRESSOR_ADDRESS, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RedemptionLoggerV310Contract, RedstoneOptions, RedstonePriceFeedContract, RedstoneUpdater, RouterV310Contract, SDKConstruct, SECONDS_PER_YEAR, SLIPPAGE_DECIMALS, STATE_VERSION, SUPPORTED_NETWORKS, SdkAlreadyAttachedError, SdkChainMismatchError, SdkMissingChainStateError, SdkNotAttachedError, SdkRWADataNotLoadedError, SdkStateVersionMismatchError, SdkSyncFailedError, SecuritizeDegenNFT, SecuritizeLiquidatorContract, SecuritizeOnRampAdapterContract, SecuritizeRWAFactory, SecuritizeRedemptionGatewayAdapterContract, SimulateWithPriceUpdatesError, SimulationError, StakingRewardsAdapterContract, TokensMeta, TraderJoePoolVersion, TraderJoeRouterAdapterContract, TypedObjectUtils, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UpdatablePriceFeedRegistry, UpshiftVaultAdapterContract, VERSION_RANGE_310, VelodromeV2RouterAdapterContract, VotingContractStatus, WAD, WAD_DECIMALS_POW, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WstETHPriceFeedContract, WstETHV1AdapterContract, YearnPriceFeedContract, ZapperContract, ZeroPriceFeedContract, ZodAddress, ZodBigInt, ZodHex, accountSnapshotFromCreditAccountData, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, amountOf, assetsMap, attachOptionsSchema, botPermissionsToString, bpsToRay, buildDelayedStrategyPositionOperationPreview, bytes32ToString, calcBorrowApy, calcBorrowRate, calcDefaultQuota, calcEffectiveBorrowApy, calcHealthFactor, calcLiquidationPrice, calcLiquidationPriceForTarget, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcQuotaUpdate, calcRecommendedQuota, calcTimeToLiquidationMs, calcUtilization, calcUtilizationRaw, chains, checkAccountQuotas, checkBorrowLimit, checkCollateralFunding, checkCollateralised, checkCreditAccountFrozen, checkCreditManagerPaused, checkCreditOperation, checkDebtLimits, checkEmergencyLiquidator, checkForbiddenToken, checkHealthFactors, checkIncreaseDebt, checkIncreaseQuota, checkLeverage, checkLiquidation, checkLiquidationEligibility, checkLiquidationFunding, checkLiquidatorEligible, checkMarket, checkMarketExpired, checkMidasAccountGreenlist, checkObtained, checkOperation, checkPoolFunding, checkPoolLiquidity, checkPoolOperation, checkPoolPaused, checkPoolSunset, checkQuotaCount, checkQuotaLimit, checkRWAOpenRequirements, checkRWAOpening, checkReservePriceLimited, checkSimulation, checkWallet, checkWalletAllowance, checkWalletBalance, childLogger, classifyCloseOrRepay, classifyCurveOperation, classifyInnerOperations, collateralPriceInUnderlying, collectTraces, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, abi as creditFacadeV310Abi, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, decodeDelayedIntent, detectDelayedClaim, detectDelayedOperation, detectNetwork, dominantCollateral, encodeDelayedIntent, erc4626ReferralAdapterAbi, estimateClaimableAt, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, executeMulticallBatches, expectedBalanceDeltas, fetchCreditAccountSlice, fetchRedstonePayloads, filterDust, filterDustUSD, findCallTo, findCallWithInput, findCuratorMarketConfigurator, findExecuteBytes, fmtBinaryMask, fnSigToName, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAccountTargetCollateral, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getLegacyStrategyTarget, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, hasAdapterDeployParamsAbi, healthFactorBps, hexEq, hydrateAddressProvider, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCreditAccountAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isCloseOrRepay, isDust, isLPPriceFeed, isPhantomToken, isPoolOperation, isPublicNetwork, isRWAFactory, isRWAOperation, isRWAToken, isStrategyCollateral, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, isZeroBalance, iwstETHAbi, iwstEthv1AdapterAbi, json_parse, json_stringify, lidoV1_WETHGatewayAbi, makeReplayState, mellowDvvAdapterAbi, midasGreenlistsAccount, minSeizedAmount, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parseFacadeOperationCalldata, parseOperationCalldata, parsePoolOperationCalldata, parsePosNegAmount, parseRWAFactoryOperationCalldata, percentFmt, pickStrategyTargetCollateral, previewAdjustStrategyPosition, previewExitOrRepayStrategyPosition, previewOperation, raise, rayToBps, rayToNumber, replayInnerOperations, replayMulticall, resolveDelayedClaimIntent, resolveProtocolCall, retry, rewardsFromTransfers, roundUpQuota, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, soleNonUnderlyingCollateral, strategyName, swapFromTransfers, toAddress, toBN, toBigInt, toChainIds, toClaimableWithdrawal, toCreditAccountSlice, toNetTransfers, toPendingWithdrawal, toRequestableWithdrawal, toSignificant, toToken, toTokenAmount, toWithdrawalStatus, updatableDependencies, usdToNumber, watchBlocksAsync };
@@ -98,29 +98,34 @@ import { CreditSuite } from "./credit/CreditSuite.js";
98
98
  import { expectedBalanceDeltas } from "./credit/expectedBalanceDeltas.js";
99
99
  import "./credit/index.js";
100
100
  import { collateralPriceInUnderlying } from "./oracle/collateralPriceInUnderlying.js";
101
- import { isUpdatablePriceFeed } from "./pricefeeds/isUpdatablePriceFeed.js";
102
101
  import { PriceFeedRef } from "./pricefeeds/PriceFeedRef.js";
103
102
  import { AbstractPriceFeedContract, PartialPriceFeedInitError } from "./pricefeeds/AbstractPriceFeed.js";
104
103
  import { AbstractLPPriceFeedContract, isLPPriceFeed } from "./pricefeeds/AbstractLPPriceFeed.js";
105
- import { BalancerStablePriceFeedContract } from "./pricefeeds/BalancerStablePriceFeed.js";
106
- import { BalancerWeightedPriceFeedContract } from "./pricefeeds/BalancerWeightedPriceFeed.js";
107
- import { BoundedPriceFeedContract } from "./pricefeeds/BoundedPriceFeed.js";
108
- import { CompositePriceFeedContract } from "./pricefeeds/CompositePriceFeed.js";
109
- import { CurveCryptoPriceFeedContract } from "./pricefeeds/CurveCryptoPriceFeed.js";
110
- import { CurveStablePriceFeedContract } from "./pricefeeds/CurveStablePriceFeed.js";
111
- import { CurveUSDPriceFeedContract } from "./pricefeeds/CurveUSDPriceFeed.js";
112
- import { Erc4626PriceFeedContract } from "./pricefeeds/Erc4626PriceFeed.js";
113
- import { ExternalPriceFeedContract } from "./pricefeeds/ExternalPriceFeed.js";
114
- import { getRawPriceUpdates } from "./pricefeeds/getRawPriceUpdates.js";
115
- import { MellowLRTPriceFeedContract } from "./pricefeeds/MellowLRTPriceFeed.js";
116
- import { PendleTWAPPTPriceFeed } from "./pricefeeds/PendleTWAPPTPriceFeed.js";
117
- import { PythPriceFeed } from "./pricefeeds/PythPriceFeed.js";
118
- import { RedstonePriceFeedContract } from "./pricefeeds/RedstonePriceFeed.js";
104
+ import { BalancerStablePriceFeedContract } from "./pricefeeds/feeds/BalancerStablePriceFeed.js";
105
+ import { BalancerWeightedPriceFeedContract } from "./pricefeeds/feeds/BalancerWeightedPriceFeed.js";
106
+ import { BoundedPriceFeedContract } from "./pricefeeds/feeds/BoundedPriceFeed.js";
107
+ import { CompositePriceFeedContract } from "./pricefeeds/feeds/CompositePriceFeed.js";
108
+ import { ConstantPriceFeedContract } from "./pricefeeds/feeds/ConstantPriceFeed.js";
109
+ import { CurveCryptoPriceFeedContract } from "./pricefeeds/feeds/CurveCryptoPriceFeed.js";
110
+ import { CurveStablePriceFeedContract } from "./pricefeeds/feeds/CurveStablePriceFeed.js";
111
+ import { CurveUSDPriceFeedContract } from "./pricefeeds/feeds/CurveUSDPriceFeed.js";
112
+ import { Erc4626PriceFeedContract } from "./pricefeeds/feeds/Erc4626PriceFeed.js";
113
+ import { ExternalPriceFeedContract } from "./pricefeeds/feeds/ExternalPriceFeed.js";
114
+ import { MellowLRTPriceFeedContract } from "./pricefeeds/feeds/MellowLRTPriceFeed.js";
115
+ import { PendleTWAPPTPriceFeed } from "./pricefeeds/feeds/PendleTWAPPTPriceFeed.js";
116
+ import { PythPriceFeed } from "./pricefeeds/feeds/PythPriceFeed.js";
117
+ import { RedstonePriceFeedContract } from "./pricefeeds/feeds/RedstonePriceFeed.js";
118
+ import { WstETHPriceFeedContract } from "./pricefeeds/feeds/WstETHPriceFeed.js";
119
+ import { YearnPriceFeedContract } from "./pricefeeds/feeds/YearnPriceFeed.js";
120
+ import { ZeroPriceFeedContract } from "./pricefeeds/feeds/ZeroPriceFeed.js";
121
+ import { PriceFeedRegistry } from "./pricefeeds/PriceFeedRegistry.js";
119
122
  import { fetchRedstonePayloads } from "./pricefeeds/updates/fetchRedstonePayloads.js";
120
- import { WstETHPriceFeedContract } from "./pricefeeds/WstETHPriceFeed.js";
121
- import { YearnPriceFeedContract } from "./pricefeeds/YearnPriceFeed.js";
122
- import { ZeroPriceFeedContract } from "./pricefeeds/ZeroPriceFeed.js";
123
- import { PriceFeedRegister } from "./pricefeeds/PriceFeedsRegister.js";
123
+ import { getRawPriceUpdates } from "./pricefeeds/updates/getRawPriceUpdates.js";
124
+ import { isUpdatablePriceFeed } from "./pricefeeds/updates/isUpdatablePriceFeed.js";
125
+ import { PriceUpdatesCache } from "./pricefeeds/updates/PriceUpdatesCache.js";
126
+ import { RedstoneOptions, RedstoneUpdater } from "./pricefeeds/updates/RedstoneUpdater.js";
127
+ import { updatableDependencies } from "./pricefeeds/updates/updatableDependencies.js";
128
+ import { UpdatablePriceFeedRegistry } from "./pricefeeds/updates/UpdatablePriceFeedRegistry.js";
124
129
  import "./pricefeeds/index.js";
125
130
  import { PriceOracleV310Contract } from "./oracle/PriceOracleV310Contract.js";
126
131
  import { createPriceOracle } from "./oracle/createPriceOracle.js";
@@ -145,4 +150,4 @@ import { RWARegistry, RWA_COMPRESSOR_ADDRESS } from "./rwa/RWARegistry.js";
145
150
  import { isRWAFactory } from "./rwa/types.js";
146
151
  import "./rwa/index.js";
147
152
  import "./types.js";
148
- export { AbstractAdapterContract, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AccountMigratorAdapterContract, AdapterType, BalancerStablePriceFeedContract, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, BoundedPriceFeedContract, CamelotV3AdapterContract, CompositePriceFeedContract, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, CreditConfiguratorV310Contract, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, DEFAULT_QUOTA_BUFFER_BPS, DEGEN_NFT_MIDAS, DEGEN_NFT_SECURITIZE, DaiUsdsAdapterContract, ERC4626AdapterContract, ERC4626ReferralAdapterContract, Erc4626PriceFeedContract, ExternalPriceFeedContract, FluidDexAdapterContract, GaugeContract, IERC20ZapperContract, IETHZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LidoV1AdapterContract, LinearInterestRateModelContract, MAX_LEVERAGE_BUFFER_BPS, MarketRegister, MarketSuite, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasDegenNFT, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, PARTIAL_LIQUIDATION_BUFFER_BPS, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, PartialPriceFeedInitError, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PoolSuite, PoolV310Contract, PriceFeedRef, PriceFeedRegister, PriceOracleV310Contract, PythPriceFeed, RWARegistry, RWA_COMPRESSOR_ADDRESS, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RedstonePriceFeedContract, SecuritizeDegenNFT, SecuritizeLiquidatorContract, SecuritizeOnRampAdapterContract, SecuritizeRWAFactory, SecuritizeRedemptionGatewayAdapterContract, StakingRewardsAdapterContract, TraderJoePoolVersion, TraderJoeRouterAdapterContract, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UpshiftVaultAdapterContract, VelodromeV2RouterAdapterContract, WstETHPriceFeedContract, WstETHV1AdapterContract, YearnPriceFeedContract, ZapperContract, ZeroPriceFeedContract, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, bpsToRay, calcBorrowApy, calcEffectiveBorrowApy, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcUtilization, calcUtilizationRaw, classifyCurveOperation, collateralPriceInUnderlying, createAdapter, createPriceOracle, createZapper, abi as creditFacadeV310Abi, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, dominantCollateral, erc4626ReferralAdapterAbi, expectedBalanceDeltas, fetchRedstonePayloads, fnSigToName, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getRawPriceUpdates, hasAdapterDeployParamsAbi, healthFactorBps, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isLPPriceFeed, isRWAFactory, isStrategyCollateral, isUpdatablePriceFeed, iwstETHAbi, iwstEthv1AdapterAbi, lidoV1_WETHGatewayAbi, mellowDvvAdapterAbi, minSeizedAmount, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, pickStrategyTargetCollateral, rayToBps, rewardsFromTransfers, strategyName, swapFromTransfers, toNetTransfers, usdToNumber };
153
+ export { AbstractAdapterContract, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AccountMigratorAdapterContract, AdapterType, BalancerStablePriceFeedContract, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, BoundedPriceFeedContract, CamelotV3AdapterContract, CompositePriceFeedContract, ConstantPriceFeedContract, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, CreditConfiguratorV310Contract, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, DEFAULT_QUOTA_BUFFER_BPS, DEGEN_NFT_MIDAS, DEGEN_NFT_SECURITIZE, DaiUsdsAdapterContract, ERC4626AdapterContract, ERC4626ReferralAdapterContract, Erc4626PriceFeedContract, ExternalPriceFeedContract, FluidDexAdapterContract, GaugeContract, IERC20ZapperContract, IETHZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LidoV1AdapterContract, LinearInterestRateModelContract, MAX_LEVERAGE_BUFFER_BPS, MarketRegister, MarketSuite, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasDegenNFT, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, PARTIAL_LIQUIDATION_BUFFER_BPS, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, PartialPriceFeedInitError, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PoolSuite, PoolV310Contract, PriceFeedRef, PriceFeedRegistry, PriceOracleV310Contract, PriceUpdatesCache, PythPriceFeed, RWARegistry, RWA_COMPRESSOR_ADDRESS, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RedstoneOptions, RedstonePriceFeedContract, RedstoneUpdater, SecuritizeDegenNFT, SecuritizeLiquidatorContract, SecuritizeOnRampAdapterContract, SecuritizeRWAFactory, SecuritizeRedemptionGatewayAdapterContract, StakingRewardsAdapterContract, TraderJoePoolVersion, TraderJoeRouterAdapterContract, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UpdatablePriceFeedRegistry, UpshiftVaultAdapterContract, VelodromeV2RouterAdapterContract, WstETHPriceFeedContract, WstETHV1AdapterContract, YearnPriceFeedContract, ZapperContract, ZeroPriceFeedContract, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, bpsToRay, calcBorrowApy, calcEffectiveBorrowApy, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcUtilization, calcUtilizationRaw, classifyCurveOperation, collateralPriceInUnderlying, createAdapter, createPriceOracle, createZapper, abi as creditFacadeV310Abi, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, dominantCollateral, erc4626ReferralAdapterAbi, expectedBalanceDeltas, fetchRedstonePayloads, fnSigToName, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getRawPriceUpdates, hasAdapterDeployParamsAbi, healthFactorBps, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isLPPriceFeed, isRWAFactory, isStrategyCollateral, isUpdatablePriceFeed, iwstETHAbi, iwstEthv1AdapterAbi, lidoV1_WETHGatewayAbi, mellowDvvAdapterAbi, minSeizedAmount, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, pickStrategyTargetCollateral, rayToBps, rewardsFromTransfers, strategyName, swapFromTransfers, toNetTransfers, updatableDependencies, usdToNumber };
@@ -16,7 +16,7 @@ import { safeValue } from "../../../model/result.js";
16
16
  import "../../../model/index.js";
17
17
  import { priceFeedCompressorAbi } from "../../../abi/compressors/priceFeedCompressor.js";
18
18
  import { PriceFeedRef } from "../pricefeeds/PriceFeedRef.js";
19
- import { getRawPriceUpdates } from "../pricefeeds/getRawPriceUpdates.js";
19
+ import { getRawPriceUpdates } from "../pricefeeds/updates/getRawPriceUpdates.js";
20
20
  import "../pricefeeds/index.js";
21
21
  import PriceFeedAnswerMap from "./PriceFeedAnswerMap.js";
22
22
  import { isAddressEqual, stringToHex } from "viem";
@@ -1,6 +1,5 @@
1
1
  import { BaseContract } from "../../base/BaseContract.js";
2
2
  import "../../base/index.js";
3
- import { isUpdatablePriceFeed } from "./isUpdatablePriceFeed.js";
4
3
  import { PriceFeedRef } from "./PriceFeedRef.js";
5
4
  //#region src/onchain/market/pricefeeds/AbstractPriceFeed.ts
6
5
  var PartialPriceFeedInitError = class extends Error {
@@ -84,10 +83,6 @@ var AbstractPriceFeedContract = class extends BaseContract {
84
83
  pricefeeds: this.underlyingPriceFeeds.map((f) => f.stateHuman(raw))
85
84
  };
86
85
  }
87
- updatableDependencies() {
88
- const underlying = this.underlyingPriceFeeds.flatMap((f) => f.priceFeed.updatableDependencies());
89
- return isUpdatablePriceFeed(this) ? [this, ...underlying] : underlying;
90
- }
91
86
  /**
92
87
  * {@inheritDoc IPriceFeedContract.describe}
93
88
  */
@@ -0,0 +1,126 @@
1
+ import { AddressMap } from "../../utils/AddressMap.js";
2
+ import { bytes32ToString } from "../../utils/bytes32ToString.js";
3
+ import "../../utils/index.js";
4
+ import { SDKConstruct } from "../../base/SDKConstruct.js";
5
+ import "../../base/index.js";
6
+ import { PartialPriceFeedInitError } from "./AbstractPriceFeed.js";
7
+ import { BalancerStablePriceFeedContract } from "./feeds/BalancerStablePriceFeed.js";
8
+ import { BalancerWeightedPriceFeedContract } from "./feeds/BalancerWeightedPriceFeed.js";
9
+ import { BoundedPriceFeedContract } from "./feeds/BoundedPriceFeed.js";
10
+ import { CompositePriceFeedContract } from "./feeds/CompositePriceFeed.js";
11
+ import { ConstantPriceFeedContract } from "./feeds/ConstantPriceFeed.js";
12
+ import { CurveCryptoPriceFeedContract } from "./feeds/CurveCryptoPriceFeed.js";
13
+ import { CurveStablePriceFeedContract } from "./feeds/CurveStablePriceFeed.js";
14
+ import { CurveUSDPriceFeedContract } from "./feeds/CurveUSDPriceFeed.js";
15
+ import { Erc4626PriceFeedContract } from "./feeds/Erc4626PriceFeed.js";
16
+ import { ExternalPriceFeedContract } from "./feeds/ExternalPriceFeed.js";
17
+ import { MellowLRTPriceFeedContract } from "./feeds/MellowLRTPriceFeed.js";
18
+ import { PendleTWAPPTPriceFeed } from "./feeds/PendleTWAPPTPriceFeed.js";
19
+ import { PythPriceFeed } from "./feeds/PythPriceFeed.js";
20
+ import { RedstonePriceFeedContract } from "./feeds/RedstonePriceFeed.js";
21
+ import { WstETHPriceFeedContract } from "./feeds/WstETHPriceFeed.js";
22
+ import { YearnPriceFeedContract } from "./feeds/YearnPriceFeed.js";
23
+ import { ZeroPriceFeedContract } from "./feeds/ZeroPriceFeed.js";
24
+ //#region src/onchain/market/pricefeeds/PriceFeedRegistry.ts
25
+ /**
26
+ * Chain-level cache of price feed contract instances.
27
+ *
28
+ * All {@link IPriceOracleContract}s across different markets share a single
29
+ * `PriceFeedRegistry`, avoiding duplicate contract wrappers for the same
30
+ * on-chain feed.
31
+ **/
32
+ var PriceFeedRegistry = class extends SDKConstruct {
33
+ #feeds = new AddressMap(void 0, "priceFeeds");
34
+ /**
35
+ * Returns all price feeds known to sdk
36
+ */
37
+ get feeds() {
38
+ return this.#feeds.values();
39
+ }
40
+ /**
41
+ * Checks whether a price feed is already registered at the given address.
42
+ * @param address - On-chain address to look up.
43
+ **/
44
+ has(address) {
45
+ return this.#feeds.has(address);
46
+ }
47
+ /**
48
+ * Returns the cached price feed contract at the given address, if any.
49
+ * @param address - On-chain address to look up.
50
+ **/
51
+ get(address) {
52
+ return this.#feeds.get(address);
53
+ }
54
+ /**
55
+ * Returns the cached price feed contract at the given address.
56
+ * @param address - On-chain address to look up.
57
+ * @throws If no feed is registered at that address.
58
+ **/
59
+ mustGet(address) {
60
+ return this.#feeds.mustGet(address);
61
+ }
62
+ /**
63
+ * Inserts or updates a price feed from a full tree node.
64
+ *
65
+ * If a fully loaded feed already exists at the same address, only the
66
+ * answer is refreshed. Otherwise a new contract wrapper is created and
67
+ * cached.
68
+ *
69
+ * @param data - Full price feed tree node from the compressor.
70
+ * @returns The cached (or newly created) feed instance.
71
+ * @throws If the created feed is only partially initialized.
72
+ **/
73
+ upsert(data) {
74
+ const existing = this.#feeds.get(data.baseParams.addr);
75
+ if (existing?.loaded) {
76
+ existing.updateAnswer(data.answer);
77
+ return existing;
78
+ }
79
+ const feed = this.create(data);
80
+ if (!feed.loaded) throw new PartialPriceFeedInitError({
81
+ ...data,
82
+ abi: [],
83
+ name: ""
84
+ });
85
+ this.#feeds.upsert(data.baseParams.addr, feed);
86
+ return feed;
87
+ }
88
+ /**
89
+ * Instantiates the appropriate price feed contract wrapper based on
90
+ * the `contractType` discriminator in the node's base params.
91
+ *
92
+ * @param data - Partial or full price feed tree node.
93
+ * @returns A new (uncached) feed contract instance.
94
+ * @throws If the contract type is unsupported and strict mode is enabled.
95
+ **/
96
+ create(data) {
97
+ const contractType = bytes32ToString(data.baseParams.contractType);
98
+ switch (contractType) {
99
+ case "PRICE_FEED::BALANCER_STABLE": return new BalancerStablePriceFeedContract(this.sdk, data);
100
+ case "PRICE_FEED::BALANCER_WEIGHTED": return new BalancerWeightedPriceFeedContract(this.sdk, data);
101
+ case "PRICE_FEED::BOUNDED": return new BoundedPriceFeedContract(this.sdk, data);
102
+ case "PRICE_FEED::COMPOSITE": return new CompositePriceFeedContract(this.sdk, data);
103
+ case "PRICE_FEED::CONSTANT": return new ConstantPriceFeedContract(this.sdk, data);
104
+ case "PRICE_FEED::CURVE_CRYPTO": return new CurveCryptoPriceFeedContract(this.sdk, data);
105
+ case "PRICE_FEED::CURVE_STABLE": return new CurveStablePriceFeedContract(this.sdk, data);
106
+ case "PRICE_FEED::CURVE_USD": return new CurveUSDPriceFeedContract(this.sdk, data);
107
+ case "PRICE_FEED::ERC4626": return new Erc4626PriceFeedContract(this.sdk, data);
108
+ case "PRICE_FEED::EXTERNAL": return new ExternalPriceFeedContract(this.sdk, data);
109
+ case "PRICE_FEED::MELLOW_LRT": return new MellowLRTPriceFeedContract(this.sdk, data);
110
+ case "PRICE_FEED::PENDLE_PT_TWAP": return new PendleTWAPPTPriceFeed(this.sdk, data);
111
+ case "PRICE_FEED::PYTH": return new PythPriceFeed(this.sdk, data);
112
+ case "PRICE_FEED::REDSTONE": return new RedstonePriceFeedContract(this.sdk, data);
113
+ case "PRICE_FEED::WSTETH": return new WstETHPriceFeedContract(this.sdk, data);
114
+ case "PRICE_FEED::YEARN": return new YearnPriceFeedContract(this.sdk, data);
115
+ case "PRICE_FEED::ZERO": return new ZeroPriceFeedContract(this.sdk, data);
116
+ default: {
117
+ const err = /* @__PURE__ */ new Error(`Price feed type ${contractType} not supported for price feed at ${data.baseParams.addr}`);
118
+ if (this.sdk.strictContractTypes) throw err;
119
+ this.logger?.error(err);
120
+ return new ExternalPriceFeedContract(this.sdk, data);
121
+ }
122
+ }
123
+ }
124
+ };
125
+ //#endregion
126
+ export { PriceFeedRegistry };
@@ -1,7 +1,7 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { bptStablePriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/BalancerStablePriceFeed.ts
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { bptStablePriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/BalancerStablePriceFeed.ts
5
5
  var BalancerStablePriceFeedContract = class extends AbstractLPPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,8 +1,8 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { bptWeightedPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { bptWeightedPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
4
  import { decodeAbiParameters, hexToBytes } from "viem";
5
- //#region src/onchain/market/pricefeeds/BalancerWeightedPriceFeed.ts
5
+ //#region src/onchain/market/pricefeeds/feeds/BalancerWeightedPriceFeed.ts
6
6
  var BalancerWeightedPriceFeedContract = class extends AbstractLPPriceFeedContract {
7
7
  vault;
8
8
  poolId;
@@ -1,8 +1,8 @@
1
- import { AbstractPriceFeedContract } from "./AbstractPriceFeed.js";
2
- import { boundedPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
1
+ import { AbstractPriceFeedContract } from "../AbstractPriceFeed.js";
2
+ import { boundedPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
4
  import { decodeAbiParameters } from "viem";
5
- //#region src/onchain/market/pricefeeds/BoundedPriceFeed.ts
5
+ //#region src/onchain/market/pricefeeds/feeds/BoundedPriceFeed.ts
6
6
  var BoundedPriceFeedContract = class extends AbstractPriceFeedContract {
7
7
  upperBound;
8
8
  constructor(options, args) {
@@ -1,7 +1,7 @@
1
- import { AbstractPriceFeedContract } from "./AbstractPriceFeed.js";
2
- import { compositePriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/CompositePriceFeed.ts
1
+ import { AbstractPriceFeedContract } from "../AbstractPriceFeed.js";
2
+ import { compositePriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/CompositePriceFeed.ts
5
5
  var CompositePriceFeedContract = class extends AbstractPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,7 +1,7 @@
1
- import { AbstractPriceFeedContract } from "./AbstractPriceFeed.js";
2
- import { constantPriceFeedAbi } from "../../abi/oracles.js";
1
+ import { AbstractPriceFeedContract } from "../AbstractPriceFeed.js";
2
+ import { constantPriceFeedAbi } from "../../../abi/oracles.js";
3
3
  import { decodeAbiParameters } from "viem";
4
- //#region src/onchain/market/pricefeeds/ConstantPriceFeed.ts
4
+ //#region src/onchain/market/pricefeeds/feeds/ConstantPriceFeed.ts
5
5
  var ConstantPriceFeedContract = class extends AbstractPriceFeedContract {
6
6
  price;
7
7
  constructor(options, args) {
@@ -1,7 +1,7 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { curveCryptoLpPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/CurveCryptoPriceFeed.ts
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { curveCryptoLpPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/CurveCryptoPriceFeed.ts
5
5
  var CurveCryptoPriceFeedContract = class extends AbstractLPPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,7 +1,7 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { curveStableLpPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/CurveStablePriceFeed.ts
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { curveStableLpPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/CurveStablePriceFeed.ts
5
5
  var CurveStablePriceFeedContract = class extends AbstractLPPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,7 +1,7 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { curveUsdPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/CurveUSDPriceFeed.ts
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { curveUsdPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/CurveUSDPriceFeed.ts
5
5
  var CurveUSDPriceFeedContract = class extends AbstractLPPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,7 +1,7 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { erc4626PriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/Erc4626PriceFeed.ts
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { erc4626PriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/Erc4626PriceFeed.ts
5
5
  var Erc4626PriceFeedContract = class extends AbstractLPPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,7 +1,7 @@
1
- import { AbstractPriceFeedContract } from "./AbstractPriceFeed.js";
2
- import { chainlinkReadableAggregatorAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/ExternalPriceFeed.ts
1
+ import { AbstractPriceFeedContract } from "../AbstractPriceFeed.js";
2
+ import { chainlinkReadableAggregatorAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/ExternalPriceFeed.ts
5
5
  var ExternalPriceFeedContract = class extends AbstractPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,7 +1,7 @@
1
- import { AbstractLPPriceFeedContract } from "./AbstractLPPriceFeed.js";
2
- import { mellowLrtPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
4
- //#region src/onchain/market/pricefeeds/MellowLRTPriceFeed.ts
1
+ import { AbstractLPPriceFeedContract } from "../AbstractLPPriceFeed.js";
2
+ import { mellowLrtPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
+ //#region src/onchain/market/pricefeeds/feeds/MellowLRTPriceFeed.ts
5
5
  var MellowLRTPriceFeedContract = class extends AbstractLPPriceFeedContract {
6
6
  constructor(options, args) {
7
7
  super(options, {
@@ -1,8 +1,8 @@
1
- import { AbstractPriceFeedContract } from "./AbstractPriceFeed.js";
2
- import { pendleTWAPPTPriceFeedAbi } from "../../abi/oracles.js";
3
- import "../../abi/index.js";
1
+ import { AbstractPriceFeedContract } from "../AbstractPriceFeed.js";
2
+ import { pendleTWAPPTPriceFeedAbi } from "../../../abi/oracles.js";
3
+ import "../../../abi/index.js";
4
4
  import { decodeAbiParameters } from "viem";
5
- //#region src/onchain/market/pricefeeds/PendleTWAPPTPriceFeed.ts
5
+ //#region src/onchain/market/pricefeeds/feeds/PendleTWAPPTPriceFeed.ts
6
6
  const abi = pendleTWAPPTPriceFeedAbi;
7
7
  var PendleTWAPPTPriceFeed = class extends AbstractPriceFeedContract {
8
8
  market;
@@ -1,7 +1,7 @@
1
- import { AbstractPriceFeedContract } from "./AbstractPriceFeed.js";
2
- import { pythPriceFeedAbi } from "../../abi/oracles.js";
1
+ import { AbstractPriceFeedContract } from "../AbstractPriceFeed.js";
2
+ import { pythPriceFeedAbi } from "../../../abi/oracles.js";
3
3
  import { decodeAbiParameters } from "viem";
4
- //#region src/onchain/market/pricefeeds/PythPriceFeed.ts
4
+ //#region src/onchain/market/pricefeeds/feeds/PythPriceFeed.ts
5
5
  const abi = pythPriceFeedAbi;
6
6
  var PythPriceFeed = class extends AbstractPriceFeedContract {
7
7
  token;