How Gigastonk works.
One pure function and a price feed. Small enough to read here, then reproduce yourself — which is the only reason to believe any of the numbers on this site.
Overview
A market is a token paired with a backing asset, plus one decision: where the revenue goes. Gigastonk computes that decision from real data — the actual holder list on chain and live prices — and shows the arithmetic in between.
It does not custody anything, and it does not move funds. It reads, computes, and shows its work.
The pair
20 backing assets across three classes:
- ·Stocks (12) — own the upside of real companies.
- ·Memecoins (7) — back it with something internet-native.
- ·Commodities (1) — gold, held on-chain.
Every mint was verified against on-chain liquidity before listing. This matters more than it sounds: searching a ticker like "WIF" on any token API returns a pile of impostors with the same symbol and near-zero liquidity. A market backed by the wrong mint looks perfectly fine right up until someone checks.
The split
Revenue is divided by the strategy the creator picked, in whole cents:
rewards = round(revenue × strategy.rewardShare) liquidity = revenue − rewards # so the two always add back up payout[i] = largestRemainder(rewards, holderBalances)[i]
- ·Holder rewards — 100% to holders, 0% to liquidity. Everything the market earns goes back to the people holding it.
- ·Hybrid — 50% to holders, 50% to liquidity. Half to holders, half into liquidity that stays with the market.
- ·Managed liquidity — 0% to holders, 100% to liquidity. Everything compounds into the market's own liquidity instead.
There is no clock and no network inside the split. Hours, revenue and holders are all inputs, so the same inputs give the same answer anywhere — that is what makes a payout checkable rather than promised.
Rounding
Money is integers. Percentages are not. Split $1,000 between a 200-token holder and a 100-token holder and the exact shares are $666.67 and $333.33 — which do not add up to $1,000 in whole cents.
floor every share → 66666 + 33333 = 99999 cents one cent left over give it to the largest → 66667 + 33333 = 100000 cents ✓ remaining fraction
- ·The payouts sum to the pot exactly — no dust stranded, none invented.
- ·Perfect proportionality is impossible in whole cents, so the guarantee we make is the one that can be kept: conservation first, proportional to within one cent.
- ·Ties break on index, so the result never depends on the order holders arrived in.
Exclusions
Burn addresses and the system program are removed before shares are computed. They cannot receive, and — the part that actually matters — they cannot dilute. A minimum-to-earn threshold is measured against the eligible pool, not total supply, so wallets that can never be paid never shrink your share.
Zero vs unknown
A known zero prints $0. Something we could not read prints —. They are different facts and this codebase never lets one wear the other's clothes.
So an asset without a live price is listed and labelled rather than dropped or shown as worthless, and a market with no revenue yet says $0 rather than pretending the number is still loading.
API
Read-only, JSON, live prices.
/api/universeEvery backing asset with a live price. Unpriced assets are listed with priceUsd: null.
{ "listed": 20, "priced": …,
"assets": [ { "symbol": "SPYx", "cls": "stock", "priceUsd": 700.12 }, … ] }/api/marketA whole market: the token read on-chain, the pair priced live, and the split computed over real holders.
{ "mint": "…", "backing": "SPYx",
"strategy": "hybrid", "revenueUsd": 2500, "minShare": 0.001 }/api/stateHonest protocol aggregate — zeros until a real registry exists.
{ "launched": false, "marketsLive": 0, "assets": 20 }What's real
- ·Live today: the verified asset universe, live prices, real holder lists, and the split engine — property-tested, exact to the cent.
- ·Not live: launching a token from here, routing fees into backing, executing payouts, and the on-chain market registry. Those need a program we have not shipped.
- ·Every number is real or zero. Roadmap is published as roadmap — you can hold us to that, and check the part that already works.