Mainly

Confirmation levels

What "confirmed" means on Solana, and how Mainly picks safe defaults so you rarely have to think about it.

Background

Solana doesn't have a single notion of "the current state." Data can be read at three levels of certainty, which raw RPC calls a commitment level:

LevelMeaningTypical latencyCan it be rolled back?
processedSeen by the current leader~400 msYes — a small percentage of processed slots are skipped
confirmedVoted on by a supermajority of the cluster~1 sPractically never
finalizedRooted; 31+ confirmed blocks built on top~13 sNo

Mainly's defaults

Every read endpoint accepts an optional confirmation query parameter:

GET /wallets/{address}/balance?confirmation=finalized
  • The default everywhere is confirmed — the level virtually all production Solana apps use. It's fast and, in practice, irreversible.
  • Use finalized when you're about to act irreversibly off-chain (credit a user's account, ship a product, release funds).
  • processed is allowed only on real-time endpoints where speed beats certainty. History endpoints reject it — Solana itself doesn't support processed reads of historical data — with a unsupported_confirmation error.

Writes

When sending a transaction with "confirm": true, Mainly waits for confirmed status before responding, and the status endpoint reports the level a transaction has reached (submittedconfirmedfinalized).

If you never touch the confirmation parameter, you get the behavior most apps want.

On this page