Skip to main content
New to Hadron? Start with Getting started.

Midprice updates and sequence numbers

Midprice and base-spread updates cost under 40 CU, so you can send one every slot. Midprice updates and curve updates each carry a sequence. One lower than the stored value fails (SequenceTooOld), so a delayed transaction can’t overwrite a newer one. If you send from more than one place, use a strictly increasing counter such as the slot.

Roles and pool states

Each pool splits control across separate keys.
The quoting authority can’t withdraw, but it can set prices. Someone with a stolen quoting key can push prices and trade against your inventory. The drawdown guard and factor clamp limit the damage (see Risk controls), and your alerting should be able to reach the pause key quickly.

Pool states

Only the pool authority can turn a pool back on. The pause key can stop a pool but can’t restart it.

Tokens

Pools support SPL Token and Token-2022 mints, including transfer-fee and transfer-hook tokens.
  • Transfer-fee tokens are priced on what the vault actually receives, so you don’t absorb the token’s fee. Don’t widen your curves to cover it, or traders pay it twice.
  • A trader’s minimum output is checked before the output token’s own transfer fee, so on a transfer-fee output they can receive slightly less than their minimum.
  • Non-transferable tokens can’t be used to create a pool.