Oracle & Risk Controls
Oracles & Risk Controls
MegaStrategy uses deterministic, multi-venue oracles and automated safety controls to ensure reliable protocol operation.
Price References
The protocol uses time-weighted average prices (TWAPs) as the primary price reference for critical operations.
24-Hour TWAP
Used for:
Minting reserved $MSTR after USD bond sales
Valuing $MSTR at maturity for staker compensation
General settlement references where spot prices could be manipulated
Additional Price Windows
The protocol may use supplementary TWAP or VWAP (volume-weighted) windows for:
LP safety bands
Issuance parameter checks
Redemption triggers
Specific windows are defined per use case to balance responsiveness against manipulation resistance.
Oracle Architecture
Multi-Venue Aggregation
Prices are aggregated from multiple venues to prevent single-source manipulation.
Venue weighting: Each venue contributes to the aggregate based on defined weights and caps.
Outlier filtering: Prices that deviate significantly from the aggregate are filtered before inclusion.
Data Quality Controls
Staleness detection: If price data exceeds a freshness threshold, the oracle enters an unhealthy state.
Deviation circuit breakers: Sudden large price movements trigger circuit breakers that pause dependent operations.
Unhealthy State Handling
When oracle data fails quality checks:
Dependent protocol actions are paused
The unhealthy state is published on-chain
Operations automatically resume when feeds recover
Manual intervention is not required for recovery
Safety Controls
Series Isolation
Each bond series operates independently:
Separate ledger and accounting
Separate backstop pool (USD series)
Separate settlement waterfall
Problems in one series cannot directly impact another series' mechanics.
Deterministic Settlement
Settlement rules are published at series creation and cannot change:
Waterfall order is fixed
Buffer allocations are defined upfront
Staker compensation formulas are immutable
This eliminates governance risk at settlement time.
LP Safety Bands
Liquidity provision operates within defined bands:
Bands are calculated from oracle prices
Operations outside bands are blocked
Bands adjust automatically as prices move
Redemption Controls
If redemption mechanisms are enabled for a series:
Triggers are oracle-based and deterministic
Size limits prevent bank-run dynamics
Cadence rules space out redemptions
On-Chain Transparency
All oracle data and risk parameters are published on-chain:
Raw venue prices
On-chain
Aggregated TWAP/VWAP
On-chain
Oracle health status
On-chain
Circuit breaker state
On-chain
Safety band boundaries
On-chain
Any observer can independently verify oracle inputs, calculations, and protocol responses.
Risk Parameters
Governance defines risk parameters subject to change-control policy:
TWAP window
Duration for time-weighted averaging
Venue weights
Contribution of each price source
Staleness threshold
Maximum age for valid price data
Deviation threshold
Trigger for circuit breakers
LP band width
Allowed range around oracle price
Redemption trigger
Oracle condition that enables redemptions
Redemption size limit
Maximum redemption per period
Redemption cadence
Minimum time between redemptions
Last updated