Skip to main content

Maid White SDK in Python

Project description

Maid White Python SDK


$ pip install maidwhite


from maidwhite import MaidWhite

# Get client with username and password
m = MaidWhite("username", "password")

# Get client with access token
m = MaidWhite("access_token")

# Get device list
l = m.get_devices()

# find device
ac = [x for x in l if x.display_name == "My Device"]

if len(ac) == 0:
	print("device not found")

my_device = ac[0]

# Get state
state = my_device.get_state()

# Set state
my_device.set_state({"power_status": "true"})

# Get power status
power_status = my_device.get_power_status()

# Set power status

Project details

Download files

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

Files for maidwhite, version 0.0.1
Filename, size File type Python version Upload date Hashes
Filename, size maidwhite-0.0.1-py3-none-any.whl (6.8 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size maidwhite-0.0.1.tar.gz (2.2 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page