Skip to main content

Smart contracts

This section documents the public-facing smart contracts in the 4626 protocol.


Contract taxonomy

Core

The foundational contracts that implement the vault system:

ContractPurpose
CreatorOVaultERC-4626 vault for creator coins
CreatorOVaultWrapperConverts ▢TOKEN ↔ ■TOKEN
CreatorShareOFTLayerZero OFT for cross-chain
CreatorRegistryGlobal registry of vaults and tokens

Strategies

Capital deployment strategies:

ContractAssetPurpose
CCALaunchStrategy■TOKENFair launch via CCA
CreatorCharmStrategyTOKENV3 LP via Charm
AjnaStrategyTOKENLending pools
V4 StrategiesTOKENV4 liquidity

Governance

ve(3,3) governance system:

ContractPurpose
CreatorGaugeControllerFee distribution
VaultGaugeVotingEpoch voting
ve4626Vote-escrowed tokens
VoterRewardsDistributorVoter rewards
BribeDepotExternal bribes

Services

Supporting infrastructure:

ContractPurpose
CreatorLotteryManagerJackpot system
CreatorOraclePrice feeds
SolanaBridgeAdapterSolana bridge

Helpers

Deployment and automation:

ContractPurpose
VaultActivationBatcher1-click activation
CreatorVaultDeployerFull deployment
Create2DeployerDeterministic addresses

Architecture

                    ┌─────────────────────┐
│ CreatorRegistry │
│ (global state) │
└─────────────────────┘

┌────────────────────┼────────────────────┐
│ │ │
▼ ▼ ▼
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ CreatorOVault │ │ CreatorShareOFT │ │ Governance │
│ (ERC-4626) │ │ (LayerZero) │ │ Contracts │
└─────────────────┘ └─────────────────┘ └─────────────────┘
│ │ │
▼ ▼ │
┌─────────────────┐ ┌─────────────────┐ │
│ Strategies │ │ GaugeController │◄─────────┘
└─────────────────┘ └─────────────────┘


┌─────────────────┐
│ LotteryManager │
└─────────────────┘

Sections

SectionContents
CoreVault, Wrapper, ShareOFT
StrategiesCCA, Charm, Ajna, V4
GovernanceGaugeController, Voting, ve4626

For lottery mechanics, see Concepts: Lottery.


Deployment

For deployment guides, see:


API reference

For complete function signatures and NatSpec documentation, see: