File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change
1
+ const ADDRESSES = require ( "../helper/coreAssets.json" ) ;
2
+ const { fetchURL } = require ( '../helper/utils' ) ;
3
+
4
+ async function fetchTvl ( api ) {
5
+ const response = await fetchURL ( "https://api.gas111.com/api/v1/internal/tokens/balances-list" )
6
+ for ( const pool of response . data ) {
7
+ api . add ( ADDRESSES . ton . TON , pool . bonding_curve_balance / 2 ) // we include only the TON part of the pool
8
+ }
9
+ }
10
+
11
+
12
+ module . exports = {
13
+ methodology : `
14
+ Each token launched via gaspump has a bonding curve. The TVL is the sum of all bonding curve balances.
15
+ It is slightly different from the address balance, which is composed from curve balance + fees accumulated.
16
+ ` . trim ( ) ,
17
+ timetravel : false ,
18
+ ton : {
19
+ tvl : fetchTvl
20
+ }
21
+ }
You can’t perform that action at this time.
0 commit comments