Skip to main content
PATCH
Move a widget or show another chart in it

Authorizations

next-auth.session-token
string
cookie
required

NextAuth session JWT cookie. Development: often next-auth.session-token. Production (HTTPS): often __Secure-next-auth.session-token. Send the cookie your browser receives after sign-in.

Path Parameters

dashboardId
string<cuid2>
required

Dashboard identifier.

widgetId
string<cuid2>
required

The widget's id, from the dashboard's widgets.

Body

application/json

Send a layout, a chartId, or both. Repointing shows another chart in the widget's place — the way to give one dashboard its own copy of a shared chart.

layout
object

A widget's position and size on the dashboard's 12-column grid, in whole grid units: 1 ≤ w ≤ 12, x + w ≤ 12, 1 ≤ h ≤ 8, 0 ≤ y ≤ 1000. Widgets may not overlap; gaps are allowed and close upward when the dashboard is drawn.

chartId
string<cuid2>

A chart in the dashboard's workspace that is not already on the dashboard.

Response

The updated widget

data
object
required

One chart's placement on the dashboard. chart is exactly what reading the chart returns.