Deploying a Lending Market
Deployments Paused: Currently the Curve team has paused new deployments for any further lending markets, as we await the release of Llamalend v2 in the coming months.
Currently, there's no UI for deploying lending markets, but you can deploy via Etherscan or contact the Curve team, who are happy to help deploy lending markets with the correct oracles and parameters.
Important: You can only deploy lending markets if one of the tokens is crvUSD (either as the borrowable token or as the collateral token).
Requirements
Data needed when deploying a new lending market:
- Token addresses of the collateral and borrowable tokens
- Simulated parameters (A, fee, loan_discount, liquidation_discount)
- Minimum and maximum borrow rates (defaults to 0.5% and 50% if not set)
- Price oracle contract
- Name for the lending market
For more information on how to acquire this information, see: Oracles & Parameters.
Deploying via Etherscan
This guide assumes you have all the required data from the Requirements section ready.
First, locate the appropriate Factory contract on Etherscan for your target chain. Currently, Llamalend is deployed on the following chains:
- Ethereum: 0xeA6876DDE9e3467564acBeE1Ed5bac88783205E0
- Arbitrum: 0xcaEC110C784c9DF37240a8Ce096D352A75922DeA
- Fraxtal: 0xf3c9bdab17b7016fbe3b77d17b1602a7db93ac66
- Optimism: 0x5EA8f3D674C70b020586933A0a5b250734798BeF
- Sonic: 0x30D1859DaD5A52aE03B6e259d1b48c4b12933993
Deployment Methods
There are two deployment methods available:
-
create_from_poolfunction: Use this when both tokens exist in the same Curve liquidity pool with a suitable oracle. The factory will automatically use the pool's EMA oracle, eliminating the need for an external oracle. -
createfunction: Use this when you need a custom price oracle, such as when a token has a Curve pool but is priced against USDC instead of crvUSD.
Recommendation: The create_from_pool function is the easiest approach. For example, if a protocol wants to create a lending market for their governance token, they should first create a TOKEN/crvUSD liquidity pool, which will provide the necessary oracle.
create_from_pool
This function can be used when both tokens are in the same Curve liquidity pool with a reliable oracle (stableswap-ng, twocrypto-ng, or tricrypto-ng).


Required inputs:
- borrowed_token: Token address of the borrowable token
- collateral_token: Token address of the collateral token
- A: Value obtained from simulations
- fee: Value obtained from simulations
- loan_discount: Value obtained from simulations
- liquidation_discount: Value obtained from simulations
- pool: Curve liquidity pool contract address containing both tokens
- name: Name of the market (see naming conventions)
- min_borrow_rate: Minimum borrow rate (see rate parameters)
- max_borrow_rate: Maximum borrow rate (see rate parameters)
create
This function can be used when the collateral token's oracle cannot be obtained from an existing Curve pool.


Required inputs:
The inputs are the same as the create_from_pool method above, except that instead of providing a pool contract address, you provide a custom price oracle (which must have a price() function to comply with the ABI):
- borrowed_token: Token address of the borrowable token
- collateral_token: Token address of the collateral token
- A: Value obtained from simulations
- fee: Value obtained from simulations
- loan_discount: Value obtained from simulations
- liquidation_discount: Value obtained from simulations
- price_oracle: Custom price oracle contract address (must have
price()function) - name: Name of the market (see naming conventions)
- min_borrow_rate: Minimum borrow rate (see rate parameters)
- max_borrow_rate: Maximum borrow rate (see rate parameters)