Aggregating Pools
Tips on integrating Shell-native liquidity pools
Quick Links
Swap through Shell-native fractal pools

You can use Shell pools to swap any ERC-20 (or ERC-721 or ERC-1155) tokens, as long as there exists a viable path of AMMs.
Fractal pools can serve as a stepping stone in swapping between ERC-20 tokens. A fractal pool uses LP tokens as one or both of its reserve assets. For example:
- The two reserve assets of - Stablepoolare- DAI+USDCLP token and- USDT+USDCLP token.
- The two reserve assets for - ETH+USDpool are- shETHand- StablepoolLP token.
Let's swap shDAI to shETH. You must deposit shDAI into the DAI+USDC pool to get the DAI+USDC LP token, then take that LP token and deposit it into Stablepool to get the Stablepool LP token, then swap that LP token to shETH using the fractal pool (ETH+USD).
Remember in Shell Protocol, ERC-20 (or 721 or 1155) tokens are wrapped onto a shared ERC-1155 ledger (the Ocean). Shell pools always use the Shell-wrapped ERC-1155 version of these tokens.
Shell LP tokens are also ERC-1155. They each have their own Ocean IDs, just as the Shell-wrapped ERC-20s do.
Whenever you swap from one ERC-20 token to another through Shell pools, there will be a wrap and unwrap in that transaction. For example, trading DAI for ETH would look like this:
- wrap - DAI->- shDAI
- deposit - shDAI->- DAI+USDCLP
- deposit - DAI+USDCLP ->- StablepoolLP
- swap - StablepoolLP ->- shETH(through- ETH+USDpool)
- unwrap - shETH->- ETH
The fractal design makes querying the prices of token pairs somewhat complicated.
Last updated

