IoT Stadium

API Documentation

Widget

Widget - PUT Update Controller Widget

Post

{{url_iot_backend}}/ext/dashboards/:dashboardId/widgets/:id
{
	"key": "Content-Type",
	"value": "application/json"
},
{
	"key": "Authorization",
	"value": "Bearer {{token}}"
},

Parameter

Field Type Description
wiget_name String

Name of the widget

description String

Description text for the widget

width Integer

Width in grid units (2–12). Corresponds to % layout width.

height Integer

Widget height in pixels (min: 150, max: 600)

widget_type String

Type of the widget, should be: "device-controller"

device_actuator Array

List of actuator devices to control via the widget

device_actuator[].device_actuator_id Integer

ID of the actuator device

{
    "widget_name": "test controller postman",
    "description": "test",
    "width": 6,
    "height": 300,
    "widget_type": "device-controller",
    "device_actuator": [
        {
            "device_actuator_id": 162
        }
    ]
}                                            
{
    "message": "dashboard updated",
    "data": {
        "id": "812"
    },
    "code": 200
}
{
    "message": "Invalid Message",
    "code": 400,
    "errors": [
        {
            "field": "widget_name",
            "message": "The widget name field is required.."
        }
    ]
}