balancednetwork / balanced-network-info

ℹ️ Balanced network analytics.
https://stats.balanced.network
MIT License
0 stars 0 forks source link

More precision on volume & fee numbers #37

Closed BennyOptions closed 3 years ago

BennyOptions commented 3 years ago

Red Box:

Smart Contract -> Backend: Eventlog: Swap Two fields: BALN Fee and LP Fee (charged in fromToken) Maintain a rolling 24 hour sum of BALN Fee and LP Fee for both tokens in the pool

Backend -> Frontend: Quote Token: Sum{BALN Fee, LP Fee} $$ value + Base Token: Sum{BALN Fee, LP Fee} $$ value

Green Box:

Smart Contract -> Backend Eventlog: Swap Fields: fromValue Maintain a rolling 24 hour sum of fromValue for both tokens in the pool

Backend -> Frontend Sum{fromValue base $$ value, fromValue quote $$ value}

Screen Shot 2021-08-25 at 8.29.46 PM.png