Routing: composite exchanges on Swop.fi
We’ve got an important upgrade of user experience on Swop.fi: the feature of exchanging one token for another via an intermediate token. Now you can swap tokens that do not have a common pool, and Swop.fi prompts you the best route.
Exchange in pair without common pool
Each token on Swop.fi (except EAST and RACE) has a pool with USDN, so the exchange via USDN is available for almost any pair.
For example, you exchange USDT to WAVES (or vice versa). If you manually perform the two exchanges — USDT to USDN and then USDN to WAVES, you have to pay the network fee of 0.005 WAVES twice, and the price of the second exchange may change while executing the first.
The new smart contract of routing performs both exchanges in a single transaction using nested invocations of the pools’ smart contracts. In this way, you initially fix the minimum amount to receive and pay the network fee only once.
If the prices in the pools have changed due to other users’ trades before yours and the minimum to receive became unachievable, your transaction is canceled.
Prompt optimal route
In pools with high liquidity, the price impact of an individual trade is far less significant. That’s why, for example, it’s often more profitable to make the USDN to EGG exchange via the WAVES-USDN and EGG-WAVES pools than directly via the EGG-USDN pool — even taking into account the fee of each pool.
Swop.fi automatically finds the best possible route for your chosen token pair and exchange amount. You can view all available options and their results if you want.