Canvas
Canvas lets the AI agent render structured visual panels in the widget.
When to Use Canvas
Use canvas when a plain text answer is not enough.
Examples:
- Product grid.
- Product detail card.
- Image gallery.
- Comparison table.
- KPI/stat cards.
- Markdown information panel.
Enable Canvas
- Open the integration.
- Enable canvas.
- Save the integration.
- Update your widget integration to provide canvas templates.
- Test with questions that should produce visual output.
How Canvas Works
Template Examples
Common template IDs include:
product_gridproduct_detailimage_gallerymarkdown_cardcompare_tablekpi_stats
Only templates declared by your integration should be used.
Good Canvas Design
Keep canvas templates focused.
Good uses:
- Show several products side by side.
- Compare plans.
- Display account metrics.
- Show a structured summary.
Avoid using canvas for:
- Long legal text.
- Hidden or sensitive data.
- Actions that require user confirmation unless your app handles confirmation.
Verification Checklist
- Canvas is enabled on the integration.
- The widget receives template definitions.
- The AI agent uses declared template IDs only.
- Invalid canvas payloads are rejected.
- The rendered view looks correct on desktop and mobile.