@steerprotocol/sdk 4.0.0-next.12 → 4.0.0-next.13
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.
- package/README.md +6 -0
- package/dist/index.cjs +220 -30
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -0
- package/dist/index.d.mts +3 -0
- package/dist/index.mjs +220 -30
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -240,6 +240,9 @@ export declare enum AmmDeployment {
|
|
|
240
240
|
AerodromeSlipstreamBase = "aerodrome-slipstream-base",
|
|
241
241
|
AerodromeSlipstreamV2Base = "aerodrome-slipstream-v2-base",
|
|
242
242
|
AerodromeSlipstreamV3Base = "aerodrome-slipstream-v3-base",
|
|
243
|
+
SushiSwapV3Base = "sushiswap-v3-base",
|
|
244
|
+
SushiSwapV3Bsc = "sushiswap-v3-bsc",
|
|
245
|
+
UniswapV3Bsc = "uniswap-v3-bsc",
|
|
243
246
|
SushiSwapV3Polygon = "sushiswap-v3-polygon",
|
|
244
247
|
RetroV3Polygon = "retro-v3-polygon",
|
|
245
248
|
UniswapV3Polygon = "uniswap-v3-polygon",
|
package/dist/index.d.mts
CHANGED
|
@@ -240,6 +240,9 @@ export declare enum AmmDeployment {
|
|
|
240
240
|
AerodromeSlipstreamBase = "aerodrome-slipstream-base",
|
|
241
241
|
AerodromeSlipstreamV2Base = "aerodrome-slipstream-v2-base",
|
|
242
242
|
AerodromeSlipstreamV3Base = "aerodrome-slipstream-v3-base",
|
|
243
|
+
SushiSwapV3Base = "sushiswap-v3-base",
|
|
244
|
+
SushiSwapV3Bsc = "sushiswap-v3-bsc",
|
|
245
|
+
UniswapV3Bsc = "uniswap-v3-bsc",
|
|
243
246
|
SushiSwapV3Polygon = "sushiswap-v3-polygon",
|
|
244
247
|
RetroV3Polygon = "retro-v3-polygon",
|
|
245
248
|
UniswapV3Polygon = "uniswap-v3-polygon",
|
package/dist/index.mjs
CHANGED
|
@@ -756,6 +756,9 @@ let AmmDeployment = /* @__PURE__ */ function(AmmDeployment) {
|
|
|
756
756
|
AmmDeployment["AerodromeSlipstreamBase"] = "aerodrome-slipstream-base";
|
|
757
757
|
AmmDeployment["AerodromeSlipstreamV2Base"] = "aerodrome-slipstream-v2-base";
|
|
758
758
|
AmmDeployment["AerodromeSlipstreamV3Base"] = "aerodrome-slipstream-v3-base";
|
|
759
|
+
AmmDeployment["SushiSwapV3Base"] = "sushiswap-v3-base";
|
|
760
|
+
AmmDeployment["SushiSwapV3Bsc"] = "sushiswap-v3-bsc";
|
|
761
|
+
AmmDeployment["UniswapV3Bsc"] = "uniswap-v3-bsc";
|
|
759
762
|
AmmDeployment["SushiSwapV3Polygon"] = "sushiswap-v3-polygon";
|
|
760
763
|
AmmDeployment["RetroV3Polygon"] = "retro-v3-polygon";
|
|
761
764
|
AmmDeployment["UniswapV3Polygon"] = "uniswap-v3-polygon";
|
|
@@ -19894,6 +19897,38 @@ const quickSwapIntegralPolygon = /* @__PURE__ */ new Deployment({
|
|
|
19894
19897
|
}
|
|
19895
19898
|
}, (context, definition) => new QuickSwapIntegral(context, definition, new AlgebraIntegralDataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
19896
19899
|
//#endregion
|
|
19900
|
+
//#region src/amm/deployments/sushiswap-v3.ts
|
|
19901
|
+
/** Prior SDK endpoint metadata retained; vault reads verify factory registration independently. */
|
|
19902
|
+
const sushiswapV3Polygon = /* @__PURE__ */ new Deployment({
|
|
19903
|
+
id: "sushiswap-v3-polygon",
|
|
19904
|
+
chainId: 137,
|
|
19905
|
+
contracts: { factory: { address: "0x917933899c6a5F8E37F31E19f92CdBFF7e8FF0e2" } },
|
|
19906
|
+
dataAdapter: {
|
|
19907
|
+
kind: "subgraph",
|
|
19908
|
+
url: "https://gateway.thegraph.com/api/subgraphs/id/CqLnQY1d6DLcBYu7aZvGmt17LoNdTe4fDYnGbE2EgotR"
|
|
19909
|
+
}
|
|
19910
|
+
}, (context, definition) => new SushiSwapV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
19911
|
+
/** Prior SDK endpoint metadata retained; vault reads verify factory registration independently. */
|
|
19912
|
+
const sushiswapV3Bsc = /* @__PURE__ */ new Deployment({
|
|
19913
|
+
id: "sushiswap-v3-bsc",
|
|
19914
|
+
chainId: 56,
|
|
19915
|
+
contracts: { factory: { address: "0x126555dd55a39328F69400d6aE4F782Bd4C34ABb" } },
|
|
19916
|
+
dataAdapter: {
|
|
19917
|
+
kind: "subgraph",
|
|
19918
|
+
url: "https://gateway.thegraph.com/api/subgraphs/id/FiJDXMFCBv88GP17g2TtPh8BcA8jZozn5WRW7hCN7cUT"
|
|
19919
|
+
}
|
|
19920
|
+
}, (context, definition) => new SushiSwapV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
19921
|
+
/** Prior SDK endpoint metadata retained; vault reads verify factory registration independently. */
|
|
19922
|
+
const sushiswapV3Base = /* @__PURE__ */ new Deployment({
|
|
19923
|
+
id: "sushiswap-v3-base",
|
|
19924
|
+
chainId: 8453,
|
|
19925
|
+
contracts: { factory: { address: "0xc35DADB65012eC5796536bD9864eD8773aBc74C4" } },
|
|
19926
|
+
dataAdapter: {
|
|
19927
|
+
kind: "subgraph",
|
|
19928
|
+
url: "https://gateway.thegraph.com/api/subgraphs/id/Cz4Snpih41NNNPZcbj1gd3fYXPwFr5q92iWMoZjCarEb"
|
|
19929
|
+
}
|
|
19930
|
+
}, (context, definition) => new SushiSwapV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
19931
|
+
//#endregion
|
|
19897
19932
|
//#region src/amm/deployments/uniswap-v3.ts
|
|
19898
19933
|
/** Addresses: https://developers.uniswap.org/docs/protocols/v3/deployments/v3-base-deployments */
|
|
19899
19934
|
const uniswapV3Base = /* @__PURE__ */ new Deployment({
|
|
@@ -19923,6 +19958,20 @@ const uniswapV3Polygon = /* @__PURE__ */ new Deployment({
|
|
|
19923
19958
|
url: "https://gateway.thegraph.com/api/subgraphs/id/EsLGwxyeMMeJuhqWvuLmJEiDKXJ4Z6YsoJreUnyeozco"
|
|
19924
19959
|
}
|
|
19925
19960
|
}, (context, definition) => new UniswapV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
19961
|
+
/** Addresses: https://developers.uniswap.org/docs/protocols/v3/deployments/bsc-deployments */
|
|
19962
|
+
const uniswapV3Bsc = /* @__PURE__ */ new Deployment({
|
|
19963
|
+
id: "uniswap-v3-bsc",
|
|
19964
|
+
chainId: 56,
|
|
19965
|
+
contracts: {
|
|
19966
|
+
factory: { address: "0xdB1d10011AD0Ff90774D0C6Bb92e5C5c8b4461F7" },
|
|
19967
|
+
positionManager: { address: "0x7b8A01B39D58278b5DE7e48c8449c9f4F5170613" },
|
|
19968
|
+
quoter: { address: "0x78D78E420Da98ad378D7799bE8f4AF69033EB077" }
|
|
19969
|
+
},
|
|
19970
|
+
dataAdapter: {
|
|
19971
|
+
kind: "subgraph",
|
|
19972
|
+
url: "https://gateway.thegraph.com/api/subgraphs/id/G5MUbSBM7Nsrm9tH2tGQUiAF4SZDGf2qeo1xPLYjKr7K"
|
|
19973
|
+
}
|
|
19974
|
+
}, (context, definition) => new UniswapV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
19926
19975
|
//#endregion
|
|
19927
19976
|
//#region src/amm/adapters/uniswap-v4/key-lookup.ts
|
|
19928
19977
|
const abi = /* @__PURE__ */ parseAbi([
|
|
@@ -22922,18 +22971,6 @@ const retroV3Polygon = /* @__PURE__ */ new Deployment({
|
|
|
22922
22971
|
}
|
|
22923
22972
|
}, (context, definition) => new RetroV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
22924
22973
|
//#endregion
|
|
22925
|
-
//#region src/amm/deployments/sushiswap-v3.ts
|
|
22926
|
-
/** Prior SDK endpoint metadata retained; vault reads verify factory registration independently. */
|
|
22927
|
-
const sushiswapV3Polygon = /* @__PURE__ */ new Deployment({
|
|
22928
|
-
id: "sushiswap-v3-polygon",
|
|
22929
|
-
chainId: 137,
|
|
22930
|
-
contracts: { factory: { address: "0x917933899c6a5F8E37F31E19f92CdBFF7e8FF0e2" } },
|
|
22931
|
-
dataAdapter: {
|
|
22932
|
-
kind: "subgraph",
|
|
22933
|
-
url: "https://gateway.thegraph.com/api/subgraphs/id/CqLnQY1d6DLcBYu7aZvGmt17LoNdTe4fDYnGbE2EgotR"
|
|
22934
|
-
}
|
|
22935
|
-
}, (context, definition) => new SushiSwapV3(context, definition, new UniswapV3DataAdapter(definition.dataAdapter, definition.contracts.factory.address, context.indexerRequest)));
|
|
22936
|
-
//#endregion
|
|
22937
22974
|
//#region src/vault/adapters/uniswap-v3/identity.ts
|
|
22938
22975
|
const baseV3VaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
22939
22976
|
beacon: "0xDf0b9Ef4d7C4E294A74efB4407129bd66e4f82f0",
|
|
@@ -22942,6 +22979,14 @@ const baseV3VaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
|
22942
22979
|
implementationCodeHash: "0x9fff8189bb2dd53465e6cb2bee210b941b7b37dee5ca30ee6eac3463ce871ff7",
|
|
22943
22980
|
helperCodeHash: "0x8d178d093d945e3d89a5ac57aa9f14a56d4446508557da168a5713496de77937"
|
|
22944
22981
|
}))();
|
|
22982
|
+
/** Migrated Base Sushi uses the qualified FeeManager/helper layout. */
|
|
22983
|
+
const baseSushiVaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
22984
|
+
...baseV3VaultIdentity,
|
|
22985
|
+
beacon: "0xb4f89b74aee9b9f1340835470fe4a6ed54e7fc11",
|
|
22986
|
+
implementation: "0x6270905CAb3fC7f9bAf13803Fa2F1111D14B8005",
|
|
22987
|
+
implementationCodeHash: "0xce1144e291dec2375eedebc3fd1032f41b107761031bcec1fcef02641c0bdaab",
|
|
22988
|
+
proxyCodeHashes: Object.freeze([baseV3VaultIdentity.proxyCodeHash, "0x925993ab444b9b69993f1a22416897ccc0eadff0f3681fee18ec0617efbc2f4f"])
|
|
22989
|
+
}))();
|
|
22945
22990
|
const beaconSlot = "0xa3f0ad74e5423aebfd80d3ef4346578335a9a72aeaee59ff6cb3582b35133d50";
|
|
22946
22991
|
const polygonV3VaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
22947
22992
|
feePolicy: "fixed",
|
|
@@ -22972,11 +23017,29 @@ const bscPancakeVaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
|
22972
23017
|
implementation: "0x588B34D2a9598497f481A9d31B4eD372C6135f32",
|
|
22973
23018
|
implementationCodeHash: "0xf5709c6a1fcfeb4488663da7f8182975d3adc7a07f0ed0f04b98d9488cae6a83"
|
|
22974
23019
|
}))();
|
|
23020
|
+
const bscSushiVaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
23021
|
+
...polygonV3VaultIdentity,
|
|
23022
|
+
feeRounding: "aggregate",
|
|
23023
|
+
beacon: "0x33553c0914e1dc95de011f26f438a599df56f268",
|
|
23024
|
+
implementation: "0xE11709193e7b2E0a0F2a4591022cFf4f01E75050",
|
|
23025
|
+
implementationCodeHash: "0x10d00977df1a122495edb85c60972f2ffb92240f14a3770461cd32372e6b4570"
|
|
23026
|
+
}))();
|
|
23027
|
+
const bscV3VaultIdentity = /* @__PURE__ */ (() => Object.freeze({
|
|
23028
|
+
...polygonV3VaultIdentity,
|
|
23029
|
+
feeRounding: "aggregate",
|
|
23030
|
+
beacon: "0x05ac33a55366a61fed4b0720946691c9faebcbb0",
|
|
23031
|
+
implementation: "0x16BA7102271dC83Fff2f709691c2B601DAD7668e",
|
|
23032
|
+
implementationCodeHash: "0x6cc14caa5a81aea294c4913dfcf437aa9d6528084ca4835ac87f036e424b2da0"
|
|
23033
|
+
}))();
|
|
22975
23034
|
const qualifiedVaults = /* @__PURE__ */ (() => Object.freeze([
|
|
22976
23035
|
{
|
|
22977
23036
|
amm: uniswapV3Base,
|
|
22978
23037
|
identity: baseV3VaultIdentity
|
|
22979
23038
|
},
|
|
23039
|
+
{
|
|
23040
|
+
amm: sushiswapV3Base,
|
|
23041
|
+
identity: baseSushiVaultIdentity
|
|
23042
|
+
},
|
|
22980
23043
|
{
|
|
22981
23044
|
amm: uniswapV3Polygon,
|
|
22982
23045
|
identity: polygonV3VaultIdentity
|
|
@@ -22992,10 +23055,17 @@ const qualifiedVaults = /* @__PURE__ */ (() => Object.freeze([
|
|
|
22992
23055
|
{
|
|
22993
23056
|
amm: pancakeSwapV3Bsc,
|
|
22994
23057
|
identity: bscPancakeVaultIdentity
|
|
23058
|
+
},
|
|
23059
|
+
{
|
|
23060
|
+
amm: sushiswapV3Bsc,
|
|
23061
|
+
identity: bscSushiVaultIdentity
|
|
23062
|
+
},
|
|
23063
|
+
{
|
|
23064
|
+
amm: uniswapV3Bsc,
|
|
23065
|
+
identity: bscV3VaultIdentity
|
|
22995
23066
|
}
|
|
22996
23067
|
]))();
|
|
22997
23068
|
function v3VaultIdentity(chainId, factory) {
|
|
22998
|
-
if (chainId === 8453) return baseV3VaultIdentity;
|
|
22999
23069
|
const qualified = qualifiedVaults.find(({ amm }) => amm.definition.chainId === chainId && sameAddress(factory, amm.definition.contracts.factory.address));
|
|
23000
23070
|
if (qualified) return qualified.identity;
|
|
23001
23071
|
throw new Error("V3 vault identity is not configured for this chain/factory");
|
|
@@ -24210,8 +24280,19 @@ async function executeV3VaultReader(context, args, mode) {
|
|
|
24210
24280
|
}
|
|
24211
24281
|
async function readV3VaultSnapshot(context, rpc, pool, factory) {
|
|
24212
24282
|
const storage = await readVaultStorage(context);
|
|
24283
|
+
const identity = v3VaultIdentity(rpc.chainId, factory);
|
|
24284
|
+
let proxyCodeHash = identity.proxyCodeHash;
|
|
24285
|
+
if (identity.feePolicy !== "fixed" && identity.proxyCodeHashes) {
|
|
24286
|
+
const code = await vaultRpc(context).getCode({
|
|
24287
|
+
address: context.address,
|
|
24288
|
+
blockNumber: context.blockNumber
|
|
24289
|
+
});
|
|
24290
|
+
if (!code || !identity.proxyCodeHashes.includes(keccak256(code))) identityMismatch("Unsupported vault contract code");
|
|
24291
|
+
proxyCodeHash = keccak256(code);
|
|
24292
|
+
}
|
|
24213
24293
|
const expected = {
|
|
24214
|
-
...
|
|
24294
|
+
...identity,
|
|
24295
|
+
proxyCodeHash,
|
|
24215
24296
|
factory,
|
|
24216
24297
|
pool
|
|
24217
24298
|
};
|
|
@@ -24630,6 +24711,66 @@ const bscPancakeVaultProtocol = /* @__PURE__ */ (() => Object.freeze({
|
|
|
24630
24711
|
protocolAddress: pancakeSwapV3Bsc.definition.contracts.factory.address,
|
|
24631
24712
|
deployment: pancakeSwapV3Bsc
|
|
24632
24713
|
}))();
|
|
24714
|
+
const bscSushiVaultDiscovery = /* @__PURE__ */ (() => Object.freeze({
|
|
24715
|
+
amm: sushiswapV3Bsc,
|
|
24716
|
+
beaconNames: Object.freeze(["MultiPositionSushi"])
|
|
24717
|
+
}))();
|
|
24718
|
+
const bscSushiVaultBinding = /* @__PURE__ */ (() => Object.freeze({
|
|
24719
|
+
readUnderlying: (context) => readUnderlyingForFactory(context, sushiswapV3Bsc.definition.contracts.factory.address),
|
|
24720
|
+
beaconNames: bscSushiVaultDiscovery.beaconNames,
|
|
24721
|
+
kind: "liquidity",
|
|
24722
|
+
readSnapshot: readV3VaultAccounting,
|
|
24723
|
+
createVault: (context) => new UniswapV3Vault(context),
|
|
24724
|
+
beaconAddress: bscSushiVaultIdentity.beacon,
|
|
24725
|
+
implementationAddress: bscSushiVaultIdentity.implementation,
|
|
24726
|
+
implementationCodeHash: bscSushiVaultIdentity.implementationCodeHash
|
|
24727
|
+
}))();
|
|
24728
|
+
const bscSushiVaultProtocol = /* @__PURE__ */ (() => Object.freeze({
|
|
24729
|
+
kind: "liquidity",
|
|
24730
|
+
role: "amm-factory",
|
|
24731
|
+
protocolAddress: sushiswapV3Bsc.definition.contracts.factory.address,
|
|
24732
|
+
deployment: sushiswapV3Bsc
|
|
24733
|
+
}))();
|
|
24734
|
+
const bscV3VaultDiscovery = /* @__PURE__ */ (() => Object.freeze({
|
|
24735
|
+
amm: uniswapV3Bsc,
|
|
24736
|
+
beaconNames: Object.freeze(["MultiPositionUniswapV3"])
|
|
24737
|
+
}))();
|
|
24738
|
+
const bscV3VaultBinding = /* @__PURE__ */ (() => Object.freeze({
|
|
24739
|
+
readUnderlying: (context) => readUnderlyingForFactory(context, uniswapV3Bsc.definition.contracts.factory.address),
|
|
24740
|
+
beaconNames: bscV3VaultDiscovery.beaconNames,
|
|
24741
|
+
kind: "liquidity",
|
|
24742
|
+
readSnapshot: readV3VaultAccounting,
|
|
24743
|
+
createVault: (context) => new UniswapV3Vault(context),
|
|
24744
|
+
beaconAddress: bscV3VaultIdentity.beacon,
|
|
24745
|
+
implementationAddress: bscV3VaultIdentity.implementation,
|
|
24746
|
+
implementationCodeHash: bscV3VaultIdentity.implementationCodeHash
|
|
24747
|
+
}))();
|
|
24748
|
+
const bscV3VaultProtocol = /* @__PURE__ */ (() => Object.freeze({
|
|
24749
|
+
kind: "liquidity",
|
|
24750
|
+
role: "amm-factory",
|
|
24751
|
+
protocolAddress: uniswapV3Bsc.definition.contracts.factory.address,
|
|
24752
|
+
deployment: uniswapV3Bsc
|
|
24753
|
+
}))();
|
|
24754
|
+
const baseSushiVaultDiscovery = /* @__PURE__ */ (() => Object.freeze({
|
|
24755
|
+
amm: sushiswapV3Base,
|
|
24756
|
+
beaconNames: Object.freeze(["MultiPositionSushi"])
|
|
24757
|
+
}))();
|
|
24758
|
+
const baseSushiVaultBinding = /* @__PURE__ */ (() => Object.freeze({
|
|
24759
|
+
readUnderlying: (context) => readUnderlyingForFactory(context, sushiswapV3Base.definition.contracts.factory.address),
|
|
24760
|
+
beaconNames: baseSushiVaultDiscovery.beaconNames,
|
|
24761
|
+
kind: "liquidity",
|
|
24762
|
+
readSnapshot: readV3VaultAccounting,
|
|
24763
|
+
createVault: (context) => new UniswapV3Vault(context),
|
|
24764
|
+
beaconAddress: baseSushiVaultIdentity.beacon,
|
|
24765
|
+
implementationAddress: baseSushiVaultIdentity.implementation,
|
|
24766
|
+
implementationCodeHash: baseSushiVaultIdentity.implementationCodeHash
|
|
24767
|
+
}))();
|
|
24768
|
+
const baseSushiVaultProtocol = /* @__PURE__ */ (() => Object.freeze({
|
|
24769
|
+
kind: "liquidity",
|
|
24770
|
+
role: "amm-factory",
|
|
24771
|
+
protocolAddress: sushiswapV3Base.definition.contracts.factory.address,
|
|
24772
|
+
deployment: sushiswapV3Base
|
|
24773
|
+
}))();
|
|
24633
24774
|
//#endregion
|
|
24634
24775
|
//#region src/vault/deployments/base.ts
|
|
24635
24776
|
function createBaseVaultResolver() {
|
|
@@ -24654,7 +24795,16 @@ function createBaseVaultResolver() {
|
|
|
24654
24795
|
snapshotRuntime: integralVaultBatchReaderRuntime,
|
|
24655
24796
|
readSnapshot: readIntegralBulkSnapshot
|
|
24656
24797
|
},
|
|
24657
|
-
...baseAerodromeVaultMappings
|
|
24798
|
+
...baseAerodromeVaultMappings,
|
|
24799
|
+
{
|
|
24800
|
+
identity: baseSushiVaultIdentity,
|
|
24801
|
+
factory: sushiswapV3Base.definition.contracts.factory.address,
|
|
24802
|
+
runtime: v3VaultResolutionReaderRuntime,
|
|
24803
|
+
binding: baseSushiVaultBinding,
|
|
24804
|
+
snapshotRuntime: v3VaultBatchReaderRuntime,
|
|
24805
|
+
helperCodeHash: baseSushiVaultIdentity.helperCodeHash,
|
|
24806
|
+
readSnapshot: readV3BulkSnapshot
|
|
24807
|
+
}
|
|
24658
24808
|
];
|
|
24659
24809
|
return Object.freeze({
|
|
24660
24810
|
reader: {
|
|
@@ -24677,12 +24827,14 @@ function createBaseVaultResolver() {
|
|
|
24677
24827
|
implementations: Object.freeze([
|
|
24678
24828
|
...baseV3VaultResolver.implementations,
|
|
24679
24829
|
...baseAerodromeVaultMappings.map((mapping) => mapping.binding),
|
|
24680
|
-
baseIntegralVaultBinding
|
|
24830
|
+
baseIntegralVaultBinding,
|
|
24831
|
+
baseSushiVaultBinding
|
|
24681
24832
|
]),
|
|
24682
24833
|
protocols: Object.freeze([
|
|
24683
24834
|
...baseV3VaultResolver.protocols,
|
|
24684
24835
|
baseIntegralVaultProtocol,
|
|
24685
|
-
...baseAerodromeVaultProtocols
|
|
24836
|
+
...baseAerodromeVaultProtocols,
|
|
24837
|
+
baseSushiVaultProtocol
|
|
24686
24838
|
])
|
|
24687
24839
|
});
|
|
24688
24840
|
}
|
|
@@ -24699,6 +24851,7 @@ var base_default = /* @__PURE__ */ defineSteerNetwork({
|
|
|
24699
24851
|
}
|
|
24700
24852
|
}, baseContracts, "https://api.subgraph.ormilabs.com/api/public/803c8c8c-be12-4188-8523-b9853e23051d/subgraphs/steer-protocol-base/beta/gn", [
|
|
24701
24853
|
uniswapV3Base,
|
|
24854
|
+
sushiswapV3Base,
|
|
24702
24855
|
uniswapV4Base,
|
|
24703
24856
|
quickSwapIntegralBase,
|
|
24704
24857
|
aerodromeSlipstreamBase,
|
|
@@ -24707,6 +24860,7 @@ var base_default = /* @__PURE__ */ defineSteerNetwork({
|
|
|
24707
24860
|
], /* @__PURE__ */ createBaseVaultResolver(), /* @__PURE__ */ (() => Object.freeze([
|
|
24708
24861
|
...baseAerodromeVaultDiscovery,
|
|
24709
24862
|
baseV3VaultDiscovery,
|
|
24863
|
+
baseSushiVaultDiscovery,
|
|
24710
24864
|
baseIntegralVaultDiscovery
|
|
24711
24865
|
]))());
|
|
24712
24866
|
//#endregion
|
|
@@ -25926,14 +26080,33 @@ async function readV4BulkSnapshot(vault, data, rpc) {
|
|
|
25926
26080
|
}
|
|
25927
26081
|
//#endregion
|
|
25928
26082
|
//#region src/vault/deployments/bsc.ts
|
|
25929
|
-
const mappings = /* @__PURE__ */ (() => Object.freeze([
|
|
25930
|
-
|
|
25931
|
-
|
|
25932
|
-
|
|
25933
|
-
|
|
25934
|
-
|
|
25935
|
-
|
|
25936
|
-
|
|
26083
|
+
const mappings = /* @__PURE__ */ (() => Object.freeze([
|
|
26084
|
+
{
|
|
26085
|
+
identity: bscPancakeVaultIdentity,
|
|
26086
|
+
factory: pancakeSwapV3Bsc.definition.contracts.factory.address,
|
|
26087
|
+
runtime: v3VaultResolutionReaderRuntime,
|
|
26088
|
+
snapshotRuntime: fixedFeeV3VaultBatchReaderRuntime,
|
|
26089
|
+
binding: bscPancakeVaultBinding,
|
|
26090
|
+
readSnapshot: readV3BulkSnapshot
|
|
26091
|
+
},
|
|
26092
|
+
...[{
|
|
26093
|
+
identity: bscSushiVaultIdentity,
|
|
26094
|
+
binding: bscSushiVaultBinding,
|
|
26095
|
+
amm: sushiswapV3Bsc
|
|
26096
|
+
}, {
|
|
26097
|
+
identity: bscV3VaultIdentity,
|
|
26098
|
+
binding: bscV3VaultBinding,
|
|
26099
|
+
amm: uniswapV3Bsc
|
|
26100
|
+
}].map(({ identity, binding, amm }) => ({
|
|
26101
|
+
identity,
|
|
26102
|
+
binding,
|
|
26103
|
+
factory: amm.definition.contracts.factory.address,
|
|
26104
|
+
runtime: v3VaultResolutionReaderRuntime,
|
|
26105
|
+
snapshotRuntime: fixedFeeV3VaultBatchReaderRuntime,
|
|
26106
|
+
readSnapshot: readV3BulkSnapshot
|
|
26107
|
+
})),
|
|
26108
|
+
v4BulkMapping(bscV4VaultIdentity, bscV4VaultBinding, uniswapV4Bsc.definition.contracts)
|
|
26109
|
+
]))();
|
|
25937
26110
|
//#endregion
|
|
25938
26111
|
//#region src/catalog/bsc.ts
|
|
25939
26112
|
var bsc_default = /* @__PURE__ */ defineSteerNetwork({
|
|
@@ -25947,7 +26120,9 @@ var bsc_default = /* @__PURE__ */ defineSteerNetwork({
|
|
|
25947
26120
|
}, bscContracts, "https://api.subgraph.ormilabs.com/api/public/803c8c8c-be12-4188-8523-b9853e23051d/subgraphs/steer-protocol-bsc-beta/prod/gn", [
|
|
25948
26121
|
pancakeSwapV3Bsc,
|
|
25949
26122
|
pancakeSwapInfinityCLBsc,
|
|
25950
|
-
uniswapV4Bsc
|
|
26123
|
+
uniswapV4Bsc,
|
|
26124
|
+
sushiswapV3Bsc,
|
|
26125
|
+
uniswapV3Bsc
|
|
25951
26126
|
], /* @__PURE__ */ (() => Object.freeze({
|
|
25952
26127
|
reader: {
|
|
25953
26128
|
readMany: (contexts, allowFailure) => readBulkVaults(contexts, mappings, allowFailure),
|
|
@@ -25959,14 +26134,29 @@ var bsc_default = /* @__PURE__ */ defineSteerNetwork({
|
|
|
25959
26134
|
await readContext(context.steer.context, { blockNumber: context.blockNumber });
|
|
25960
26135
|
const identity = await readRegisteredVaultIdentity(context);
|
|
25961
26136
|
if (!identity) return null;
|
|
25962
|
-
if (
|
|
26137
|
+
if (findV3VaultIdentity(context.steer.context.chainId, identity.beaconAddress, identity.implementationAddress)) await verifyV3Identity(context, identity);
|
|
25963
26138
|
else await verifyV4VaultIdentity(context, identity);
|
|
25964
26139
|
return identity;
|
|
25965
26140
|
}
|
|
25966
26141
|
},
|
|
25967
|
-
implementations: Object.freeze([
|
|
25968
|
-
|
|
25969
|
-
|
|
26142
|
+
implementations: Object.freeze([
|
|
26143
|
+
bscPancakeVaultBinding,
|
|
26144
|
+
bscSushiVaultBinding,
|
|
26145
|
+
bscV3VaultBinding,
|
|
26146
|
+
bscV4VaultBinding
|
|
26147
|
+
]),
|
|
26148
|
+
protocols: Object.freeze([
|
|
26149
|
+
bscPancakeVaultProtocol,
|
|
26150
|
+
bscSushiVaultProtocol,
|
|
26151
|
+
bscV3VaultProtocol,
|
|
26152
|
+
bscV4VaultProtocol
|
|
26153
|
+
])
|
|
26154
|
+
}))(), /* @__PURE__ */ Object.freeze([
|
|
26155
|
+
bscPancakeVaultDiscovery,
|
|
26156
|
+
bscSushiVaultDiscovery,
|
|
26157
|
+
bscV3VaultDiscovery,
|
|
26158
|
+
bscV4VaultDiscovery
|
|
26159
|
+
]));
|
|
25970
26160
|
//#endregion
|
|
25971
26161
|
//#region src/catalog/celo.ts
|
|
25972
26162
|
var celo_default = /* @__PURE__ */ defineSteerNetwork({
|