Integration Examples

Complete swap flow

If you want to see a complete flow to make a swap you can review this code. In this example you can see the different steps.

  1. Get pool data

  2. Estimate Clipper Prices

  3. Create a quote

  4. Sign a quote

  5. Execute a transaction

Swaps

There are three kinds of assets:

  1. Shorttail: Assets on Clipper Pool

  2. Longtail: Assets not on Clipper Pool but can be traded through coves.

  3. ClipperLP: Underlying token representing fraction of clipper pool.

Given those three assets, there may be the following Swap combinations:

Core pool Swaps

Native token → Shorttail

Shorttail → Native token

Shorttail → Shorttail

Last updated

#221: Integrating with Clipper RFQ

Change request updated