TokenisedFundVault

Documentation for eth_defi.tokenised_fund.vault.TokenisedFundVault Python class.

class TokenisedFundVault

Bases: eth_defi.vault.base.VaultBase

Base class for every tokenised fund protocol adapter.

Tokenised fund classification belongs to the adapter type instead of a manually maintained address list. This also covers products discovered dynamically from issuer registries, such as Asseto funds.

Parameters
  • token_cache

    Token cache for vault tokens.

    Allows to pass eth_defi.token.TokenDiskCache to speed up operations.

  • require_denomination_token

    If True, accessing denomination_token will raise RuntimeError when the on-chain lookup returns None.

    Use for deployment scripts and operational contexts where a missing denomination token is always a hard error.

Attributes summary

address

Vault contract address.

chain_id

Chain this vault is on

denomination_token

Get the token which denominates the vault valuation

deposit_manager

Deposit manager assocaited with this vault

description

Human-readable vault strategy description.

flow_manager

Flow manager associated with this vault

info

Get info dictionary related to this vault deployment.

manager_name

Protocol-supplied vault manager or curator display name.

name

Vault name.

share_token

ERC-20 that presents vault shares.

short_description

One-liner vault summary.

symbol

Vault share token symbol

whitelist_notes

Optional qualification for the exported whitelist status.

Methods summary

__init__([token_cache, ...])

param token_cache

fetch_available_liquidity([block_identifier])

Get the amount of denomination token available for immediate withdrawal.

fetch_denomination_token()

Read denomination token from onchain.

fetch_denomination_token_address()

Get the address for the denomination token when one exists.

fetch_deposit_closed_reason()

Get human-readable reason why deposits are closed.

fetch_deposit_next_open()

Get when deposits will next be open.

fetch_info()

Read vault parameters from the chain.

fetch_minimum_deposit([block_identifier])

Fetch a source-proven minimum deposit in decimal token units.

fetch_minimum_redemption([block_identifier])

Fetch a source-proven redemption minimum in decimal share units.

fetch_nav()

Fetch the most recent onchain NAV value.

fetch_portfolio(universe[, block_identifier])

Read the current token balances of a vault.

fetch_redemption_closed_reason()

Get human-readable reason why redemptions are closed.

fetch_redemption_next_open()

Get when withdrawals/redemptions will next be open.

fetch_scan_record_extra_data()

Fetch protocol-specific private scan row columns.

fetch_share_token()

Read share token details onchain.

fetch_utilisation_percent([block_identifier])

Get the percentage of assets currently lent out.

get_deposit_fee(block_identifier)

Deposit fee is set to zero by default as vaults usually do not have deposit fees.

get_deposit_manager()

Return a manager that explicitly refuses public fund operations.

get_deposit_manager_capability()

Report explicit lack of public deposit and redemption support.

get_estimated_lock_up()

What is the estimated lock-up period for this vault.

get_fee_data()

Get fee data structure for this vault.

get_fee_mode()

Get how this vault accounts its fees.

get_flags()

Return vault flags including the tokenised fund classification.

get_flow_manager()

Get flow manager to read indiviaul settle events.

get_historical_reader(stateful)

Get share price reader to fetch historical returns.

get_link([referral])

Return the issuer's most useful public fund link.

get_management_fee(block_identifier)

Get the current management fee as a percent.

get_notes()

Get a human readable message if we know somethign special is going on with this vault.

get_performance_fee(block_identifier)

Get the current performance fee as a percent.

get_protocol_name()

Return the name of the vault protocol.

get_risk()

Get risk profile of this vault.

get_share_price_source()

Return the source used for share-price observations.

get_spec()

get_whitelist_notes()

Return an export caveat for the vault-wide whitelist status.

get_withdraw_fee(block_identifier)

Withdraw fee is set to zero by default as vaults usually do not have withdraw fees.

has_block_range_event_support()

Does this vault support block range-based event queries for deposits and redemptions.

has_custom_fees()

Does this vault have fees outside the shared fee model.

has_deposit_distribution_to_all_positions()

Deposits go automatically to all open positions.

is_account_whitelisted(address)

Determine whether an account has completed the vault's KYC policy.

is_whitelisted_deposit()

Classify tokenised-fund subscriptions as permissioned.

is_whitelisted_deposit()

Classify tokenised-fund subscriptions as permissioned.

Tokenised-fund adapters model issuer-operated products whose subscriptions require investor eligibility, issuer approval, or both. This is a vault-wide classification: individual adapters may expose different KYC, allow-list, transfer-agent, or offchain settlement mechanisms, so is_account_whitelisted() remains protocol-specific.

Returns

Always True because tokenised-fund deposits are permissioned.

Return type

bool

get_deposit_manager()

Return a manager that explicitly refuses public fund operations.

The manager gives runtime callers a typed refusal, while get_deposit_manager_capability() provides the corresponding report metadata. Concrete issuer integrations must replace both only after implementing their complete permission-aware dealing lifecycle.

Returns

Non-operational tokenised-fund deposit manager.

Return type

eth_defi.tokenised_fund.vault.TokenisedFundDepositManager

get_deposit_manager_capability()

Report explicit lack of public deposit and redemption support.

Returns

A two-direction capability with both operations disabled.

Return type

eth_defi.vault.deposit_redeem.VaultDepositManagerCapability

get_flags()

Return vault flags including the tokenised fund classification.

Preserve address- and protocol-specific flags supplied by the generic vault implementation, then add the descriptive flag used by tokenised fund listings.

Returns

A new set containing all generic flags and VaultFlag.tokenised_fund.

Return type

set[eth_defi.vault.flag.VaultFlag]

get_link(referral=None)

Return the issuer’s most useful public fund link.

Tokenised-fund adapters must provide a product landing page where one exists, then fall back to an official announcement, curator page or protocol page. A block-explorer address is technical contract metadata, not an investor-facing product link, and is never a valid fallback for these products.

Parameters

referral (Optional[str]) – Optional referral code. Tokenised-fund products currently do not use it.

Returns

An official issuer, curator or protocol URL.

Raises

NotImplementedError – Always. Concrete adapters must select the appropriate official link rather than inheriting VaultBase’s explorer URL.

Return type

str

__init__(token_cache=None, require_denomination_token=False)
Parameters
  • token_cache (Optional[dict]) –

    Token cache for vault tokens.

    Allows to pass eth_defi.token.TokenDiskCache to speed up operations.

  • require_denomination_token (bool) –

    If True, accessing denomination_token will raise RuntimeError when the on-chain lookup returns None.

    Use for deployment scripts and operational contexts where a missing denomination token is always a hard error.

abstract property address: eth_typing.evm.HexAddress

Vault contract address.

  • Often vault protocols need multiple contracts per vault, so what this function returns depends on the protocol

abstract property chain_id: int

Chain this vault is on

property denomination_token: Optional[eth_defi.token.TokenDetails]

Get the token which denominates the vault valuation

  • Used in deposits and redemptions

  • Used in NAV calculation

  • Used in profit benchmarks

  • Usually USDC

Returns

Token wrapper instance.

Maybe None for broken vaults like https://arbiscan.io/address/0x9d0fbc852deccb7dcdd6cb224fa7561efda74411#code

Note

None results are not cached — the next access will retry the on-chain call. This avoids permanently caching a transient RPC failure.

property deposit_manager: eth_defi.vault.deposit_redeem.VaultDepositManager

Deposit manager assocaited with this vault

property description: Optional[str]

Human-readable vault strategy description.

  • Fetched from protocol-specific offchain sources (e.g. Euler GitHub labels, Lagoon web app API)

  • Returns None if the protocol does not provide descriptions or the vault is not in the metadata source

  • Override in subclasses that support offchain metadata

fetch_available_liquidity(block_identifier='latest')

Get the amount of denomination token available for immediate withdrawal.

Only applicable to lending protocol vaults (IPOR, Euler, Morpho, Gearbox, etc.). Non-lending protocols should leave this method unimplemented.

Note: maxRedeem(address(0)) does NOT work as a proxy for available liquidity because it requires a specific address that has already deposited shares. For address(0), balanceOf is always 0, so maxRedeem returns 0 regardless of actual liquidity.

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) – Block to query. Defaults to “latest”.

Raises

NotImplementedError – For non-lending protocol vaults.

Returns

Amount in denomination token units (human-readable Decimal).

Return type

Optional[decimal.Decimal]

abstract fetch_denomination_token()

Read denomination token from onchain.

Use denomination_token() for cached access.

Return type

eth_defi.token.TokenDetails

fetch_denomination_token_address()

Get the address for the denomination token when one exists.

Synthetic accounting units used by some tokenised funds do not have an ERC-20 denomination token and return None.

This may trigger an RPC call.

Returns

ERC-20 denomination token address, or None for a synthetic accounting unit.

Return type

Optional[eth_typing.evm.HexAddress]

fetch_deposit_closed_reason()

Get human-readable reason why deposits are closed.

  • Override in protocol-specific subclasses

  • Default behaviour: assume deposits are always open (return None)

Returns

Human-readable string explaining why deposits are closed, or None if deposits are open.

Example reasons:

  • ”Epoch redemption window closed (opens in 14h)”

  • ”Vault paused by admin”

  • ”Max deposit cap reached”

  • ”Vault utilisation too high”

Return type

Optional[str]

fetch_deposit_next_open()

Get when deposits will next be open.

  • For epoch-based vaults (Ostium, D2), return calculated window open time

  • For non-epoch vaults (Plutus, IPOR, Morpho), return None

  • Override in protocol-specific subclasses

Returns

Naive UTC datetime when deposits will next be available, or None if:

  • Deposits are currently open

  • Timing is unpredictable (manually controlled)

  • Protocol does not support timing information

Return type

Optional[datetime.datetime]

abstract fetch_info()

Read vault parameters from the chain.

Use info() property for cached access.

Return type

eth_defi.vault.base.VaultInfo

fetch_minimum_deposit(block_identifier='latest')

Fetch a source-proven minimum deposit in decimal token units.

A None result means this adapter does not expose a known minimum; it does not prove the protocol accepts arbitrarily small deposits. A zero result means the adapter positively established that the vault has no minimum deposit.

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) – Block at which to read the protocol configuration.

Returns

Decimal denomination-token minimum, or None when unknown.

Return type

Optional[decimal.Decimal]

fetch_minimum_redemption(block_identifier='latest')

Fetch a source-proven redemption minimum in decimal share units.

A None result means this adapter does not expose a known minimum; it does not prove the protocol accepts arbitrarily small redemptions. A zero result means the adapter positively established that the vault has no minimum redemption.

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) – Block at which to read the protocol configuration.

Returns

Decimal vault-share minimum, or None when unknown.

Return type

Optional[decimal.Decimal]

abstract fetch_nav()

Fetch the most recent onchain NAV value.

Returns

Vault NAV, denominated in denomination_token()

Return type

decimal.Decimal

abstract fetch_portfolio(universe, block_identifier=None)

Read the current token balances of a vault.

  • SHould be supported by all implementations

Parameters
Return type

eth_defi.vault.base.VaultPortfolio

fetch_redemption_closed_reason()

Get human-readable reason why redemptions are closed.

  • Override in protocol-specific subclasses

  • Default behaviour: assume redemptions are always open (return None)

Returns

Human-readable string explaining why redemptions are closed, or None if redemptions are open.

Example reasons:

  • ”Epoch funding phase in progress (opens in 2d 5h)”

  • ”Vault paused by admin”

  • ”Vault utilisation too high - insufficient liquidity”

Return type

Optional[str]

fetch_redemption_next_open()

Get when withdrawals/redemptions will next be open.

  • For epoch-based vaults (Ostium, D2), return calculated window open time

  • For non-epoch vaults (Plutus, IPOR, Morpho), return None

  • Override in protocol-specific subclasses

Returns

Naive UTC datetime when withdrawals will next be available, or None if:

  • Withdrawals are currently open

  • Timing is unpredictable (manually controlled)

  • Protocol does not support timing information

Return type

Optional[datetime.datetime]

fetch_scan_record_extra_data()

Fetch protocol-specific private scan row columns.

Some vault protocols expose structured metadata that is useful for the raw scanner output but does not fit the shared human-readable columns. Override this hook in protocol-specific subclasses instead of adding a separate branch to eth_defi.erc_4626.scan.create_vault_scan_record().

Returns

Mapping of private scan-row column names, usually prefixed with _. The default implementation returns no extra data.

Return type

dict[str, object]

abstract fetch_share_token()

Read share token details onchain.

Use share_token() for cached access.

Return type

eth_defi.token.TokenDetails

fetch_utilisation_percent(block_identifier='latest')

Get the percentage of assets currently lent out.

Only applicable to lending protocol vaults (IPOR, Euler, Morpho, Gearbox, etc.). Non-lending protocols should leave this method unimplemented.

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) – Block to query. Defaults to “latest”.

Raises

NotImplementedError – For non-lending protocol vaults.

Returns

Utilisation as float between 0.0 and 1.0 (0% to 100%).

Return type

Optional[float]

property flow_manager: eth_defi.vault.base.VaultFlowManager

Flow manager associated with this vault

get_deposit_fee(block_identifier)

Deposit fee is set to zero by default as vaults usually do not have deposit fees.

Internal: Use get_fee_data().

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) –

Return type

Optional[float]

get_estimated_lock_up()

What is the estimated lock-up period for this vault.

Returns

None if not know

Return type

Optional[datetime.timedelta]

get_fee_data()

Get fee data structure for this vault.

Raises

ValueError – In the case of broken or unimplemented fee reading methods in the smart contract

Return type

eth_defi.vault.fee.FeeData

get_fee_mode()

Get how this vault accounts its fees.

Return type

Optional[eth_defi.vault.fee.VaultFeeMode]

abstract get_flow_manager()

Get flow manager to read indiviaul settle events.

Return type

eth_defi.vault.base.VaultFlowManager

abstract get_historical_reader(stateful)

Get share price reader to fetch historical returns.

Parameters

stateful (bool) – If True, use a stateful reading strategy.

Returns

None if unsupported

Return type

eth_defi.vault.base.VaultHistoricalReader

get_management_fee(block_identifier)

Get the current management fee as a percent.

Internal: Use get_fee_data().

Returns

0.1 = 10%

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) –

Return type

float

get_notes()

Get a human readable message if we know somethign special is going on with this vault.

Return type

Optional[str]

get_performance_fee(block_identifier)

Get the current performance fee as a percent.

Internal: Use get_fee_data().

Returns

0.1 = 10%

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) –

Return type

float

get_protocol_name()

Return the name of the vault protocol.

Return type

str

get_risk()

Get risk profile of this vault.

Return type

Optional[eth_defi.vault.risk.VaultTechnicalRisk]

get_share_price_source()

Return the source used for share-price observations.

Vault integrations override this method when they expose a share price. Returning None distinguishes unsupported or unknown pricing from a known source classification.

Returns

Share-price source, or None when the adapter does not provide one.

Return type

Optional[eth_defi.vault.price_source.PriceSource]

get_whitelist_notes()

Return an export caveat for the vault-wide whitelist status.

Adapters may attach a concise, stable explanation when a classification is an explicitly requested operating assumption or excludes an integration-specific permission mechanism. The note describes the policy classification only; it must not be used to report temporary deposit availability.

Returns

Export note, or None when the classification needs no caveat.

Return type

Optional[str]

get_withdraw_fee(block_identifier)

Withdraw fee is set to zero by default as vaults usually do not have withdraw fees.

Internal: Use get_fee_data().

Parameters

block_identifier (Union[Literal['latest', 'earliest', 'pending', 'safe', 'finalized'], eth_typing.evm.BlockNumber, eth_typing.evm.Hash32, eth_typing.encoding.HexStr, int]) –

Return type

float

abstract has_block_range_event_support()

Does this vault support block range-based event queries for deposits and redemptions.

  • If not we use chain balance polling-based approach

Return type

bool

has_custom_fees()

Does this vault have fees outside the shared fee model.

Custom fees cause risk in vault comparison because the shared management/performance/deposit/withdraw fee fields cannot describe the full fee structure.

Do not return True merely because a vault implements custom accessors for ordinary management, performance, deposit, or withdraw fees. Return True only when some vault fee cannot be reflected in those standard fields as a fee-like value.

Returns

True if the vault has fees outside the shared fee model.

Return type

bool

abstract has_deposit_distribution_to_all_positions()

Deposits go automatically to all open positions.

  • Deposits do not land into the vault as cash

  • Instead, smart contracts automatically increase all open positions

  • The behaviour of Velvet Capital

Return type

bool

property info: eth_defi.vault.base.VaultInfo

Get info dictionary related to this vault deployment.

  • Get cached data on the various vault parameters

Returns

Vault protocol specific information dictionary

is_account_whitelisted(address)

Determine whether an account has completed the vault’s KYC policy.

The result concerns KYC or manual identity-approval membership only. A protocol may still require scheduling, a token balance, an allowance, available capacity, or an open epoch before a deposit can be submitted. Callers must use the relevant deposit manager pre-flight before broadcasting a transaction.

Parameters

address (eth_typing.evm.HexAddress) – Account whose deposit-policy membership is queried.

Returns

True when the account has the required KYC/identity approval.

Raises

NotImplementedError – If the adapter cannot safely query account membership.

Return type

bool

property manager_name: Optional[str]

Protocol-supplied vault manager or curator display name.

  • Used when the vault name itself does not contain the curator brand

  • Returns None if the protocol does not expose separate manager metadata

  • Override in subclasses that support manager or operator metadata

abstract property name: str

Vault name.

property share_token: eth_defi.token.TokenDetails

ERC-20 that presents vault shares.

  • User gets shares on deposit and burns them on redemption

property short_description: Optional[str]

One-liner vault summary.

  • Shorter version of description() suitable for listings and tables

  • Returns None if not available

  • Override in subclasses that support offchain metadata

abstract property symbol: str

Vault share token symbol