Theory

To Polkaswap means to exchange (swap) tokens on Polkaswap, Polkaswap is a non-custodial, cross-chain AMM DEX protocol for swapping tokens, Polkaswap removes trusted intermediaries and provides the opportunity for faster trading, and Polkaswap also combines multiple liquidity sources under a common liquidity aggregation algorithm, operating completely on-chain, in a trustless and decentralized way.

XYK Pools are managed by the community. Anyone can provide liquidity to any pool. Liquidity pools (XYK pools) are explained in this video on the Finemtaics YouTube channel. It's recommended to watch it in order to understand how Pools work in general.

You can provide liquidity in an XYK pool so that users are able to exchange tokens. There are 3 main cases here:

  1. The pool doesn't exist and you'll be the first liquidity provider (LP)
  2. The pool exists and you're adding liquidity
  3. You already have a share in the pool and you'd like to remove liquidity

Every liquidity provider gets PSWAP rewards for providing liquidity. Rewards are the incentive for users to provide liquidity. There are 2 types of rewards:

  1. Rewards paid from LP fees
  2. LP Farming bonus rewards

Rewards paid from LP fees are distributed every day for each liquidity pool. For example, if you have a share in 3 liquidity pools, then your rewards that are available to claim will be updated twice a day.

LP Farming bonus rewards are distributed every 6 hours.

Along with the network fee in XOR, all 3 cases require an additional fee - liquidity provider fee (LP fee). The LP fee is used to incentivise liquidity providers to supply liquidity in liquidity pools. Liquidity pools are described in this article.

Practice

We recommend using the SORA testnet for practice exercises. Here are the Testnet links:

  1. Polkaswap test application
  2. Polkadot js SORA testnet application
  3. Android testnet application
  4. iOS testnet application

In the practice section, we'll create a liquidity pool, provide liquidity to the existing pool and remove the liquidity.

Creating a new Liquidity pool

Creating a pool is really easy. Just open Polkaswap, then open the Pool section.

Untitled

There are 2 options: