Logic Commands
Scenes
Section titled “Scenes”AddExecutorCollectionDTO
Section titled “AddExecutorCollectionDTO”Add a scene.
| Field | Data type | Description |
| executorCollection | Object | An ExecutorCollection DTO object. |
code examples
{ "commandId": "OwnCommandId", "executorCollection": { "name": "Executor Room 1", "description": "Light and Dimmer Room1 Executor", "executors": [ { "type": "VALUE", "position": 0, "type": "VALUE", "thingId": "91905b50-bf83-4584-a14b-d4c2800cec1e", "channelId": "Dimmer", "value": { "type": "RAW", "type": "RAW", "value": 100.0 } }, { "type": "DELAY", "position": 1, "type": "DELAY", "delay": 3000 }, { "type": "STATE", "position": 2, "type": "STATE", "thingId": "thingIdFud14_2", "channelId": "Valve", "state": "OPEN" } ] }}{ "commandId": "OwnCommandId"}CreateExecutorThingDTO
Section titled “CreateExecutorThingDTO”Create a virtual device that can be used to control and display the connected scenes.
| Field | Data type | Description |
| id | String | ID of the ExecutorCollection for which a virtual device is to be created. |
| name | String | The name of the device to be created. |
code examples
{ "commandId": "OwnCommandId", "id": "9ece616d-ffbb-432b-bfd7-4362a38f435a", "name": "ExecutorThing 2"}DeleteExecutorCollectionDTO
Section titled “DeleteExecutorCollectionDTO”Delete a scene.
| Field | Data type | Description |
| id | String | ID of the ExecutorCollection to be deleted. |
code examples
{ "commandId": "OwnCommandId", "id": "9ece616d-ffbb-432b-bfd7-4362a38f435a"}ExecuteExecutorCollectionDTO
Section titled “ExecuteExecutorCollectionDTO”Execute an existing scene once.
| Field | Data type | Description |
| id | String | The ID of an existing scene. |
code examples
{ "commandId": "OwnCommandId", "id": "9ece616d-ffbb-432b-bfd7-4362a38f435a"}ExecuteExecutorCollectionObjectDTO
Section titled “ExecuteExecutorCollectionObjectDTO”Execute an existing or temporary scene once.
| Field | Data type | Description |
| executorCollection | Object | An ExecutorCollection DTO object that is to be executed. |
code examples
{ "commandId": "OwnCommandId", "executorCollection": { "id": "76dd6b1f-3f6a-4c02-b6d7-3539cd03201c", "name": "Executor5", "description": "Open Valve 5 seconds", "executors": [ { "position": 0, "type": "STATE", "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Valve", "state": "OPEN" }, { "position": 1, "type": "DELAY", "delay": 5000 }, { "position": 2, "type": "STATE", "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Valve", "state": "CLOSE" } ] }}{ "commandId": "OwnCommandId", "executorCollection": { "id": "76dd6b1f-3f6a-4c02-b6d7-3539cd03201c", "name": "TestExecutor", "description": "", "executors": [ { "position": 0, "type": "VALUE", "thingId": "91905b50-bf83-4584-a14b-d4c2800cec1e", "channelId": "Dimmer", "value": { "type": "RAW", "value": 100.0 } }, { "position": 1, "type": "DELAY", "delay": 5000 }, { "position": 2, "type": "VALUE", "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Dimmer", "value": { "type": "LINK", "foreignThingId": "91905b50-bf83-4584-a14b-d4c2800cec1e", "foreignChannelId": "Dimmer" } }, { "position": 3, "type": "DELAY", "delay": 5000 }, { "position": 4, "type": "VALUE", "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Dimmer", "value": { "type": "CALCULATED", "expression": "a+b", "values": { "a": { "type": "RAW", "value": 5.0 }, "b": { "type": "RAW", "value": 5.0 } } } } ] }}GetRunningExecutorCollectionsDTO
Section titled “GetRunningExecutorCollectionsDTO”Retrieves all currently executed scenes.
| Field | Data type | Description |
| searchString | String | Optional field for filtering the scenes. The name and description are searched. If the field does not exist or is empty, no filter is applied. |
code examples
{ "commandId": "OwnCommandId"}{ "commandId": "OwnCommandId", "searchString": "floor 1"}RunningExecutorCollectionsDTO
Section titled “RunningExecutorCollectionsDTO”Sent as a return to the command request.
| Field | Data type | Description |
| runningExecutorCollections | Array | An array of currently executed ExecutorCollectionDTOs. |
code examples
[ { "id": "6e092f8b-a897-460e-af40-d065a5a8d06d", "name": "ExecutorTEst", "description": "", "executors": [ { "type": "VALUE", "position": 0, "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Dimmer", "value": { "type": "RAW", "value": 77 } }, { "type": "DELAY", "position": 1, "delay": 5000 }, { "type": "VALUE", "position": 2, "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Dimmer", "value": { "type": "LINK", "foreignThingId": "91905b50-bf83-4584-a14b-d4c2800cec1e", "foreignChannelId": "Dimmer" } } ] }, { "id": "b8563612-6676-4e87-97f6-ac9fc80b8ecb", "name": "Executor1", "description": "", "executors": [ { "type": "RANDOM", "position": 0, "thingId": "91905b50-bf83-4584-a14b-d4c2800cec1e", "channelId": "Dimmer" }, { "type": "DELAY", "position": 1, "delay": 50000 } ] }]StopExecutorCollectionDTO
Section titled “StopExecutorCollectionDTO”Stops the execution of a scene.
| Field | Data type | Description |
| id | String | ID of the ExecutorCollection to be stopped. |
code examples
{ "commandId": "OwnCommandId", "id": "9ece616d-ffbb-432b-bfd7-4362a38f435a"}UpdateExecutorCollectionDTO
Section titled “UpdateExecutorCollectionDTO”Change a scene.
| Field | Data type | Description |
| ExecutorCollection | Object | An ExecutorCollection DTO object. The ID must be set correctly. |
code examples
{ "commandId": "OwnCommandId", "executorCollection": { "id": "76dd6b1f-3f6a-4c02-b6d7-3539cd03201c", "name": "New Name", "description": "new Description", "executors": [ { "type": "STATE", "position": 0, "thingId": "thingIdFud14_2", "channelId": "Valve", "state": "CLOSE" }, { "type": "DELAY", "position": 1, "delay": 5000 }, { "type": "STATE", "position": 2, "thingId": "thingIdFud14_2", "channelId": "Valve", "state": "OPEN" } ] }}RefreshExecutorCollectionsDTO
Section titled “RefreshExecutorCollectionsDTO”The data of the specified scenes is resent.
| Field | Data type | Description |
| ExecutorCollectionIds | Array | A list of ExecutorCollection IDs that are to be updated. If the field does not exist or is empty, all ExecutorCollections are updated. |
code examples
{ "commandId": "OwnCommandId"}{ "commandId": "OwnCommandId", "executorCollectionIds": [ "252afd4a-56d6-470d-ae87-cf0433eb15a5", "971c0c85-8f5d-45b6-894a-b8026f09d6ca" ]}AddConditionCollectionDTO
Section titled “AddConditionCollectionDTO”Add a rule.
| Field | Data type | Description |
| conditionCollection | Object | A ConditionCollection DTO object. |
code examples
{ "commandId": "OwnCommandId", "conditionCollection": { "type": "COLLECTION", "position": 0, "name": "MY_COLLECTION", "description": "A beautiful condition collection", "conditions": [ { "type": "STATE", "position": 0, "comparator": "EQUAL", "thingId": "d5da720e-2ad6-4c86-88c0-f84390f76570", "channelId": "WindowHandle", "smartCheck": false, "state": "CLOSED" }, { "type": "OPERATOR", "position": 1, "comparator": "AND" }, { "type": "VALUE", "position": 2, "comparator": "GREATER", "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Dimmer", "smartCheck": false, "value": 45.0 } ] }}{ "commandId": "OwnCommandId"}DeleteConditionCollectionDTO
Section titled “DeleteConditionCollectionDTO”Delete a rule.
| Field | Data type | Description |
| id | String | ID of the ConditionCollection |
code examples
{ "commandId": "OwnCommandId", "id": "7c6ba18c-d4ee-4254-91aa-9989bf581f68"}UpdateConditionCollectionDTO
Section titled “UpdateConditionCollectionDTO”Change a rule.
| Dield | Data type | Description |
| conditionCollection | Object | A ConditionCollection DTO object. The ID must be set correctly |
code examples
{ "commandId": "OwnCommandId", "conditionCollection": { "type": "COLLECTION", "position": 0, "id": "7c6ba18c-d4ee-4254-91aa-9989bf581f68", "name": "Conditon1", "description": "Controls Dimmer Bathroom", "conditions": [ { "type": "STATE", "position": 0, "comparator": "EQUAL", "thingId": "d5da720e-2ad6-4c86-88c0-f84390f76570", "channelId": "WindowHandle", "smartCheck": false, "state": "CLOSED" }, { "type": "OPERATOR", "position": 1, "comparator": "OR" }, { "type": "VALUE", "position": 2, "comparator": "GREATER", "thingId": "f5a69feb-59f0-4a44-a243-d2420c84f562", "channelId": "Dimmer", "smartCheck": false, "value": 45.0 } ] }}RefreshConditionCollectionsDTO
Section titled “RefreshConditionCollectionsDTO”The data of the specified rules is sent again.
| Field | Data type | Description |
| conditionCollectionIds | Array | A list of ConditionCollection IDs that are to be updated. If the field does not exist or is empty, all ConditionCollections are updated. |
code examples
{ "commandId": "OwnCommandId", "conditionCollectionIds": [ "0809bb46-4ce7-42a3-8c78-04cb7d24a30e", "e37b6aee-2e35-4b64-82a5-8dd7a822e861" ]}{ "commandId": "OwnCommandId"}Connections
Section titled “Connections”AddConnectionDTO
Section titled “AddConnectionDTO”Add a connection.
| Field | Data type | Description |
| connection | Object | A Connection DTO object. |
code examples
{ "commandId": "OwnCommandId", "connection": { "active": true, "conditionCollectionId": "0809bb46-4ce7-42a3-8c78-04cb7d24a30e", "executorCollectionId": "971c0c85-8f5d-45b6-894a-b8026f09d6ca", "name": "Connection 1", "description": "Connects cond1 and exec1" }}{ "commandId": "OwnCommandId"}DeleteConnectionDTO
Section titled “DeleteConnectionDTO”Delete a connection.
| Field | Data type | Description |
| id | String | ID of the Connection to be deleted. |
code examples
{ "commandId": "OwnCommandId", "id": "1ff100d2-d3ab-484f-b36f-1e84c6a7a4db"}SetConnectionEnabledDTO
Section titled “SetConnectionEnabledDTO”Activates or deactivates a connection without deleting it.
| Field | Data type | Description |
| id | String | ID of the Connection. |
| enabled | Boolean | Flag whether the link should be active or not. |
code examples
{ "commandId": "OwnCommandId", "id": "1ff100d2-d3ab-484f-b36f-1e84c6a7a4db", "enabled": true}UpdateConnectionDTO
Section titled “UpdateConnectionDTO”Update a connection.
| Field | Data type | Description |
| connection | Object | A Connection DTO object. The ID must be set correctly. |
code examples
{ "commandId": "OwnCommandId", "connection": { "id": "2d46cc1b-5780-4d4e-b5de-293ec346d6b7", "active": false, "conditionCollectionId": "0809bb46-4ce7-42a3-8c78-04cb7d24a30e", "executorCollectionId": "971c0c85-8f5d-45b6-894a-b8026f09d6ca", "name": "Connection 1", "description": "Connects cond1 and exec1" }}RefreshConnectionsDTO
Section titled “RefreshConnectionsDTO”The data of the specified connections is resent.
| Field | Data type | Description |
| connectionIds | Array | A list of Connection IDs that are to be updated. If the field does not exist or is empty, all Connections are updated. |
code examples
{ "commandId": "OwnCommandId", "connectionIds": [ "da12f7c7-4126-46f1-a811-32dac2bbf2c7", "fe742922-ddf1-4ea2-a52d-d29435359bfa" ]}{ "commandId": "OwnCommandId"}Timer commands
Section titled “Timer commands”CreateTimerDTO
Section titled “CreateTimerDTO”Create a new timer with the desired name.
| Field | Data type | Description |
| name | String | The name of the new timer. |
code examples
{ "commandId": "OwnCommandId", "name": "Azure timer"}UpdateTimerDTO
Section titled “UpdateTimerDTO”Change timer settings.
| Field | Data type | Description |
| timer | Object | A SimpleIoTCoreTimer DTO object. The ID must be set correctly. |
code examples
{ "commandId": "OwnCommandId", "timer": { "id": "7c6ba18c-d4ee-4254-91aa-9989bf581f68", "type": "TIMER", "enabled": true, "visible": true, "time": 0, "offset": 0, "period": 15, "selectedDays": [ "MONDAY", "TUESDAY", "WEDNESDAY", "THURSDAY", "FRIDAY", "SATURDAY", "SUNDAY" ] }}SetTimerEnabledDTO
Section titled “SetTimerEnabledDTO”Activate/deactivate timer.
| Field | Data type | Description |
| id | String | The unique timer ID. |
| enabled | Boolean | Flag whether the timer is enabled or not. |
code examples
{ "commandId": "OwnCommandId", "id": "7c6ba18c-d4ee-4254-91aa-9989bf581f68", "enabled": false}