This repository contains the deployment scripts and configuration for deploying the Mento Protocol across multiple blockchain networks. The Mento Protocol is a decentralized exchange protocol that enables the creation and trading of stable assets.
This project provides a comprehensive framework for deploying Mento Protocol instances with:
- Multiple stable tokens (cUSD, cEUR, cREAL, etc.)
- Various collateral assets (CELO, USDC, USDT, axlUSDC, axlEUROC)
- Configurable exchange pools with different pricing modules
- Oracle integration for price feeds
- Circuit breakers for risk management
- Governance configuration
├── script/
│ ├── actions/ # Actions, one-off dev utils
│ ├── config/
│ │ ├── MentoConfig.sol # Base configuration contract
│ │ └── MentoConfig_celo_sepolia.sol # Celo Sepolia testnet configuration
│ ├── deploy/ # Component deployment scripts
│ ├── helpers/ # Utility contracts, helper libraries
│ ├── protocol.yaml # Mento Protocol deployment compose file
│ └── governance.yaml # Mento Governance deployment compose file
└── lib/
└── mento-core/ # Core Mento Protocol contracts
- cUSD - Celo Dollar
- cEUR - Celo Euro
- cREAL - Celo Brazilian Real
- eXOF - ECO CFA
- cKES - Celo Kenyan Shilling
- PUSO - Philippine Peso Stablecoin
- cCOP - Celo Colombian Peso
- cGHS - Celo Ghanaian Cedi
- cGBP - Celo British Pound
- cZAR - Celo South African Rand
- cCAD - Celo Canadian Dollar
- cAUD - Celo Australian Dollar
- cCHF - Celo Swiss Franc
- cJPY - Celo Japanese Yen
- cNGN - Celo Nigerian Naira
- CELO - Native Celo token
- USDC - USD Coin
- USDT - Tether USD
- axlUSDC - Axelar USDC
- axlEUROC - Axelar EUROC
The protocol supports 19 configured exchange pools with two types of pricing modules:
- Constant Sum Pricing Module - For stable-to-stable swaps (e.g., cUSD/USDC)
- Constant Product Pricing Module - For volatile pairs (e.g., cUSD/CELO)
Each pool has configurable:
- Spread percentages
- Rate feed oracles
- Reset frequencies
- Trading limits (5-minute, daily, and global limits)
The system uses Chainlink-compatible oracle feeds with:
- Value-based circuit breakers
- Median-based circuit breakers
- Configurable cooldown periods and thresholds
- Mock aggregators for testnet deployments
- Foundry installed
- treb installed for managing deployments
- Node.js and npm (for dependencies)
- Access to target network RPC endpoint
# Clone the repository
git clone https://github.com/mento-protocol/mento-deployments-v2
cd mento-deployments-v2
# Create a local .env based on the .env.example and fill out the empty values
cp .env.example .env
# Install dependencies
forge install
# Install the celo contracts
cd lib/mento-core && npm install
# Update submodules
git submodule update --init --recursiveWe deploy using treb.
# Run deployment
treb compose script/protocol.yaml -n <testnet> -n <namespace>The main configuration is handled through network-specific config contracts (e.g., MentoConfig_celo_sepolia.sol). These contracts define:
- Token Configuration: Stable tokens and collateral assets
- Oracle Configuration: Price feeds and circuit breakers
- Swap Configuration: Exchange pools and trading limits
- Governance Configuration: Timelock delays, voting periods, and quorum requirements
Trading limits are organized in tiers:
- Tier 1: 100k/500k/2.5M USD limits
- Tier 2: 50k/250k/1.25M USD limits
Limits are applied per timestep (5 minutes and 1 day) with global caps.
forge buildforge fmt- All price feeds include circuit breakers for protection against oracle failures
- Trading limits prevent large-scale manipulation
- Governance timelock ensures changes are transparent and delayed
- Regular security audits are conducted on the protocol
This project is licensed under the MIT License
For questions and support:
- Open an issue in this repository
- Join the Mento Discord community
- Visit mento.org for more information