Skip to main content
The chart component renders a bar, line, or pie chart on the canvas. It is display-only. chart is enabled on any PAL with the Magic Canvas skill attached; see Enabling and configuring components. Its only config key is enabled (default true):

Behavior

The PAL decides when to draw a chart; there is no developer-triggered path. Its system prompt directs it to chart small numeric comparisons or trends, with short labels and numeric values.

Arguments

No other arguments are accepted.
Arguments exceeding the limits above produce a load error card instead of a chart.

Example invocation

Interaction Types

chart is lifecycle-only: sending submit or skip returns a 400 (canvas.chart does not support this interaction type.). The interactions endpoint accepts four types:
Expect canvas.chart interactions only from clients you build yourself. The stock Tavus SDK and hosted embed currently POST none of these: the card has no dismiss control, render failures surface only via the local onError callback, clearing the canvas removes instances locally without an interaction, and renderer heartbeats use a separate model-context channel that never reaches the interactions endpoint or your webhook.
Custom clients POST interactions to POST https://tavusapi.com/v2/conversations/{conversation_id}/canvas/interactions (validation rules). Each recorded interaction fires your conversation webhook once as a canvas.interaction event (message_type: "canvas") and is available via GET https://tavusapi.com/v2/conversations/{conversation_id}/canvas/interactions (API key required).

Example Webhook Event

A dismiss POSTed by a custom client:
created_at is a Python isoformat() timestamp: UTC but timezone-naive, with microseconds and no trailing Z or offset. The same shape appears in the GET response.
For lifecycle types, Tavus validates the envelope (ids, component, type) but only enforces that value is an object under 16 KB; don’t depend on specific keys inside it.