Skip to content

Commit

Permalink
Add Yei
Browse files Browse the repository at this point in the history
  • Loading branch information
kexleyBeefy committed Aug 8, 2024
1 parent db2b7c3 commit 37c85af
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 1 deletion.
26 changes: 26 additions & 0 deletions src/api/stats/sei/getYeiApys.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
const { getAaveV3ApyData, getAaveV3PoolData } = require('../common/aave/getAaveV3Apys');
const pools = require('../../../data/sei/yeiPools.json');
const { SEI_CHAIN_ID } = require('../../../constants');

const config = {
dataProvider: '0x60c82A40C57736a9c692C42e87A8849Fb407F0d6',
incentives: '0x60485C5E5E3D535B16CC1bd2C9243C7877374259',
rewards: [
{
token: '0xE30feDd158A2e3b13e9badaeABaFc5516e95e8C7',
oracle: 'tokens',
oracleId: 'WSEI',
decimals: '1e18',
},
],
};

const getYeiApys = async () => {
return getAaveV3ApyData(config, pools, SEI_CHAIN_ID);
};

const getYeiPoolData = async pool => {
return getAaveV3PoolData(config, pool, SEI_CHAIN_ID);
};

module.exports = { getYeiApys, getYeiPoolData };
3 changes: 2 additions & 1 deletion src/api/stats/sei/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const { getBeefyCowSeiApys } = require('./getBeefyCowSeiApys');
const { getYeiApys } = require('./getYeiApys');

const getApys = [getBeefyCowSeiApys];
const getApys = [getBeefyCowSeiApys, getYeiApys];

const getSeiApys = async () => {
const start = Date.now();
Expand Down
35 changes: 35 additions & 0 deletions src/data/sei/yeiPools.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
[
{
"name": "yei-usdt",
"token": "0xB75D0B03c06A926e488e2659DF1A861F860bD3d1",
"aToken": "0x945C042a18A90Dd7adb88922387D12EfE32F4171",
"debtToken": "0x25eA70DC3332b9960E1284D57ED2f6A90d4a8373",
"oracle": "tokens",
"oracleId": "USDT",
"decimals": "1e6",
"borrowDepth": 1,
"borrowPercent": 0
},
{
"name": "yei-usdc",
"token": "0x3894085Ef7Ff0f0aeDf52E2A2704928d1Ec074F1",
"aToken": "0xc1a6F27a4CcbABB1C2b1F8E98478e52d3D3cB935",
"debtToken": "0x5Bfc2d187e8c7F51BE6d547B43A1b3160D72a142",
"oracle": "tokens",
"oracleId": "USDC",
"decimals": "1e6",
"borrowDepth": 1,
"borrowPercent": 0
},
{
"name": "yei-wsei",
"token": "0xE30feDd158A2e3b13e9badaeABaFc5516e95e8C7",
"aToken": "0x809FF4801aA5bDb33045d1fEC810D082490D63a4",
"debtToken": "0x648e683aaE7C18132564F8B48C625aE5038A9607",
"oracle": "tokens",
"oracleId": "WSEI",
"decimals": "1e18",
"borrowDepth": 1,
"borrowPercent": 0
}
]

0 comments on commit 37c85af

Please sign in to comment.