mirror of
https://github.com/alexgo-io/DefiLlama-Adapters.git
synced 2026-01-12 22:43:12 +08:00
22 lines
503 B
JavaScript
22 lines
503 B
JavaScript
const axios = require('axios')
|
|
|
|
const chains = ['bsc','kcc', 'aurora', 'clv']
|
|
const url = 'https://api.killswitch.finance/ksw/tvl'
|
|
|
|
const tvl = async (api) => {
|
|
const { data } = await axios.get(url)
|
|
return api.addUSDValue(Math.round(data.summary[api.chain]))
|
|
}
|
|
|
|
module.exports = {
|
|
timetravel: false,
|
|
doublecounted: true,
|
|
misrepresentedTokens: true,
|
|
}
|
|
|
|
chains.forEach((chain) => {
|
|
if (chain === 'clv') return module.exports[chain] = { tvl: () => ({}) };
|
|
module.exports[chain] = { tvl }
|
|
})
|
|
|