This implements revision D of Meridian: Off-chain scheduled rewards.
Response:
{
"address": "scheduledRewardsInAttoFIL",
// ...
}
Response:
"scheduledRewardsInAttoFIL"
Request:
{
"participants": ["address" /* ... */],
"scores": ["score" /* ... */],
"signature": {
"r": "...",
"s": "...",
"v": "..."
}
}
Sign over a packed keccak256 with this schema:
['address[]', 'uint256[]']
The response includes the resulting scheduled rewards of all affected participants (excluding the burner address):
{
"address": "scheduledRewardsInAttoFIL",
// ...
}
Request:
{
"participants": ["address" /* ... */],
"rewards": ["amountInAttoFIL", /* ... */],
"signature": {
"r": "...",
"s": "...",
"v": "..."
}
}
Sign over a packed keccak256 with this schema:
['address[]', 'uint256[]']
The response includes the resulting scheduled rewards of all affected participants:
{
"adddress": "scheduledRewardsInAttoFIL",
// ...
}
The log endpoint returns an audit trail of all scheduled rewards changes over time:
[
{
timestamp: "2024-08-28T14:15:08.113Z",
address: "address",
scheduledRewardsDelta: "amountInAttoFIL",
score: "score"
}, {
timestamp: "2024-08-28T14:15:25.441Z",
address: "address",
scheduledRewardsDelta: "negativeAmountInAttoFIL"
// In case of a payout, no `score` is logged
}
// ...
]
redis-server &
npm start