You can create a monitoring dashboard by defining its configuration in a JSON file.
{
"title": "Industrial test boiler - type A",
"description": "test one",
"cards": [{
"id": "fuel_flow",
"size": "SMALL",
"title": "Fuel flow",
"type": "VALUE",
"content": {
"attributes": [{
"dataSourceId": "fuel_flow_rate",
"label": "Latest",
"precision": 3,
"thresholds": [{
"color": "#F00",
"comparison": ">",
"icon": "Warning",
"value": 2
}]
},
{
"dataSourceId": "fuel_flow_rate_min",
"label": "Minimum",
"precision": 3,
"thresholds": [{
"color": "#5aa700",
"comparison": ">",
"icon": "Checkmark outline",
"value": -2
}]
},
{
"dataSourceId": "fuel_flow_rate_max",
"label": "Maximum",
"precision": 3,
"thresholds": [{
"color": "#5aa700",
"comparison": "<",
"icon": "Checkmark outline,
"value": 5
}]
}
]
},
"dataSource": {
"attributes": [{
"aggregator": "last",
"attribute": "fuel_flow_rate",
"id": "fuel_flow_rate"
},
{
"aggregator": "min",
"attribute": "fuel_flow_rate",
"id": "fuel_flow_rate_min"
},
{
"aggregator": "max",
"attribute": "fuel_flow_rate",
"id": "fuel_flow_rate_max"
}
]
}
},
{
"id": "air_flow_mean_and_max_threshold",
"size": "LARGE",
"title": "Daily Max and Mean Air Flow for the last Week - Threshold",
"type": "TABLE",
"content": {
"columns": [{
"dataSourceId": "airflow_mean",
"label": "Airflow Mean"
},
{
"dataSourceId": "airflow_max",
"label": "Airflow Max"
},
{
"dataSourceId": "timestamp",
"label": "Time",
"type": "TIMESTAMP"
}
],
"expandedRows": [{
"dataSourceId": "company_code",
"label": "Company code"
}],
"sort": "DESC",
"thresholds": [{
"comparison": ">",
"dataSourceId": "high_pressure",
"severity": 3,
"value": 0
},
{
"comparison": ">",
"dataSourceId": "critical_pressure",
"severity": 1,
"value": 0
}
]
},
"dataSource": {
"attributes": [{
"aggregator": "mean",
"attribute": "air_flow_rate",
"id": "airflow_mean"
},
{
"aggregator": "count",
"attribute": "Is_Pressure_Too_High",
"id": "high_pressure"
},
{
"aggregator": "count",
"attribute": "Is_Pressure_Critical",
"id": "critical_pressure"
},
{
"aggregator": "max",
"attribute": "air_flow_rate",
"id": "airflow_max"
},
{
"aggregator": "last",
"attribute": "company_code",
"id": "company_code"
}
],
"range": {
"count": -7,
"interval": "day"
},
"timeGrain": "day",
"groupBy": ["manufacturer", "deviceid"]
}
},
{
"id": "air_flow_mean",
"size": "LARGE",
"title": "Air flow mean vs max",
"type": "TIMESERIES",
"content": {
"series": [{
"dataSourceId": "airflow_mean",
"label": "Airflow Mean"
},
{
"dataSourceId": "airflow_max",
"label": "Airflow Max"
}
],
"xLabel": "X axis",
"yLabel": "Y axis",
"unit": "PSI"
},
"dataSource": {
"attributes": [{
"aggregator": "mean",
"attribute": "air_flow_rate",
"id": "airflow_mean"
},
{
"aggregator": "max",
"attribute": "air_flow_rate",
"id": "airflow_max"
}
],
"range": {
"type": "periodToDate",
"count": -7,
"interval": "day"
},
"timeGrain": "day"
}
},
{
"id": "sensor-readings-image",
"size": "LARGE",
"title": "Sensor Readings",
"type": "IMAGE",
"content": {
"alt": "Sensor Readings",
"zoomMax": 5,
"image": "world_map",
"hotspots": [{
"icon": "Carbon icon",
"color": "'#0F0",
"content": {
"title": "Sensor readings",
"description": "Image card for Sensor readings",
"attributes": [{
"dataSourceId": "temp_last",
"label": "Temperature",
"unit": "F"
}]
},
"locations": [{
"x": "22.85",
"y": "33.183",
"dataFilter": {
"deviceid": "00001"
}
}],
"thresholds": [{
"dataSourceId": "temp_last",
"comparison": ">=",
"value": 100,
"color": "red",
"icon": "Close filled"
}]
}]
},
"dataSource": {
"attributes": [{
"aggregator": "last",
"attribute": "temp",
"id": "temp_last"
},
{
"aggregator": "last",
"attribute": "humidity",
"id": "humidity_last"
},
{
"aggregator": "last",
"attribute": "wind",
"id": "wind_last"
},
{
"aggregator": "last",
"attribute": "conditions",
"id": "conditions_last"
}
],
"range": {
"type": "rolling",
"count": -1,
"interval": "day"
},
"groupBy": [
"deviceid"
]
}
}
],
"layouts": {
"max": [],
"xl": [],
"lg": [],
"md": [],
"sm": [],
"xs": []
}
}
The structure of the dashboard schema is as follows:
At the top level of the JSON file, configure dashboard attributes.
Example:
{
"cards": [],
"title": "Industrial Boiler type A",
"timeGrain": "week",
"description": "Test boiler",
"layouts": {}
}
Table 1 - Dashboard
Parameter | Description | Type | Required |
---|---|---|---|
cards |
A definition of one or more cards. Cards present information as a table, a line graph, an image, or as values. | array | yes |
title |
The title of the dashboard. | string | yes |
timeGrain |
The default time grain on all cards on the dashboard. The value overrides the value set in the JSON configuration of line cards and table cards. Valid values are hour , day , week , month , or year . |
string | no |
description |
A description of the dashboard configuration. | string | no |
layouts |
Defines the default position of cards on the dashboard per breakpoint size. If you do not define any layouts, the default layout is applied for each breakpoint when you import the JSON for the dashboard. | object | no |
Use the cards array to define cards.
Use the layout object to define the layout.