Amcrest AD410 snapshot notification

Hi,
So i configured my AD410 in HA including sensor and all is working fine.
One issue which is remaining for me is i cant send snapshot notification.
I am using this URL for snapshot:
http://admin:[email protected]/cgi-bin/snapshot.cgi
When i open it in chrome it work (but in low resolution which is a different issue).
But when i try send this in HA using below code it doesn’t send the snapshot .
I tried this on multiple phone and also hass.agent to PC all with same issue.
any idea how to fix this ?

service: notify.my_pc
data:
  message: hi
  title: hello
  data:
    image: http://admin:[email protected]/cgi-bin/snapshot.cgi 

Image must be accessible from WAN or it will only be accesible in local network OR not at all if sent as notification

The link to image is being sent not the image itself. Usually i put image in www folder and point to that

EDIT
Https may also be required for ios and html5 notification

Can you explain how to put the image in www folder and point to that ?

FYI,
I am trying to send the message in local network without success.
Also tried to change the link to HTTPS in the beginning with out success.

If using something like html5 or notify.ios the link must be externally accessible even if local asset i believe.

-put file like notify.jpeg in www folder
-in automation save the image to be sent to that location
-send the notify.jpeg image in your notification
-you may delete or write some default image to location after image is sensitive

Honestly you may use some token to allow access to image as well but i never figure out how to use bearer token in link for this

not sure how to complete this steps …
can we talk in private ?
how do i save the image in automation and then send it ?

-in automation save the image to be sent to that location
-send the notify.jpeg image in your notification
-you may delete or write some default image to location after image is sensitive

I make automation later and edit this post with it

What notify method are you using?

I like to see this snapshot on multi notify service.
I use the HA app on my phone and also HASS.agent on PC and also android tv notification on my tv.
This is when someone will press the doorbell.
I guess if i can get one of this services to work i will be able to copy to other services.

I found this in thr docs that has example and explains in better detail where and how to store fike and has automation example

Let me know if that works for you

I am recommending using www folder since your using multiple services

As to your additional issue of the snapshot being low-res - that is inexplicably the default for AD410 snapshots (720x576 resolution)

You can change this to use the maximum 2560x1920 resolution via these HTTP API/CGI commands entered into a browser:

<ip_addr>/cgi-bin/configManager.cgi?action=setConfig&Encode[0].SnapFormat[0].Video.resolution=2560x1920

<ip_addr>/cgi-bin/configManager.cgi?action=setConfig&Encode[0].SnapFormat[0].Video.Width=2560

<ip_addr>/cgi-bin/configManager.cgi?action=setConfig&Encode[0].SnapFormat[0].Video.Height=1920

EDIT: The latter 2 commands aren’t strictly necessary to change the snapshot resolution, but are advisable for configuration consistency.

working thank you

I was able to get snapshot in companion app and in telegram.
It took me so much time but after tried it with " " and with local and not www it worked .
also thanks to GaryOkie i was able to fix the resolution.
Still i cant make it work in hass.agent .
also didn’t try yet on android tv notification

also you mentioned the option to:
“-you may delete or write some default image to location after image is sensitive”
can you explain how to do that ?

Get a photo or image from any website or your own and save it in the same folder.

After message is sent add some short delay(like 5 seconds) then write the image over the sensitive one

This does 2 things

  • delay to allow device to retrieve image before it is gone
  • default image always verifies device was able to access location. Sometimes images don’t download to device and i get 404 or some error message. If photo did bot exist it would be hard to tell if access issue or file missing issue. Default photo always lets you know if HA worked or another issue caused problem

“After message is sent add some short delay(like 5 seconds) then write the image over the sensitive one”

How do i do that ?

Also still cant get this to work on Hass.agent of android tv notification.
Any Idea ?

post one of the current working and i will try to add

I presume you used this integration?

“post one of the current working and i will try to add”

alias: Amcrest front door button pressed
description: ""
trigger:
  - platform: event
    event_type: amcrest
    event_data:
      event: CallNoAnswered
      payload:
        action: Start
condition: []
action:
  - service: camera.snapshot
    data:
      filename: /config/www/camsnapshot/cameradoor.png
    target:
      entity_id: camera.amcrest_doorbell_front_door
  - service: notify.mobile_app_galaxy_note_10
    data:
      message: Someone in the front door
      data:
        image: /local/camsnapshot/cameradoor.png
        actions:
  - service: notify.sagi_pc
    data:
      message: Someone in the front door
      data:
        image: /config/www/camsnapshot/cameradoor.png
mode: single

" I presume you used this integration?"

Yes this one

let me know if anything else is needed

AUTOMATION

alias: Amcrest front door button pressed
description: ""
trigger:
  - platform: event
    event_type: amcrest
    event_data:
      event: CallNoAnswered
      payload:
        action: Start
condition: []
action:
  - service: camera.snapshot
    data:
      filename: /config/www/camsnapshot/cameradoor.png
    target:
      entity_id: camera.amcrest_doorbell_front_door
  - service: notify.mobile_app_galaxy_note_10
    data:
      message: Someone in the front door
      data:
        image: /local/camsnapshot/cameradoor.png
        actions: null
  - service: notify.sagi_pc
    data: null
  - delay:
      hours: 0
      minutes: 0
      seconds: 5
      milliseconds: 0
  - service: shell_command.overwriteconfig_www_camsnapshot_cameradoor

Put a file, it can be anything really but a photo would be nice, in the same folder as one you want to overwrite and name it cameradoor.tmp

You need to make the shell command below and add it to “shell_command” section of your configuration.yaml

shell_command:
  overwriteconfig_www_camsnapshot_cameradoor: cp  /local/camsnapshot/cameradoor.tmp /local/camsnapshot/cameradoor.png

the shell command should work, I just forget if /local will be the correct file path or not. you may need to check that. You can just call the service in Dev Tools to test it.

1 Like

working with /config/www in the beginning instead of local
Thx a lot.

You have any idea how to make the image notification in HASS.agent on PC or with android TV notification ?

Are you able to send and display a text message to the android TV without a picture?

Looking at the integration, it is pretty simple setup, so if it is not working i’m thinking you missed some small step in the set up.

Yes , text is working in android tv and also in pc.
It is just not showing the image