Skip to main content
PUT
Edit one widget's code

Authorizations

Authorization
string
header
required

Authorization: Bearer <token> where <token> is either a neo_sk_<env>_<secret> API key (service account) or a Microsoft Entra ID access token (dashboard user).

Path Parameters

dashboard_id
string
required
widget_id
string
required

Body

application/json

A hand edit of one widget's code: the field of its kind, one or more.

definition_id
string<uuid>
required

The definition the edit was made on (definition_id of the dashboard as read): a 409 when it is no longer the one in use.

function
string | null

A function widget: its whole def widget_<id>(ctx):, decorators included, nothing else. Shared helpers and collect(ctx) are changed through a full PUT.

Maximum string length: 200000
html
string | null

An html widget: its new html, under the same rules as on a PUT.

Maximum string length: 64000
query
PublicWidgetQuery · object | null

A described widget: its new query, checked against the dataset's columns.

Response

Success.

data
PublicDashboardCard · object
required

What a write answers: enough for the chat to open the dashboard beside it.

meta
object
required