Lumen ChartsLumen Charts
Api

PineEditorWorkspaceApi

Download Markdown

Integration guide · Reference index

Public contract reference. This declaration describes types and callback shapes; availability is constrained by the linked integration guide and the runtime capability. Legacy product-specific fields are not a promise of implementation.

getSnapshot

getSnapshot(): PineEditorWorkspaceSnapshot;

Use the type signature above and the integration guide for the owning capability.

subscribe

subscribe(listener: (change: PineEditorWorkspaceChange) => void): () => void;

Use the type signature above and the integration guide for the owning capability.

ParameterTypeRequired
listener(change: PineEditorWorkspaceChange) => voidYes

subscribeLayoutRequests

subscribeLayoutRequests(
    listener: (request: PineEditorLayoutRequest) => void,
  ): () => void;

Use the type signature above and the integration guide for the owning capability.

ParameterTypeRequired
listener(request: PineEditorLayoutRequest) => voidYes

previewCompile

previewCompile(source: string): Promise<PineScriptCompileResult>;

Use the type signature above and the integration guide for the owning capability.

ParameterTypeRequired
sourcestringYes

replaceSource

replaceSource(
    source: string,
    expected: { generation: number; sourceHash: string },
  ): Promise<PineEditorWorkspaceSnapshot>;

Use the type signature above and the integration guide for the owning capability.

ParameterTypeRequired
sourcestringYes
expected{ generation: number; sourceHash: string }Yes

openEditor

openEditor(): Promise<void>;

Use the type signature above and the integration guide for the owning capability.

openStrategyTester

openStrategyTester(): Promise<void>;

Use the type signature above and the integration guide for the owning capability.

check

check(): Promise<PineEditorWorkspaceSnapshot>;

Use the type signature above and the integration guide for the owning capability.

run

run(): Promise<PineEditorWorkspaceSnapshot>;

Use the type signature above and the integration guide for the owning capability.

save

save(title?: string): Promise<PineEditorWorkspaceSnapshot>;

Use the type signature above and the integration guide for the owning capability.

ParameterTypeRequired
titlestringNo

getStrategyReport

getStrategyReport(): PineStrategyReport | null;

Use the type signature above and the integration guide for the owning capability.

On this page