diff --git a/package.json b/package.json index 982998f9..9cbe5a3f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@curvefi/api", - "version": "2.53.4", + "version": "2.53.5", "description": "JavaScript library for curve.fi", "main": "lib/index.js", "author": "Macket", diff --git a/src/constants/pools/ethereum.ts b/src/constants/pools/ethereum.ts index b8d6c94c..1013510b 100644 --- a/src/constants/pools/ethereum.ts +++ b/src/constants/pools/ethereum.ts @@ -1705,4 +1705,134 @@ export const LLAMMAS_DATA_ETHEREUM: IDict = lowerCasePoolDataAddresse swap_abi: LlammaABI, gauge_abi: gaugeV5ABI, }, + "wsteth-llamma": { + name: "wsteth", + full_name: "wsteth", + symbol: "wsteth", + reference_asset: "CRYPTO", + swap_address: '0x37417b2238aa52d0dd2d6252d989e728e8f706e4', + token_address: '0x0000000000000000000000000000000000000000', + gauge_address: '0x0000000000000000000000000000000000000000', + is_crypto: true, + is_plain: true, + is_llamma: true, + underlying_coins: ['crvUSD', 'wstETH'], + wrapped_coins: ['crvUSD', 'wstETH'], + underlying_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0', + ], + wrapped_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0x7f39C581F595B53c5cb19bD0b3f8dA6c935E2Ca0', + ], + underlying_decimals: [18, 18], + wrapped_decimals: [18, 18], + swap_abi: LlammaABI, + gauge_abi: gaugeV5ABI, + }, + "wbtc-llamma": { + name: "wbtc", + full_name: "wbtc", + symbol: "wbtc", + reference_asset: "CRYPTO", + swap_address: '0xe0438eb3703bf871e31ce639bd351109c88666ea', + token_address: '0x0000000000000000000000000000000000000000', + gauge_address: '0x0000000000000000000000000000000000000000', + is_crypto: true, + is_plain: true, + is_llamma: true, + underlying_coins: ['crvUSD', 'WBTC'], + wrapped_coins: ['crvUSD', 'WBTC'], + underlying_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0x2260fac5e5542a773aa44fbcfedf7c193bc2c599', + ], + wrapped_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0x2260fac5e5542a773aa44fbcfedf7c193bc2c599', + ], + underlying_decimals: [18, 8], + wrapped_decimals: [18, 8], + swap_abi: LlammaABI, + gauge_abi: gaugeV5ABI, + }, + "weth-llamma": { + name: "weth", + full_name: "weth", + symbol: "weth", + reference_asset: "CRYPTO", + swap_address: '0x1681195c176239ac5e72d9aebacf5b2492e0c4ee', + token_address: '0x0000000000000000000000000000000000000000', + gauge_address: '0x0000000000000000000000000000000000000000', + is_crypto: true, + is_plain: true, + is_llamma: true, + underlying_coins: ['crvUSD', 'WETH'], + wrapped_coins: ['crvUSD', 'WETH'], + underlying_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2', + ], + wrapped_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2', + ], + underlying_decimals: [18, 18], + wrapped_decimals: [18, 18], + swap_abi: LlammaABI, + gauge_abi: gaugeV5ABI, + }, + "sfrxeth2-llamma": { + name: "sfrxeth2", + full_name: "sfrxeth2", + symbol: "sfrxeth2", + reference_asset: 'CRYPTO', + swap_address: '0xfa96ad0a9e64261db86950e2da362f5572c5c6fd', + token_address: '0x0000000000000000000000000000000000000000', + gauge_address: '0x0000000000000000000000000000000000000000', + is_crypto: true, + is_plain: true, + is_llamma: true, + underlying_coins: ['crvUSD', 'sfrxETH'], + wrapped_coins: ['crvUSD', 'sfrxETH'], + underlying_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0xac3E018457B222d93114458476f3E3416Abbe38F', + ], + wrapped_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0xac3E018457B222d93114458476f3E3416Abbe38F', + ], + underlying_decimals: [18, 18], + wrapped_decimals: [18, 18], + swap_abi: LlammaABI, + gauge_abi: gaugeV5ABI, + }, + "tbtc-llamma": { + name: "tbtc", + full_name: "tbtc", + symbol: "tbtc", + reference_asset: "CRYPTO", + swap_address: '0xf9bd9da2427a50908c4c6d1599d8e62837c2bcb0', + token_address: '0x0000000000000000000000000000000000000000', + gauge_address: '0x0000000000000000000000000000000000000000', + is_crypto: true, + is_plain: true, + is_llamma: true, + underlying_coins: ['crvUSD', 'tBTC'], + wrapped_coins: ['crvUSD', 'tBTC'], + underlying_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0x18084fba666a33d37592fa2633fd49a74dd93a88', + ], + wrapped_coin_addresses: [ + '0xf939E0A03FB07F59A73314E73794Be0E57ac1b4E', + '0x18084fba666a33d37592fa2633fd49a74dd93a88', + ], + underlying_decimals: [18, 18], + wrapped_decimals: [18, 18], + swap_abi: LlammaABI, + gauge_abi: gaugeV5ABI, + }, }); diff --git a/src/router.ts b/src/router.ts index 22b326e1..a381b592 100644 --- a/src/router.ts +++ b/src/router.ts @@ -230,7 +230,7 @@ const _buildRouteGraph = memoize(async (): Promise>> = } } - const ALL_POOLS = Object.entries(curve.getPoolsData()).filter(([id, _]) => id !== "crveth"); + const ALL_POOLS = Object.entries(curve.getPoolsData()).filter(([id, _]) => !["crveth", "y", "busd", "pax"].includes(id)); const amplificationCoefficientDict = await _getAmplificationCoefficientsFromApi(); for (const [poolId, poolData] of ALL_POOLS) { const wrappedCoinAddresses = poolData.wrapped_coin_addresses.map((a: string) => a.toLowerCase()); @@ -260,7 +260,7 @@ const _buildRouteGraph = memoize(async (): Promise>> = if (curve.chainId === 1 && tvl < 1000) continue; if (curve.chainId !== 1 && tvl < 100) continue; - const excludedUnderlyingSwaps = (poolId === 'aave' && curve.chainId === 1) || (poolId === 'geist' && curve.chainId === 250); + const excludedUnderlyingSwaps = (poolId === 'ib' && curve.chainId === 1) || (poolId === 'geist' && curve.chainId === 250); // Wrapped coin <-> LP "swaps" (actually add_liquidity/remove_liquidity_one_coin) if (!poolData.is_fake && !poolData.is_llamma && wrappedCoinAddresses.length < 6) {