Bet XNT on real-world outcomes. Winners split the pot pro-rata. 5% house fee hardcoded to Flux. Soul-bound positions, frozen contract, no admin withdraw.
--. Operator: --. House fee: 5% on losing pool, hardcoded destination = Flux. No admin withdraw exists.
Operator creates a market with a question, deadline, and YES/NO outcomes. Citizens bet XNT on either side before the deadline. Each side accumulates into a separate pool inside the market PDA.
After deadline, operator calls resolve_market with the actual outcome. The losing side's pool is split: 5% goes to Flux, 95% becomes prize pool for the winning side.
Winners claim pro-rata: your_payout = your_stake + (your_stake / total_winning_pool) * losing_pool * 0.95. Pure parimutuel math, checked u128 throughout.
Cancellation: if a market becomes ambiguous, operator can cancel — both sides get full refunds, no fee. Refund flow uses the same position PDA, just calls refund_cancelled.
No admin escape. The operator can ONLY: create markets, resolve markets after deadline, cancel markets before resolution. Cannot withdraw user funds. Fee destination is hardcoded to Flux in the Rust — operator-key compromise cannot redirect.