Skip to content

Commit

Permalink
Add curve eBTC
Browse files Browse the repository at this point in the history
  • Loading branch information
roman-monk committed Aug 13, 2024
1 parent 9e08fee commit 0d8fe8e
Show file tree
Hide file tree
Showing 5 changed files with 46 additions and 19 deletions.
13 changes: 13 additions & 0 deletions packages/address-book/src/address-book/ethereum/tokens/tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2094,6 +2094,19 @@ export const tokens = {
bridge: 'native',
documentation: 'https://docs.stake.link/',
},
eBTC: {
name: 'eBTC',
symbol: 'eBTC',
oracleId: 'eBTC',
address: '0x661c70333AA1850CcDBAe82776Bb436A0fCfeEfB',
chainId: 1,
decimals: 18,
website: 'https://www.ebtc.finance/',
description:
"eBTC is a collateralized crypto asset soft pegged to the price of Bitcoin and built on the Ethereum network. It is backed exclusively by Lido's stETH and powered by immutable smart contracts with minimized counterparty reliance. It is designed to be the most decentralized synthetic Bitcoin in DeFi and offers the ability for anyone in the world to borrow BTC at no cost.",
bridge: 'native',
documentation: 'https://docs.ebtc.finance/ebtc',
},
'USD0++': {
name: 'USD0 Liquid Bond',
symbol: 'USD0++',
Expand Down
7 changes: 6 additions & 1 deletion src/api/stats/common/getCowVaultApys.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import { getCowProviderForClm } from '../../cowcentrated/providers';
import { getCampaignsForChain } from '../../offchain-rewards';
import { Campaign } from '../../offchain-rewards/types';
import { OptionalRecord } from '../../../utils/object';
import { envBoolean } from '../../../utils/env';

type OffchainVaultApr = {
total: number;
Expand All @@ -28,13 +29,17 @@ type RewardPoolApr = {
total: number;
};

const THROW_ON_EMPTY_COW_META: boolean = envBoolean('THROW_ON_EMPTY_COW_META', true);

/**
* Base CLMs + Reward Pools
*/
export const getCowApys = async (apiChain: ApiChain) => {
const clms = getCowVaultsMeta(apiChain);
if (!clms.length) {
throw new Error(`No clms found for ${apiChain}`);
if (THROW_ON_EMPTY_COW_META) {
throw new Error(`No clms found for ${apiChain}`);
} else return {};
}

const offchainCampaignsByVault = await getOffchainCampaignsByVault(apiChain);
Expand Down
2 changes: 2 additions & 0 deletions src/api/stats/getAmmPrices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -640,6 +640,8 @@ const coinGeckoCoins: Record<string, string[]> = {
'helio-protocol-hay': ['lisUSD'],
'usual-usd': ['USD0'],
'usd0-liquid-bond': ['USD0++'],
'badger-dao': ['BADGER'],
'overnight-finance': ['oOVN'],
'dinero-staked-eth': ['pxETH'],
};

Expand Down
18 changes: 0 additions & 18 deletions src/data/archive/oldLpPools.json
Original file line number Diff line number Diff line change
Expand Up @@ -1049,24 +1049,6 @@
"decimals": "1e0"
}
},
{
"name": "boo-ftm-badger",
"address": "0x1c94665FD3ecFa969Feda7Ed01e35522e6982022",
"decimals": "1e18",
"chainId": 250,
"lp0": {
"address": "0x21be370D5312f44cB42ce377BC9b8a0cEF1A4C83",
"oracle": "tokens",
"oracleId": "WFTM",
"decimals": "1e18"
},
"lp1": {
"address": "0x753fbc5800a8C8e3Fb6DC6415810d627A387Dfc9",
"oracle": "tokens",
"oracleId": "BADGER",
"decimals": "1e18"
}
},
{
"name": "boo-ftm-band",
"address": "0x91b39D5584e2A7DC829f696235742cc293F2e8cf",
Expand Down
25 changes: 25 additions & 0 deletions src/data/ethereum/convexPools.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,29 @@
[
{
"name": "curve-ebtc-tbtc",
"pool": "0x272bf7e4ce3308b1fb5e54d6a1fc32113619c401",
"gauge": "0x48727018d010dc2e414c5a14d588385ae112869e",
"rewardPool": "0xDbd17Dc03a442D4349de988533737db3fBb5eC39",
"getDy": ["v1", 0, 1],
"extras": [
{
"rewardPool": "0x129583e1a5E9c2C1b3afD086970811aF736fc17e",
"oracleId": "BADGER"
}
],
"tokens": [
{
"oracle": "tokens",
"oracleId": "eBTC",
"decimals": "1e18"
},
{
"oracle": "tokens",
"oracleId": "tBTC",
"decimals": "1e18"
}
]
},
{
"name": "curve-thusd-crvusd",
"pool": "0x9e641187391b7a5fe9ee193359408ca3894f68a2",
Expand Down

0 comments on commit 0d8fe8e

Please sign in to comment.