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

Upgrade Dapps Staking indexer to aggregate total ASTR and SDN staked #753

Open
bobo-k2 opened this issue Apr 24, 2023 · 0 comments
Open
Assignees
Labels
enhancement New feature or request

Comments

@bobo-k2
Copy link
Contributor

bobo-k2 commented Apr 24, 2023

Motivation
It would be very useful to have historical information about staked amounts on the portal dashboard page. This is first ticket in series of tickets related to adding total staked ASTR/SDN on the dashboard page.

Suggested Solution
Upgrade Dapps Staking indexer project to support TVL and total tokens staked. Indexing for Astar and Shiden should be supported.

TVL indexer already exists in separate project and it should be moved to Dapp Staking indexer project.

Total staked is a new feature which should be added to the project. Staked value should be aggregated on daily basis. To achieve that BondAndStake, Withdrawn and WithdrawFromUnregistered events should be listened. The formula for calculating ASTR staked should be something like:

staked = balance_bonded - balance_withdrawn - balance_withdrawn_from_unreg

Alternatives
Not at the moment. Any ideas are welcome.

Additional Information
Please comment if ticket is not clear enough.

@bobo-k2 bobo-k2 added the enhancement New feature or request label Apr 24, 2023
@bobo-k2 bobo-k2 added Tier 2 Medium complexity task UI DAO Community task labels Apr 26, 2023
@bobo-k2 bobo-k2 removed Tier 2 Medium complexity task UI DAO Community task labels May 24, 2023
@bobo-k2 bobo-k2 self-assigned this May 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant