Skip to content

Commit

Permalink
Add BSC deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
philippe-git committed Nov 4, 2023
1 parent a730054 commit 09849d8
Show file tree
Hide file tree
Showing 6 changed files with 479 additions and 115 deletions.
216 changes: 112 additions & 104 deletions constants/coins/coins.js
Original file line number Diff line number Diff line change
Expand Up @@ -620,109 +620,117 @@ module.exports = {
decimals: 18,
},
mim: {
id: 'mim',
coingeckoId: 'magic-internet-money',
type: REFERENCE_ASSETS.USD,
symbol: 'MIM',
decimals: 18,
address: '0x99d8a9c45b2eca8864373a26d1459e3dff1e17f3',
},
spell: {
id: 'spell',
coingeckoId: 'spell-token',
type: REFERENCE_ASSETS.SPELL,
symbol: 'SPELL',
decimals: 18,
address: '0x090185f2135308bad17527004364ebcc2d37e5f6',
},
t: {
id: 't',
coingeckoId: 'threshold-network-token',
type: REFERENCE_ASSETS.T,
symbol: 'T',
decimals: 18,
address: '0xCdF7028ceAB81fA0C6971208e83fa7872994beE5',
},
crv: {
id: 'crv',
coingeckoId: 'curve-dao-token',
type: REFERENCE_ASSETS.CRV,
symbol: 'CRV',
decimals: 18,
address: '0xd533a949740bb3306d119cc777fa900ba034cd52',
},
eurt: {
id: 'eurt',
coingeckoId: 'tether-eurt',
type: REFERENCE_ASSETS.EUR,
symbol: 'EURT',
decimals: 6,
address: '0xC581b735A1688071A1746c968e0798D642EDE491',
},
rai: {
id: 'rai',
coingeckoId: 'rai',
type: REFERENCE_ASSETS.OTHER,
symbol: 'RAI',
decimals: 18,
address: '0x03ab458634910aad20ef5f1c8ee96f1d6ac54919',
},
cvx: {
id: 'cvx',
coingeckoId: 'convex-finance',
type: REFERENCE_ASSETS.CVX,
symbol: 'CVX',
decimals: 18,
address: '0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b',
},
xaut: {
id: 'xaut',
coingeckoId: 'tether-gold',
type: REFERENCE_ASSETS.OTHER,
symbol: 'XAUt',
decimals: 6,
address: '0x68749665ff8d2d112fa859aa293f07a622782f38',
},
spell: {
id: 'spell',
coingeckoId: 'spell-token',
type: REFERENCE_ASSETS.SPELL,
symbol: 'SPELL',
decimals: 18,
address: '0x090185f2135308bad17527004364ebcc2d37e5f6',
},
t: {
id: 't',
type: REFERENCE_ASSETS.T,
symbol: 'T',
coingeckoId: 'threshold-network-token',
decimals: 18,
address: '0xCdF7028ceAB81fA0C6971208e83fa7872994beE5',
},
id: 'mim',
coingeckoId: 'magic-internet-money',
type: REFERENCE_ASSETS.USD,
symbol: 'MIM',
decimals: 18,
address: '0x99d8a9c45b2eca8864373a26d1459e3dff1e17f3',
},
spell: {
id: 'spell',
coingeckoId: 'spell-token',
type: REFERENCE_ASSETS.SPELL,
symbol: 'SPELL',
decimals: 18,
address: '0x090185f2135308bad17527004364ebcc2d37e5f6',
},
t: {
id: 't',
coingeckoId: 'threshold-network-token',
type: REFERENCE_ASSETS.T,
symbol: 'T',
decimals: 18,
address: '0xCdF7028ceAB81fA0C6971208e83fa7872994beE5',
},
crv: {
id: 'crv',
coingeckoId: 'curve-dao-token',
type: REFERENCE_ASSETS.CRV,
symbol: 'CRV',
decimals: 18,
address: '0xd533a949740bb3306d119cc777fa900ba034cd52',
},
eurt: {
id: 'eurt',
coingeckoId: 'tether-eurt',
type: REFERENCE_ASSETS.EUR,
symbol: 'EURT',
decimals: 6,
address: '0xC581b735A1688071A1746c968e0798D642EDE491',
},
rai: {
id: 'rai',
coingeckoId: 'rai',
type: REFERENCE_ASSETS.OTHER,
symbol: 'RAI',
decimals: 18,
address: '0x03ab458634910aad20ef5f1c8ee96f1d6ac54919',
},
cvx: {
id: 'cvx',
coingeckoId: 'convex-finance',
type: REFERENCE_ASSETS.CVX,
symbol: 'CVX',
decimals: 18,
address: '0x4e3fbd56cd56c3e72c1403e103b45db9da5b9d2b',
},
xaut: {
id: 'xaut',
coingeckoId: 'tether-gold',
type: REFERENCE_ASSETS.OTHER,
symbol: 'XAUt',
decimals: 6,
address: '0x68749665ff8d2d112fa859aa293f07a622782f38',
},
spell: {
id: 'spell',
coingeckoId: 'spell-token',
type: REFERENCE_ASSETS.SPELL,
symbol: 'SPELL',
decimals: 18,
address: '0x090185f2135308bad17527004364ebcc2d37e5f6',
},
t: {
id: 't',
type: REFERENCE_ASSETS.T,
symbol: 'T',
coingeckoId: 'threshold-network-token',
decimals: 18,
address: '0xCdF7028ceAB81fA0C6971208e83fa7872994beE5',
},

// Sidechain coins
wmatic: {
id: 'wmatic',
type: REFERENCE_ASSETS.MATIC,
symbol: 'WMATIC',
decimals: 18,
address: '0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270',
coingeckoId: 'wmatic',
},
wftm: {
id: 'wftm',
type: REFERENCE_ASSETS.FTM,
symbol: 'WFTM',
decimals: 18,
address: '0x21be370d5312f44cb42ce377bc9b8a0cef1a4c83',
coingeckoId: 'wrapped-fantom',
},
wavax: {
id: 'wavax',
type: REFERENCE_ASSETS.AVAX,
symbol: 'WAVAX',
decimals: 18,
address: '0xb31f66aa3c1e785363f0875a1b74e27b85fd66c7',
coingeckoId: 'wrapped-avax',
},
// Sidechain coins
wmatic: {
id: 'wmatic',
type: REFERENCE_ASSETS.MATIC,
symbol: 'WMATIC',
decimals: 18,
address: '0x0d500b1d8e8ef31e21c99d1db9a6444d3adf1270',
coingeckoId: 'wmatic',
},
wftm: {
id: 'wftm',
type: REFERENCE_ASSETS.FTM,
symbol: 'WFTM',
decimals: 18,
address: '0x21be370d5312f44cb42ce377bc9b8a0cef1a4c83',
coingeckoId: 'wrapped-fantom',
},
wavax: {
id: 'wavax',
type: REFERENCE_ASSETS.AVAX,
symbol: 'WAVAX',
decimals: 18,
address: '0xb31f66aa3c1e785363f0875a1b74e27b85fd66c7',
coingeckoId: 'wrapped-avax',
},
wbnb: {
id: 'wbnb',
type: REFERENCE_ASSETS.BNB,
symbol: 'WBNB',
decimals: 18,
address: '0xbb4CdB9CBd36B01bD1cBaEBF2De08d9173bc095c',
coingeckoId: 'wrapped-bnb',
},
};
35 changes: 35 additions & 0 deletions constants/configs/configs.js
Original file line number Diff line number Diff line change
Expand Up @@ -569,5 +569,40 @@ const configs = {
approxBlocksPerDay: 43000, // Very approx from list of blocks on https://basescan.org/blocks
graphEndpoint: undefined, // Not supported by TheGraph's hosted service https://thegraph.com/docs/en/developing/supported-networks/
},
bsc: {
hasNoMainRegistry: true, // No main registry deployed nor address provider
poolsBaseUrlOld: null,
poolsBaseUrl: 'https://curve.fi/#/bsc/pools/',
shortId: 'bsc',
nativeCurrencySymbol: 'BNB',
chainId: 56,
nativeCurrencyCoingeckoId: 'binancecoin',
platformCoingeckoId: 'binance-smart-chain',
nativeAssetErc20WrapperId: 'wbnb', // Used by crypto facto, since it handles wrapped native as native
rpcUrl: `https://lb.drpc.org/ogrpc?network=bsc&dkey=${process.env.DRPC_API_KEY}`,
multicallAddress: '0xca11bde05977b3631167028862be2a173976ca11',
multicall2Address: '0xca11bde05977b3631167028862be2a173976ca11',
getFactoryRegistryAddress: async () => '0xEfDE221f306152971D8e9f181bFe998447975810',
getFactoryCryptoRegistryAddress: async () => '0xBd5fBd2FA58cB15228a9Abdac9ec994f79E3483C',
getFactoryTricryptoRegistryAddress: async () => '0xc55837710bc500F1E3c7bb9dd1d51F7c5647E657',
factoryImplementationAddressMap: new Map([
['0xB90B9B1F91a01Ea22A182CD84C1E22222e39B415'.toLowerCase(), 'plain2basic'],
['0x7CDE88e96E9445D986537074B1bFD32c5623c71f'.toLowerCase(), 'plain2balances'],
['0x5BD917879e04Cf18EC79285a1C960C5fbA7f5EA3'.toLowerCase(), 'plain2eth'],
['0x630C7Ad3998f397df0c0A8FfDB7a65B61ec5539E'.toLowerCase(), 'plain2optimized'],
['0xD166EEdf272B860E991d331B71041799379185D5'.toLowerCase(), 'plain3basic'],
['0x5C627d6925e448Ae418BC8a45d56B31fe5009Bea'.toLowerCase(), 'plain3balances'],
['0x22D710931F01c1681Ca1570Ff016eD42EB7b7c2a'.toLowerCase(), 'plain3eth'],
['0xA50d9a424A14aF0b9e7e9243dc1597d977f6cB09'.toLowerCase(), 'plain3optimized'],
['0xeD49979026DC44DC7E83b1471794ec9b2a365Ea2'.toLowerCase(), 'plain4basic'],
['0x0Cc51c9786f3777a6d50961CEBb2BB6E69ec5e07'.toLowerCase(), 'plain4balances'],
['0x0a31527a8dE2Ee97BBD8cCE14Db8E8826a0b6C4f'.toLowerCase(), 'plain4eth'],
['0x1086F023146f9026A9Bb22983CE866813C59518A'.toLowerCase(), 'plain4optimized'],
]),
BASE_POOL_LP_TO_GAUGE_LP_MAP: new Map([]),
DISABLED_POOLS_ADDRESSES: [].map(lc),
approxBlocksPerDay: 28800, // https://bscscan.com/chart/blocks
graphEndpoint: undefined, // Not supported by TheGraph's hosted service https://thegraph.com/docs/en/developing/supported-networks/
},
};
export default configs;
23 changes: 12 additions & 11 deletions constants/reference-assets.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
{
"USD": "usd",
"EUR": "eur",
"BTC": "btc",
"ETH": "eth",
"LINK": "link",
"SPELL": "spell",
"T": "t",
"MATIC": "matic",
"FTM": "ftm",
"AVAX": "avax",
"SNX": "snx"
"USD": "usd",
"EUR": "eur",
"BTC": "btc",
"ETH": "eth",
"LINK": "link",
"SPELL": "spell",
"T": "t",
"MATIC": "matic",
"FTM": "ftm",
"AVAX": "avax",
"SNX": "snx",
"BNB": "bnb"
}
Loading

1 comment on commit 09849d8

@vercel
Copy link

@vercel vercel bot commented on 09849d8 Nov 4, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.