{s}omniamarkets

@somnia-chain/markets-sdk


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

Type Alias: BaseMarket

BaseMarket = object

Defined in: query.ts:142

Fields every market has, regardless of type.

Properties

id

id: string

Defined in: query.ts:144

Primary key (lowercased): bytes32 marketId for binary, pool address for spot.


marketType

marketType: MarketType

Defined in: query.ts:146

Discriminator — narrow on this (or the is*Market guards).


poolAddress

poolAddress: string

Defined in: query.ts:151

The pool serving this market (lowercased; == id for SPOT/PERP). For binary, a TIME-VARYING binding — see the recycle caveat on BinaryMarket.nonce.


lastPrice

lastPrice: string | null

Defined in: query.ts:153

Last fill price (raw). For binary, ≈ YES probability × 10^decimals. Null until first fill.


lastTradeAt

lastTradeAt: string | null

Defined in: query.ts:155

Timestamp (unix seconds) of the last fill; null until first fill.


cumulativeBaseVolume

cumulativeBaseVolume: string

Defined in: query.ts:157

Cumulative base/outcome-token volume (raw, decimal string).


cumulativeQuoteVolume

cumulativeQuoteVolume: string

Defined in: query.ts:159

Cumulative quote/collateral volume (raw, decimal string).


tradeCount

tradeCount: string

Defined in: query.ts:161

Lifetime fill count (decimal string).


baseDecimals

baseDecimals: number

Defined in: query.ts:163

Base-token decimals (binary: outcome tokens mirror the collateral's decimals).


quoteDecimals

quoteDecimals: number

Defined in: query.ts:168

Quote-token decimals (binary: the collateral's — per-venue, e.g. 6dp TestUSDC vs 18dp USDso). Format prices/amounts with this.


createdAtTimestamp

createdAtTimestamp: string

Defined in: query.ts:170

Timestamp (unix seconds) the market was created/indexed.