Ring doorbell let light's flash

Hello,

I have a Ring Video doorbell. And I am trying to let some lights flash (with the color red if it’s possible) when someone rings the bell. But I can’t figure it out the way I want it.

I tried it with an automation, but now it flashes a few times and stays on. What i would like to do is flash (red) and after that go off when the lights were off. When the lights were on, flash red a few times and stay on (normal color).

- action:
- data:
  entity_id: group.all_lights
  flash: short
service: light.turn_on
alias: Deurbel
condition: []
id: '1511455642829'
trigger:
- entity_id: binary_sensor.ring_achterdeur_ding
from: 'off'
platform: state
to: 'on'
- entity_id: binary_sensor.ring_veurdeur_ding
from: 'off'
platform: state
to: 'on'