Returns the total amount of underlying assets in open orders for a users account.
lendOrder
functionlendOrder(uint256amount)external;
Opens a lend order for a user.
Users have the right at anytime to cancel their lend order and withdraw their assets.
Assets will be transferred to the BloomPool contract when executing this function, but no receipt token will be given. TBYs are only minted after orders have been matched and market makers have performed their swaps.
killOpenOrder
Allows users to cancel their open lend order and withdraw their underlying assets.
matchedDepth
Returns the current total depth of matched orders.
amountMatched
Returns the total amount of underlying assets in matched orders for a users account.
matchedOrder
Returns the matched order details for a users account in the form of a MatchOrder struct.
matchedOrderCount
Returns the number of matched orders for a users account.
killMatchOrder
Allows users to cancel their match lend orders and withdraw their underlying assets.
Returns the totalRemoved amount in terms of asset tokens.
killBorrowerMatch
Allows borrowers to cancel their match orders and withdraw their underlying assets
Returns the lenderAmount and borrowerReturn in terms of underlying assets that were returned to the various users.
fillOrder
This is a permissioned function. Only KYCed borrowers can call this function.
Allows borrowers to fill a single accounts lend order with a specified amount of underlying assets.
Returns the amount of liquidity filled in terms of asset tokens.
fillOrders
This is a permissioned function. Only KYCed borrowers can call this function.
Allows borrowers to fill a multiple accounts lend orders with a specified amount of underlying assets.
Returns the amount of liquidity filled in terms of asset tokens.
idleCapital
Returns the idle capital of the borrower.
withdrawIdleCapital
Allows borrowers to withdraw idle capital from the system.
function matchedDepth() external view returns (uint256);
function amountMatched(address account) external view returns (uint256 amount);
function matchedOrder(address account, uint256 index) external view returns (MatchOrder memory);
/**
* @notice Struct to store the details of a lend order that has been matched.
* @param lCollateral The amount of underlying assets the lender used as collateral.
* @param bCollateral The amount of underlying assets the borrower used as collateral.
* @param borrower The address of the borrower who filled the order.
*/
struct MatchOrder {
uint128 lCollateral;
uint128 bCollateral;
address borrower;
}
function matchedOrderCount(address account) external view returns (uint256);
function killMatchOrder(uint256 amount) external returns (uint256 totalRemoved);
function killBorrowerMatch(address lender) external returns (uint256 lenderAmount, uint256 borrowerReturn);
function fillOrder(address account, uint256 amount) external returns (uint256 filled);
function fillOrders(address[] calldata accounts, uint256 amount) external returns (uint256 filled);
function idleCapital(address account) external view returns (uint256);
function withdrawIdleCapital(uint256 amount) external;