> For the complete documentation index, see [llms.txt](https://docs.teller.org/v2/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.teller.org/v2/personas/reward-allocators.md).

# Reward Allocators

Any account can use the contract `MarketLiquidityRewards` to allocate (deposit) tokens into the smart contract which can be redeemed by borrowers and lenders who are using the protocol in specific ways. &#x20;

Specific parameters can be set as requirements for claiming rewards and a reward can only be claimed once per loan per allocation. &#x20;

### Reward Requirement Parameters (optional)

**`rewardPerLoanPrincipalAmount`** - The amount of reward token claimable per amount of loan principal.  This number should be expanded by the principal token decimals. &#x20;

**`requiredPrincipalTokenAddress`** - A loan must use this token as the 'lending token' to generate claimable rewards. If set to zero address, any lending token can be used.

**`requiredCollateralTokenAddress`** - A loan must use this token as collateral to receive rewards from this allocation. If set to zero address, any (or none) collateral tokens can be used.

**`minimumCollateralPerPrincipalAmount`** - A loan must be collateralized at least by this ratio (only checked if **requiredCollateralTokenAddress** is non-zero).

**`bidStartTimeMin`** - The minimum timestamp for which the loan must have been accepted.

**`bidStartTimeMax`** - the maximum timestamp for which the loan must have been accepted.

[**`allocationStrategy`**](#user-content-fn-1)[^1] - Either BORROWER or LENDER, signifying the type of protocol user that can claim the rewards from this allocation&#x20;

```
struct RewardAllocation {
    address allocator;
    address rewardTokenAddress;
    uint256 rewardTokenAmount;
    uint256 marketId;
    //requirements for loan
    address requiredPrincipalTokenAddress; //0 for any
    address requiredCollateralTokenAddress; //0 for any  -- could be an enumerable set?
    uint256 minimumCollateralPerPrincipalAmount;
    uint256 rewardPerLoanPrincipalAmount;
    uint32 bidStartTimeMin;
    uint32 bidStartTimeMax;
    AllocationStrategy allocationStrategy;
}
```

[^1]: This is an ENUM where BORROWER:0 and LENDER:1
