Track Validator Daily Statistics
This guide will help you monitor the daily income of your validators using stakefish API. You'll learn how to track both individual and aggregated validators.
Validator Daily Rewards
To track the daily performance of individual or multiple validators, you can utilize the following API endpoint. This endpoint provides detailed information on the daily rewards and penalties associated with your validators over a specified period.
curl -X POST "https://api.testnet.stake.fish/v1/eth/rewards/v2/rewards" \
-H 'Content-Type: application/json' \
--data '{
"validatorIndices": [1803068],
"startDate": "2024-08-28",
"endDate": "2024-09-03"
}'
Explanation of Fields:
validatorIndices
: Specifies the list of validator indices. Keep in mind it will return aggregated data for all selected validators.startDate
: Start date in YYYY-MM-DD format.endDate
: End date in YYYY-MM-DD format. You can check the latest available date using the syncing endpoint.
Stakefish tracks rewards using UTC time. Always.
Example Response:
After sending the POST request, you’ll receive a response similar to the following:
{
"results": [
{
"validatorCount": 1,
"summaryDate": "2024-09-03",
"effectiveBalance": "32000000000000000000",
"closingBalance": "32004776725000000000",
"withdrawals": "0",
"consensusRewards": "1422054000000000",
"consensusPenalties": "7700000000000",
"consensusIncome": "1414354000000000",
"cumulativeConsensusIncome": "5090383000000000",
"executionIncome": "0",
"cumulativeExecutionIncome": "0",
"cumulativeTotalIncome": "5090383000000000"
},
...
],
"totalItems": 4
}
Visualizing the Data
Here are examples, how stakefish uses this endpoint to display performance charts that help to understand earned rewards over time.
Wallet Daily Rewards
Wallet Cumulative Rewards Over Time:
These charts provide a clear visual representation of your validator’s performance, making it easier to track and analyze your staking rewards.
Updated 2 months ago