Update a widget
A widget is one chart on a dashboard. Change only the fields you send. A change that would leave the widget unable to show data is refused with 400, and nothing is saved.
Changing only the name, size, position or filters never fails on the chart settings. Filters you send are checked as described in Filters.
Path parameters
slug:requiredstringThe workspace slug. It appears in your Plane URLs. In https://app.plane.so/my-team/projects/, the slug is my-team.
dashboard_id:requiredstring (uuid)The dashboard the widget is on.
pk:requiredstring (uuid)The widget ID. A widget on a different dashboard returns 404.
Body parameters
name:optionalstringDisplay name, 1 to 255 characters.
chart_type:optionalstringThe chart type, for example BAR_CHART. See Chart types or List widget types.
chart_model:optionalstringThe variant of the chart type, for example STACKED. It must be one the chart type allows. Chart types without variants still need BASIC.
config:optionalobjectSettings for the chart type. Some chart types require keys here, for example columns on WORK_ITEMS_TABLE. See Chart types.
x_axis_property:optionalstringAxis charts only, and required for them. A built-in property such as PRIORITY or STATE_GROUPS, or a custom work item property as cp_<property_id>. See Axis properties.
y_axis_metric:optionalstringAxis charts and NUMBER only, and required for them. For example WORK_ITEM_COUNT. See Axis metrics.
x_axis_date_grouping:optionalstringBucket size when the x axis is a date: DAY, WEEK, MONTH or YEAR.
group_by:optionalstringAxis charts only. A second grouping, with the same values as x_axis_property. BASIC and COMPARISON models clear it.
width:optionalintegerWidth on the dashboard grid, 0 or more. Default 1.
height:optionalintegerHeight on the dashboard grid, 0 or more. Default 1.
x_axis_coord:optionalintegerColumn on the dashboard grid, 0 or more. Default 0.
y_axis_coord:optionalintegerRow on the dashboard grid, 0 or more. Default 0.
pql_filters:optionalobjectPQL filter for this widget only, on top of the dashboard's, as { "stripped": "<PQL>" }. It applies when last_used_filter is pql_filters. If you send a non-empty one without filters or last_used_filter, the widget switches last_used_filter to pql_filters. See Filters.
filters:optionalobjectFilter object for this widget only. It applies when last_used_filter is rich_filters. See Filters.
last_used_filter:optionalstringWhich widget filter applies: pql_filters, or rich_filters (applies filters). Default rich_filters.
rich_filters:optionalobjectThe web app's filter-builder state. Stored and returned as sent; charts don't read it.
Response shaping
fields:optionalstringComma-separated list of fields to return. Fields you don't request are left out of the response instead of coming back as null. id is always included. Pass all to get every requestable field. An unknown field name returns 400. See Sparse fields.
Requestable here: chart_model, chart_type, config, created_at, created_by_id, dashboard_id, filters, group_by, height, id, last_used_filter, name, pql_filters, rich_filters, updated_at, updated_by_id, width, x_axis_coord, x_axis_date_grouping, x_axis_property, y_axis_coord, y_axis_metric.
Scopes
workspaces.dashboards.widgets:write, or the broad write scope.
Errors
| Status | Code | Cause |
|---|---|---|
400 | invalid_request | The widget doesn't fit its chart type: a missing config key or axis, a model the chart type doesn't allow, an unknown chart_type, or invalid filters. errors[] names the field. |
401 | unauthorized | Missing or invalid credentials. |
402 | payment_required | Dashboards, or this chart type, aren't included in the workspace's plan, or you aren't a member of the workspace. |
403 | forbidden | You can see the dashboard but can't edit it. |
404 | not_found | The dashboard or widget doesn't exist, or you can't see the dashboard. |
406 | not_acceptable | The Accept header asks for a representation the API can't produce. |
429 | rate_limited | Throttled. Wait for the Retry-After header's seconds before retrying. |
curl -X PATCH \
"https://api.plane.so/api/v2/workspaces/my-team/dashboards/05186e3b-94a3-49b0-8403-9307d292daea/widgets/0bda418f-3e9a-47bd-8e70-faa04e1f9540/" \
-H "X-Api-Key: $PLANE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"chart_model": "GROUPED",
"x_axis_coord": 0
}'import requests
response = requests.patch(
"https://api.plane.so/api/v2/workspaces/my-team/dashboards/05186e3b-94a3-49b0-8403-9307d292daea/widgets/0bda418f-3e9a-47bd-8e70-faa04e1f9540/",
headers={"X-Api-Key": "your-api-key"},
json={
"chart_model": "GROUPED",
"x_axis_coord": 0
},
)
print(response.json())const response = await fetch(
"https://api.plane.so/api/v2/workspaces/my-team/dashboards/05186e3b-94a3-49b0-8403-9307d292daea/widgets/0bda418f-3e9a-47bd-8e70-faa04e1f9540/",
{
method: "PATCH",
headers: {
"X-Api-Key": "your-api-key",
"Content-Type": "application/json",
},
body: JSON.stringify({
chart_model: "GROUPED",
x_axis_coord: 0,
}),
},
);
const data = await response.json();{
"id": "0bda418f-3e9a-47bd-8e70-faa04e1f9540",
"dashboard_id": "05186e3b-94a3-49b0-8403-9307d292daea",
"name": "Bar Chart",
"chart_type": "BAR_CHART",
"chart_model": "GROUPED",
"config": {
"group_by": "STATE_GROUPS",
"y_axis_metric": "WORK_ITEM_COUNT",
"x_axis_property": "PRIORITY",
"x_axis_date_grouping": null
},
"x_axis_property": "PRIORITY",
"x_axis_date_grouping": null,
"y_axis_metric": "WORK_ITEM_COUNT",
"group_by": "STATE_GROUPS",
"height": 4,
"width": 6,
"x_axis_coord": 0,
"y_axis_coord": 0,
"filters": {},
"pql_filters": {
"json": {},
"stripped": ""
},
"rich_filters": {},
"last_used_filter": "rich_filters",
"created_at": "2026-11-16T15:21:27.804027Z",
"updated_at": "2026-11-16T15:21:35.255170Z",
"created_by_id": "a5706ff6-df7d-4dac-947a-0a4fe14b6ed8",
"updated_by_id": "a5706ff6-df7d-4dac-947a-0a4fe14b6ed8"
}{
"type": "invalid_request",
"code": "invalid_request",
"detail": "One or more fields failed validation.",
"errors": [
{
"field": "chart_model",
"code": "invalid",
"message": "BAR_CHART does not support MULTI_LINE."
}
]
}
