A collection of example scripts that illustrate how to use the Balancer SDK to create pools, swap tokens, add liquidity, and remove liquidity. Everything is configured to run on a local fork of Ethereum mainnet and use the Balancer Aave Lido wETH-wstETH pool
- Clone this repo & install dependencies
git clone https://github.com/balancer/balancer-v3-sdk-examples
cd balancer-v3-sdk-examples
pnpm install
- Add a
MAINNET_RPC_URLto a.envfile
MAINNET_RPC_URL=
- Run an example script
npx hardhat run scripts/add-liquidity/addLiquidityProportional.ts