Selected Credit Vault interfaces. These tables are a navigation aid, not a complete ABI. Obtain the ABI for the verified implementation, including inherited and variant-specific methods. Epoch vault entry points and asynchronous receipts should be integrated using their actual interfaces; do not assume an ERC-4626 deposit/redeem interface.
Components#
| Component | Responsibility |
|---|---|
IdleCDOEpochVariant and inherited IdleCDOCreditVault |
Tranche issuance/accounting, epoch controls, withdrawal requests, and claim forwarding. |
IdleCreditVault strategy |
Borrower/manager configuration, withdrawal receipts, settlement, and recovery reserve. |
IdleCDOEpochQueue, where configured |
Hold queued assets or tranche tokens, process aggregate requests, and distribute claims by epoch. |
The queue entries below cover the standard epoch queue. Check the deployment configuration for any programmable-borrower adapter. A queue address, BB token address, or method in source does not establish that the corresponding route is enabled.
Lender transaction methods#
Inputs named amount below are unsigned integers in base units. Underlying-token inputs use the underlying's decimals; tranche inputs use 18 decimals. Return values from simulation are estimates at that state, not mined transaction receipts.
| Target and method | Input and return | Integration rule |
|---|---|---|
Vault depositAA(uint256 amount) / depositBB(uint256 amount) |
Underlying in; uint256 gross tranche shares. |
Approve underlying to the vault. Ordinary deposits require an unpaused vault and eligibility; BB also requires its enable flag. |
Vault depositDuringEpoch(uint256 amount, address tranche) |
Underlying in; uint256 tranche tokens minted. |
Separate optional route; requires enabled mode, valid tranche, nonzero existing tranche supply, active timing, and other gates. |
Vault requestWithdraw(uint256 amount, address tranche) |
Tranche tokens in; uint256 requested underlying amount. |
Burns caller tranche tokens; no tranche allowance to vault required. Zero means full balance. Normal/instant selection is automatic. |
Vault claimWithdrawRequest() |
No arguments or return value. | Forwards the caller to strategy claim accounting. |
Vault claimInstantWithdrawRequest() |
No arguments or return value. | Requires the vault instant-claim gate, then strategy claim accounting. |
Queue requestDeposit(uint256 amount) |
Underlying in; no return value. | Approve underlying to the configured queue; records the next strategy epoch. |
Queue requestWithdraw(uint256 amount) |
Tranche tokens in; no return value. | Approve tranche tokens to the configured queue. Supply the actual amount; zero does not mean full balance. |
Queue claimDepositRequest(uint256 epoch) |
Request epoch; no return value. | Requires a processed standard deposit with a positive epoch price and zero pending deposits. Transfers tranche tokens. |
Queue claimWithdrawRequest(uint256 epoch) |
Processing epoch; no return value. | Requires queue claim collection and a priced or explicitly zero-value settlement; transfers underlying or clears a zero-value claim. |
Queue deleteRequest(uint256 epoch) / deleteWithdrawRequest(uint256 epoch) |
Request epoch; no return value. | Cancels the caller’s entire unprocessed entry for the specified epoch. |
On a tranche's first mint, address(1) receives 1,000 share base units. The recipient receives the gross return less those units. Use an initialization deposit that quotes more than 1,000 gross share base units and reconcile the recipient's actual balance increase after confirmation. Initialize an empty tranche with a direct deposit before enabling standard queued subscriptions. The queue prices claims from the gross return, so a first-issuance claim can exceed its received shares.
Zero deposit or queue request amounts can produce a successful call without a new position. A direct zero-amount withdrawal uses the entire balance, which may itself be zero. A claim may also succeed on an empty ledger entry or clear a recorded entitlement at zero payout. Reconcile the request state and actual token movement.
State to read#
| Target | Selected getters | Use |
|---|---|---|
| Vault identity | token(), strategy(), AATranche(), BBTranche() |
Resolve canonical related addresses. |
| Vault action gates | paused(), defaulted(), isEpochRunning(), epochEndDate(), epochDuration(), bufferPeriod(), allowAAWithdrawRequest(), allowBBWithdrawRequest() |
Determine candidate actions before simulation. |
| Vault optional routes | isBBDepositEnabled(), isDepositDuringEpochDisabled(), isProgrammableBorrower(), disableInstantWithdraw(), allowInstantWithdraw() |
Distinguish transaction routes and new-request versus claim gates. |
| Vault eligibility | keyring(), keyringPolicyId(), isWalletAllowed(address) |
Read policy and evaluate the actual caller. |
| Vault valuation | tranchePrice(address), virtualPrice(address), maxWithdrawable(address,address) |
Saved price, accounting view, and full-balance normal-request estimate respectively. |
| Strategy | epochNumber(), withdrawsRequests(address), instantWithdrawsRequests(address), apr0Users(address), lastWithdrawRequest(address), postDefaultRequests(address), defaultRecoveryInitialized(), defaultRecoveryFinalized() |
Track receipt cohorts and settlement; receipt balance alone is incomplete. |
| Queue | tranche(), idleCDOEpoch(), userDepositsEpochs(address,uint256), userWithdrawalsEpochs(address,uint256), epochPrice(uint256), epochWithdrawPrice(uint256), epochPendingDeposits(uint256), epochPendingWithdrawals(uint256), epochPendingClaims(uint256), pendingClaims(), isEpochWithdrawZero(uint256) |
Match queue, tranche, user, and epoch; distinguish pending claims from finalized zero payout. |
The isAYSActive and skipDefaultCheck fields are internal storage without public getters in the interfaces described here. Use verified implementation/configuration evidence and simulation to assess those mode restrictions; do not call invented getters.
tranchePrice returns the saved accounting price for an issued tranche, or par when supply is zero. virtualPrice uses managed backing net of recorded fees. Accounting checkpoints record elapsed management fees, and the resulting NAV decline follows the ordinary BB-first loss waterfall. maxWithdrawable estimates a full-balance normal request with elapsed fees and normal-request fee and interest accounting. Simulate the intended request for the actual route and execution estimate. See Management fees and tranche prices.
The queue owner or strategy manager calls processDeposits() and processWithdrawRequests() for the current strategy epoch. Submissions target the next strategy epoch. If the strategy advances past an unprocessed bucket, cancel the request using its original epoch. An outstanding aggregate withdrawal claim sets pendingClaims() and blocks the next withdrawal processor until processWithdrawalClaims(priorEpoch) collects it. See the queue operating sequence.
Events and indexing#
| Event | Emitter and interpretation |
|---|---|
AccrueInterest(uint256 interest, uint256 fees) |
Epoch vault; emitted in the successful settlement accounting path. Decode with the matching ABI and reconcile with transaction/state evidence. |
BorrowerDefault(uint256 funds) |
Epoch vault; emitted by borrower-default handling, which also pauses deposits, stops the epoch, and closes new request flags. funds does not itself establish a finalized recovery payout. |
Both event arguments are non-indexed in this source. The queue declares no dedicated request/claim events in the interfaces described here. Track the originating transaction, token movements, and epoch mappings; an ERC20 transfer alone does not identify every request or prove claimability. Index using chain, block hash, transaction hash, and log index; reconcile reverted or reorganized observations.
Errors and failed simulations#
| Error | Source and interpretation |
|---|---|
NotAllowed() |
Epoch vault, strategy, and queue use this for several role and state gates. It is not a unique KYC error. Inspect caller, state, tranche, flags, and the exact failing method. |
EpochNotRunning() |
Queue submission gate requires a running epoch. |
Is0() |
Used in several contracts; queue withdrawal processing also rejects a zero implied request price. Do not map every occurrence to an empty input. |
ContractLimitReached() |
Deposit would exceed a configured nonzero vault value limit. |
NotAuthorized() |
Inherited owner/guardian checks and other base authorization gates. |
AmountTooHigh() / AlreadyInitialized() / Default() |
Credit-vault base declares these errors; interpretation depends on the executing call path and implementation. |
Inherited libraries, underlying tokens, policy contracts, and variant hooks can also revert. Preserve the raw revert data for diagnostics, decode only against the matching ABI, and present an actionable message after checking the failing gate. A successful simulation can become stale before inclusion; refresh state and handle a mined revert without treating the action as completed.
For product-level distinctions between standard and revolving models, read Vault configurations and Revolving Credit Vaults.