Automation on sonoff t1 2 gang

Hi all
I’ve problem with automation. I’d like to to turn on a shelly device or another shelly device pressing sonoff t1 button 1 or button 2,
I’ve created two automations and they’re working on hassio, but not with pressing button on sonoff T1 button 1 or 2.
this is my automation for button 1 :

  • id: ‘1595370490090’
    alias: SONOFF T1 PRESS BUTTON 1
    description: ‘’
    trigger:
    • entity_id: switch.sonoff_1000860e73_1
      from: ‘Off’
      platform: state
      to: ‘On’
      condition: []
      action:
    • device_id: 4c2324430ddc4cafa4104ef31d75f29f
      domain: light
      entity_id: light.shelly_shrgbw2_fc99ec_1
      type: turn_on

where is the error?
sorry for my english…
thanks in advance
rgds
Paolo

Please see instructions here (item #11) about how to properly format YAML code snippets. As it is we can’t read it properly.