Skip to main content

Python package for controlling Whisker automatic robots.

Project description

pypi downloads Buy Me A Coffee/Beer Purchase Litter-Robot

pylitterbot

Python package for controlling Whisker connected self-cleaning litter boxes and feeders.

This is an unofficial API for controlling various Whisker automated robots. It currently supports Litter-Robot 3 (with connect), Litter-Robot 4 and Feeder-Robot.

Disclaimer

This API is experimental and was reverse-engineered by monitoring network traffic and decompiling source code from the Whisker app since no public API is currently available at this time. It may cease to work at any time. Use at your own risk.

Installation

Install using pip

pip install pylitterbot

Alternatively, clone the repository and run

poetry install

Usage

import asyncio

from pylitterbot import Account

# Set email and password for initial authentication.
username = "Your username"
password = "Your 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())

which will output something like:

Name: Litter-Robot Name, Serial: LR3C012345, id: a0123b4567cd8e

To start a clean cycle

await robot.start_cleaning()

If no exception occurred, your Litter-Robot should now perform a clean cycle.

Currently the following methods are available in the Robot class:

  • refresh()
  • start_cleaning()
  • reset_settings()
  • set_panel_lockout()
  • set_night_light()
  • set_power_status()
  • set_sleep_mode()
  • set_wait_time()
  • set_name()
  • get_activity_history()
  • get_insight()

TODO

  • Improve support for Litter-Robot 4
  • Improve support for Feeder-Robot

Support Me

I'm not employed by Whisker and provide this python package as-is.

If you don't already own a Litter-Robot, please consider using my referral link to purchase your own robot and save $25!

If you already own a Litter-Robot and/or want to donate to me directly, consider buying me a coffee (or beer) instead by using the link below:

Buy Me a Coffee at ko-fi.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pylitterbot-2023.5.1.tar.gz (28.3 kB view details)

Uploaded Source

Built Distribution

pylitterbot-2023.5.1-py3-none-any.whl (36.7 kB view details)

Uploaded Python 3

File details

Details for the file pylitterbot-2023.5.1.tar.gz.

File metadata

  • Download URL: pylitterbot-2023.5.1.tar.gz
  • Upload date:
  • Size: 28.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.0 Linux/6.5.0-1023-azure

File hashes

Hashes for pylitterbot-2023.5.1.tar.gz
Algorithm Hash digest
SHA256 db33d766ba66b8facd3103d67798b72aadf9bacebbeefc4a3aab9c54e4991d34
MD5 ab56e7da63cc16a70c6af14cf8c65e17
BLAKE2b-256 7f4dd6c17ba277ed0d074bb748527d361fc43e2e4189d31831daa089e3f99457

See more details on using hashes here.

File details

Details for the file pylitterbot-2023.5.1-py3-none-any.whl.

File metadata

  • Download URL: pylitterbot-2023.5.1-py3-none-any.whl
  • Upload date:
  • Size: 36.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.0 Linux/6.5.0-1023-azure

File hashes

Hashes for pylitterbot-2023.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3b7cf5d0a280fbab95741ae6de63449f0b42cba6fbf3ccb77cdffb5bdb9fc072
MD5 98c315b4db54f9e29db7570707cde171
BLAKE2b-256 3af2720bebc5583242d59d91baf7e932e14bfe97dcace46f9cf82687f8f44d7c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page