WarpX V3 Factory
The WarpX V3 Factory enables permissionless creation of WarpX V3 liquidity pools for any ERC20 token pair.
Creating a New Pool
function createPool(address tokenA, address tokenB, uint24 fee) external returns (address pool)Creates a liquidity pool for the given token pair and fee tier.
Tokens can be passed in any order; they will be sorted internally
Reverts if the pool already exists or if the fee tier is not supported
Returns the address of the newly created pool
Parameters:
tokenA
address
One of the two tokens in the pool
tokenB
address
The other token in the pool
fee
uint24
Fee tier (e.g., 500, 3000, 10000) in hundredths of a bip
Example:
address pool = factory.createPool(USDC, WETH, 3000); // 0.30% fee tierQuerying Existing Pools
function getPool(address tokenA, address tokenB, uint24 fee) external view returns (address pool)Returns the pool address for a token pair and fee tier, or address(0) if it doesn't exist.
Parameters:
tokenA
address
First token address
tokenB
address
Second token address
fee
uint24
Fee tier
Example:
Checking Fee Tier Validity
Returns the tick spacing for a fee tier, or 0 if the fee tier is not enabled.
Parameters:
fee
uint24
Fee amount to check
Example:
Supported Fee Tiers
100 (0.01%)
1
Stablecoin pairs (e.g., USDC/USDT)
500 (0.05%)
10
Correlated assets (e.g., WETH/stETH)
3000 (0.30%)
60
Most token pairs
10000 (1.00%)
200
Exotic or high-volatility pairs
Last updated