Skip to main content

Omnia Payment Channels

Omnia is Minima's Layer 2 protocol based on eltoo — a scheme for replaceable state updates. Instead of punishing old states (like Lightning), eltoo simply allows the latest signed state to replace any earlier one on-chain.

Core concepts

TermMeaning
ChannelA 2-of-2 MULTISIG WOTS covenant between two parties
State updateA new balance split signed by both parties, replacing the prior state
SettlementBroadcasting the latest agreed state to the Minima chain
HTLCHash Time-Locked Contract — enables multi-hop routing across channels

Channel lifecycle

open() → fund() → [update() ...] → cooperativeClose() | forceClose()
import { openChannel, updateChannel, closeChannel } from '@totemsdk/omnia';

// Open with 100 MIN capacity
const channel = await openChannel({
counterparty: peerPublicKey,
localAmount: 50_000_000n, // satoshi units
remoteAmount: 50_000_000n,
chainProvider,
wotsLease,
});

// Update balance: send 10 MIN to counterparty
const updated = await updateChannel(channel, {
localDelta: -10_000_000n,
});

// Cooperatively close
await closeChannel(channel, { cooperative: true });

Package family

PackageRole
@totemsdk/omniaCore state machine
@totemsdk/omnia-factoryN-of-N group channel creation
@totemsdk/omnia-routerMulti-hop pathfinding and fee logic
@totemsdk/omnia-spliceResize a channel without closing
@totemsdk/omnia-hyperswarmPeer discovery and wire transport
@totemsdk/omnia-vtxoVirtual UTXO claim layer — cash-like off-chain balances backed by Merkle commitment trees

See also