StableX Whitepaper
Cross-Chain Stablecoin Exchange on IOTA
Overview
StableX is a cross-chain stablecoin exchange platform built on IOTA, supporting both IOTA L1 (Move) and IOTA EVM (Solidity). The exchange addresses fragmented liquidity for regional stablecoins by allowing users to deposit USDC or regional stablecoins, earn unified yield, and receive SBX tokens that can be withdrawn as any currency (with asymmetric withdrawal rules).
Unified Basket
All currencies (USDC + CHFX + TRYB + SEKX) in one pool, providing deep liquidity across all pairs.
SBX Token
Single fungible token (1 SBX = 1 USD) with rebasing mechanism representing your share of the pool.
Unified APY
All depositors earn the same APY (higher than USDC alone) regardless of which currency they deposit.
Asymmetric Withdrawal
Regional depositors can withdraw USDC or regionals; USDC depositors can only withdraw regionals.
Pool Mechanics
Unified Basket
All currencies (USDC + CHFX + TRYB + SEKX) exist in one unified pool. This creates deep liquidity for all trading pairs and allows for direct swaps between any two currencies without intermediate steps.
SBX Token
When users deposit into the pool, they receive SBX tokens at a 1:1 ratio with USD value. SBX tokens represent a share of the entire pool and can be withdrawn as any supported currency (subject to asymmetric withdrawal rules).
Asymmetric Withdrawal
To maintain pool balance and incentivize regional stablecoin deposits:
- • Regional depositors: Can withdraw any regional stablecoin OR USDC
- • USDC depositors: Can only withdraw regional stablecoins (cannot withdraw USDC)
Unified APY
All depositors earn the same APY regardless of which currency they deposit. This APY is typically higher than what USDC alone would provide, as it represents a weighted average of yields from all currencies in the pool.
Chart 5: Pool Architecture
Price Feed Architecture
API-Based Price Feeds
Prices are queried off-chain via API and passed as parameters to contract functions. This approach provides better flexibility and lower gas costs compared to on-chain oracle queries.
- • No Onchain Queries: Removed dependency on Pyth Network onchain queries
- • Price Format: All prices in micro-USD (1e6 = $1.00)
- • Off-Chain Queries: Frontend queries API before submitting transactions
- • Parameter Passing: Prices passed as function parameters
Chart 9: Price Feed Architecture
Swapping Mechanism
Direct A→B Swaps (Infinity Pool Core)
Unlike traditional DEXs that require routing through intermediate tokens, StableX enables direct swaps between any two regional stablecoins. This is the core of the infinity pool concept.
- • No USD intermediate - direct exchange between regional stablecoins
- • Rate calculation: rate_A_to_B = price_B / price_A (both in USD/[CURRENCY] format)
- • Single fee applied based on target asset depth
- • True infinity pool mechanics - all assets in one unified pool
- • Prices passed as parameters - queried from API off-chain before transaction
Chart 7: Direct A→B Swap Flow
Fee Structure
Three-Tier Fee System (80%/30% Thresholds)
Tier 1: ≥80% Coverage
Fixed cheap rate for stablecoins when pool has sufficient depth.
Fee = floor + base (no deviation penalty)
Example: 7 bps (0.07%) - optimal for healthy pools
Tier 2: 30-80% Coverage
Linear/pricewise fee that scales with deviation from target.
Fee = floor + base + k * deviation
Example: 7-32 bps range
Tier 3: <30% Coverage
Sudden jump - dramatic fee increase to discourage draining.
Fee = (floor + base) * 10x + exponential term
No cap - fees can exceed 14%+ to discourage draining
Example: 77 bps at 29%, up to 1432 bps at 1%
Chart 6: Three-Tier Fee Curve
System Architecture
System Overview
StableX operates on a dual-chain architecture, leveraging both IOTA L1 (Move-based) and IOTA EVM (Solidity-based) to provide unified liquidity across chains. The system consists of pool contracts, bridge contracts, token contracts, and a relayer service that facilitates cross-chain transfers.
Chart 1: System Architecture Overview
Component Diagram
Detailed breakdown of all system components and their interactions.
Chart 2: Component Diagram
Data Flow
How data and transactions flow through the system for different operations.
Chart 3: Data Flow Diagram
Cross-Chain Bridge
Bridge Flow
The bridge enables seamless token transfers between IOTA L1 and IOTA EVM, maintaining unified liquidity across both chains.
L1 → EVM (Lock → Mint)
- User calls
bridge_l1::lock_*()on L1 with token coin and recipient EVM address - L1 bridge locks tokens in escrow and emits
LockEvent - Relayer watches L1 events and calls
EVMBridge::mint()on EVM - EVM bridge mints wrapped tokens to recipient
EVM → L1 (Burn → Unlock)
- User calls
EVMBridge::burn()on EVM with token type, amount, and recipient L1 address - EVM bridge burns wrapped tokens and emits
BurnEvent - Relayer watches EVM events and calls
bridge_l1::unlock()on L1 - L1 bridge unlocks tokens from escrow and transfers to recipient
Chart 8: Cross-Chain Bridge Flow
Multi-Chain Architecture
L1 Components (Move-based)
- • Native tokens: CHFX, TRYB, SEKX, USDC, SBX
- • Pool contract: sbx_pool.move
- • Bridge contract: bridge_l1.move (locks/unlocks tokens)
- • Flash vault: flash_vault.move
- • Shared objects: Pool and Registry created as shared objects
EVM Components (Solidity-based)
- • ERC-20 tokens: CHFX, TRYB, SEKX, USDC, wSBX (wrapped SBX)
- • Pool contract: StableXPool.sol
- • Bridge contract: EVMBridge.sol (mints/burns wrapped tokens)
- • Standard ERC-20: All tokens follow ERC-20 standard
Unified Liquidity
While pools exist separately on L1 and EVM, they are bridged via cross-chain transfers, allowing users to access liquidity from either chain seamlessly.
Chart 4: Multi-Chain Architecture
Security & Audits
Reentrancy Protection
All contracts implement reentrancy guards to prevent recursive calls and ensure atomic operations.
Nonce System
Bridge contracts use a nonce system to prevent replay attacks and ensure each bridge operation can only be executed once.
Event Verification
The relayer verifies events from both chains before executing cross-chain operations, ensuring the integrity of bridge transfers.
Tokenomics
SBX Token
SBX is the unified token representing shares in the pool. It maintains a 1:1 peg with USD and uses a rebasing mechanism to reflect yield accrual.
Rebasing Mechanism
SBX tokens automatically rebase to reflect earned yield, maintaining the 1:1 USD peg while allowing holders to see their balance grow over time.
Yield Distribution
All yield generated from the pool is distributed proportionally to all SBX holders, regardless of which currency they originally deposited.
Roadmap
Current Status
✅ Production Ready - Multi-Chain Support
- ✅ Multi-currency staking on both L1 and EVM
- ✅ Direct A→B swaps on both chains
- ✅ Cross-chain token transfers
- ✅ Multi-wallet support (IOTA L1 and EVM)
- ✅ Unified basket architecture
- ✅ Shared objects (L1)
- ✅ Asymmetric withdrawal rules
- ✅ Unified APY
- ✅ Flash loan vault (L1)
- ✅ Complete frontend dApp
Future Development
1. Additional Regional Stablecoins
Expand support to more regional currencies to increase global accessibility and liquidity.
- • Target Currencies: JPYX (Japanese Yen), GBPX (British Pound), AUDX (Australian Dollar), CADX (Canadian Dollar), and more
- • Enhanced Multi-Currency Pools: Support for 10+ regional stablecoins in unified liquidity pool
- • Regional Market Features: Currency-specific features tailored to local market needs
- • Regulatory Compliance: Ensure each currency meets regional regulatory requirements
2. Enhanced Yield Strategies
Implement automated yield generation across multiple DeFi protocols.
- • Automated Yield Farming: Integrate with lending protocols, DEXs, and yield aggregators
- • Multi-Strategy Vault: Allocate funds across multiple strategies based on risk/return profiles
- • Auto-Compounding: Automatically reinvest yields to maximize returns
- • Strategy Performance Tracking: Real-time APY tracking per strategy with historical analytics
- • Risk Management: Slippage controls, impermanent loss protection, and strategy rebalancing
3. Payment/Offramp Protocol Integration
Enable real-world usage through partnerships with payment processors and offramp services.
- • Merchant Acceptance: Enable businesses to accept regional stablecoins as payment
- • Point-of-Sale Integration: Connect with payment terminals and e-commerce platforms
- • Fiat Conversion: Convert SBX and regional stablecoins to local fiat currencies
- • Bank Transfers: Direct bank account integration for withdrawals
- • Card Issuance: Debit/credit cards linked to SBX balances
- • Cross-Border Payments: Low-cost international remittances
- • Corporate Treasury: B2B payment solutions for businesses
4. Additional Enhancements
- • Governance mechanisms
- • Advanced analytics dashboard
- • Mobile application
- • Enhanced security audits and monitoring
StableX Whitepaper v1.0 | Built on IOTA