# records reference

> Records produced by subscriptions and snapshot queries.

A subscription is a record whose fields are series: `chart.close` is the current value and `chart.close[1]` the previous one. Market fields are nullable; a missing value plots as a gap.

## Records

### BookDepth {#bookdepth}

```flowscope
type BookDepth
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Book price-bin size. |
| `bidQty` | `float` | — | Bid quantity in the query range. |
| `askQty` | `float` | — | Ask quantity in the query range. |
| `bidValue` | `float` | — | Bid quote value in the query range. |
| `askValue` | `float` | — | Ask quote value in the query range. |
| `bidLevels` | `int` | — | Bid levels included in the query range. |
| `askLevels` | `int` | — | Ask levels included in the query range. |
| `bidMinPrice` | `float?` | — | Lowest bid price included, or null when empty. |
| `bidMaxPrice` | `float?` | — | Highest bid price included, or null when empty. |
| `askMinPrice` | `float?` | — | Lowest ask price included, or null when empty. |
| `askMaxPrice` | `float?` | — | Highest ask price included, or null when empty. |
| `deltaQty` | `float` | — | Bid quantity minus ask quantity. |
| `deltaValue` | `float` | — | Bid value minus ask value. |
| `totalQty` | `float` | — | Bid plus ask quantity. |
| `totalValue` | `float` | — | Bid plus ask value. |
| `ratioQty` | `float` | — | Quantity imbalance ratio; NaN when total quantity is 0. |
| `ratioValue` | `float` | — | Value imbalance ratio; NaN when total value is 0. |
| `ratio` | `float` | — | Default quote-value imbalance ratio; NaN when total value is 0. |

### BookLevel {#booklevel}

```flowscope
type BookLevel
```

| Field | Type | History | Description |
|---|---|---|---|
| `index` | `int` | — | 0-based level index within the side, 0 = best. |
| `price` | `float` | — | Level price. |
| `qty` | `float` | — | Level quantity. |
| `value` | `float` | — | Total value at this level: `price * qty`. |

### BookLevels {#booklevels}

```flowscope
type BookLevels
```

| Field | Type | History | Description |
|---|---|---|---|
| `len` | `int` | — | Number of levels in the view; raw depth may be capped by your data plan. |
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Book price-bin size. |

### BookSideSummary {#booksidesummary}

```flowscope
type BookSideSummary
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Book price-bin size. |
| `levels` | `int` | — | Levels included in the band. |
| `qty` | `float` | — | Total quantity in the band. |
| `value` | `float` | — | Total quote value, summed as price times quantity in the band. |
| `avgPrice` | `float` | — | Quantity-weighted average price of the band (ladder VWAP): value / qty. |
| `minPrice` | `float` | — | Lowest level price included. |
| `maxPrice` | `float` | — | Highest level price included. |

### BookSub {#booksub}

```flowscope
type BookSub
```

### CvdForming {#cvdforming}

```flowscope
type CvdForming
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | — | Opening time of the forming bar. |
| `open` | `float?` | — | Forming cumulative volume-delta open value. |
| `high` | `float?` | — | Forming cumulative volume-delta high value. |
| `low` | `float?` | — | Forming cumulative volume-delta low value. |
| `close` | `float?` | — | Forming cumulative volume-delta close value. |
| `bucket` | `int` | — | CVD bucket group. |
| `bucketLabel` | `string` | — | CVD bucket label. |
| `bucketMinUsd` | `float?` | — | CVD bucket minimum USD notional. |
| `bucketMaxUsd` | `float?` | — | CVD bucket maximum USD notional. |

### CvdSub {#cvdsub}

```flowscope
type CvdSub
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | `[n]` | Opening time of the confirmed bar. |
| `open` | `float?` | `[n]` | Confirmed cumulative volume-delta open value. |
| `high` | `float?` | `[n]` | Confirmed cumulative volume-delta high value. |
| `low` | `float?` | `[n]` | Confirmed cumulative volume-delta low value. |
| `close` | `float?` | `[n]` | Confirmed cumulative volume-delta close value. |
| `bucket` | `int` | — | CVD bucket group. |
| `bucketLabel` | `string` | — | CVD bucket label. |
| `bucketMinUsd` | `float?` | — | CVD bucket minimum USD notional. |
| `bucketMaxUsd` | `float?` | — | CVD bucket maximum USD notional. |
| `forming` | `CvdForming` | — | Current forming CVD values. Read these values directly; history indexing with `[n]` is not supported. |
| `isNew` | `bool` | — | True during an update in which this subscription confirmed at least one period. |
| `isRealtime` | `bool` | — | True while the forming period receives live updates. |
| `isHistory` | `bool` | — | True during history replay. |
| `isFirst` | `bool` | — | True when `index == 0`. |
| `index` | `int` | — | Position of the current reference period in the loaded history, counting from 0. |
| `isLast` | `bool` | — | True during live updates of the last loaded period, which is still forming. Always false during historical replay and inside `on X.close`, including the transition to live data. Use it in `on X.update` to draw only at the live edge. |

### FootprintBucket {#footprintbucket}

```flowscope
type FootprintBucket
```

| Field | Type | History | Description |
|---|---|---|---|
| `index` | `int` | — | 0-based bucket index, ascending by price. |
| `from` | `float` | — | Inclusive lower price bound of the bucket. |
| `to` | `float` | — | Exclusive upper price bound of the bucket. |
| `buy` | `float` | — | Buy volume re-binned into the bucket. |
| `sell` | `float` | — | Sell volume re-binned into the bucket. |
| `total` | `float` | — | Total volume: `buy + sell`. |
| `delta` | `float` | — | Volume delta: `buy - sell`. |

### OhlcvForming {#ohlcvforming}

```flowscope
type OhlcvForming
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | — | Opening time of the forming bar. |
| `open` | `float?` | — | Forming open price. |
| `high` | `float?` | — | Forming high price. |
| `low` | `float?` | — | Forming low price. |
| `close` | `float?` | — | Forming close price. |
| `volume` | `float?` | — | Forming total volume. |
| `buyVolume` | `float?` | — | Forming buy volume. |
| `sellVolume` | `float?` | — | Forming sell volume. |
| `buyCount` | `int?` | — | Forming buy trade count. |
| `sellCount` | `int?` | — | Forming sell trade count. |
| `trades` | `int?` | — | Forming trade count. |

### OhlcvSub {#ohlcvsub}

```flowscope
type OhlcvSub
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | `[n]` | Opening time of the confirmed bar. `[n]` looks back by this subscription's periods. |
| `open` | `float?` | `[n]` | Confirmed open price. |
| `high` | `float?` | `[n]` | Confirmed high price. |
| `low` | `float?` | `[n]` | Confirmed low price. |
| `close` | `float?` | `[n]` | Confirmed close price. |
| `volume` | `float?` | `[n]` | Confirmed total volume. |
| `buyVolume` | `float?` | `[n]` | Confirmed buy volume. |
| `sellVolume` | `float?` | `[n]` | Confirmed sell volume. |
| `buyCount` | `int?` | `[n]` | Confirmed buy trade count. |
| `sellCount` | `int?` | `[n]` | Confirmed sell trade count. |
| `trades` | `int?` | `[n]` | Confirmed trade count. |
| `forming` | `OhlcvForming` | — | Current forming OHLCV values. Read these values directly; history indexing with `[n]` is not supported. |
| `isNew` | `bool` | — | True during an update in which this subscription confirmed at least one period. |
| `isRealtime` | `bool` | — | True while the forming period receives live updates. |
| `isHistory` | `bool` | — | True during history replay. |
| `isFirst` | `bool` | — | True when `index == 0`. |
| `index` | `int` | — | Position of the current reference period in the loaded history, counting from 0. |
| `isLast` | `bool` | — | True during live updates of the last loaded period, which is still forming. Always false during historical replay and inside `on X.close`, including the transition to live data. Use it in `on X.update` to draw only at the live edge. |

### OiForming {#oiforming}

```flowscope
type OiForming
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | — | Opening time of the forming bar. |
| `open` | `float?` | — | Forming open-interest open value. |
| `high` | `float?` | — | Forming open-interest high value. |
| `low` | `float?` | — | Forming open-interest low value. |
| `close` | `float?` | — | Forming open-interest close value. |

### OiSub {#oisub}

```flowscope
type OiSub
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | `[n]` | Opening time of the confirmed bar. |
| `open` | `float?` | `[n]` | Confirmed open-interest open value. |
| `high` | `float?` | `[n]` | Confirmed open-interest high value. |
| `low` | `float?` | `[n]` | Confirmed open-interest low value. |
| `close` | `float?` | `[n]` | Confirmed open-interest close value. |
| `forming` | `OiForming` | — | Current forming open-interest values. Read these values directly; history indexing with `[n]` is not supported. |
| `isNew` | `bool` | — | True during an update in which this subscription confirmed at least one period. |
| `isRealtime` | `bool` | — | True while the forming period receives live updates. |
| `isHistory` | `bool` | — | True during history replay. |
| `isFirst` | `bool` | — | True when `index == 0`. |
| `index` | `int` | — | Position of the current reference period in the loaded history, counting from 0. |
| `isLast` | `bool` | — | True during live updates of the last loaded period, which is still forming. Always false during historical replay and inside `on X.close`, including the transition to live data. Use it in `on X.update` to draw only at the live edge. |

### Profile {#profile}

```flowscope
type Profile
```

### StatForming {#statforming}

```flowscope
type StatForming
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | — | Opening time of the forming statistics bar. |
| `sellLiq` | `float?` | — | Last-value sell liquidation value. |
| `buyLiq` | `float?` | — | Last-value buy liquidation value. |
| `markPrice` | `float?` | — | Last-value mark price. Null when the feed carries no mark; aggregate exchange specs never have one. |
| `fundingRate` | `float?` | — | Last-value funding rate. |

### StatSub {#statsub}

```flowscope
type StatSub
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | `[n]` | Opening time of the confirmed statistics bar. |
| `sellLiq` | `float?` | `[n]` | Confirmed sell liquidation value. |
| `buyLiq` | `float?` | `[n]` | Confirmed buy liquidation value. |
| `markPrice` | `float?` | `[n]` | Confirmed mark price. Null when the feed carries no mark; aggregate exchange specs never have one. |
| `fundingRate` | `float?` | `[n]` | Confirmed funding rate. |
| `forming` | `StatForming` | — | Current last-value statistics view. Read these values directly; history indexing with `[n]` is not supported. |
| `isNew` | `bool` | — | True during an update in which this subscription confirmed at least one period. |
| `isRealtime` | `bool` | — | True while the forming period receives live updates. |
| `isHistory` | `bool` | — | True during history replay. |
| `isFirst` | `bool` | — | True when `index == 0`. |
| `index` | `int` | — | Position of the current reference period in the loaded history, counting from 0. |
| `isLast` | `bool` | — | True during live updates of the last loaded period, which is still forming. Always false during historical replay and inside `on X.close`, including the transition to live data. Use it in `on X.update` to draw only at the live edge. |

### Trade {#trade}

```flowscope
type Trade
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time` | — | Trade timestamp in Unix seconds, rounded down to a whole second. |
| `price` | `float` | — | Trade price. |
| `size` | `float` | — | Trade size, always positive. |
| `isBuy` | `bool` | — | true = aggressive buy, false = aggressive sell. |

### TradesSub {#tradessub}

```flowscope
type TradesSub
```

### VdForming {#vdforming}

```flowscope
type VdForming
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | — | Opening time of the forming bar. |
| `open` | `float?` | — | Forming volume-delta open value. |
| `high` | `float?` | — | Forming volume-delta high value. |
| `low` | `float?` | — | Forming volume-delta low value. |
| `close` | `float?` | — | Forming volume-delta close value. |
| `bucket` | `int` | — | Volume-delta bucket group. |
| `bucketLabel` | `string` | — | Volume-delta bucket label. |
| `bucketMinUsd` | `float?` | — | Volume-delta bucket minimum USD notional. |
| `bucketMaxUsd` | `float?` | — | Volume-delta bucket maximum USD notional. |

### VdSub {#vdsub}

```flowscope
type VdSub
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time?` | `[n]` | Opening time of the confirmed bar. |
| `open` | `float?` | `[n]` | Confirmed volume-delta open value. |
| `high` | `float?` | `[n]` | Confirmed volume-delta high value. |
| `low` | `float?` | `[n]` | Confirmed volume-delta low value. |
| `close` | `float?` | `[n]` | Confirmed volume-delta close value. |
| `bucket` | `int` | — | Volume-delta bucket group. |
| `bucketLabel` | `string` | — | Volume-delta bucket label. |
| `bucketMinUsd` | `float?` | — | Volume-delta bucket minimum USD notional. |
| `bucketMaxUsd` | `float?` | — | Volume-delta bucket maximum USD notional. |
| `forming` | `VdForming` | — | Current forming volume-delta values. Read these values directly; history indexing with `[n]` is not supported. |
| `isNew` | `bool` | — | True during an update in which this subscription confirmed at least one period. |
| `isRealtime` | `bool` | — | True while the forming period receives live updates. |
| `isHistory` | `bool` | — | True during history replay. |
| `isFirst` | `bool` | — | True when `index == 0`. |
| `index` | `int` | — | Position of the current reference period in the loaded history, counting from 0. |
| `isLast` | `bool` | — | True during live updates of the last loaded period, which is still forming. Always false during historical replay and inside `on X.close`, including the transition to live data. Use it in `on X.update` to draw only at the live edge. |

### VolumeArea {#volumearea}

```flowscope
type VolumeArea
```

| Field | Type | History | Description |
|---|---|---|---|
| `pocPrice` | `float` | — | Price with the largest value for the selected basis. Ties use the lowest price. |
| `lowPrice` | `float` | — | Value-area low (VAL). |
| `highPrice` | `float` | — | Value-area high (VAH). |
| `buy` | `float` | — | Buy volume over the queried band. |
| `sell` | `float` | — | Sell volume over the queried band. |
| `total` | `float` | — | Total volume over the queried band. |
| `delta` | `float` | — | Buy minus sell volume over the queried band. |
| `ratio` | `float` | — | Volume-delta ratio over the queried band (NaN when total is 0). |
| `levels` | `int` | — | Distinct price levels in the queried band. |

### VolumeBuckets {#volumebuckets}

```flowscope
type VolumeBuckets
```

| Field | Type | History | Description |
|---|---|---|---|
| `len` | `int` | — | Number of buckets in the view. |
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Finest source price-bin size of the re-binned snapshot. |

### VolumeLevel {#volumelevel}

```flowscope
type VolumeLevel
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Volume-profile price-bin size. |
| `index` | `int` | — | 0-based level index, ascending by price. |
| `price` | `float` | — | Level price. |
| `buy` | `float` | — | Buy volume at this level. |
| `sell` | `float` | — | Sell volume at this level. |
| `total` | `float` | — | Buy plus sell volume. |
| `delta` | `float` | — | Buy volume minus sell volume. |
| `ratio` | `float` | — | Volume-delta ratio; NaN when total volume is 0. |

### VolumeLevels {#volumelevels}

```flowscope
type VolumeLevels
```

| Field | Type | History | Description |
|---|---|---|---|
| `len` | `int` | — | Number of stored profile levels in the view. |
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Volume-profile price-bin size. |

### VolumeSub {#volumesub}

```flowscope
type VolumeSub
```

### VolumeSummary {#volumesummary}

```flowscope
type VolumeSummary
```

| Field | Type | History | Description |
|---|---|---|---|
| `time` | `time` | — | Start time of the snapshot period. |
| `binSize` | `float` | — | Volume-profile price-bin size. |
| `levels` | `int` | — | Number of profile levels included. |
| `minPrice` | `float` | — | Lowest profile price included. |
| `maxPrice` | `float` | — | Highest profile price included. |
| `buy` | `float` | — | Buy volume. |
| `sell` | `float` | — | Sell volume. |
| `total` | `float` | — | Total volume. |
| `delta` | `float` | — | Buy volume minus sell volume. |
| `ratio` | `float` | — | Volume-delta ratio; NaN when total volume is 0. |
