Staked Defi Balance Strategy Added for All Ferrum Network Staking Contracts [staked-defi-balance] #1129
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Release Notes
New Strategy: Staked Defi Balance
In this update, I have added a new strategy called
Staked Defi Balance
to the snapshot-strategies repository. This custom strategy returns the score of addresses based on their staked token balance in a specific Ferrum Network DeFi staking pool contract.Changes
New Strategy File: A new file named
index.ts
has been added to thesrc/strategies/staked-defi-balance
directory. This file contains the implementation of theStaked Defi Balance
strategy, including multicall functionality to fetch staking balances and score calculation logic.Examples File: A new
examples.json
file has been added to thesrc/strategies/staked-defi-balance
directory. This file demonstrates how to use the new strategy with the correct parameters, such astokenContractAddress
,symbol
,decimals
,minStakedBalance
,stakingPoolContractAddress
, andmethodABI
.Schema File: A new
schema.json
file has been added to thesrc/strategies/staked-defi-balance
directory. This file defines the JSON schema for the strategy parameters, ensuring that they follow the correct structure and data types. The schema enforces the required parameters and validates their format.Impact
This update expands the capabilities of the snapshot-strategies repository by providing a new strategy for users to calculate scores based on staked token balances in Ferrum Network's DeFi Staking Contracts. This strategy can be helpful for governance proposals and voting mechanisms that involve staked tokens in a specific staking pool contract.
Usage
To use this strategy, include it in your Snapshot configuration and provide the necessary parameters as shown in the
examples.json
file. Make sure the parameters follow the structure defined in theschema.json
file for proper validation.Here is an example of parameters:
Please make sure to update your Snapshot configuration to include the new strategy and follow the release notes for any future updates or changes.