> ## Documentation Index
> Fetch the complete documentation index at: https://docs.0xmonaco.com/llms.txt
> Use this file to discover all available pages before exploring further.

# V1.0.98

# Monaco Protocol SDK v1.0.98

This release adds the `reference` candle series, full OHLC of the mark price for charting margin markets with little trading, and makes the WebSocket `market_stats` 24h figures count a trade within about a second. No action is required: the series is opt-in, and existing trade and `mark` requests and subscriptions are unchanged.

## Added

### The `reference` candle series

The candlestick read accepts a third price series, `reference`, next to `trade` (the default) and `mark` (`sdk.market.getCandlesticks(pairId, interval, { priceType: "reference" })`; `GET /api/v1/market/pairs/charts/candlestick/{tradingPairId}/{interval}?priceType=reference`; gRPC `MarketService.GetCandles` with `price_type = "reference"`). Each candle is the full open, high, low and close of the mark price over its bucket, where a `mark` candle's four prices are all the closing mark. Volume, quote volume and trade count are always `0`, so use the series to chart markets whose trade candles are sparse. It is served at every interval (`1m`, `5m`, `15m`, `1h`, `4h`, `1d`).

* Like `mark`, it is margin-only: a spot pair is rejected with REST `400` / gRPC `InvalidArgument`, and a margin pair with no reference history returns no candles. Any other `priceType` value is rejected the same way.
* Paging (`startTime`, `endTime`, `limit`), gap filling and the open-interest fields behave as on the trade series.
* `sdk.ws.ohlcv(pairId, mode, interval, handler, "reference", onSnapshot?)` subscribes to `ohlcv:<pair>:<mode>:<interval>:reference`: a 350-candle snapshot from the same series, then live frames whose `priceType` is `"reference"`, on every interval. A four-token subscription still receives only the trade series.
* In `@0xmonaco/types`, `GetCandlesticksParams.priceType`, `OHLCVPriceType` and `OHLCVEvent.priceType` include `"reference"`.

See [OHLCV](https://docs.0xmonaco.com/ohlcv) and [WebSockets](https://docs.0xmonaco.com/sdk/typescript/websockets.md).

## Fixed

### `market_stats` 24h figures count a trade within a second

The WebSocket `market_stats` 24h volume, high, low, price change and last trade price now count a trade within about a second of its execution. The REST market endpoints can trail them by a couple of minutes after a trade, so expect the WebSocket figures to lead briefly. See [WebSocket reference](https://docs.0xmonaco.com/reference/websockets.md).

## Upgrade

```bash theme={null}
npm install @0xmonaco/core@1.0.98 @0xmonaco/types@1.0.98 @0xmonaco/react@1.0.98
# or bun
bun add @0xmonaco/core@1.0.98 @0xmonaco/types@1.0.98 @0xmonaco/react@1.0.98
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.