Skip to main content
Every global a script can use, from the API’s own declarations, so it matches what the terminal runs. A script has no imports: these names are always there.

Basic types

Times, colours, venues, intervals and the missing value na.

The declaration

indicator(): the script’s name and where it draws.

Inputs

Settings the reader changes in the chart’s settings panel.

Streams

Bars, trades, liquidations, the order book, open interest, funding, breadth and liquidation levels.

State

Values kept between bars: cells, lists, maps, series and tallies.

Indicators (ta)

Moving averages, oscillators, bands and the rest of the ta library, matching TradingView.

Plots

Lines, histograms, areas, points, shapes, markers, fills, levels, backgrounds and bar colours.

Drawings

Lines, boxes, labels, polylines, linefills and tables.

Alerts

Alerts the reader arms and the script fires.

Colours, text and time

color, fmt, clock, log and random.

Diagnostics

Every code the editor reports, what it means and what to do.

Next step

Start with Basic types.
Last modified on October 16, 2026