Closed lenoth closed 1 year ago
It looks like you are creating a new account object when getting the robots which means that account is not authenticated and won't have any information.
Ah, good catch. Do you know if robots only load if the user has a Litter Robot Connect account?
Using this snippet below I can't load them either. I'm able to authenticate with the correct account, just can't run commands following that.
import asyncio
from pylitterbot import Account
# Set email and password for initial authentication.
username = AUTHENTICATION_EMAIL
password = AUTHENTICATION_PASSWORD
async def main():
# Create an account.
account = Account()
try:
# Connect to the API and load robots.
await account.connect(username=username, password=password, load_robots=True)
# Print robots associated with account.
print("Robots:")
for robot in account.robots:
print(robot)
finally:
# Disconnect from the API.
await account.disconnect()
if __name__ == "__main__":
asyncio.run(main())
Do you know if robots only load if the user has a Litter Robot Connect account?
Yes, you can only see robots associated with your account. If you don't have any robots, there won't be anything to display. Your question makes it seem like you don't have a Litter-Robot or Feeder-Robot, or am I misinterpreting?
I have the litter robot 3. There is an extra option to buy the Connect which enables your account to use their mobile app.
Wasn't sure if that was a requirement to load my robot or not.
Ahh yes, this only supports reading and controlling connected robots. I'm curious what your use case is with this module and trying to access your LR3. At most you'd only be able to see a serial number or something, but I don't know the endpoints that are called to just get robots that are registered but have no cloud accessibility.
Ah! I'll have to get the connection then. Working on bit of a hobby project to control most of my home from my own personal built assistant on a React Native app and assign automations. (Already have it setup through SmartThings & Alexa, but wanted my own that I could experiment with).
Awesome library though, you deserve a beer! Thanks for the help.
Hi, I'm running into a problem where I can authenticate my user but nothing comes back when listing robots or running commands. Am I doing something wrong? Thank you in advance!