A decentralized governance system demonstrating cross-subnet coordination using Avalanche's Interchain Messaging (ICM/Teleporter).
Governance happens on C-Chain. Execution happens on BEAM. Policy decisions made by DAO token holders on C-Chain control how assets are managed on the BEAM subnet.
| Document | Description |
|---|---|
| PROOF_OF_WORK.md | Complete system overview with deployed contracts and verification commands |
| HOW_TO_RUN_THE_DEMO.md | Step-by-step deployment and demo execution guide |
| VERIFICATION_GUIDE.md | Contract verification instructions for block explorers |
| SWITCH_TO_MOCK_CLIENT.md | Guide for switching between mock and real cross-chain policy clients |
- mpDAO Token β ERC20 governance token with capped supply and burn mechanism
- VotingPower β Stake/lock mpDAO to gain voting power (time-weighted)
- PolicyGovernor β Epoch-based voting with quorum requirements
- PolicyServer β Cross-chain message handler for policy distribution
- StBEAMVault β ERC-4626 compliant liquid staking vault
- MockPolicyClient β Policy consumer (demo mode, no Teleporter dependency)
- WBEAM β Wrapped BEAM token
- Users vote on validator delegation weights using mpDAO voting power
- PolicyGovernor finalizes policy each epoch (7 days)
- BEAM vault reads policy and distributes deposits across validator buckets
- Bucket accounting simulates how funds would be delegated to validators
- Node.js 18+
- Funded wallet on Avalanche Fuji Testnet (C-Chain and BEAM)
npm install
npx hardhat compileCopy .env.example to .env and configure:
cp .env.example .envRequired variables:
PRIVATE_KEY=0x...
RPC_CCHAIN_TESTNET=https://api.avax-test.network/ext/bc/C/rpc
RPC_BEAM_TESTNET=https://build.onbeam.com/rpc/testnet
SNOWTRACE_API_KEY=your_api_key # Optional but recommendednpm run smoke:cchain
npm run smoke:beamDeployment (see HOW_TO_RUN_THE_DEMO.md)
# C-Chain deployments
npm run deploy:mpdao
npm run deploy:voting-power
npm run deploy:policy-governor
# BEAM deployments
npm run deploy:beam-vault# Read C-Chain governance state
npm run read:cchain-policy
# Read BEAM vault and buckets
npm run read:beam-vault
# Check balances
CHECK_ADDRESS=0x... npm run check_mpdao_balance.js --network cchain_testnet
CHECK_ADDRESS=0x... npm run check_beam_balances.js --network beam_testnet# Verify all C-Chain contracts
npm run verify:cchain
# Verify specific contract only (saves API calls)
VERIFY_ONLY=policyGovernor npm run verify:cchain# Switch vault to use MockPolicyClient (demo mode)
npm run vault:use-mock
# Switch to real PolicyClient (requires Teleporter)
npm run vault:use-real| Contract | Address | Explorer |
|---|---|---|
| mpDAO Token | 0x31e0752Deb99f1fCE9701Dc5611A1652189dEdC3 |
View |
| VotingPower | 0xFd7ad3deF7768f0b69F4d2cA0Cea094d715b0583 |
View |
| PolicyGovernor | 0x19Af9A1F3f276e4F4A708Aca04E5B2Ea1520D08E |
View |
| PolicyServer | 0x4A8C4229642215aB4F035Bc4A732cB918E74B283 |
View |
| Contract | Address | Explorer |
|---|---|---|
| WBEAM | 0x244AfCd5a0bc8A4400c6702C6a2A7717945c5e70 |
View |
| StBEAMVault | 0x16A289aF7727Bfc3A2c4bda7993568D8A3148c48 |
View |
| MockPolicyClient | 0xFd7ad3deF7768f0b69F4d2cA0Cea094d715b0583 |
View |
- β ERC-20 Governance Token with capped supply and burn mechanism
- β Time-Weighted Voting β Lock tokens longer for more voting power
- β Epoch-Based Governance β 7-day voting periods with quorum requirements
- β ERC-4626 Vault β Standard compliant liquid staking on BEAM
- β Policy-Driven Distribution β Governance decisions control asset allocation
- β Anti-Manipulation Safeguards β Epoch timing rules prevent last-minute manipulation
- β Upgradeable Architecture β ERC-1967 proxy pattern for future enhancements
npx hardhat compilenpx hardhat testnpm run cleanMIT
This is a hackathon proof-of-concept. For production use, additional security audits and testing are required.