mirror of
https://github.com/alexgo-io/DefiLlama-Adapters.git
synced 2026-01-12 08:34:23 +08:00
feat: add Utopia Miner contract ABI and TVL calculation (#16917)
This commit is contained in:
20
projects/utopia/index.js
Normal file
20
projects/utopia/index.js
Normal file
@@ -0,0 +1,20 @@
|
||||
const sdk = require('@defillama/sdk');
|
||||
|
||||
const UTOPIA_MINER_CONTRACT = '0x61ea85A817344789d836fbC18B9099bB280b383D';
|
||||
|
||||
async function tvl(api) {
|
||||
const contractBalance = await sdk.api.eth.getBalance({
|
||||
target: UTOPIA_MINER_CONTRACT,
|
||||
chain: 'bsc',
|
||||
});
|
||||
|
||||
api.addGasToken(contractBalance.output);
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
methodology:
|
||||
'TVL is calculated as the total BNB balance locked in the Utopia Miner contract.',
|
||||
bsc: {
|
||||
tvl,
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user