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: