{s}omniamarkets

@somnia-chain/markets-sdk


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

Interface: PerpStateOnchain

Defined in: reads.ts:125

A perp pool's live pricing/funding state, read straight from chain in one pipelined fan-out. Fresher than the indexed Market row (funding fields there only update when FundingUpdated fires, i.e. per settlement window).

Properties

markPrice

markPrice: bigint

Defined in: reads.ts:127

EMA-smoothed oracle mark price (raw quote units per whole base).


indexPrice

indexPrice: bigint

Defined in: reads.ts:129

Unsmoothed oracle index price (raw quote units per whole base).


indexUpdatedAt

indexUpdatedAt: bigint

Defined in: reads.ts:131

Index price oracle timestamp (seconds).


fundingRate

fundingRate: bigint

Defined in: reads.ts:133

Current funding rate per settlement window (1e18-scaled fraction, signed).


cumulativeFundingPerUnit

cumulativeFundingPerUnit: bigint

Defined in: reads.ts:135

Settled cumulative funding per base unit (1e18-scaled, signed).


projectedCumulativeFundingPerUnit

projectedCumulativeFundingPerUnit: bigint

Defined in: reads.ts:137

Cumulative funding projected to now (unsettled accrual included).


longOpenInterest

longOpenInterest: bigint

Defined in: reads.ts:139

Total long open interest in base units.


shortOpenInterest

shortOpenInterest: bigint

Defined in: reads.ts:141

Total short open interest in base units.