Calix Chain

AMM DEX

Uniswap V2 / PancakeSwap V2-compatible AMM deployed on the Calix EVM. Permissionless liquidity pools, 0.3% swap fee, and fully open-source contracts.

How It Works

The DEX uses the constant-product formula x ยท y = k. Any address can create a trading pair via the factory; the pair contract mints LP tokens representing a proportional share of the pool. All pairs are deployed via CREATE2, so addresses are deterministic and can be computed off-chain.

๐Ÿ’ก
PancakeSwap V2 compatible. PancakeSwap V2 is a fork of Uniswap V2 and shares the same contract interface. Any SDK, tool, or frontend built for PancakeSwap V2 works on Calix DEX without modification โ€” just switch to the Calix RPC endpoint and contract addresses.

Deployed Contracts

ContractDescriptionAddress
WCLXWrapped CLX โ€” ERC-20 wrapper for native CLXAvailable at launch
UniswapV2FactoryDeploys and indexes all pairsAvailable at launch
UniswapV2PairPer-pair AMM pool (deployed by factory)CREATE2
UniswapV2Router02User-facing router: swap, add/remove liquidityAvailable at launch

Key Operations

FunctionRouter MethodNotes
Add liquidity (tokens)addLiquidityDeposits tokenA + tokenB, mints LP tokens
Add liquidity (native CLX)addLiquidityCLXWraps CLX to WCLX internally
Remove liquidityremoveLiquidityBurns LP tokens, returns underlying tokens
Swap tokens โ†’ tokensswapExactTokensForTokensExact input, minimum output enforced
Swap CLX โ†’ tokensswapExactCLXForTokensSend CLX as msg.value
Swap tokens โ†’ CLXswapExactTokensForCLXUnwraps WCLX, sends native CLX to recipient

ethers.js Integration

import { ethers } from "ethers";
import RouterABI from "./abi/UniswapV2Router02.json";

const ROUTER_ADDRESS = "0x..."; // Available at launch โ€” see /scan for verified address

const provider = new ethers.JsonRpcProvider("https://calixchain.io/rpc");
const signer   = await provider.getSigner();
const router   = new ethers.Contract(ROUTER_ADDRESS, RouterABI, signer);

// Swap exact 1 CLX for tokens
const tx = await router.swapExactCLXForTokens(
  amountOutMin,
  [WCLX_ADDRESS, tokenAddress],
  recipientAddress,
  Math.floor(Date.now() / 1000) + 300,   // deadline: 5 min
  { value: ethers.parseEther("1") }
);
await tx.wait();

Reference