@somnia-chain/markets-sdk


@somnia-chain/markets-sdk / index / SweepableOrder

Type Alias: SweepableOrder

SweepableOrder = object

Defined in: packages/sdk/src/orders.ts:572

A resting order that is PAST ITS EXPIRY but has not been cleaned off the book — the target of a permissionless sweep.

Carries exactly what the two sweep verbs need: orderId for SomniaMarketsClient.createTrader's cancelExpiredOrders, and isBid + price for sweepExpiredAtLevel.

Properties

id

id: string

Defined in: packages/sdk/src/orders.ts:574

Row id (${pool}_${orderId}).


orderId

orderId: string

Defined in: packages/sdk/src/orders.ts:576

uint128 OrderId as a decimal string — pass to cancelExpiredOrders.


pool

pool: string

Defined in: packages/sdk/src/orders.ts:578

The pool the order rests on (lowercased).


marketType

marketType: MarketType

Defined in: packages/sdk/src/orders.ts:580

Which market kind the pool is — sweeping works the same on all of them.


owner

owner: string

Defined in: packages/sdk/src/orders.ts:582

The order's owner (lowercased).


isBid

isBid: boolean

Defined in: packages/sdk/src/orders.ts:584

True = bid side, false = ask — pass to sweepExpiredAtLevel.


price

price: string

Defined in: packages/sdk/src/orders.ts:586

The exact price level, raw pool units — pass to sweepExpiredAtLevel.


quantityRemaining

quantityRemaining: string

Defined in: packages/sdk/src/orders.ts:588

Unfilled remainder that would be released, raw base/outcome units.


expireTimestampNs

expireTimestampNs: string

Defined in: packages/sdk/src/orders.ts:590

Expiry as a uint64 NANOsecond timestamp (decimal string).


placedAtTimestamp

placedAtTimestamp: string

Defined in: packages/sdk/src/orders.ts:592

Timestamp (unix seconds) the order was placed.