ILendingProtocol
Defined in: protocols/lending.ts:25
The lending interface every lending and vault module implements. Vault modules (Morpho vaults,
Mellow, Kamino Earn) support supply and withdraw; borrowing exists where the market allows
it, otherwise it throws.
Methods
Section titled “Methods”borrow()
Section titled “borrow()”borrow(
options):Promise<LendingResult>
Defined in: protocols/lending.ts:35
Borrow against collateral.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingResult>
quoteBorrow()
Section titled “quoteBorrow()”quoteBorrow(
options):Promise<LendingQuote>
Defined in: protocols/lending.ts:37
Network fee of borrow.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingQuote>
quoteRepay()
Section titled “quoteRepay()”quoteRepay(
options):Promise<LendingQuote>
Defined in: protocols/lending.ts:41
Network fee of repay.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingQuote>
quoteSupply()
Section titled “quoteSupply()”quoteSupply(
options):Promise<LendingQuote>
Defined in: protocols/lending.ts:29
Network fee of supply.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingQuote>
quoteWithdraw()
Section titled “quoteWithdraw()”quoteWithdraw(
options):Promise<LendingQuote>
Defined in: protocols/lending.ts:33
Network fee of withdraw.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingQuote>
repay()
Section titled “repay()”repay(
options):Promise<LendingResult>
Defined in: protocols/lending.ts:39
Repay a borrow.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingResult>
supply()
Section titled “supply()”supply(
options):Promise<LendingResult>
Defined in: protocols/lending.ts:27
Deposit into the market or vault. Sends an approval first when needed.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingResult>
withdraw()
Section titled “withdraw()”withdraw(
options):Promise<LendingResult>
Defined in: protocols/lending.ts:31
Withdraw a deposit.
Parameters
Section titled “Parameters”options
Section titled “options”Returns
Section titled “Returns”Promise<LendingResult>