inject_html_component
Inject styled HTML components like KPI rows, data tables, and alert banners into Hex cells to build dashboards without Python.
Instructions
Write a styled HTML component into a Hex HTML cell. These render in the published app with no Python needed.
component_type: kpi_row — row of metric cards (props: metrics=[{label, value, delta, delta_type}]) section_header — section title + subtitle (props: title, subtitle) data_table — styled HTML table (props: dataframe_var, max_rows) alert_banner — info/warning/error banner (props: message, level) divider — styled horizontal rule (props: label)
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"project_id": "<project_id>",
"cell_id": "<cell_id>",
"component_type": "<component_type>",
"props": "<props>"
},
"name": "inject_html_component"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| props | Yes | ||
| cell_id | Yes | ||
| auto_run | No | ||
| project_id | Yes | ||
| component_type | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |