Deepstack Automation throwing error

HASSOS v 2022.8
I have the following script and it throws the following error

Message malformed: expected dictionary

The formatting is correct and I’ve single quotes (I think) in the correct areas

Any suggestions as to what is causing the error

- id: 1120-0929-26722
  alias: Object detection automation
  description: ""
  trigger:
    - platform: event
      event_type: deepstack.object_detected
      event_data:
        event_data:
          name: person
    - platform: event
      event_type: deepstack.object_detected
      event_data:
        event_data:
          name: bird
    - platform: event
      event_type: deepstack.object_detected
      event_data:
        event_data:
          name: car
    - platform: event
      event_type: deepstack.object_detected
      event_data:
        event_data:
          name: truck
    - platform: event
      event_type: deepstack.object_detected
      event_data:
        event_data:
          name: cat
    - platform: event
      event_type: deepstack.object_detected
      event_data:
        event_data:
          name: dog
    - action:
        - data_template:
            caption: >-
              New object detection with confidence {{ trigger.event.data.confidence }}
            file: "{{ trigger.event.data.saved_file  }}"
          service: notify.telegram
    - action:
        - data:
            message: 'ROI Detected'
            name: deepstack.object_detected
            service: logbook.log
      mode: single