> For the complete documentation index, see [llms.txt](https://gitbook.mor.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gitbook.mor.org/smart-contracts/documentation/distribution-protocol/v7-protocol/get-started/claim.md). Agents can also search and read this documentation through its [MCP server](https://gitbook.mor.org/~gitbook/mcp).

# Claim

The [claim](https://gitbook.mor.org/smart-contracts/documentation/distribution-protocol/v7-protocol/contracts/depositpool.md#claim) function allows a user to claim their accumulated MOR rewards from a reward pool. This function is typically called after a lock period has expired or when the user wants to realize pending rewards. The caller claims their rewards, and the minted MOR tokens are sent to the specified receiver address on L2.

Before transferring any rewards, the contract enforces next conditions:

* The minimum claim lock period since the last stake must have passed.
* The minimum interval since the last claim must have passed.
* The custom claim lock (set via `claimLockEnd`) must have expired.

If all conditions are met, the contract calculates the latest reward amount based on the user’s virtual deposit and the difference in the reward coefficient. The claim updates the user’s multiplier.

Finally, the `sendMintMessage` function is called on the `Distributor` to initiate MOR minting to the receiver.

No deposit tokens are moved during the claim. Only MOR tokens are minted cross-chain (via LayerZero) to the user’s address on the destination chain.

## ClaimFor

The claimFor function allows another address to claim rewards on behalf of a user. This supports use cases like automated agents, wallets, or third-party services claiming on users’ behalf.

The contract verifies one of the following:

* The staker has explicitly whitelisted the `msg.sender` via `setClaimSender`.
* Or, the staker has assigned a fixed `claimReceiver` address via `setClaimReceiver`— in that case, receiver is overridden with the preconfigured address.

The rest of the logic mirrors the `claim` function.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://gitbook.mor.org/smart-contracts/documentation/distribution-protocol/v7-protocol/get-started/claim.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
