Widgets

Create Widget

Create a widget with its metrics on a dashboard. A widget belongs to exactly one dashboard.

post/v1/widgets

Request

  • Base URL
    https://api.getbluejay.ai
  • URL
    https://api.getbluejay.ai/v1/widgets
  • Auth
    HTTPBearer (a scheme the document does not define)

Headers

X-Organization-Idstring
X-API-Keystring required

API key required to authenticate requests.

Request body

namestring required
descriptionstring nullable
chart_type'line' | 'bar' | 'pie' | 'table' | 'kpi' | 'pivot_table' | 'histogram' required
chart_mode'time_series' | 'categorical' nullable
data_type'observability' | 'simulation'
bar_mode'stacked' | 'side_by_side' nullable
aggregationstring[]
time_bucket'hour' | 'day' | 'week' | 'month' nullable
simulation_idsinteger[]

Required (non-empty) when group_by='simulation'

show_indeterminateboolean
column_visibilityobject nullable
color_overridesobject nullable

Per-series/per-slice colours as {"<label the chart draws>": "#rrggbb"}. Labels are matched case-insensitively; omitted labels keep the default palette.

show_legendboolean

Draw the colour key under the chart (pie, bar and line)

dashboard_idstring required

Dashboard the widget belongs to; a widget lives on exactly one dashboard

Response

Successful Response

idstring required
organization_idstring nullable
namestring required
descriptionstring nullable
chart_typestring required
chart_modestring nullable
data_typestring required
applies_to_all_agentsboolean
bar_modestring nullable
aggregationstring[] nullable
time_bucketstring nullable
group_bystring nullable
simulation_idsinteger[] nullable
show_indeterminateboolean nullable
filtersunknown
column_visibilityunknown
color_overridesobject nullable

The colour the chart draws each series or slice in, keyed by its label lowercased. Written whole when a widget is saved, so it names every label rather than only the ones a person changed.

show_legendboolean

Whether the chart draws its colour key

created_bystring nullable
created_atstring nullable
updated_atstring nullable

Changes