frontend
frontend copied to clipboard
Celo: Epoch rewards tab on Block view
Implement Epoch rewards tab on the Block view page.
Distributions
The first section deals with distributions, which represent the token transfers of CELO to various Celo funds. Note that, on the API level, the same object as for token transfers is returned. You can retrieve these distributions from the following endpoint: https://celo-alfajores.blockscout.com/api/v2/blocks/25678080/epoch
Election Rewards
The second section deals with election rewards happened in the epoch block. When the user opens the Election Rewards tab, the table should display aggregated reward information, which can be obtained from:
https://celo-alfajores.blockscout.com/api/v2/blocks/{block_number}/epoch/
.
For more detailed, granular information, users can open the dropdown to view rewards by type. This data is available at:
https://celo-alfajores.blockscout.com/api/v2/blocks/{block_number}/election-rewards/{reward_type}
where reward_type
can be one of: validator
, group
, voter
, or delegated-payment
. Please note that this endpoint is paginated, but should be displayed with infinite scroll.