Input Parameters
| Field | Type | Required / Default | Description & Constraints |
|---|---|---|---|
chartType |
string |
Required | Enterprise chart type: 'bar', 'stacked_bar', 'horizontal_bar', 'line', 'area', 'waterfall', 'funnel', or 'gantt'. (enum: bar | stacked_bar | horizontal_bar | line | area | waterfall | funnel | gantt) |
title |
string |
Optional | Executive headline chart title. (maxLength: 180) |
subtitle |
string |
Optional | Context subtitle (timeframe, unit scope, or cohort). (maxLength: 220) |
footnote |
string |
Optional | Source attribution or footnote rendered along the bottom edge. (maxLength: 240) |
width |
integer |
Default: 840 |
Target SVG viewport width in pixels. (min: 360, max: 2400) |
height |
integer |
Default: 480 |
Target SVG viewport height in pixels (auto-expands if dense rows/margins require it). (min: 240, max: 1800) |
palette |
string |
Default: "corporate" |
Accessible executive palette ('corporate', 'slate', 'emerald', or 'dark'). (enum: corporate | slate | emerald | dark) |
valueFormat |
string |
Default: "compact" |
Axis and data-label formatter ('compact' -> 12.4K, 'currency' -> $1.2M, 'percent' -> 45.3%, 'percent_ratio' -> 0.453 as 45.3%, 'integer', 'decimal', 'raw'). (enum: compact | currency | percent | percent_ratio | integer | decimal | raw) |
currencySymbol |
string |
Default: "$" |
Currency symbol prefix used when valueFormat is 'currency'. (maxLength: 8) |
unitSuffix |
string |
Default: "" |
Optional unit suffix appended to formatted values (e.g. ' ms', 'x'). (maxLength: 16) |
xAxisLabel |
string |
Optional | Optional horizontal axis title. (maxLength: 120) |
yAxisLabel |
string |
Optional | Optional vertical axis title. (maxLength: 120) |
showDataLabels |
boolean |
Optional | Render collision-checked value labels directly on bars/points. |
showLegend |
boolean |
Optional | Override automatic legend visibility. |
showGrid |
boolean |
Default: true |
Render subtle dashed reference gridlines. |
includeZero |
boolean |
Optional | Force numeric scale to include the 0 baseline. |
categories |
array |
Optional | Category or time-bucket labels for bar, stacked_bar, horizontal_bar, line, and area charts. (minItems: 1, maxItems: 120) |
series |
array |
Optional | 1 to 12 data series for Cartesian charts. (minItems: 1, maxItems: 12) |
referenceLine |
object |
Optional | Optional target/threshold reference line. |
waterfallSteps |
array |
Optional | Ordered bridge steps for 'waterfall' charts. (minItems: 2, maxItems: 40) |
funnelStages |
array |
Optional | Ordered conversion stages for 'funnel' charts. (minItems: 2, maxItems: 20) |
ganttTasks |
array |
Optional | Timeline tasks and milestones for 'gantt' charts. (minItems: 1, maxItems: 60) |
ganttMilestones |
array |
Optional | Optional vertical milestone guide lines for 'gantt' charts. (minItems: 1, maxItems: 12) |
REST Example (curl)
curl -X POST "https://chart-viz.apikeg.com/v1/render-chart" \
-H "Content-Type: application/json" \
-d '{
"chartType": "waterfall",
"title": "FY26 Net ARR Bridge",
"subtitle": "Consolidated SaaS ($USD)",
"palette": "corporate",
"valueFormat": "currency",
"currencySymbol": "$",
"unitSuffix": "",
"width": 840,
"height": 480,
"showGrid": true,
"waterfallSteps": [
{
"label": "Opening ARR",
"value": 4200000,
"kind": "start"
},
{
"label": "New Logos",
"value": 1150000,
"kind": "delta"
},
{
"label": "Expansion",
"value": 680000,
"kind": "delta"
},
{
"label": "Gross ARR",
"kind": "subtotal"
},
{
"label": "Contraction",
"value": -210000,
"kind": "delta"
},
{
"label": "Logo Churn",
"value": -320000,
"kind": "delta"
},
{
"label": "Ending ARR",
"kind": "total"
}
]
}'
MCP tools/call Payload
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "render_chart",
"arguments": {
"chartType": "waterfall",
"title": "FY26 Net ARR Bridge",
"subtitle": "Consolidated SaaS ($USD)",
"palette": "corporate",
"valueFormat": "currency",
"currencySymbol": "$",
"unitSuffix": "",
"width": 840,
"height": 480,
"showGrid": true,
"waterfallSteps": [
{
"label": "Opening ARR",
"value": 4200000,
"kind": "start"
},
{
"label": "New Logos",
"value": 1150000,
"kind": "delta"
},
{
"label": "Expansion",
"value": 680000,
"kind": "delta"
},
{
"label": "Gross ARR",
"kind": "subtotal"
},
{
"label": "Contraction",
"value": -210000,
"kind": "delta"
},
{
"label": "Logo Churn",
"value": -320000,
"kind": "delta"
},
{
"label": "Ending ARR",
"kind": "total"
}
]
}
}
}