Add a widget to a dashboard
widget_createAdd a timeseries widget to a dashboard by specifying a query, visualization type, and position. Supports chart styles like line, bar, area, and stacked bar.
Instructions
Create a new widget on the given dashboard. type is a widget type (V1: 'timeseries' only). query is an InsightsQuery — a discriminated union on kind (V1: 'timeseries' only). viz controls presentation (chartType: 'line' | 'bar' | 'area' | 'stacked_bar' | 'single_metric'). position defaults to a sensible {x,y,w,h} if omitted. Templates can't have widgets added via this tool.
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": {
"type": "<type>",
"name": "<name>",
"query": "<query>",
"dashboard_id": "<dashboard_id>"
},
"name": "widget_create"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | Yes | ||
| name | Yes | ||
| description | No | ||
| position | No | ||
| query | Yes | ||
| viz | No | ||
| dashboard_id | Yes | Target dashboard. |