> For the complete documentation index, see [llms.txt](https://docs.octusbridge.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.octusbridge.io/integrate/octus-bridge-contracts/everscale/staking-section/relayround.md).

# RelayRound

#### **`hasUnclaimedReward`**

Checks if user has unclaimed rewards.

```
function hasUnclaimedReward(address _relay_staker_addr) external view responsible returns (bool has_reward)
```

**Parameters:**

| Name                  | Type    | Description       |
| --------------------- | ------- | ----------------- |
| \_relay\_staker\_addr | address | Address of staker |

**Return value:**

| Name        | Type | Description                                    |
| ----------- | ---- | ---------------------------------------------- |
| has\_reward | bool | True if it has unclaimed rewards, false if not |

#### **`getRewardForRound`**

Calculates reward for certain round and sends it to user.

```
function getRelayByStakerAddress(
        address _relay_staker_addr
    ) external view responsible returns (uint256 _ton_key, uint160 _eth_addr, address _staker_addr, uint128 _staked_tokens)
```

**Parameters:**

| Name                  | Type    | Description    |
| --------------------- | ------- | -------------- |
| \_relay\_staker\_addr | address | Staker address |

**Return value:**

| Name             | Type    | Description                |
| ---------------- | ------- | -------------------------- |
| \_ton\_key       | uint256 | Ton account’s public key   |
| \_eth\_addr      | uint160 | Ethereum account’s address |
| \_staker\_addr   | address | Staker address             |
| \_staked\_tokens | uint128 | Amount of tokens staked    |

#### **`sendRelaysToRelayRound`**

Sets relayers to the specific round.

```
function sendRelaysToRelayRound(address relay_round_addr, uint32 count) external override onlyRoot
```

**Parameters:**

| Name               | Type    | Description                                 |
| ------------------ | ------- | ------------------------------------------- |
| relay\_round\_addr | address | Address of relayer round                    |
| count              | uint32  | Number of relayers to send to relayer round |

#### **`_checkRelaysInstalled`**

Checks whether there are enough relayers installed.

```
function _checkRelaysInstalled() internal
```

#### **`destroy`**

Destroy round if ended.

```
function destroy() external override onlyRoot
```

#### **`onCodeUpgrade`**

Sets relayer round data based on the upgraded data.

```
function onCodeUpgrade(TvmCell upgrade_data) private
```

**Parameters:**

| Name          | Type    | Description                                 |
| ------------- | ------- | ------------------------------------------- |
| upgrade\_data | TvmCell | Upgraded election data in cell format       |
| count         | uint32  | Number of relayers to send to relayer round |

#### **`upgrade`**

Upgrades relayer round data and code.

```
function upgrade(TvmCell code, uint32 new_version, address send_gas_to) external onlyRoot
```

**Parameters:**

| Name          | Type    | Description                             |
| ------------- | ------- | --------------------------------------- |
| code          | TvmCell | relayer round’s platform code           |
| new\_version  | uint32  | New version of relayer round’s platform |
| send\_gas\_to | address | Address where to send remaining gas     |

**Events emitted:**

* RelayRoundCodeUpgraded


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.octusbridge.io/integrate/octus-bridge-contracts/everscale/staking-section/relayround.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
