interface Tier2Context {
    asOf?: number;
    bars: readonly Bar[];
    dataContext?: Readonly<ChartDataContext>;
    from: number;
    requestState?: Readonly<IndicatorRequestState>;
    settings: Readonly<IndicatorSettings>;
    signal?: AbortSignal;
    to: number;
    requestBars(request: IndicatorBarsRequest): Promise<readonly Bar[]>;
}

Properties

asOf?: number

Inclusive availability cutoff during opted-in native timed replay.

bars: readonly Bar[]

The chart's current source bars: use for the requested time window.

dataContext?: Readonly<ChartDataContext>

Host identity when supplied. Indicator settings remain independent.

from: number

UTC seconds of the first and last source bar (0 when there are none).

requestState?: Readonly<IndicatorRequestState>

Native source, provider and external-data revisions, when supplied.

settings: Readonly<IndicatorSettings>
signal?: AbortSignal

Cancelled when this request is obsolete or the instance is removed.

to: number

Methods

  • The host's bar provider, when the runtime supplies one, so a fetch that needs another instrument's candles asks the host rather than carrying its own transport and credentials. Rejects when the host registered none. A request that names no variant is sent in the chart's session and adjustment (see inheritedDataVariant); naming one, {} included, wins.

    Parameters

    Returns Promise<readonly Bar[]>