We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2e60b7e commit 8eec7d5Copy full SHA for 8eec7d5
projects/size-credit/index.js
@@ -0,0 +1,23 @@
1
+const { sumTokensExport } = require('../helper/unwrapLPs')
2
+const ADDRESSES = require('../helper/coreAssets.json')
3
+
4
+const AUSDC_CONTRACT = '0x4e65fe4dba92790696d040ac24aa414708f5c0ab'
5
+const SZDEBT_CONTRACT = '0xb0a00c4b3d77c896f46dc6b204695e22de7a185d'
6
+const SIZE_PROXY_CONTRACT = '0xC2a429681CAd7C1ce36442fbf7A4a68B11eFF940'
7
+const tokens = [
8
+ ADDRESSES.base.WETH,
9
+ AUSDC_CONTRACT,
10
+]
11
12
+async function borrowed(api) {
13
+ const totalDebt = await api.call({ abi: 'erc20:totalSupply', target: SZDEBT_CONTRACT, });
14
15
+ return api.add(ADDRESSES.base.USDbC, totalDebt)
16
+}
17
18
+module.exports = {
19
+ base: {
20
+ tvl: sumTokensExport({ tokens, owner: SIZE_PROXY_CONTRACT }),
21
+ borrowed
22
+ }
23
0 commit comments