Ring Alarm - MQTT Discovery Alarm integration

It should work virtualized. That is how I have it, not on RPi.
R u using the right link, its https://github.com/rs1932/ring-alarm-hassio-addon

Ah! That was it…I was using the old version. Thanks again!

I installed the updated plugin, put in credentials and pointed it to my local MQTT server, but nothing appears to be happening. When I refresh the logs it just shows:

Ring Alarm Integration
Node Version
v10.14.2
NPM Version
6.4.1
git version 2.20.1
added 121 packages from 86 contributors and audited 406 packages in 3.073s
found 0 vulnerabilities

The MQTT logs also don’t show any type of login. Here’s what my configs look like:

Mosquito MQTT:
{
“logins”: [],
“anonymous”: true,
“customize”: {
“active”: false,
“folder”: “mosquitto”
},
“certfile”: “fullchain.pem”,
“keyfile”: “privkey.pem”
}

Ring config:
{
“host”: “localhost”,
“port”: 1883,
“ring_topic”: “ring”,
“hass_topic”: “hass/status”,
“mqtt_user”: “”,
“mqtt_pass”: “”,
“ring_user”: “[email protected]”,
“ring_pass”: “myringpassword”
}

Is there something else I’m missing? I appreciate the help.

I don’t know if anonymous MQTT authentication works. I have authentication configured and it works great. Try configuring authentication.

Update to your usernames, passwords and IP address.

Mosquito MQTT:

{
  "logins": [
    {
      "username": "MQTTusername",
      "password": "MQTTpassword"
    }
  ],
  "anonymous": false,
  "customize": {
    "active": false,
    "folder": "mosquitto"
  },
  "certfile": "fullchain.pem",
  "keyfile": "privkey.pem"
}

Ring:

{
  "host": "192.168.1.1",
  "port": 1883,
  "ring_topic": "ring",
  "hass_topic": "hass/status",
  "mqtt_user": "MQTTusername",
  "mqtt_pass": "MQTTpassword",
  "ring_user": "[email protected]",
  "ring_pass": "RINGpassword"
}

Thanks for the tip…I tried every possible combination with MQTT and the ring integration. Currently, I am only able to get it running on my Pi pointing to my VMware instance of HA running MQTT. There must be an issue with this add-on and the vmware image. Here’s the MQTT error I get when I try running it on my vmware hassio instance:

1555986906: Socket error on client mqttjs_babb8dfa, disconnecting.

It’s running with the exact same config, etc. However, it runs just fine on the Pi arch.

Hi so I have all of this setup in Hassio. It appears thought that I can unlock/lock doors? Also with the Alaram you can only arm it if all contact sensors are closed? If I try to arm with a window open the ring hub just repeats over and over that sensors require bypass. Am I missing something here? I’d love to get all of this working!

That is by design. You cannot arm the alarm if there is a sensor that is broken and set to be armed in the mode you set the alarm (home or away). If you want to leave a window open when you arm the alarm, you either need to disable the contact sensor on that alarm in the Ring app or buy a spare magnet from Ring and attach it at the open position of the window. I would think that arming the alarm with a window wide open seems to be counter-productive.

Curious, I have a motion detector that is offline. But Hassio on the pi says it is detected?

My SD card fried. Previous backups I recovered didn’t work.
I had to rebuild my HA from scratch. So now I’m back up and running.
But when I add https://github.com/rs1932/ring-alarm-hassio-addon to the add-ons page, nothing populates my dashboard.
Thoughts? Is this still maintained?
I want to add this as an add-on. I use a RPi3B+.
Before everything fried on me, the add-on worked fine, I seem to remember.
I don’t know why it isn’t populating my dashboard.

what do the ring logs say?
read the link in here

AHA!!! Thanks! :smiley:

Just in case it’s helpful, I documented the steps that worked for me when integrating Alexa, HA (Hassbian) and Ring Alarm. Believe the specific MQTT script was built off this one (credit to acolytec3), so I’d imagine you could plug that in just the same.

It’s not really counter-productive? I have 2 floors, at night I leave the upstairs windows open for air but still want to arm my alarm. It would be nice if there was a way to exclude certain devices.

Yes, in the case of the 2nd story, that does make sense. You can disable a contact sensor inside the Ring app. Click on the desired sensor, and in it’s mode settings, you can set which mode the sensor is monitored. In your case, you would want to uncheck the home mode. Then the sensor will not be monitored when the alarm is set to armed and home.

Hi Grey,

Do you think you can help me out, newbie here. Ive set up the ring alarm hass.io add-on from github.com/rs1932/ring-alarm-hassio-addon and ive been trying to configure it for hours but still having issues with the alarm not appearing on the states. here are my configurations for mqtt, config.yaml, and ring add-on

{
“logins”: [
{
“username”: “username”,
“password”: “password”
}
],
“anonymous”: false,
“customize”: {
“active”: false,
“folder”: “mosquitto”
},
“certfile”: “fullchain.pem”,
“keyfile”: “privkey.pem”
}

mqtt:
broker: 127.0.0.1
username: userrr
password: skyis9
discovery: true
discovery_prefix: homeassistant
birth_message:
topic: ‘hass/status’
payload: ‘online’
qos: 0
retain: false
will_message:
topic: ‘hass/status’
payload: ‘offline’

{
“host”: “192.168.50.XXX”,
“port”: 1883,
“ring_topic”: “ring”,
“hass_topic”: “hass/status”,
“mqtt_user”: “username”,
“mqtt_pass”: “password”,
“ring_user”: “email”,
“ring_pass”: “password”
}

p.s is that “127.0.0.1” entry correct? I found that other people entered that, not sure if im correct. Please advise. Thanks.

Hey, well of course I can’t tell if your formatting is correct from above, but the info looks fine to me. That said I do have to ask you are using the ip of the hassio and not XXX :slight_smile:

I am not convinced the keep alive/birth thing works.

from the dashboard restart the ring add-on and look at the bottom for the logs. It will show about 8 lines quickly, then after a while it should fill up with your sensors.

oh, yes I also have 127.0.0.1

as well you installed the mosquito broker, not the web server and client thing? It only worked for me with the plain broker. May have just been me though

The problem is I want to monitor the windows in ring because when I do leave I generally close them and monitor from Ring app. It would be nice if there was a way in HA to do this instead.

I’ve started having an issue with my locks after upgrading HA as well.

The states and history show up just fine but the locks will not lock or unlock. I have 4 of them including 1 about 5 feet from the hub and none of them work. This was working about 15-30 days ago. Since then I’ve upgraded HA to the latest version, installed new batteries, unplugged lock and plug back in but still Unlock and Lock from HA does not work at all. Inside of ring this functions perfectly fine. Is anyone else having this issue? I’ve tried restarting but no luck! Please advise!

Here is what the integration is saying

2019-08-23T11:38:21.657Z ring-alarm-mqtt Received set lock state LOCK for lock Id: 629d0745
2019-08-23T11:38:21.658Z ring-alarm-mqtt Location Id: c2903t-1rv71-0
(node:40) UnhandledPromiseRejectionWarning: TypeError: location.setDeviceInfo is not a function
    at setLockTargetState (/ring-alarm-mqtt/ring-alarm-mqtt.js:379:22)
    at processCommand (/ring-alarm-mqtt/ring-alarm-mqtt.js:426:17)
    at process._tickCallback (internal/process/next_tick.js:68:7)
(node:40) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 26)
(node:41) UnhandledPromiseRejectionWarning: TypeError: location.setDeviceInfo is not a function
    at setLockTargetState (/ring-alarm-mqtt/ring-alarm-mqtt.js:379:22)
    at processCommand (/ring-alarm-mqtt/ring-alarm-mqtt.js:426:17)
    at process._tickCallback (internal/process/next_tick.js:68:7)
(node:41) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:41) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Yes, I am using the actual IP just added XX for privacy. How do I know if I have 127.0.0.1?

& yes im using the actual mosquito broker and not the web client add-on.

I went into my logs for the ring add-on and its showing all my sensors. But how do i get them to show in the dashboard or even in the states tab?

This is the code that it shows for each sensor:

availability_topic: ‘ring/9qh12m-590qo-0/status’,
payload_available: ‘online’,
payload_not_available: ‘offline’,
state_topic:
‘ring/9qh12m-590qo-0/alarm/binary_sensor/37d04ef8-5079-4322-aa55-a8b4af49a96a/state’,
json_attributes_topic:
‘ring/9qh12m-590qo-0/alarm/binary_sensor/37d04ef8-5079-4322-aa55-a8b4af49a96a/attributes’,
device_class: ‘door’ }
2019-08-23T18:21:07.314Z ring-alarm-mqtt HASS config topic: homeassistant/binary_sensor/9qh12m-590qo-0/fc03d74e-ecda-4031-9684-2d039f1b1593/config
2019-08-23T18:21:07.315Z ring-alarm-mqtt { name: ‘Dining Front Window’,
unique_id: ‘fc03d74e-ecda-4031-9684-2d039f1b1593’,

not sure what to tell you. I just rebooted my pi and ring is not working but it does show in states and on the dashboard. When I restart then the sensor show their states instead of empty circles on the dashboard.

127.0.0.1 is valid. Have you enabled the 2 factor auth in ring.com? I think that will not work

I think I would format my sd card and start a fresh install

I am about to give up trying to get Hassio to see my Ring alarm system. I’m running Hassio on a RPi and have an MQTT Mosquitto broker running on a separate RPi. I’ve tested the MQTT Broker and it is working just fine. On my Hassio I’ve installed the add-on found at https://github.com/rs1932/ring-alarm-hassio-addon. For configuration of the add-on I’ve included the correct MQTT username/password and the same for my Ring account. For the host I’ve tried the IP of the RPi running Hassio (192.186.XX.XXX), “localhost” and 127.0.0.1, all without any success. I am at a complete loss as to why I’m not seeing any of the sensors for my alarm system.

Any suggestions/guidance would be very appreciated.

SOLVED: In the ring alarm add-on config I needed to set the “host” to the IP of the MQTT RPi not the RPI running hassio. Did that and works just fine so far.