> ## Documentation Index
> Fetch the complete documentation index at: https://docs.microset.io/llms.txt
> Use this file to discover all available pages before exploring further.

# How Markets Work

> How Microset's on-chain prediction markets handle your predictions, payouts, and refunds.

<Info>
  Microset runs **parimutuel** prediction markets on Solana. You stake on an
  outcome; when the event settles, everyone who picked the winning outcome shares
  the pool. This page explains, in plain terms, what happens to your money at each
  step.
</Info>

## The basics

A market is a question with two or more possible outcomes — for example, "How many
runs on the next ball?" You make a prediction on the outcome you think will happen. All
predictions for a market go into a single on-chain vault. When the result is known, the
market is resolved to one winning outcome, and the pool is split among the people
who picked it.

Markets aren't limited to Yes/No — a market can have anywhere from 2 outcomes up to
several, so the same system works for any sport or event.

## A worked example

Take a 6-outcome cricket market, **"Runs on Next Ball"**:

| Your pick    | Outcome |
| ------------ | ------- |
| Dot ball     | 0 runs  |
| 1 run        | 1       |
| 2 runs       | 2       |
| 3 runs       | 3       |
| 4 / boundary | 4       |
| Six          | 6       |

Everyone's stake — across all six options — sits in one vault. Say the ball is
bowled and the result is **4**. The market resolves to that outcome, and:

* A small **protocol fee** is taken from the total pool.
* Everyone who predicted **4** splits the rest of the pool, in proportion to how much they staked.
* The other five outcomes win nothing — their stakes flow to the winners.

So if you staked more on the winning outcome, you get a bigger share of the pool.

## How your money is handled

<CardGroup cols={2}>
  <Card title="Non-custodial" icon="lock">
    Your funds move only when you sign a transaction. Microset never holds your
    private keys.
  </Card>

  <Card title="One on-chain vault" icon="vault">
    Each market's stakes are held in a program-controlled vault and paid out only
    by fixed on-chain rules.
  </Card>

  <Card title="Proportional payouts" icon="scale">
    Winners share the pool in proportion to their stake on the winning outcome.
  </Card>

  <Card title="Refunds if voided" icon="rotate-ccw">
    If a market is voided, everyone gets a full refund of their stake — no fee.
  </Card>
</CardGroup>

## What you can do

<Steps>
  <Step title="Make a prediction">
    Choose a market and an outcome, enter an amount, and sign the transaction. Your
    stake moves into the market's vault. You can predict until the market's close time.
  </Step>

  <Step title="Wait for resolution">
    After the event, the market is resolved to the winning outcome. A protocol fee
    is taken from the pool and the rest is locked in for winners to claim.
  </Step>

  <Step title="Claim your winnings">
    If you picked the winning outcome, claim your share. Your payout is sent
    straight to your wallet.
  </Step>

  <Step title="Claim a refund (if voided)">
    If a market is voided, claim to get your full stake back with no fee applied.
  </Step>
</Steps>

### Quick predictions (optional)

To make several predictions without approving each one in your wallet, you can create a
**quick-prediction session**: you sign once to fund a small on-chain escrow with a spend
limit you choose. Predictions are then placed from that escrow up to the limit. You stay
in control — the session has a cap, and you can withdraw unused funds or revoke it
at any time.

## Built-in safety

The program enforces these rules on-chain, so they can't be bypassed:

| Protection                      | What it means for you                                                                      |
| ------------------------------- | ------------------------------------------------------------------------------------------ |
| Only winners can claim          | If you didn't pick the winning outcome, the claim is rejected — no one can drain the pool. |
| No double claims                | Once you've claimed a market, you can't claim it again.                                    |
| No predictions after resolution | A market can't be resolved and still take new predictions — the result is locked.          |
| Single resolution               | A market is resolved exactly once; outcomes can't be flipped afterward.                    |
| Capped fees                     | The protocol fee has a hard upper limit enforced in code.                                  |
| Full refunds on void            | A voided market returns every stake in full, with no fee.                                  |

## Fees

A configurable **protocol fee** is taken from the total pool at resolution and sent
to the protocol treasury. The fee is a small percentage and is capped on-chain.
Voided markets are refunded in full with **no** fee.

## Good to know

* Solana transactions are final once confirmed — predictions and claims can't be reversed.
* Outcomes are not set by Microset — resolution is triggered by third-party sports data APIs (e.g. Roanuz) once the real-world result is known.
* Microset is sport-agnostic: the same market mechanics work for cricket, football, basketball, and more.
