seamless-protocol/ilm

Total net worth (current balance) of ILM positions [My Dashboard]

Opened this issue · 6 comments

Name of feature/metric:
Total net worth (also can be called "current balance") of all ILM positions

Description of feature/metric:
The sum of all current ILM positions, represented in USD value. Shown as a linear graph across historical time (ranging from an hour to a year, etc).

If possible, show each strategy as a separate line, and then a total line as a sum of all the strategies.

Show the % change over time.

Considerations/questions: deposits or withdrawals would just be shown as increases or decreases to balance regardless of performance.

Picture from design (if available):
Image

Estimated Timeline:

Requirements/Data Sources:
This can be done with complex Dune query. Query will potentially be expensive in terms of Dune credits and for each user we would need to run it again. I am not sure how much data can be cached here so it may end up being expensive. In this ticket it is matter of cost.

This can also be done by getting user historic strategy tokens balances and converting it in USD by getting historic equity for each strategy from Dune or Subgraph which would result in "heavy" calculations on client side and will probably be slow.

DeBank has endpoint that returns total porfolio value in USD. This endpoint is not public. if we want something like that we can speak with DeBank team to see if they are open to publish the endpoint for our need or something like that.

https://app.beefy.com/ --> Beefy has an example that shows your total AUM you've deposited, and also monthly/daily yield and average apy. Connect your wallet to see the example.
Image

https://debank.com/profile/0x84a6a7c0674a3aa03e09c026600cb46181821f07/stream --> debank has a total value tracker in the top right of any wallet page
Image

https://app.superform.xyz/ --> superform also has a total portfolio value tracker on the home page but also on the tab "portfolio" if you click it and have an open position
Image

Image

Dune API is no option. It is not scalable and it is super expensive. Solution is to send users to Dune website and on Dune website they can use query and widget on their own cost. Other solution is to use third party or build custom BE. Problematic is historic graph data. Current portfolio net worth is totally fine and we can get it from SC.

We can do individual points in history. Such as past 24h, or past 7 days.

Image

Debank total value api is not public maybe can speak to them also woudl need to ask to show only the ILM portion

Current net worth easy to show. Historic is the difficult one

for the nice to have - static view of net worth not historical