AMM Contracts

Realtime Exchange utilizes UniswapV2 for its Automated Market Makers (AMMs), specifically leveraging the UniswapV2 Router and Factory contracts. Each market has its own corresponding pair.

Contract Addresses

ContractAddress
Router0x0000000000000000000000000000000000000000
Factory0x0000000000000000000000000000000000000000
Pair Init Code Hash0x0000000000000000000000000000000000000000000000000000000000000000
AMM (V2) is currently not enabled on either network. CLMM (V3) is the primary liquidity solution.

Architecture

The AMM system consists of three main components:

Factory Contract

Creates and manages trading pair contracts. Each unique token pair gets its own dedicated pair contract.

Router Contract

Handles swap execution and liquidity operations. Provides a safe interface for interacting with pair contracts.

Pair Contracts

Individual market contracts holding liquidity for specific token pairs. Implement the constant-product formula for pricing.

Reference Documentation

For detailed specifications, refer to the official Uniswap V2 documentation:

Design Philosophy

Realtime Exchange’s AMM design relies on proven Uniswap V2 infrastructure rather than custom implementation. This approach provides:
  • Battle-tested security - Years of production use
  • Audited codebase - Extensively reviewed contracts
  • Wide compatibility - Standard interfaces for integrations
  • Familiar mechanics - Well-understood by traders and developers