aftermath-ts-sdk - v6.1.0
    Preparing search index...

    Interface PerpetualsWsUpdatesOraclePayload

    Websocket payload for oracle price updates.

    interface PerpetualsWsUpdatesOraclePayload {
        basePrice: number;
        bookPrice?: number;
        collateralPrice: number;
        marketId: string;
        markPrice: number;
    }
    Index
    basePrice: number

    Current base-asset oracle price, in quote units.

    bookPrice?: number

    Raw orderbook mid price, absent when either side of the book is empty. Optional where markPrice is not: mark falls back to the index price upstream, whereas a raw mid has none.

    The API sends JSON null here, but the websocket parser maps null to undefined, so a === null check would never match.

    collateralPrice: number

    Current collateral price, in USD.

    marketId: string

    Market object ID for the price update.

    markPrice: number

    Current mark price — what positions are marked against for PnL and liquidation, as opposed to the raw index price.