Is there any way to see when my Xiaomi Gateway Alarm has been triggered?

I am currently able to arm/disarm my Xiaomi Gateway Alarm from within HA, and that is a nice feature. When the alarm is armed, I set up the Mi Home App to trigger when certain door/window sensors are opened. This works pretty flawlessly and gives me a little peace of mind. More recently I am trying to integrate a feature where my CCTV feed displays on all of my televisions if the alarm is tripped. My automation works but upon further inspection I realized there is no way for me to see if the alarm has been triggered from within Home Assistant. Has anyone else figured this out and if so were they able to view if the alarm has been tripped? It would be great if I could configure HA to send me a notification when this happens as well. I searched the forums and didn’t find much on it. Any help is appreciated. Thanks!

Rather than having the door/window sensors trigger the alarm, you could detect this in HA and trigger the alarm from there. Then you could record that the alarm was triggered.

Not to be pedantic but just so I am understanding you correctly: You are saying that I should just monitor the sensors themselves in HA and forget the Xiaomi Hub Alarm integration? Is it possible I could use both in the meantime as I haven’t purchased any additional sirens for Home Assistant to use? I am currently using the siren integrated with the xiaomi hub.

You would keep the integration, but only use it from HA to play the siren sound. The integration page shows examples of how to trigger the alarms using xiaomi_aqara.play_ringtone. This is what I do, although I use it for the doorbell sound (although I’m using Node Red to do it).

The only problem you would have is the Xiaomi app lets you specify the sound duration, whereas the service call does not. It only plays for about 10 seconds, so you would have to repeat the sound. Also, if you’re using the push message to your phone, you would have to replace that with a notification (eg. using the HA Companion app, or Telegram, etc).

Thank you. Would you mind sharing your config for this?

Edit: Got it. Thanks for all your help.

# Play Xiaomi Hub When Alarm is Triggered
  - alias: "Sound Xiaomi Siren When Alarm Is Triggered"
      - platform: state
        entity_id: alarm_control_panel.home_alarm
        to: 'triggered'
      service: xiaomi_aqara.play_ringtone
        gw_mac: XXXXXXXXXX
        ringtone_id: 0
        ringtone_vol: 100

I also currently have it programmed so that when I disarm the alarm, the siren turns off. Ideally, I would like it to play that iconic “chirp chirp” noise it used to when disarmed and the single “chirp” when it’s armed. I cannot find these sounds under ringtones in the docs though. Any idea where I can find them?

You can upload your own sounds in the app, so you could probably get one from a free website. I tried this once but don’t use it any more. From memory, they load as custom ringtones, which start from id 10001 (according to the Integration page).

Hello @trwolff04 and @michaelblight ,

I think the same thing. I would like to trigger with gateway built-in alarm a RF outdoor siren. I not want to recreate the alarm automation in HA, because now it is independent to the state of HA server. If something is happen (server freeze, etc…) and i use HA to manage alarm, it not working…

So the original question (catch alarm trigger from gateway) is current from me.