ViNo-community/vite-node-bot

Add command for Rewards not claimed

Closed this issue · 3 comments

Add command for Rewards not claimed

https://docs.vite.org/go-vite/api/rpc/contract_v2.html#contract-getsbprewardpendingwithdrawal

Input: SBP Name

{
	"jsonrpc": "2.0",
	"id": 1,
	"method": "contract_getSBPRewardPendingWithdrawal",
	"params": "ViNo Community Node"
}

Output:

{
    "jsonrpc": "2.0",
    "id": 1,
    "result": {
        "blockProducingReward": "1499714611872146118517",
        "votingReward": "746306845207209076970",
        "totalReward": "2246021457079355195487",
        "producedBlocks": "0",
        "targetBlocks": "0",
        "allRewardWithdrawed": false
    }
}

This information can be found in v!rewards [SBP_Name]

Might rename to rewards_pending ?

v!rewards returns:

Name: ViNo_Community_Node
Block Producing Reward: 0.00
Voting Reward: 0.00
Total Reward: 0.00
Withdrawn: false