# Difference between Reward() and ClaimEarnings()

**URL:** <https://forum.livepeer.org/t/difference-between-reward-and-claimearnings/244>\
**Category:** Delegating\
**Created:** [May 11, 2018, 3:03pm UTC](https://forum.livepeer.org/t/difference-between-reward-and-claimearnings/244 "2018-05-11T15:03:47Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dob](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.livepeer.org/dob/32/7_2.png) [@dob](https://forum.livepeer.org/u/dob)\
**Post date:** [May 11, 2018, 3:03pm UTC](https://forum.livepeer.org/t/difference-between-reward-and-claimearnings/244/1 "2018-05-11T15:03:47Z")

</div>

In the first weeks of the Livepeer network being live, one thing that has constantly confused users of the protocol is the difference between the `reward()` transaction and the `claimEarnings()` transaction.

[![CloudApp](https://d3vv6lp55qjaqc.cloudfront.net/items/3W0L3U1I0A2y3V0L3U3Y/%5Bca2e4b5703a9b03ba27daeb4245ea07a%5D_Screen%2520Shot%25202018-05-11%2520at%252010.31.07%2520AM.png "Screen Shot 2018-05-11 at 10.31.07 AM.png") ](https://cl.ly/0V2w0l0r2P0n)

From [explorer.livepeer.org/me/delegating](http://explorer.livepeer.org/me/delegating)…

[![CloudApp](https://d3vv6lp55qjaqc.cloudfront.net/items/2Z0E0I0G3L1O1p3a1s2h/%5B654f8da252689a6a8e34adfb75e5ad21%5D_Screen%2520Shot%25202018-05-11%2520at%252010.34.39%2520AM.png "Screen Shot 2018-05-11 at 10.34.39 AM.png") ](https://cl.ly/03002X1q430a)

## TLDR Summary

- If you’re a transcoder, make sure to call `reward()` once per round. Don’t miss this.
- Everyone who stakes needs to eventually call `claimEarnings()` to calculate how much token and fees they generated each round, but there is no rush to invoke this proactively. It happens behind the scenes when you change bonding status (unbonding, bonding more, or changing who you are bonded to). Unclaimed earnings are counted as “Bonded” so you are earning inflation on them.

## Reward

`reward()` is a transaction that **only transcoders need to invoke**. When they invoke `reward()`, it generates newly minted LPT that gets split amongst them and their delegators.

- Only transcoders invoke reward
- They can only do this 1x/round (once per day)
- If they fail to invoke `reward()` during a round, then they miss out on the newly minted LPT, and so do their delegators. It is **very bad** to not call reward, as it’s a big missed opportunity. that does not come back. Delegators will not be happy.
- The newly generated LPT are automatically credited to the total delegated stake for the transcoder, and the delegated stake for each delegator. So they count towards stake for election in the next round’s active set.
- The livepeer node **should** call `reward()` automatically at the very start of a round. But sometimes a shaky connection to an Ethereum node, or high gas prices, can cause this txn to not be submitted. Transcoders should always check if they called `reward()`, and call it manually via the CLI if they have not seen their txn get confirmed yet. The `--gasPrice` flag to the livepeer node can also help to get the txn through.

## ClaimEarnings

`claimEarnings()` is more of an accounting necessity than something that’s useful or valuable to a user as far as LPT is concerned. As mentioned above, when a transcoder calls `reward()` the newly generated token sit in a pool that’s credited towards their total stake. Each delegator is entitled to some of this token. How much they’re owed needs to be calculated on a round-by-round basis and credited to their account. Hence, when they call `claimEarnings()` they are paying for this calculation to take place on the blockchain, and the token to move from sitting in a big pool, to being allocated towards them individually.

Fees that a transcoder earns in ETH, are immediately distributed into a delegator’s account when they call `claimEarnings()` however.

While delegators do need to do this calculation for every single round (day), one call to `claimEarnings()` can do the calculation for 100 rounds.

- Delegators or transcoders call `claimEarnings()` whenever they want to change their delegation status: unbond, bond towards another transcoder, bond more.
- One call to `claimEarnings()` can update their status for up to 100 rounds. So if it’s been longer than 100 rounds since the last update, you may have to call `claimEarnings()` multiple times.
- If it’s been less than 100 rounds, this happens in the background when you bond or unbond, you don’t need to proactively call `claimEarnings()`.
- If you are not changing your bond, the most effective strategy is to just call `claimEarnings()` once every 100 rounds. Or you can just wait and not do anything, and then call it, say 3 times if it’s been 300 rounds.
- There’s no benefit to calling `claimEarnings()` more frequently if you aren’t changing bonding status, unless you prefer the ETH fees to be sitting in your account instead of in the Livepeer contract.
- **CAUTION** : After you call `claimEarnings()` for a round, you can not call it again for that round. That means that if the transcoder earns more fees or calls `reward()` later in that round, you can not access those rewards or fees. To really optimize, change your bonding status late in the round after most of the fees have been collected and `reward()` has been called.

---

<div class="post-metadata">

**Author:** ![dob](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.livepeer.org/dob/32/7_2.png) [@dob](https://forum.livepeer.org/u/dob)\
**Post date:** [December 20, 2018, 10:55pm UTC](https://forum.livepeer.org/t/difference-between-reward-and-claimearnings/244/2 "2018-12-20T22:55:09Z")

</div>

Update on 12/20, that you can now claim up to 100 rounds in one claim call, rather than only 20.

---

<div class="post-metadata">

**Author:** ![Nate](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.livepeer.org/nate/32/357_2.png) [@Nate](https://forum.livepeer.org/u/Nate)\
**Post date:** [March 14, 2019, 3:11pm UTC](https://forum.livepeer.org/t/difference-between-reward-and-claimearnings/244/3 "2019-03-14T15:11:06Z")

</div>

I’ve recently started transcoding and have been unable to ClaimEarnings via the cli. My last claim round is listed as 0 and my start round is 1265. When I invoke “Claim” (option 10), I’ve tried a variety of end rounds: 1270, 1265, 1277, but my result is always the same:

Invoking transaction: “claimEarnings”. Params: [20]  
livepeer-transcoder[19589]: Transaction Failed: failed to estimate gas needed: gas required exceeds allowance or always failing transaction

I’m wondering if I need to be active for 20 rounds prior to claiming rewards? I know that other transcoders see the actual round they are claiming i.e. Params: [1278]

---

<div class="post-metadata">

**Author:** ![dob](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.livepeer.org/dob/32/7_2.png) [@dob](https://forum.livepeer.org/u/dob)\
**Post date:** [March 14, 2019, 4:28pm UTC](https://forum.livepeer.org/t/difference-between-reward-and-claimearnings/244/4 "2019-03-14T16:28:43Z")

</div>

You should not be required to be active for 20 rounds before you can call claimEarnings. I think this one sounds like a bug that may need to be tracked through Github with as much info as you can provide to help us debug and reproduce. Mind filing here [https://github.com/livepeer/go-livepeer/issues](https://github.com/livepeer/go-livepeer/issues)

In the meantime, you can try invoking claimEarnings via myCrypto if it is important to you to claim them at this time.
