Skip to content

chartData schema

chartData (also called cd) is the serializable chart document.

Minimal

js
{
  chartType: 'clusteredBar',
  isDataTransposed: true,
  seriesData: [/* … */],
}
js
{
  chartType: 'clusteredBar',
  isDataTransposed: true,
  seriesData: [/* … */],
  orientation: 'vertical',
  title: { visible: true, text: '…' },
  subtitle: { visible: false, text: '' },
  legend: { visible: true, colors?: string[] },
  backgroundColor?: string,
}

Partial patches

Callers may pass a partial object to setChartData / update. Omitting chartType keeps the current type. Prefer setData(seriesData) when you only have new data.

Validation

Invalid authoring input is rejected at the embed API (unknown chartType, wrong field types, foreign option bags). Ragged seriesData rows warn but still load. See Insight API for the full table.

Machine-readable rules: chart-schema.json (generated from the same registry the runtime validator uses).

Full document

Author in the editor, then:

js
const full = insight.getChartData();

Expect additional trees such as:

  • canvas
  • axes
  • annotations
  • multilines
  • type blocks: bar, line, area, pie, scatter, waterfall, barMekko, combo, …
  • seriesLabels, chartPositionPercentages, …

See also Data model and package llms.txt.

Developer & LLM documentation · Not the end-user Help Center · Help Center