Ezviz integration: download the "last_alarm_pic"

This is what I have:

  • id: ‘1762131331601’
    alias: ‘Download Snapshot on Home Door Alarm’
    description: ‘’
    triggers:
    • trigger: state
      entity_id:
      • sensor.home_door_last_alarm_picture_url
        conditions:
        actions:
    • action: downloader.download_file
      metadata: {}
      data:
      overwrite: true
      url: ‘{{ states(’‘sensor.home_door_last_alarm_picture_url’‘) }}’
      filename: entrance_door.jpg
      mode: single

Then I have a generic camera that uses the image to display last snapshot.