You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working on my own integration into Hubitat, and am looking through your code. I'm not a professional at python, so I was hoping you could help explain the following method to me:
def _encode_room_list(self, rooms: List[str]):
"""Base64 encode the list of rooms to clean"""
if not rooms:
raise ValueError('Room list must not be empty')
if len(rooms) > 3:
raise ValueError('At most three rooms may be given')
# These are a mystery to me, but they seem constant
header = b'\x80\x01\x0b\xca\x02'
footer = b'\x1a\x08155B43C4'
I do notice some unusual encoding around a possible value:
Calling "SET_Areas_To_Clean" via the App, it's sending this as the payload:
Hello,
I'm working on my own integration into Hubitat, and am looking through your code. I'm not a professional at python, so I was hoping you could help explain the following method to me:
I do notice some unusual encoding around a possible value:
Calling "SET_Areas_To_Clean" via the App, it's sending this as the payload:
Which base64 decodes to:
Any tips? I'm essentially going to be making a simple string to pass this on to the API using Groovy.
The text was updated successfully, but these errors were encountered: