From 72c97f7564cd99ba339d7c1ef3a9a889ae4279a2 Mon Sep 17 00:00:00 2001 From: Rich O Date: Wed, 27 Nov 2019 14:43:23 -0500 Subject: [PATCH] gah, forgot it's entity_id!! --- r0b3bot.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/r0b3bot.py b/r0b3bot.py index 8f41360..fbf8e14 100644 --- a/r0b3bot.py +++ b/r0b3bot.py @@ -255,7 +255,7 @@ async def printstat(ctx): #remote.call_service(hassapi, 'switch', 'turn_on', {'entity_id':'{}'.format(HASS_LIGHT)}) hassAPIRUL = HASS_IP_ADDRESS + "/api/services/switch/turn_on" payload = { - "entity": f"{HASS_LIGHT}" + "entity_id": f"{HASS_LIGHT}" } requests.post(hassAPIURL, data=payload, headers=hassHEADERS) except: @@ -289,7 +289,7 @@ async def printstat(ctx): #remote.call_service(hassapi, 'switch', 'turn_on', {'entity_id':'{}'.format(HASS_LIGHT)}) hassAPIRUL = HASS_IP_ADDRESS + "/api/services/switch/turn_off" payload = { - "entity": f"{HASS_LIGHT}" + "entity_id": f"{HASS_LIGHT}" } requests.post(hassAPIURL, data=payload, headers=hassHEADERS) except: -- 2.39.5