Skip to content

Events Sent

The plugin can send various messages to the Stream Deck application:

Event Description
setTitle Dynamically change the title of an instance of an action.
setImage Dynamically change the image displayed by an instance of an action.
showAlert Temporarily show an alert icon on the image displayed by an instance of an action.
showOk Temporarily show an OK checkmark icon on the image displayed by an instance of an action.
setSettings Save persistent data for the action's instance.
setState Change the state of the action's instance supporting multiple states.
sendToPropertyInspector Send a payload to the Property Inspector.
switchToProfile Switch to one of the preconfigured read-only profiles.
openUrl Open an URL in the default browser.

setTitle

The plugin can send a setTitle event to the Stream Deck application to dynamically change the title displayed by an instance of an action. The json structure looks like:

var json = {
    "event": "setTitle",
    "context": opaqueValue,
    "payload": {
        "title": "MyTitle",
        "target": software, hardware or both
    }
};

Note: In order to show the title on your hardware or software, the Show Title checkbox in the Stream Deck window must be activated:

Activate Show Title

Members Description
event setTitle
context An opaque value identifying the instance's action you want to modify.
payload A json object

The payload object contains the following members:

Payload Description
title The title to display. If no title is passed, the title is reset to the default title from the manifest.
target Specify if you want to display the title on the hardware and software (0), only on the hardware (1) or only on the software (2). Default is 0.

setImage

The plugin can send a setImage event to the Stream Deck application to dynamically change the image displayed by an instance of an action. The json structure looks like:

var json = {
    "event": "setImage",
    "context": opaqueValue,
    "payload": {
        "image": <base64 encoded image>,
        "target": software, hardware or both
    }
};
Members Description
event setImage
context An opaque value identifying the instance's action you want to modify.
payload A json object

The payload object contains the following members:

Payload Description
image The image to display encoded in base64 with the image format declared in the mime type (PNG, JPEG, BMP, ...). If no image is passed, the image is reset to the default image from the manifest.
target Specify if you want to display the title on the hardware and software (0), only on the hardware (1) or only on the software (2). Default is 0.

Examples of base64 encoded images:

"data:image/png;base64,iVBORw0KGgoA..."
"data:image/jpg;base64,/9j/4AAQSkZJ..."
"data:image/bmp;base64,/9j/Qk32PAAA..."

showAlert

The plugin can send a showAlert event to the Stream Deck application to temporarily show an alert icon on the image displayed by an instance of an action. The json structure looks like:

var json = {
    "event": "showAlert",
    "context": opaqueValue,
};
Members Description
event showAlert
context An opaque value identifying the instance's action.

showOk

The plugin can send a showOk event to the Stream Deck application to temporarily show an OK checkmark icon on the image displayed by an instance of an action. The json structure looks like:

var json = {
    "event": "showOk",
    "context": opaqueValue,
};
Members Description
event showOk
context An opaque value identifying the instance's action.

setSettings

The plugin can save persistent data for the action's instance. This is done using the setSettings event:

var json = {
    "event": "setSettings",
    "context": opaqueValue,
    "payload": {<json data>}
};
Members Description
event setSettings
context An opaque value identifying the instance's action.
payload A json object which is persistently saved for the action's instance.

setState

This function can be used by a plugin to dynamically change the state of an action supporting multiple states:

var json = {
    "event": "setState",
    "context": opaqueValue,
    "payload": {
        "state": 0-based integer
    }
};
Members Description
event setState
context An opaque value identifying the instance's action.
payload A json object

The payload object contains the following members:

Payload Description
state A 0-based integer value representing the state requested.

sendToPropertyInspector

The plugin can send a payload to the Property Inspector using the sendToPropertyInspector event:

var json = {
    "action": "com.elgato.example.action1",
    "event": "sendToPropertyInspector",
    "context": opaqueValue,
    "payload": {<json data>}
};
Members Description
action The action unique identifier.
event sendToPropertyInspector
context An opaque value identifying the instance's action.
payload A json object that will be received by the Property Inspector.

switchToProfile

The plugin can tell the Stream Deck application to switch to one of his preconfigured read-only profile using the switchToProfile event:

var json = {
    "event": "switchToProfile",
    "context": opaqueValue,
    "device": opaqueValue,
    "payload": {
        "profile": "ProfileName"
    }
};
Members Description
event switchToProfile
context An opaque value identifying the plugin. This value should be set to the PluginUUID received during the registration procedure.
device An opaque value identifying the device. Note that this opaque value will change each time you relaunch the Stream Deck application.
payload A json object

The payload object contains the following members:

Payload Description
profile The name of the profile to switch to. The name should be identical to the name provided in the manifest.json file.

Note that a plugin can only switch to read-only profiles that are declared in its manifest.json file. If the profile field is missing or empty, the Stream Deck application will switch back to the previously selected profile.


openUrl

The plugin can tell the Stream Deck application to open an URL in the default browser using the openUrl event:

var json = {
    "event": "openUrl",
    "payload": {
        "url": "https://www.elgato.com"
    }
};
Members Description
event openUrl
payload A json object

The payload object contains the following members:

Payload Description
url An URL to open in the default browser.