...
Code Block |
---|
await gb.notification.email("Your exhibit requires maintenance"); |
Websocket Events
This is a list of the possible websocket events that may be emitted by the SDK; for example:
Code Block |
---|
gb.on(Sockets.CONTROL_RECEIVED, (payload) => { //code reached when the SDK emits a Sockets.CONTROL_RECEIVED event }); |
Sockets.READY
Emitted after the SDK successfully authenticates with Gumband, comes online, and is ready to make requests to Gumband.
Sockets.EXHIBIT_ONLINE
Emitted when the SDK successfully authenticates with Gumband and comes online.
Sockets.EXHIBIT_OFFLINE
Emitted when the SDK losses its websocket connection with Gumband.
Sockets.CONTROL_RECEIVED
Emitted when a control is triggered, usually through the Exhibit/Controls tab in the Gumband UI.
Sockets.SETTING_RECEIVED
Emitted when a setting is changed, usually through the Exhibit/Settings tab in the Gumband UI.
Sockets.SETTING_LIST_RECEIVED
Emitted when a new setting list item is added or deleted, when the setting list items have their order changed, or when a setting within a setting list item is changed. The payload is the new setting list with all of its items.
Sockets.SETTING_LIST_ITEM_DELETED
Emitted when a setting list item is deleted. The payload is the setting list item that was deleted.
Sockets.OP_MODE_RECEIVED
Emitted when the Operation Mode is changed, usually through the Exhibit dashboard in the Gumband UI.
Sockets.HARDWARE_ONLINE
Emitted when a Gumband Hardware associated with the exhibit connects to the exhibit.
Sockets.HARDWARE_OFFLINE
Emitted when a Gumband Hardware associated with the exhibit disconnects from the exhibit.
Sockets.HARDWARE_PROPERTY_RECEIVED
Emitted when a property is changed in a Gumband Hardware that is connected to the exhibit.
Sockets.FILE_UPLOADED
Emitted when a new file has been uploaded to Gumband, usually through the Exhibit/Files tab of the Gumband UI.
Sockets.FILE_DELETED
Emitted when a file is deleted from Gumband, usually through the Exhibit/Files tab of the Gumband UI.