@ -127,8 +127,7 @@ node.log("Time-based Automations: Decision Logic Complete")
|
||||
// ---------- Service Calls ----------
|
||||
let sendLights = {
|
||||
"payload": {
|
||||
"domain": "light",
|
||||
"service": "turn_off",
|
||||
"action": "light.turn_off",
|
||||
"target": {
|
||||
"entity_id": lightsOff
|
||||
},
|
||||
@ -138,8 +137,7 @@ let sendLights = {
|
||||
|
||||
let sendSleepOff = {
|
||||
"payload": {
|
||||
"domain": "switch",
|
||||
"service": "turn_off",
|
||||
"action": "switch.turn_off",
|
||||
"target": {
|
||||
"entity_id": adaptiveSleep
|
||||
},
|
||||
@ -149,8 +147,7 @@ let sendSleepOff = {
|
||||
|
||||
let sendBooleanOff = {
|
||||
"payload": {
|
||||
"domain": "input_boolean",
|
||||
"service": "turn_off",
|
||||
"action": "input_boolean.turn_off",
|
||||
"target": {
|
||||
"entity_id": booleanOff
|
||||
},
|
||||
@ -160,8 +157,7 @@ let sendBooleanOff = {
|
||||
|
||||
let sendAdaptive = {
|
||||
"payload": {
|
||||
"domain": "switch",
|
||||
"service": "turn_" + setAdaptive,
|
||||
"action": "switch.turn_" + setAdaptive,
|
||||
"target": {
|
||||
"entity_id": switchAdaptive
|
||||
},
|
||||
@ -171,8 +167,7 @@ let sendAdaptive = {
|
||||
|
||||
let sendSceneResetMain = {
|
||||
"payload": {
|
||||
"domain": "input_text",
|
||||
"service": "set_value",
|
||||
"action": "input_text.set_value",
|
||||
"target": {
|
||||
"entity_id": selScenesMain
|
||||
},
|
||||
@ -184,8 +179,7 @@ let sendSceneResetMain = {
|
||||
|
||||
let sendSceneResetDesk = {
|
||||
"payload": {
|
||||
"domain": "input_text",
|
||||
"service": "set_value",
|
||||
"action": "input_text.set_value",
|
||||
"target": {
|
||||
"entity_id": selScenesTinaDesk
|
||||
},
|
||||
@ -197,8 +191,7 @@ let sendSceneResetDesk = {
|
||||
|
||||
let sendHoliday = {
|
||||
"payload": {
|
||||
"domain": "switch",
|
||||
"service": "turn_" + setHoliday,
|
||||
"action": "switch.turn_" + setHoliday,
|
||||
"target": {
|
||||
"entity_id": switchHoliday
|
||||
},
|
||||
@ -208,8 +201,7 @@ let sendHoliday = {
|
||||
|
||||
let sendTimer = {
|
||||
"payload": {
|
||||
"domain": "timer",
|
||||
"service": "start",
|
||||
"action": "timer.start",
|
||||
"target": {
|
||||
"entity_id": timerEntity
|
||||
},
|
||||
@ -221,8 +213,7 @@ let sendTimer = {
|
||||
|
||||
let sendTimerCancel = {
|
||||
"payload": {
|
||||
"domain": "timer",
|
||||
"service": "cancel",
|
||||
"action": "timer.cancel",
|
||||
"target": {
|
||||
"entity_id": timerEntity
|
||||
},
|
||||
@ -232,8 +223,7 @@ let sendTimerCancel = {
|
||||
|
||||
let sendNotifyPhone = {
|
||||
"payload": {
|
||||
"domain": "script",
|
||||
"service": "text_notify",
|
||||
"action": "script.text_notify",
|
||||
"data": {
|
||||
"who": "all",
|
||||
"title": notifyTitle,
|
||||
@ -246,8 +236,7 @@ let sendNotifyPhone = {
|
||||
|
||||
let sendNotifyTV = {
|
||||
"payload": {
|
||||
"domain": "script",
|
||||
"service": "tv_notify",
|
||||
"action": "script.tv_notify",
|
||||
"data": {
|
||||
"who": "all",
|
||||
"title": notifyTitle,
|
||||
@ -263,8 +252,7 @@ let sendNotifyTV = {
|
||||
|
||||
let sendFirstFloorScene = {
|
||||
"payload": {
|
||||
"domain": "script",
|
||||
"service": "evening_on_first_floor",
|
||||
"action": "script.evening_on_first_floor",
|
||||
"data": {
|
||||
"sunset_lights": 1
|
||||
}
|
||||
@ -273,8 +261,7 @@ let sendFirstFloorScene = {
|
||||
|
||||
let sendSecondFloorScene = {
|
||||
"payload": {
|
||||
"domain": "script",
|
||||
"service": "evening_on_second_floor",
|
||||
"action": "script.evening_on_second_floor",
|
||||
"data": {
|
||||
"sunset_lights": 1
|
||||
}
|
||||
@ -283,8 +270,7 @@ let sendSecondFloorScene = {
|
||||
|
||||
let sendDeskScene = {
|
||||
"payload": {
|
||||
"domain": "input_select",
|
||||
"service": "select_option",
|
||||
"action": "input_select.select_option",
|
||||
"target": {
|
||||
"entity_id": ["input_select.tina_desk_scenes"]
|
||||
},
|
||||
|
Reference in New Issue
Block a user