Why is liquidity position ownership represented by tokens or NFTs?#

Ownership of CenturionDEX liquidity is represented by v2 LP tokens (for CenturionDEX v2 liquidity) and NFTs (for CenturionDEX v3 liquidity).

The wallet address that holds the NFT or the v2 LP tokens owns the liquidity. The owner can remove the liquidity, claim earned fees, or add liquidity to the position. Transferring the v2 LP tokens or the NFT to another address gives ownership of the liquidity to the receiving wallet.

Liquidity on CenturionDEX v2#

CenturionDEX v2 represents liquidity using fungible v2 LP tokens, which follow the CRC-20 standard.

These tokens are deposited in the provider's wallet when liquidity is added to CenturionDEX v2. The amount of v2 LP tokens represents how much liquidity the provider added.

Liquidity on CenturionDEX v3#

CenturionDEX v3 represents each liquidity position as a CRC-721 NFT.

The NFT is deposited in the provider's wallet when liquidity is added to CenturionDEX v3. The NFT stores all of the data for that position.

The NFT stores the following data:

  • Nonce: Tracks permit nonces.
  • Operator: Usually a zero address unless another address is granted permission to manage the liquidity.
  • Token0 address: Address of the first token in the pool.
  • Token1 address: Address of the second token in the pool.
  • Pool fee tier: The selected fee tier for the pool.
  • Lower tick: The lower price boundary of the position.
  • Upper tick: The upper price boundary of the position.
  • Liquidity value: The value of the liquidity in the position.
  • feeGrowthInside0LastX128: Used for fee tracking on Token0.
  • feeGrowthInside1LastX128: Used for fee tracking on Token1.
  • tokensOwed0: A temporary value representing owed tokens for Token0.
  • tokensOwed1: A temporary value representing owed tokens for Token1.