Solidity API
IOrionVault
Interface for Orion vaults
SynchronousCallDisabled
error SynchronousCallDisabled()
External synchronous calls are disabled in the current context.
DepositRequest
event DepositRequest(address sender, uint256 assets)
A deposit request has been made by a user.
Parameters
Name | Type | Description |
---|---|---|
sender | address | The address of the user making the deposit request. |
assets | uint256 | The amount of assets being deposited. |
DepositRequestCancelled
event DepositRequestCancelled(address user, uint256 amount)
A deposit request has been cancelled.
Parameters
Name | Type | Description |
---|---|---|
user | address | The address of the user whose deposit request was cancelled. |
amount | uint256 | The amount of assets that were requested for deposit. |
RedeemRequest
event RedeemRequest(address sender, uint256 shares)
A redemption request has been made by a user.
Parameters
Name | Type | Description |
---|---|---|
sender | address | The address of the user making the redemption request. |
shares | uint256 | The number of shares being redeemed. |
RedeemRequestCancelled
event RedeemRequestCancelled(address user, uint256 shares)
A redemption request has been cancelled.
Parameters
Name | Type | Description |
---|---|---|
user | address | The address of the user whose redemption request was cancelled. |
shares | uint256 | The number of shares that were requested for redemption. |
CuratorUpdated
event CuratorUpdated(address newCurator)
The curator has been updated.
Parameters
Name | Type | Description |
---|---|---|
newCurator | address | The new curator address. |
FeeModelUpdated
event FeeModelUpdated(uint8 mode, uint16 performanceFee, uint16 managementFee)
The fee model has been updated.
Parameters
Name | Type | Description |
---|---|---|
mode | uint8 | The new calculation mode. |
performanceFee | uint16 | The new performance fee in basis points. |
managementFee | uint16 | The new management fee in basis points. |
Deposit
event Deposit(address user, uint256 amount, uint256 shares)
A deposit request has been processed and completed.
Parameters
Name | Type | Description |
---|---|---|
user | address | The address of the user whose deposit was processed. |
amount | uint256 | The amount of assets that were deposited. |
shares | uint256 | The number of shares that were minted. |
Withdraw
event Withdraw(address user, uint256 assets, uint256 shares)
A redemption request has been processed and completed.
Parameters
Name | Type | Description |
---|---|---|
user | address | The address of the user whose redemption was processed. |
assets | uint256 | The amount of assets that were withdrawn. |
shares | uint256 | The number of shares that were redeemed. |
CuratorFeesAccrued
event CuratorFeesAccrued(uint256 epoch, uint256 feeAmount, uint256 pendingCuratorFees)
Curator fees have been accrued for a specific epoch.
Parameters
Name | Type | Description |
---|---|---|
epoch | uint256 | The epoch for which fees were accrued. |
feeAmount | uint256 | The amount of fees accrued in underlying asset units. |
pendingCuratorFees | uint256 | The total pending curator fees in underlying asset units. |
config
function config() external view returns (contract IOrionConfig)
Orion config getter
Return Values
Name | Type | Description |
---|---|---|
[0] | contract IOrionConfig | The Orion config contract address |
vaultOwner
function vaultOwner() external view returns (address)
Vault owner getter
Return Values
Name | Type | Description |
---|---|---|
[0] | address | The vault owner address |
curator
function curator() external view returns (address)
Curator getter
Return Values
Name | Type | Description |
---|---|---|
[0] | address | The curator address |
pendingCuratorFees
function pendingCuratorFees() external view returns (uint256)
Pending curator fees getter
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | Pending curator fees amount |
convertToAssetsWithPITTotalAssets
function convertToAssetsWithPITTotalAssets(uint256 shares, uint256 pointInTimeTotalAssets, enum Math.Rounding rounding) external view returns (uint256)
Convert shares to assets with point in time total assets.
Parameters
Name | Type | Description |
---|---|---|
shares | uint256 | The amount of shares to convert. |
pointInTimeTotalAssets | uint256 | The point in time total assets. |
rounding | enum Math.Rounding | The rounding mode. |
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | The amount of assets. |
convertToSharesWithPITTotalAssets
function convertToSharesWithPITTotalAssets(uint256 assets, uint256 pointInTimeTotalAssets, enum Math.Rounding rounding) external view returns (uint256)
Convert assets to shares with point in time total assets.
Parameters
Name | Type | Description |
---|---|---|
assets | uint256 | The amount of assets to convert. |
pointInTimeTotalAssets | uint256 | The point in time total assets. |
rounding | enum Math.Rounding | The rounding mode. |
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | The amount of shares. |
requestDeposit
function requestDeposit(uint256 assets) external
Submit an asynchronous deposit request.
No share tokens are minted immediately. The specified amount of underlying tokens is transferred to the liquidity orchestrator for centralized liquidity management.
Parameters
Name | Type | Description |
---|---|---|
assets | uint256 | The amount of the underlying asset to deposit. |
cancelDepositRequest
function cancelDepositRequest(uint256 amount) external
Cancel a previously submitted deposit request.
Allows LPs to withdraw their funds before any share tokens are minted. The request must still have enough balance remaining to cover the cancellation. Funds are returned from the liquidity orchestrator to the LP.
Parameters
Name | Type | Description |
---|---|---|
amount | uint256 | The amount of funds to withdraw. |
requestRedeem
function requestRedeem(uint256 shares) external
Submit a redemption request.
No share tokens are burned immediately. The specified amount of share tokens is transferred to the vault.
Parameters
Name | Type | Description |
---|---|---|
shares | uint256 | The amount of the share tokens to withdraw. |
cancelRedeemRequest
function cancelRedeemRequest(uint256 shares) external
Cancel a previously submitted redemption request.
Allows LPs to recover their share tokens before any burning occurs. The request must still have enough shares remaining to cover the cancellation. Share tokens are returned from the vault.
Parameters
Name | Type | Description |
---|---|---|
shares | uint256 | The amount of share tokens to recover. |
updateCurator
function updateCurator(address newCurator) external
Update the vault curator address
The curator is responsible for setting allocation strategy for the vault's assets. This function enables vault owners to change allocation strategies by updating the curator. This is particularly important when curators are smart contracts, not just addresses.
Parameters
Name | Type | Description |
---|---|---|
newCurator | address | The new curator address. Must be non-zero. |
updateVaultWhitelist
function updateVaultWhitelist(address[] assets) external
Update the vault whitelist
Parameters
Name | Type | Description |
---|---|---|
assets | address[] | The new whitelist of assets. |
vaultWhitelist
function vaultWhitelist() external view returns (address[])
Get the vault whitelist
Return Values
Name | Type | Description |
---|---|---|
[0] | address[] | The array of whitelisted asset addresses for this vault. |
updateFeeModel
function updateFeeModel(uint8 mode, uint16 performanceFee, uint16 managementFee) external
Update the fee model parameters
Parameters
Name | Type | Description |
---|---|---|
mode | uint8 | The calculation mode for fees |
performanceFee | uint16 | The performance fee |
managementFee | uint16 | The management fee |
claimCuratorFees
function claimCuratorFees(uint256 amount) external
Claim accrued curator fees
Parameters
Name | Type | Description |
---|---|---|
amount | uint256 | The amount of curator fees to claim |
pendingDeposit
function pendingDeposit() external view returns (uint256)
Get total pending deposit amount across all users
This returns asset amounts, not share amounts
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | Total pending deposits denominated in underlying asset units (e.g., USDC, ETH) |
pendingRedeem
function pendingRedeem() external view returns (uint256)
Get total pending redemption shares across all users
This returns share amounts, not underlying asset amounts
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | Total pending redemptions denominated in vault share units |
curatorFee
function curatorFee(uint256 totalAssets) external view returns (uint256)
Calculate the curator's fee based on total assets
Warning: Calling this function mid-epoch may return inaccurate results since fees are calculated based on the full epoch duration
Parameters
Name | Type | Description |
---|---|---|
totalAssets | uint256 | The total assets under management |
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | The curator fee amount in underlying asset units |
fulfillDeposit
function fulfillDeposit(uint256 depositTotalAssets) external
Process all pending deposit requests and mint shares to depositors
Parameters
Name | Type | Description |
---|---|---|
depositTotalAssets | uint256 | The total assets associated with the deposit requests |
fulfillRedeem
function fulfillRedeem(uint256 redeemTotalAssets) external
Process all pending redemption requests and burn shares from redeemers
Parameters
Name | Type | Description |
---|---|---|
redeemTotalAssets | uint256 | The total assets associated with the redemption requests |
accrueCuratorFees
function accrueCuratorFees(uint256 epoch, uint256 feeAmount) external
Accrue curator fees for a specific epoch
Parameters
Name | Type | Description |
---|---|---|
epoch | uint256 | The epoch for which to accrue fees |
feeAmount | uint256 | The amount of curator fees to accrue in underlying asset units |