WYZE automation issues

All,

First, thanks for all the incredible info. Being new, it is really helpful to have so much info readily available.

Despite all the info, I am having some trouble finding a solution to my issue. I recently purchased and installed a few Wyze sensors, door, and motion. I see them in HA and they are showing motion or open/closed for doors. However, I am unable to get any automation to work. I have tried through the native automation feature and have tried with Node-red.

I have tried with both “on” and “off” as well as “clear” and “Detected”/“Open”/“Close”

Any thoughts?

Thanks

i been using the wyse sense for a long time for me work perfect , im using node-red for my automation , and a few native ones , can you post your automation , to understand if there is a error

Fernando,

Thanks a ton for the reply. Here are two screenshots of the automation feature.

I deleted my node-red automations as I was not able to get them working. Could you share an example of one of your node red WYZE sensor automations?

Thanks again.

the motion sensor is on and off

you can always test that on the developer tools -> states -> select your entity,
the payload for thw wyze sense is on and off

also i notice that in your actions you are using device instead of call service , switch.turn_on or light.turn_on and your entity

this one is a basic one for node-red

[{"id":"51c746fd.1aabb8","type":"api-call-service","z":"a0f0a9aa.3ef898","name":"off","server":"f65aa0c3.2f15d","version":1,"debugenabled":false,"service_domain":"switch","service":"turn_off","entityId":"switch.bajando","data":"","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":730,"y":120,"wires":[[]]},{"id":"c5e54ad4.9fb818","type":"delay","z":"a0f0a9aa.3ef898","name":"","pauseType":"delay","timeout":"30","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":580,"y":120,"wires":[["51c746fd.1aabb8"]]},{"id":"751b905b.fca608","type":"api-call-service","z":"a0f0a9aa.3ef898","name":"bajando on","server":"f65aa0c3.2f15d","version":1,"debugenabled":false,"service_domain":"switch","service":"turn_on","entityId":"switch.bajando","data":"","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":410,"y":120,"wires":[["c5e54ad4.9fb818"]]},{"id":"599f5241.8a47ac","type":"server-state-changed","z":"a0f0a9aa.3ef898","name":"sensor movimiento arriba","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_7798454e","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"on","halt_if_type":"str","halt_if_compare":"is","outputs":2,"output_only_on_state_change":true,"x":170,"y":120,"wires":[["751b905b.fca608"],[]]},{"id":"f65aa0c3.2f15d","type":"server","z":"","name":"mi Home Assistant","legacy":false,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true}]

and this one if to notify me if the battery is low

[{"id":"f664fc68.535c8","type":"server-state-changed","z":"c3375db8.c5ca7","name":"Puerta principal","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_77966519","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":220,"y":1800,"wires":[["5fa4b554.6cbd84"]]},{"id":"e46cb05c.a4ec8","type":"server-state-changed","z":"c3375db8.c5ca7","name":"Puerta Casa","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_77966792","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":210,"y":1840,"wires":[["5fa4b554.6cbd84"]]},{"id":"22fa205c.45b108","type":"server-state-changed","z":"c3375db8.c5ca7","name":"planta a mov","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_7798454e","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":210,"y":1880,"wires":[["5fa4b554.6cbd84"]]},{"id":"b8b1e98.0896398","type":"server-state-changed","z":"c3375db8.c5ca7","name":"baño a mov","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_779f085a","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":210,"y":1920,"wires":[["5fa4b554.6cbd84"]]},{"id":"5eb8311c.6aaed8","type":"server-state-changed","z":"c3375db8.c5ca7","name":"cuarto terraza","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_77a02f96","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":210,"y":1960,"wires":[["5fa4b554.6cbd84"]]},{"id":"6bc6ae37.b10898","type":"server-state-changed","z":"c3375db8.c5ca7","name":"sala terraza","server":"f65aa0c3.2f15d","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"binary_sensor.wyzesense_77a03077","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"x":210,"y":2000,"wires":[["5fa4b554.6cbd84"]]},{"id":"5fa4b554.6cbd84","type":"switch","z":"c3375db8.c5ca7","name":"","property":"data.attributes.battery_level","propertyType":"msg","rules":[{"t":"gt","v":"30","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":430,"y":1840,"wires":[["cf7e16e1.2d4798"]]},{"id":"cf7e16e1.2d4798","type":"api-call-service","z":"c3375db8.c5ca7","name":"bateria baja telegram","server":"f65aa0c3.2f15d","version":1,"debugenabled":false,"service_domain":"notify","service":"casa","entityId":"","data":"{\"title\":\"Bateria\",\"message\":\"La bateria de {{data.attributes.friendly_name}} esta en {{data.attributes.battery_level}}%\"}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":620,"y":1840,"wires":[[]]},{"id":"f65aa0c3.2f15d","type":"server","z":"","name":"mi Home Assistant","legacy":false,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true}]

AWESOME! I didn’t have “call Service” selected. Thanks a ton. I will work on the node-red next to build more complex automations.

Do you happen to know anything about setting up Mosquitto? Haha. I thought I followed everything as directed but for some reason I don’t think it’s working. I may just not be understanding how MQTT works.
Thanks so much!

yes i do , what have you done already?

also what devices you trying to add to the mqtt broker

cool. 1st - I have my HA running through duckdns. I have installed mosquitto through the official store. I followed instructions and created a user. I then downloaded MQTT explorer and tried to find or login into my “MQTT” but nothing is working.

Thanks for any help.

are you using ?
http:your_ha_ip:1883, dont use your duckdns url for the broker url use your local ip ,

No I was using the duckdns. Thanks. I will try that.

Really appreciate your help man.

np

get some sonoff and flash them with tasmota and soon you will understand mqtt

Ok. Cool. Can you give me an example? can I use for garage door?

yes you can

using device class you can use it for a garage door

this video will explain all for a garage door

Wow. Thanks again. This is awesome but overwhelming at times. I really appreciate your help

sorry i send you a video with esphome

this one is for tasmota mqtt

Great! Thanks again.

Hey Fernando, Thanks for the help with WYZE. I am still having issues with MQTT explorer. Here is what I am using to try to logon.

The username I am using is the username I set up for MQTT in the configuration of Mosquitto in HA.

I think my HA host is wrong but I am not sure how to find the ip?

Thanks again!

Hey man, I found my ip and have logged in to MQTT explorer. Thus, I start my mitt journey! Haha. Thanks again!