Triggers in Automations Question

Hi. I just wanted to ask if anyone knows what I am doing wrong. I am trying to setup an automation trigger that fires when there is a “ding” event from my ring doorbell. The automation is as follows;

description: ""
mode: single
triggers:
  - trigger: event
    event_type: ding
    event_data:
      entity_id: event.front_door_ring_camera_ding
conditions: []
actions: []

For some reason whenever I ring the doorbell my automation doesn’t fire. I have to use the change in entity state rather than the event trigger. I’m just curious because I may need to use the event trigger in the future.

I should also add that my automation doesn’t run even when I manually fire the “ding” event. I also setup a event listner and I do indeed get a response when I manually trigger it

Do you see the event come in when you monitor for it in Developer Tools → Events?

If so, copy and paste what the entire event looks like.

This is the response I get;

event_type: ding
data: {}
origin: REMOTE
time_fired: “2025-02-13T21:23:02.612016+00:00”
context:
id: 01JM0K36AM2NSCBKDRSF8HW4CJ
parent_id: null
user_id: faef480b6fc6461b81a5757dc34c5ca1

Your trigger is set up to require an entity_id in the event data, but, as you can see in the readout of the event, no entity_id is being passed in. So your trigger never fires.

Try:

description: ""
mode: single
triggers:
  - trigger: event
    event_type: ding
conditions: []
actions: []

That partially worked. It works when I manually fire the “ding” event but not when i physically press the doorbell

Here a pic of my logbook

The logbook isn’t too helpful for debugging event triggers. You really want to pay attention to the Developer Tools → Events tool.

Look carefully to see if there is any difference between the event as you fire it manually and the event when it’s fired by the doorbell. Paste both in here if you need help, making clear which is which. (Use the ‘Preformatted Text’ option that looks like a </> in the toolbar to help make that output more readable for people.)

thats weird… it doesn’t even show up in devtools Events when I press the doorbell. I’ve looked at the States page for the Entity this is what it shows…

You’re (rather understandably) confusing two entirely different “event” things (for lack of better word).

The event.front_door_ring_camera_ding is an event entity, and you can only use state-based triggers with it. The state of the entity is a date/time string that identifies when something last happened with the doorbell.

The event trigger that you’ve written for your automation, and that you monitor in the Development Tools → Events tool, is a lower-level thing, a stateless message.

It’s possible that the integration that underlies your doorbell and plugs it into HA sends event messages, but I don’t know one way or another whether it does. (We know that if it does send events, it does not send the event ‘ding’). To use the event entity in your screenshot, though, you are supposed to use a state trigger.

All you should need is a simple State trigger:

triggers:
  - trigger: state
    entity_id: event.front_door_ring_camera_ding

The state trigger is documented here.

Probably, this would work…

triggers:
  - trigger: state
    entity_id: event.front_door_ring_camera_ding

sorry. I know how to do that lol. Im wondering if because under states in devtools it says that its attribution value is “Data Provided by Ring.com” ? Could have something to do with it

I don’t know exactly what you mean by that… The Ring integration was updated a couple months ago to use the event entities instead of providing a binary sensor for “ding”, but this practice is not restricted to that integration. The event entities were created to try to help reduce the need for users to figure out the complexities of Event triggers for common cases like button presses.

Oh ok! Well thank you very much for taking the time to help me out! I’ve marked your use of the state trigger as the solution for this thread!

Take care