# IFeeCalculator

> Interface for calculating block-latency feed fees.

> For the complete documentation index, see [llms.txt](/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.

Source: https://dev.flare.network/ftso/solidity-reference/IFeeCalculator

Interface for calculating block-latency feed fees.

Sourced from `IFeeCalculator.sol` on [GitHub](https://github.com/flare-foundation/flare-smart-contracts-v2/blob/main/contracts/userInterfaces/IFeeCalculator.sol).

## Functions[​](#functions "Direct link to Functions")

### calculateFeeByIds[​](#calculatefeebyids "Direct link to calculateFeeByIds")

Calculates a fee that needs to be paid to fetch feeds' data, addressed by feed id.

```
function calculateFeeByIds(    bytes21[] _feedIds) external view returns (    uint256 _fee);
```

#### Parameters[​](#parameters "Direct link to Parameters")

-   `_feedIds`: List of feed ids.

### calculateFeeByIndices[​](#calculatefeebyindices "Direct link to calculateFeeByIndices")

Calculates a fee that needs to be paid to fetch feeds' data, addressed by index. The index is the position of the feed id in the [`FastUpdatesConfiguration`](https://github.com/flare-foundation/flare-smart-contracts-v2/blob/main/contracts/userInterfaces/IFastUpdatesConfiguration.sol) contract — use this overload together with `IFastUpdatesConfiguration.getFeedIndex(bytes21)` when working with FastUpdates.

```
function calculateFeeByIndices(    uint256[] _indices) external view returns (    uint256 _fee);
```

#### Parameters[​](#parameters-1 "Direct link to Parameters")

-   `_indices`: Indices of the feeds, corresponding to feed ids in the `FastUpdatesConfiguration` contract.
