# IAssetManager

> FAssets IAssetManager interface reference.

> 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/fassets/reference/IAssetManager

Command line reference for interacting with FAssets `AssetManager` contract.

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

* * *

## Information[​](#information "Direct link to Information")

### `getSettings`[​](#getsettings "Direct link to getsettings")

Returns the complete asset manager settings as the [`AssetManagerSettings`](https://github.com/flare-foundation/fassets/blob/main/contracts/userInterfaces/data/AssetManagerSettings.sol) struct.

You can find detailed explanations of each parameter in the [FAssets Operational Parameters](/fassets/operational-parameters#asset-manager-operational-parameters) documentation.

```
function getSettings()    external view    returns (AssetManagerSettings.Data memory);
```

#### `getAgentInfo`[​](#getagentinfo "Direct link to getagentinfo")

Returns detailed information about an agent as the [`AgentInfo`](https://github.com/flare-foundation/fassets/blob/main/contracts/userInterfaces/data/AgentInfo.sol) struct.

Need to provide the agent vault address.

```
function getAgentInfo(address _agentVault)    external view    returns (AgentInfo.Info memory);
```

### `getCollateralTypes`[​](#getcollateraltypes "Direct link to getcollateraltypes")

Returns the list of all available and deprecated tokens used for collateral types in the FAssets system.

Returns:

-   [`CollateralType.Data`](https://github.com/flare-foundation/fassets/blob/main/contracts/userInterfaces/data/CollateralType.sol): Array of collateral type data structures containing information about each supported collateral token.

```
function getCollateralTypes()    external view    returns (CollateralType.Data[] memory);
```

### `collateralReservationFee`[​](#collateralreservationfee "Direct link to collateralreservationfee")

Returns the collateral reservation fee amount.

Parameters:

-   `_lots`: The number of lots for which to reserve collateral.

Returns:

-   `_reservationFeeNATWei`: The amount of reservation fee in NAT wei.

```
function collateralReservationFee(    uint256 _lots) external view returns (uint256 _reservationFeeNATWei);
```

### `collateralReservationInfo`[​](#collateralreservationinfo "Direct link to collateralreservationinfo")

Returns the data about the collateral reservation for an ongoing minting. Note: once the minting is executed or defaulted, the collateral reservation is deleted and this method fails.

Parameters:

-   `_collateralReservationId`: The collateral reservation ID, as used for executing or defaulting the minting.

```
function collateralReservationInfo(uint256 _collateralReservationId)    external view    returns (CollateralReservationInfo.Data memory);
```

### `fAsset`[​](#fasset "Direct link to fasset")

Returns the FAsset token contract (ERC-20) that is managed by this asset manager instance.

Returns:

-   `IERC20`: The address of the FAsset token contract.

```
function fAsset()    external view    returns (IERC20);
```

## Direct Minting Settings[​](#direct-minting-settings "Direct link to Direct Minting Settings")

### `directMintingPaymentAddress`[​](#directmintingpaymentaddress "Direct link to directmintingpaymentaddress")

Gets the XRPL address of the core vault. This is the payment address to which the underlying assets must be sent for direct minting.

```
function directMintingPaymentAddress()    external view    returns (string memory);
```

### `getDirectMintingMinimumFeeUBA`[​](#getdirectmintingminimumfeeuba "Direct link to getdirectmintingminimumfeeuba")

Returns the minimum direct minting fee in UBA.

```
function getDirectMintingMinimumFeeUBA()    external view    returns (uint256);
```

### `getDirectMintingFeeBIPS`[​](#getdirectmintingfeebips "Direct link to getdirectmintingfeebips")

Returns the direct minting fee in BIPS.

```
function getDirectMintingFeeBIPS()    external view    returns (uint256);
```

### `getDirectMintingExecutorFeeUBA`[​](#getdirectmintingexecutorfeeuba "Direct link to getdirectmintingexecutorfeeuba")

Returns the direct minting executor fee in UBA.

```
function getDirectMintingExecutorFeeUBA()    external view    returns (uint256);
```

### `getDirectMintingOthersCanExecuteAfterSeconds`[​](#getdirectmintingotherscanexecuteafterseconds "Direct link to getdirectmintingotherscanexecuteafterseconds")

Returns the length of the preferred-executor exclusivity window for direct minting, in seconds.

When a direct minting specifies a preferred executor — either through a tag bound on the [`IMintingTagManager`](/fassets/reference/IMintingTagManager) or through the 48-byte [memo format](/fassets/direct-minting#memo-field) — only that executor may finalize the minting until this number of seconds has elapsed since the underlying payment. After the window expires, anyone can call [`executeDirectMinting`](/fassets/reference/IAssetManager#executedirectminting) to finalize the request.

If the minting is delayed by [rate limits](/fassets/direct-minting#rate-limits), the exclusivity window restarts from the [`DirectMintingDelayed`](/fassets/reference/IAssetManagerEvents#directmintingdelayed) event's `executionAllowedAt` timestamp.

```
function getDirectMintingOthersCanExecuteAfterSeconds()    external view    returns (uint256);
```

### `getDirectMintingHourlyLimitUBA`[​](#getdirectmintinghourlylimituba "Direct link to getdirectmintinghourlylimituba")

Returns the hourly direct minting limit in UBA.

```
function getDirectMintingHourlyLimitUBA()    external view    returns (uint256);
```

### `getDirectMintingDailyLimitUBA`[​](#getdirectmintingdailylimituba "Direct link to getdirectmintingdailylimituba")

Returns the daily direct minting limit in UBA.

```
function getDirectMintingDailyLimitUBA()    external view    returns (uint256);
```

### `getDirectMintingHourlyLimiterState`[​](#getdirectmintinghourlylimiterstate "Direct link to getdirectmintinghourlylimiterstate")

Returns the raw state of the hourly direct-minting [rate limiter](/fassets/direct-minting#rate-limits).

Returns:

-   `_windowStartTimestamp`: Unix timestamp when the current hourly window started, snapped to a multiple of `windowSizeSeconds` (UTC hour boundaries).
-   `_mintedInCurrentWindow`: Amount minted in the current window, denominated in AMG. Multiply by [`assetMintingGranularityUBA`](#assetmintinggranularityuba) to convert to UBA.

The value is only updated on the next limiter write, so consumers that need a live view should advance the window off-chain — see the [Check Direct Minting Limits guide](/fassets/developer-guides/fassets-direct-minting-limits).

```
function getDirectMintingHourlyLimiterState()    external view    returns (uint64 _windowStartTimestamp, uint64 _mintedInCurrentWindow);
```

### `getDirectMintingDailyLimiterState`[​](#getdirectmintingdailylimiterstate "Direct link to getdirectmintingdailylimiterstate")

Returns the raw state of the daily direct-minting [rate limiter](/fassets/direct-minting#rate-limits).

Returns:

-   `_windowStartTimestamp`: Unix timestamp when the current daily window started, snapped to 00:00 UTC.
-   `_mintedInCurrentWindow`: Amount minted in the current window, denominated in AMG. Multiply by [`assetMintingGranularityUBA`](#assetmintinggranularityuba) to convert to UBA.

The value is only updated on the next limiter write, so consumers that need a live view should advance the window off-chain — see the [Check Direct Minting Limits guide](/fassets/developer-guides/fassets-direct-minting-limits).

```
function getDirectMintingDailyLimiterState()    external view    returns (uint64 _windowStartTimestamp, uint64 _mintedInCurrentWindow);
```

### `getDirectMintingsUnblockUntilTimestamp`[​](#getdirectmintingsunblockuntiltimestamp "Direct link to getdirectmintingsunblockuntiltimestamp")

Returns the Unix timestamp until which the direct-minting [rate limiter](/fassets/direct-minting#rate-limits) is bypassed.

While `block.timestamp` is below this value, the hourly and daily caps are not enforced and queued mintings can execute without delay. Governance sets this via `unblockDirectMintingsUntil` to drain a backlog after manual review; the value is `0` when the limiter is active.

```
function getDirectMintingsUnblockUntilTimestamp()    external view    returns (uint256);
```

### `getDirectMintingLargeMintingThresholdUBA`[​](#getdirectmintinglargemintingthresholduba "Direct link to getdirectmintinglargemintingthresholduba")

Returns the threshold above which direct minting is considered large, in UBA.

```
function getDirectMintingLargeMintingThresholdUBA()    external view    returns (uint256);
```

### `getDirectMintingLargeMintingDelaySeconds`[​](#getdirectmintinglargemintingdelayseconds "Direct link to getdirectmintinglargemintingdelayseconds")

Returns the delay in seconds applied to large direct mintings.

```
function getDirectMintingLargeMintingDelaySeconds()    external view    returns (uint256);
```

### `assetMintingGranularityUBA`[​](#assetmintinggranularityuba "Direct link to assetmintinggranularityuba")

Returns the asset minting granularity — the smallest unit of FAsset stored internally within this asset manager instance.

The direct-minting [rate limiter](/fassets/direct-minting#rate-limits) stores `mintedInCurrentWindow` as `uint64` AMG (asset minting granularity) for cheap on-chain storage. Multiplying the limiter state by `assetMintingGranularityUBA` rebases it into UBA so it can be compared against the UBA-denominated hourly and daily caps.

```
function assetMintingGranularityUBA()    external view    returns (uint256);
```

### `getDirectMintingFeeReceiver`[​](#getdirectmintingfeereceiver "Direct link to getdirectmintingfeereceiver")

Returns the address that receives direct minting fees.

```
function getDirectMintingFeeReceiver()    external view    returns (address);
```

## Redeem With Tag Settings[​](#redeem-with-tag-settings "Direct link to Redeem With Tag Settings")

### `getMintingTagManager`[​](#getmintingtagmanager "Direct link to getmintingtagmanager")

Returns the minting tag manager contract address. To interact with it, use the [IMintingTagManager](/fassets/reference/IMintingTagManager) reference.

```
function getMintingTagManager()    external view    returns (address);
```

## Agents[​](#agents "Direct link to Agents")

### `getAllAgents`[​](#getallagents "Direct link to getallagents")

Returns the list of all agents.

Parameters:

-   `_start`: First index to return from the available agent's list.
-   `_end`: End index (one above last) to return from the available agent's list.

Returns:

-   `_agents`: The list of agents between the `_start` and `_end` indexes.
-   `_totalLength`: The total length of the all agents list.

```
function getAllAgents(uint256 _start, uint256 _end)    external view    returns (address[] memory _agents, uint256 _totalLength);
```

### `getAvailableAgentsList`[​](#getavailableagentslist "Direct link to getavailableagentslist")

Returns the list of available agents.

Parameters:

-   `_start`: Starting index to return from the available agent's list (inclusive).
-   `_end`: Ending index to return from the available agent's list (exclusive).

Returns:

-   `_agents`: The list of available agents between the `_start` and `_end` indexes.
-   `_totalLength`: The total length of the available agents list.

```
function getAvailableAgentsList(uint256 _start, uint256 _end)    external view    returns (address[] memory _agents, uint256 _totalLength);
```

### `getAvailableAgentsDetailedList`[​](#getavailableagentsdetailedlist "Direct link to getavailableagentsdetailedlist")

Returns the list of available agents with extra information about agents like fee, minimum collateral ratio and available collateral (in lots).

Parameters:

-   `_start`: Starting index to return from the available agent's list (inclusive).
-   `_end`: Ending index to return from the available agent's list (exclusive).

Returns:

-   `_agents`: The list of available agents with extra information.
-   `_totalLength`: The total length of the available agents list.

```
function getAvailableAgentsDetailedList(uint256 _start, uint256 _end)    external view    returns (AvailableAgentInfo.Data[] memory _agents, uint256 _totalLength);
```

## Redemption Queue[​](#redemption-queue "Direct link to Redemption Queue")

### `redemptionQueue`[​](#redemptionqueue "Direct link to redemptionqueue")

Returns the redemption queue in the form of an array of [`RedemptionTicketInfo`](https://github.com/flare-foundation/fassets/blob/main/contracts/userInterfaces/data/RedemptionTicketInfo.sol) structs.

Parameters:

-   `_firstRedemptionTicketId`: The ticket id to start listing from; if `0`, starts from the beginning.
-   `_pageSize`: The maximum number of redemption tickets to return.

Returns:

-   `_queue`: The (part of) redemption queue; maximum length is \_pageSize.
-   `_nextRedemptionTicketId`: Works as a cursor - if the `_pageSize` is reached and there are more tickets, it is the first ticket id not returned; if the end is reached, it is 0.

```
function redemptionQueue(    uint256 _firstRedemptionTicketId,    uint256 _pageSize) external view    returns (RedemptionTicketInfo.Data[] memory _queue, uint256 _nextRedemptionTicketId);
```

### `agentRedemptionQueue`[​](#agentredemptionqueue "Direct link to agentredemptionqueue")

Returns the redemption queue for specific agent in the form of an array of [`RedemptionTicketInfo`](https://github.com/flare-foundation/fassets/blob/main/contracts/userInterfaces/data/RedemptionTicketInfo.sol) structs.

Parameters:

-   `_agentVault`: The agent vault address of the queried agent.
-   `_firstRedemptionTicketId`: The ticket id to start listing from; if `0`, starts from the beginning.
-   `_pageSize`: The maximum number of redemption tickets to return.

Returns:

-   `_queue`: The (part of) the redemption queue; maximum length is \_pageSize.
-   `_nextRedemptionTicketId`: Works as a cursor - if the `_pageSize` is reached and there are more tickets, it is the first ticket id not returned; if the end is reached, it is 0.

```
function agentRedemptionQueue(    address _agentVault,    uint256 _firstRedemptionTicketId,    uint256 _pageSize) external view    returns (RedemptionTicketInfo.Data[] memory _queue, uint256 _nextRedemptionTicketId);
```

## Collateral Reservation[​](#collateral-reservation "Direct link to Collateral Reservation")

### `reserveCollateral`[​](#reservecollateral "Direct link to reservecollateral")

Reserves collateral for minting FAssets. Before paying underlying assets for minting, the minter must reserve collateral and pay a collateral reservation fee.

Parameters:

-   `_agentVault`: Agent vault address.
-   `_lots`: Number of lots for which to reserve collateral.
-   `_maxMintingFeeBIPS`: Maximum minting fee (BIPS) that can be charged by the agent - best practice is to copy the current agent's published fee; used to prevent agent from front-running reservation request and increasing fee.
-   `_executor`: Account that is allowed to execute minting (besides minter and agent).

```
function reserveCollateral(    address _agentVault,    uint256 _lots,    uint256 _maxMintingFeeBIPS,    address payable _executor) external payable;
```

## Execute Minting[​](#execute-minting "Direct link to Execute Minting")

### `executeMinting`[​](#executeminting "Direct link to executeminting")

After obtaining proof of underlying payment, the minter calls this method to finish the minting and collect the minted FAssets.

Note: May only be called by:

-   The minter (creator of the collateral reservation request).
-   The executor appointed by the minter.
-   The agent owner (owner of the agent vault in the collateral reservation).

Parameters:

-   `_payment`: Proof of the underlying payment (must contain exact `value + fee` amount and correct payment reference).
-   `_collateralReservationId`: Collateral reservation ID.

```
function executeMinting(    IPayment.Proof calldata _payment,    uint256 _collateralReservationId) external nonReentrant;
```

## Execute Direct Minting[​](#execute-direct-minting "Direct link to Execute Direct Minting")

### `executeDirectMinting`[​](#executedirectminting "Direct link to executedirectminting")

Finalizes [direct minting](/fassets/direct-minting): mints FAssets to the recipient encoded in the XRPL payment (destination tag or memo), using an attestation that the underlying was paid to the FAsset Core Vault.

Who may call, executor preference and timeouts, fees, and rate limits are described in [Direct minting](/fassets/direct-minting) and in [`getDirectMintingOthersCanExecuteAfterSeconds`](#getdirectmintingotherscanexecuteafterseconds).

Parameters:

-   `_payment`: XRP payment proof data (`IXRPPayment.Proof`) for the FDC-verified payment that satisfies the direct-minting rules.

```
function executeDirectMinting(IXRPPayment.Proof calldata _payment)    external payable;
```

## Redemption[​](#redemption "Direct link to Redemption")

### `redeem`[​](#redeem "Direct link to redeem")

Redeem number of lots of FAssets.

Returns the actual redeemed amount.

Parameters:

-   `_lots`: Number of lots to redeem.
-   `_redeemerUnderlyingAddressString`: The address to which the agent must transfer underlying amount.
-   `_executor`: The account that is allowed to execute redemption default (besides redeemer and agent).

```
function redeem(    uint256 _lots,    string memory _redeemerUnderlyingAddressString,    address payable _executor) external payable    returns (uint256 _redeemedAmountUBA);
```

### `redeemAmount`[​](#redeemamount "Direct link to redeemamount")

Redeem up to `_amountUBA` FAssets, like [`redeem`](/fassets/reference/IAssetManager#redeem), but accepts an arbitrary amount in UBA instead of whole lots and does not require a destination tag.

The `redeemAmount` function enforces a minimum redemption size `minimumRedeemAmount`.

In some cases, not all sent FAssets can be redeemed (for example, if there are insufficient tickets or the maximum ticket limit has been reached). In that case, only part of the approved assets are burned and redeemed, and the redeemer can call this method again for the remaining amount. The [`RedemptionAmountIncomplete`](/fassets/reference/IAssetManagerEvents#redemptionamountincomplete) event is emitted with the remaining amount.

Parameters:

-   `_amountUBA`: Amount of redeemer's FAssets that will be burned (this is not the received amount; redemption fee is subtracted).
-   `_redeemerUnderlyingAddressString`: Address to which the agent must transfer the underlying amount.
-   `_executor`: Account that can execute redemption default (besides redeemer and agent).

Returns:

-   `_redeemedAmountUBA`: Actual redeemed amount; may be less than requested when ticket availability or ticket limits apply.

```
function redeemAmount(    uint256 _amountUBA,    string memory _redeemerUnderlyingAddressString,    address payable _executor) external payable    returns (uint256 _redeemedAmountUBA);
```

### `redeemWithTag`[​](#redeemwithtag "Direct link to redeemwithtag")

Redeem up to `_amountUBA` FAssets and require a destination tag in the redemption XRPL payment.

In some cases, not all sent FAssets can be redeemed (for example, if there are insufficient tickets or the maximum ticket limit has been reached). In that case, only part of the approved assets are burned and redeemed, and the redeemer can call this method again for the remaining amount. The [`RedemptionAmountIncomplete`](/fassets/reference/IAssetManagerEvents#redemptionamountincomplete) event is emitted with the remaining amount.

Parameters:

-   `_amountUBA`: Amount of redeemer's FAssets that will be burned (this is not the received amount; redemption fee is subtracted).
-   `_redeemerUnderlyingAddressString`: Address to which the agent must transfer the underlying amount.
-   `_executor`: Account that can execute redemption default (besides redeemer and agent).
-   `_destinationTag`: Destination tag required in redemption payment (XRP only; must fit in 32 bits for now).

Returns:

-   `_redeemedAmountUBA`: Actual redeemed amount; may be less than requested when ticket availability or ticket limits apply.

```
function redeemWithTag(    uint256 _amountUBA,    string memory _redeemerUnderlyingAddressString,    address payable _executor,    uint256 _destinationTag) external payable    returns (uint256 _redeemedAmountUBA);
```

### `minimumRedeemAmountUBA`[​](#minimumredeemamountuba "Direct link to minimumredeemamountuba")

Minimum amount in UBA for redemption with tag. Redemption requests with smaller amounts are rejected. This governance-configured minimum applies to both [`redeemAmount`](/fassets/reference/IAssetManager#redeemamount) and [`redeemWithTag`](/fassets/reference/IAssetManager#redeemwithtag) functions.

```
function minimumRedeemAmountUBA()    external view    returns (uint256);
```

### `redemptionPaymentDefault`[​](#redemptionpaymentdefault "Direct link to redemptionpaymentdefault")

If the agent fails to transfer the redeemed underlying assets in a timely manner, the redeemer or appointed executor can invoke this method and receive payment in collateral. The agent can also call default if the redeemer is unresponsive to payout the redeemer and free the remaining collateral.

Parameters:

-   `_proof`: Proof that the agent did not pay with correct payment reference on the underlying chain.
-   `_redemptionRequestId`: ID of an existing redemption request.

```
function redemptionPaymentDefault(    IReferencedPaymentNonexistence.Proof calldata _proof,    uint256 _redemptionRequestId) external;
```

## Core Vault Settings[​](#core-vault-settings "Direct link to Core Vault Settings")

Reference for managing and interacting with FAssets `ICoreVaultSettings` contract which is inherited by the `IAssetManager` contract.

Sourced from `ICoreVaultSettings.sol` on [GitHub](https://github.com/flare-foundation/fassets/blob/main/contracts/userInterfaces/ICoreVaultClientSettings.sol).

* * *

### `getCoreVaultManager`[​](#getcorevaultmanager "Direct link to getcorevaultmanager")

Returns the core vault manager address. To interact with the Core Vault manager reference the [Core Vault Manager](/fassets/reference/ICoreVaultManager) contract.

```
function getCoreVaultManager()    external view    returns (address);
```

### `getCoreVaultDonationTag`[​](#getcorevaultdonationtag "Direct link to getcorevaultdonationtag")

Returns the destination tag used for donations to the core vault payment address.

```
function getCoreVaultDonationTag()    external view    returns (uint256);
```

### `getCoreVaultMinimumAmountLeftBIPS`[​](#getcorevaultminimumamountleftbips "Direct link to getcorevaultminimumamountleftbips")

Returns the minimum amount of minting left on agent's address after transfer to core vault.

```
function getCoreVaultMinimumAmountLeftBIPS()  external view  returns (uint256);
```

#### `getCoreVaultTransferTimeExtensionSeconds`[​](#getcorevaulttransfertimeextensionseconds "Direct link to getcorevaulttransfertimeextensionseconds")

Returns the extra time for an agent's transfer to the core vault.

```
function getCoreVaultTransferTimeExtensionSeconds()  external view  returns (uint256);
```

### `getCoreVaultTransferFeeBIPS`[​](#getcorevaulttransferfeebips "Direct link to getcorevaulttransferfeebips")

Returns the fee paid by agent for transfer to the core vault.

```
function getCoreVaultTransferFeeBIPS()  external view  returns (uint256);
```

### `getCoreVaultMinimumRedeemLots`[​](#getcorevaultminimumredeemlots "Direct link to getcorevaultminimumredeemlots")

Returns the minimum number of lots that a direct redemption from core vault can take.

```
function getCoreVaultMinimumRedeemLots()  external view  returns (uint256);
```

### `getCoreVaultRedemptionFeeBIPS`[​](#getcorevaultredemptionfeebips "Direct link to getcorevaultredemptionfeebips")

Returns the fee paid by the redeemer for direct redemptions from the core vault.

```
 function getCoreVaultRedemptionFeeBIPS()  external view  returns (uint256);
```
