Tools reference
Every chart tool takes data as an array of flat records plus field-name
accessors, and shares the options documented in
Output types: width, height,
theme, title, colors, locale, outputType, outputPath, scale
and framework.
Tools can be hidden per deployment with DISABLED_TOOLS or --tools
(see Getting started).
Chart tools
generate_line_chart
Generate a line chart (single or multi-series) for trends over a continuous or time dimension. Data is an array of flat records; x and y reference field names. Example: data=[{"month":"2024-01","sales":120,"cost":80},...], x="month", xIsTime=true, y=["sales","cost"].
| Option | Type | Default | Description |
|---|---|---|---|
data | object[] | required | Chart data: an array of flat records, e.g. [{"month": "Jan", "sales": 120, "cost": 80}, ...] |
x | string | required | Field for X values: numbers, or date strings when xIsTime is true, or category names |
y | string | string[] | required | Field name(s) for Y values. Multiple field names render multiple lines |
xIsTime | boolean | false | Treat x values as dates/timestamps (time axis) |
seriesLabels | string[] | — | Display names for the y series (legend). Defaults to field names |
lineWidth | number | 2 | Line stroke width in pixels |
curve | linear | monotoneX | basis | natural | step | stepAfter | stepBefore | "monotoneX" | Line interpolation type |
interpolateMissing | boolean | false | Draw dashed interpolated segments across missing (null) values instead of gaps |
yDomainMin | number | — | Force the Y axis to start at this value |
yDomainMax | number | — | Force the Y axis to end at this value |
referenceLines | { axis, value, label, color, lineWidth, style }[] | — | Reference lines for thresholds/targets, e.g. an SLA or goal |
referenceBands | { axis, from, to, label, color }[] | — | Shaded ranges drawn behind the data, e.g. an acceptable range |
xAxisLabel | string | — | Label for the X axis |
yAxisLabel | string | — | Label for the Y axis |
showGridLines | boolean | true | Show horizontal/vertical grid lines |
legend | boolean | true | Show a legend (multi-series charts only) |
generate_area_chart
Generate an area chart for volumes/magnitudes over a continuous or time dimension. Multiple y fields are stacked by default; set stacked=false to overlay them with transparency. Example: data=[{"month":"2024-01","mobile":120,"desktop":80},...], x="month", xIsTime=true, y=["mobile","desktop"].
| Option | Type | Default | Description |
|---|---|---|---|
data | object[] | required | Chart data: an array of flat records, e.g. [{"month": "Jan", "sales": 120, "cost": 80}, ...] |
x | string | required | Field for X values: numbers, or date strings when xIsTime is true, or category names |
y | string | string[] | required | Field name(s) for Y values. Multiple field names render multiple areas |
stacked | boolean | true | Stack multiple y series on top of each other. When false, series overlap with transparency |
curve | linear | monotoneX | basis | natural | step | stepAfter | stepBefore | "monotoneX" | Area interpolation type |
xIsTime | boolean | false | Treat x values as dates/timestamps (time axis) |
seriesLabels | string[] | — | Display names for the y series (legend). Defaults to field names |
referenceLines | { axis, value, label, color, lineWidth, style }[] | — | Reference lines for thresholds/targets, e.g. an SLA or goal |
referenceBands | { axis, from, to, label, color }[] | — | Shaded ranges drawn behind the data, e.g. an acceptable range |
xAxisLabel | string | — | Label for the X axis |
yAxisLabel | string | — | Label for the Y axis |
showGridLines | boolean | true | Show horizontal/vertical grid lines |
legend | boolean | true | Show a legend (multi-series charts only) |
generate_bar_chart
Generate a bar chart: single-series, grouped, or stacked; vertical or horizontal. Use for comparing values across categories. Example: data=[{"country":"US","gold":9,"silver":8},...], x="country", y=["gold","silver"], type="stacked".
| Option | Type | Default | Description |
|---|---|---|---|
data | object[] | required | Chart data: an array of flat records, e.g. [{"month": "Jan", "sales": 120, "cost": 80}, ...] |
x | string | required | Field for the category dimension (names or numbers) |
y | string | string[] | required | Field name(s) for bar values. Multiple field names render one bar (or stack segment) per series |
type | grouped | stacked | "grouped" | How multiple series are arranged: side-by-side groups or stacks |
orientation | vertical | horizontal | "vertical" | Bar direction. Horizontal puts categories on the Y axis |
seriesLabels | string[] | — | Display names for the series (legend). Defaults to field names |
roundedCorners | boolean | number | 2 | Outer bar corner radius in pixels (default 2, matching the library), or true for fully rounded pill tops |
barPadding | number | — | Padding between bars within a group, 0..0.9 |
referenceLines | { axis, value, label, color, lineWidth, style }[] | — | Reference lines for thresholds/targets, e.g. an SLA or goal |
referenceBands | { axis, from, to, label, color }[] |