Skip to content

Commit

Permalink
fix: replace deprecated Levvy stats endpoint (#13112)
Browse files Browse the repository at this point in the history
  • Loading branch information
ricomiles authored Jan 17, 2025
1 parent 2e42771 commit 373b6ba
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 19 deletions.
21 changes: 6 additions & 15 deletions projects/levvy-fi-tokens/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,29 +7,20 @@ module.exports = {
cardano: {
tvl: async () => {
const data = await post(
"https://citizens.theapesociety.io/api/getLevvyData",
{}
"https://8080-truthful-birthday-xc2vhr.us1.demeter.run/api/v1/token/platform/stats",
''
);
return {
cardano: data.tokens.tvl,
};
},
staking: async () => {
const data = await post(
"https://citizens.theapesociety.io/api/getLevvyData",
{}
);
return {
cardano: data.tokens.staked,
cardano: data.totalValueLocked/1e6,
};
},
borrowed: async () => {
const data = await post(
"https://citizens.theapesociety.io/api/getLevvyData",
{}
"https://8080-truthful-birthday-xc2vhr.us1.demeter.run/api/v1/token/platform/stats",
''
);
return {
cardano: data.tokens.borrowed,
cardano: data.totalValueBorrowed/1e6,
};
},
},
Expand Down
8 changes: 4 additions & 4 deletions projects/levvy-fi/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ module.exports = {
misrepresentedTokens: true,
cardano: {
tvl: async () => {
const data = await post('https://citizens.theapesociety.io/api/getLevvyData', {})
const data = await post('https://8080-truthful-birthday-xc2vhr.us1.demeter.run/api/v1/nft/platform/stats', '')
return {
cardano: data.adaTVL,
cardano: data.totalValueLocked/1e6,
}
},
borrowed: async () => {
const data = await post('https://citizens.theapesociety.io/api/getLevvyData', {})
const data = await post('https://8080-truthful-birthday-xc2vhr.us1.demeter.run/api/v1/nft/platform/stats', '')
return {
cardano: data.borrowed,
cardano: data.totalValueBorrowed/1e6,
}
}
},
Expand Down

0 comments on commit 373b6ba

Please sign in to comment.