Create Widget
Adds a widget configuration to a dashboard and returns the id of the created widget. Use the dashboard detail endpoint for its full configuration, or a query endpoint for computed widget data.
Path parameters
dashboardId
The id of the dashboard.
Headers
CONFIDENT_API_KEY
The API key of your Confident AI project.
Request
The widget configuration to add to the dashboard.
name
The widget's name.
description
An optional description of the widget.
type
The visualization type of a widget.
unit
The unit a widget's values are measured in.
mode
How a widget aggregates its lines. TIME_SERIES plots each configured line over time; DIMENSION_SERIES takes a single metric and splits it into one series per value of the widget’s dimension. This is the widget’s saved configuration — it does not by itself describe the shape of a query response (use kind on the query result for that).
bucketMode
How a widget’s data is bucketed over the query time range. SERIES splits the range into one bucket per granularity interval (a time series); RANGE aggregates the whole range into a single bucket (one total, as used by BIG_NUMBER widgets). Defaults to SERIES when omitted.
dimension
The dimension a widget breaks down by when mode is DIMENSION_SERIES.
topK
Limits a dimension breakdown to the top K series.
startTime
The start of the widget's custom time range, if set.
endTime
The end of the widget's custom time range, if set.
layout
A widget's position on the dashboard grid.
lines
The series to show in the widget.
Response
The id of the created widget.
success
Indicates if the request was successful.
data
The id of the affected dashboard or widget.
deprecated
Indicates if this endpoint is deprecated.