Which tabs are available?
The app checks the connected wallet’s position in the selected pool. Deposit stays available as the starting point. Borrow unlocks when collateral is present, Repay when debt is present, and Withdraw when collateral is present. Withdraw still checks how much can leave without violating the position’s limits. Existing deposits are read from Solana; returning users do not need to deposit again to unlock their position. Choose an additional saved position from the position selector when applicable. A wallet or pool change requires a new position check. Use Refresh position if you changed the position elsewhere.1
Deposit
Choose your collateral token and its paired token, enter a deposit amount, and approve the transaction. Your collateral moves into the protocol’s accounts. Depositing alone does not borrow anything or earn liquidity-provider interest.
2
Borrow
Select Borrow and choose the token you want to receive. Enter the loan amount and review the transaction before approving. The borrowed tokens go to your wallet; your collateral stays deposited. Available liquidity and the protocol’s position and market checks limit the amount you can borrow.
3
Repay
Repay the borrowed token plus accrued interest. Set the maximum you want to spend; the pool takes the amount required up to that limit. Transfer fees can reduce the debt repaid, so check the remaining debt after confirmation.
4
Withdraw
Withdraw eligible collateral to your wallet. Outstanding debt, position health, pool conditions and token restrictions determine how much can leave. Repaying the full debt removes the borrowing constraint, but does not bypass token restrictions or return collateral automatically.
An example: your deposit and your loan are separate
These amounts are hypothetical, assume unchanged token prices, and exclude network fees and token transfer taxes.
A borrowing limit of $807.50 would mean you may borrow **up to** that amount under the quoted conditions. It does not mean your $1,000 deposit was exchanged for $807.50 or that the difference was charged as a fee. You can borrow less, or deposit without borrowing.
Debt is denominated in the borrowed token. If that token’s dollar price changes, the dollar cost of repaying it changes too.
Who pays interest, and who earns it?
Borrowers pay interest. Liquidity providers earn a share of realized interest, and ANVIL receives the configured protocol share. Depositing collateral is a different action from providing liquidity. For example, if $10 of interest reaches the interest vault and the protocol share is 15%, $1.50 belongs to the protocol and $8.50 is allocated to liquidity providers. This illustrates the split; it is not an additional 15% charge on the borrower’s loan. Actual distributions follow the on-chain settings and token accounting. To supply tokens and earn pool fees, see Provide liquidity.How much can I borrow?
The program values collateral using its pool pricing and price-impact calculations. It applies a dynamic collateral factor, a borrowing buffer, and additional position, market and cash-availability checks. In the current code, the collateral factor is capped at 85%, and new borrowing applies 95% of the applicable factor. At that ceiling, the calculation is85% × 95% = 80.75% of the pool-adjusted collateral value. This is a ceiling in the calculation, not a promised percentage of a token’s displayed market value. The actual amount can be lower.
