Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
rcqiao opened this issue Jul 15, 2024 · 6 comments
Open

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

rcqiao opened this issue Jul 15, 2024 · 6 comments
Assignees

Comments

@rcqiao
Copy link

rcqiao commented Jul 15, 2024

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.

@rcqiao rcqiao changed the title Total net worth (current balance) of ILM positions Total net worth (current balance) of ILM positions [My Dashboard] Jul 15, 2024
@rcqiao
Copy link
Author

rcqiao commented Jul 17, 2024

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

@kitanovicd
Copy link
Collaborator

kitanovicd commented Jul 23, 2024

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.

@kitanovicd
Copy link
Collaborator

kitanovicd commented Jul 23, 2024

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

Image

@rcqiao
Copy link
Author

rcqiao commented Jul 24, 2024

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

@rcqiao
Copy link
Author

rcqiao commented Jul 24, 2024

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

@rcqiao
Copy link
Author

rcqiao commented Jul 24, 2024

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants