Wyze has recently implemented a rate limit on accessing their private APIs. Due to this change, I cannot recommend installing this integration in HA until this all gets sorted out. I might resort to adding a "send_command" that maybe you can use to query Wyze servers. This way it's more event based and it will be on you to make sure you don't hit the rate limits. I have disabled polling on this integration.
To update the state of the device, you can do a vacuum.send_command
with command update
which will update the state of the vacuum. See vacuum-card example for an implementation.
Simple implementation of the Wyze Vacuum right into Home Assistant.
- Home Assistant 😅
- HACS Installed in Home Assistant
- Wyze Account without 2FA - Tip: Create a new account that you share just the vacuum with that doesn't have 2FA enabled.
- On Home Assistant go to HACS -> Integration
- Click menu on the top right
- Click on custom repositories
- Add https://github.com/romedtino/simple-wyze-vac as an Integration
- Edit your configuration.yaml and add
simple_wyze_vac:
username: your_wyze_email@email.com
password: your_wyze_password
- Verify your configuration file is valid
- Restart Home Assistant
If it all worked out, you should now have Wyze vacuum entity(ies)
service: vacuum.send_command
data:
command: sweep_rooms
params:
rooms:
- Hallway
- Kitchen
target:
entity_id: vacuum.theovac
service: vacuum.set_fan_speed
data:
fan_speed: quiet
target:
entity_id: vacuum.your_vac
- Battery Level
- Location is not supported but it is considered "supported" by HA so the button doesn't crash the component when using vacuum-card if you use it.
There's a lovely Lovelace vacuum-card here in which you can implement your vacuum like so:
Here is my YAML configuration of the card
type: custom:vacuum-card
entity: vacuum.theovac
image: default
show_toolbar: true
show_status: true
show_name: true
compact_view: false
actions:
- name: Clean living room
service: script.vacuum_room_clean
icon: mdi:sofa
service_data:
rooms:
- Living Room
- name: Update
service: script.vacuum_update_state
icon: mdi:update
and the contents of the scripts it invokes
alias: Vacuum Room Clean
variables:
rooms:
- Living Room
sequence:
- service: vacuum.send_command
data:
command: sweep_rooms
params:
rooms: ' {{ rooms }} '
target:
entity_id: vacuum.theovac
mode: single
alias: Vacuum Update State
sequence:
- service: vacuum.send_command
data:
command: update
target:
entity_id: vacuum.theovac
mode: single
- In theory everything from wyze-sdk should be possible?
- @shauntarves/wyze-sdk
- aarongodfrey - Helped figuring out what in the world I am doing
- Samuel - More info on how custom components work