> For the complete documentation index, see [llms.txt](https://docs.bancor.network/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.bancor.network/developer-guides/write-functions/rewards/autoprocessrewards.md).

# autoProcessRewards()

### Function autoProcessRewards()

{% code title="AutoCompoundingRewards.sol" %}

```solidity
function autoProcessRewards() external nonReentrant
```

{% endcode %}

This function is used to trigger the actual distribution of the auto compounding rewards based on the pre-defined program. Once called, it will burn the calculated bnTokens from the amount deposited in the externalRewardsVault and redistribute the underlying asset and value to all liquidity providers.
