From 72e96623920261f9064db28932c755fcef5c68f6 Mon Sep 17 00:00:00 2001 From: Ss5h Date: Wed, 25 Oct 2023 16:35:08 +0900 Subject: [PATCH] add everdex project, update bfc core Asset --- projects/everdex/index.js | 29 +++++++++++++++++++++++++++++ projects/helper/coreAssets.json | 4 +++- projects/helper/tokenMapping.js | 6 ++++++ 3 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 projects/everdex/index.js diff --git a/projects/everdex/index.js b/projects/everdex/index.js new file mode 100644 index 000000000000..66da98510dae --- /dev/null +++ b/projects/everdex/index.js @@ -0,0 +1,29 @@ +const ADDRESSES = require('../helper/coreAssets.json'); +const { getUniTVL } = require("../helper/unknownTokens"); +const { sumTokens2, } = require('../helper/unwrapLPs'); +const sdk = require('@defillama/sdk'); + +const chain = 'bfc' + +// 3-pools +const tokensAndOwners = [ + // stablePoolDaiUsdcUsdt + [ADDRESSES.bfc.UnifiedDAI, '0xa455434802d8B530C77d2B7547eF93C798896581'], + [ADDRESSES.bfc.UnifiedUSDC, '0xa455434802d8B530C77d2B7547eF93C798896581'], + [ADDRESSES.bfc.UnifiedUSDT, '0xa455434802d8B530C77d2B7547eF93C798896581'], +] + +async function tvl() { + return sumTokens2({ tokensAndOwners, chain }); +} + +const uniTVL = getUniTVL({ factory: '0x19f21b0AB98EC10d734E314356Ad562ae349177d', useDefaultCoreAssets: true}); + + +module.exports = { + misrepresentedTokens: true, + start: 1674864000, + bfc: { + tvl: sdk.util.sumChainTvls([tvl, uniTVL]) + }, +}; \ No newline at end of file diff --git a/projects/helper/coreAssets.json b/projects/helper/coreAssets.json index 2d16dbdf4e03..82c584acdda9 100644 --- a/projects/helper/coreAssets.json +++ b/projects/helper/coreAssets.json @@ -1451,12 +1451,14 @@ "USDT": "0x999f90f25a2922ae1b21A06066F7EDEbedad42a9" }, "bfc": { + "WBFC": "0x1c1b06405058AbE02e4748753aeD1458BEFEE3B9", "UnifiedETH": "0x6c9944674C1D2cF6c4c4999FC7290Ba105dcd70e", "UnifiedBNB": "0xB800EaF843F962DFe5e145A8c9D07A3e70b11d7F", "UnifiedUSDC": "0x640952E7984f2ECedeAd8Fd97aA618Ab1210A21C", "UnifiedMATIC": "0x21ad243b81eff53482F6F6E7C76539f2CfC0B734", "UnifiedUSDT": "0x3eA8654d5755e673599473ab37d92788B5bA12aE", - "UnifiedDAI": "0xcDB9579Db96EB5C8298dF889D915D0FF668AfF2a" + "UnifiedDAI": "0xcDB9579Db96EB5C8298dF889D915D0FF668AfF2a", + "BIFI": "0x047938C3aD13c1eB821C8e310B2B6F889b6d0003" }, "scroll": { "WETH": "0x5300000000000000000000000000000000000004", diff --git a/projects/helper/tokenMapping.js b/projects/helper/tokenMapping.js index bea1ae7636bc..dc8211fe011f 100644 --- a/projects/helper/tokenMapping.js +++ b/projects/helper/tokenMapping.js @@ -66,6 +66,12 @@ const fixBalancesTokens = { }, elsm: { '0xa801b1a7846156d4c81bd188f96bfcb621517611': { coingeckoId: 'vulcan-forged', decimals: 18 }, + }, + bfc: { + [ADDRESSES.bfc.WBFC]: { coingeckoId: 'bifrost', decimals: 18}, + [ADDRESSES.bfc.BIFI]: { coingeckoId: 'bifi', decimals: 18}, + '0xB1f3A83597Bce2AD842c29bD750AE17afc474137': {coingeckoId: 'witch-token', decimals: 18}, + '0x17102AC78a02a98fC78B0c29B7b0506f035A99E5': {coingeckoId: 'super-athletes-token', decimals: 18} } }