Architecture

Overview
DotSwap is a modular Bitcoin-native DEX infrastructure designed to support decentralized swaps, liquidity provisioning, and financial coordination for UTXO-based assets including BTC, Runes and BRC20. The architecture is composed of several core components that work together to enable secure, non-custodial, and efficient trading without relying on smart contracts.
1. Liquidity Infrastructure
1.1 DotSwap LP Pools (Custodial CPMM)
Operate on the Constant Product (x * y = k) model
Funds managed via MMM (Multi-layer Multi-signature Matrix) with MPC and Bitcoin native multi-sig
Custody secured through partners like Safeheron and Slowmist
Supports direct deposits of BTC + BRC20/Runes for earning swap fees
1.2 Nexus LP Pools (Self-Custodial CLMM)
Operated by LPs running Nexus nodes
Support custom price ranges, fees, and liquidity depths
All funds are self-custodied and coordinated via threshold multisig
Transactions are co-signed and broadcast to the Bitcoin network
2. Trading Execution Layer
2.1 Instant Swaps (V1 Engine)
Users deposit assets into a multisig-managed DotSwap account
Internal ledger updates balances instantly
Suitable for high-frequency and low-latency trading
2.2 Limit Orders
Off-chain coordinated orderbook using Nexus network
Users sign and submit limit orders
Orders are matched off-chain, settled with co-signed on-chain Bitcoin transactions
2.3 AMM Swaps
Users interact with CPMM or CLMM pools for permissionless swaps
Routing logic selects the best price across available liquidity sources
3. Coordination Layer: DotSwap Nexus
The Nexus Coordination Layer is the backbone of DotSwap’s decentralized execution system. It handles:
Order Matching: Coordinates limit order matching across interfaces and APIs.
Multisig Signing: Handles threshold multisig signing to enable non-custodial swaps.
Routing: Finds optimal trade paths using AMMs and limit orders.
Interface Bridge: Connects frontends, LPs, and coordination logic securely.
Nexus is modular and can be integrated into external products (wallets, dApps, aggregators) for embedded liquidity.
4. Security & Custody
MMM Framework: Used in custodial pools, powered by MPC and multi-sig
User-Controlled Funds: Nexus LPs retain control throughout the lifecycle
Audited Infrastructure: Partnerships with Safeheron and Slowmist ensure operational security
HTLC Fallbacks: For reclaimability in Bitcoin Channels and fallback exits
5. Ecosystem Interfaces
5.1 Swap API & SDK
Programmatic access to liquidity, order routing, and TX generation
5.2 Wallet Integrations
Native compatibility with Unisat, Xverse, OKX Wallet
Enable swaps and LP interaction directly from user wallets
5.3 Diamond Reward System
Activity-based point system used across all modules
Powers user incentives, airdrops, and governance mechanics
Conclusion
DotSwap is designed from the ground up for Bitcoin-native DeFi. Its layered architecture balances speed, security, and flexibility—providing builders and users with a reliable foundation for trading, liquidity, and innovation across the Bitcoin ecosystem.
Last updated
Was this helpful?