How to check how much of given asset can be borrowed?
- undefined Aave
Hi, does anyone know how to check how much of given asset can be borrowed? I mean max amount when borrowing say BTC in Aave flashloan
For Aave flashloan entire available liquidity of pool is available to borrow. In case of stable or variable mode borrow, you can borrow max that can be supported by total collateral i.e. max amount with HF >= 1 ``` available liquidity = totalSupplied - totalBorrowed ``` in case an asset has debt ceiling ``` available liquidity =min( totalBorrowed - debtceiling, totalSupplied - totalBorrowed) ``` More [info](https://aave.peeranha.io/feed).