Yes it works off the network. Attention that is configured only for an ip webcam application … for other ip cameras, the url address may change.
Yup, it changes.
Actually I was trying to find a generic solution by using the HA component camera with something like this:
send_webcam_screenshots_by_telegram:
alias: "Send Webcam screenshots by Telegram"
sequence:
- service: notify.telegramChat
data:
message: "Livingroom"
title: "Home Assistant"
data_template:
photo:
url: http://192.168.1.5:8124{{ states.camera.living_room.attributes.entity_picture }}
caption: "Livingroom"
but I’m getting the following error:
`17-03-16 19:38:27 ERROR (MainThread) [homeassistant.core] Invalid service data for notify.telegramchat: extra keys not allowed @ data['data_template']. Got OrderedDict([('photo', OrderedDict([('url', 'http://192.168.1.5:8124{{ states.camera.living_room.attributes.entity_picture }}'), ('caption', 'Livingroom')]))])`
Any ideas??
can i use this with any IP camera?
What is “this”?
You can use the photo
with other IP cameras if you have a URL for a photo, but the new android_ip_webcam
component is just for the… Android IP Webcam app.
what is your cam? foscam?other?
try put this url on your browser…
http://192.168.1.5:8124/snapshot.cgi?user=IF_YOU_HAVE&pwd=IF_YOU_HAVE&resolution=32
If you dont have a username and password
put only http://192.168.1.5:8124/snapshot.cgi
LOL yes, “This” is component for android IP
This is very good if can i use this for my IP camera with telegramChat
Any one try?
I’m having trouble with this automation:
Traceback (most recent call last):
File "/srv/homeassistant/homeassistant_venv/lib/python3.4/site-packages/homeassistant/components/notify/telegram.py", line 157, in send_photo
photo=photo, caption=caption)
File "/home/homeassistant/.homeassistant/deps/telegram/bot.py", line 125, in decorator
result = func(self, *args, **kwargs)
File "/home/homeassistant/.homeassistant/deps/telegram/bot.py", line 151, in decorator
result = self._request.post(url, data, timeout=kwargs.get('timeout'))
File "/home/homeassistant/.homeassistant/deps/telegram/utils/request.py", line 207, in post
**urlopen_kwargs)
File "/home/homeassistant/.homeassistant/deps/telegram/utils/request.py", line 152, in _request_wrapper
raise BadRequest(repr(message))
telegram.error.BadRequest: "Bad Request: wrong persistent file_id specified: can't unserialize it. Wrong last symbol"
Automation:
- alias: 'Send IP Cam photo'
trigger:
platform: time
hours: '/1'
minutes: '0'
seconds: '0'
condition:
condition: state
entity_id: group.all_devices
state: 'not_home'
action:
service: notify.galaxy_s6_edge
data:
title: 'Home Assistant'
message: 'Photo'
data:
photo:
url: 'http://xx.xx.xx.xx:8080/photo.jpg'
caption: 'Live from de Residentie'
Yes it shows
your notify.galaxy_s6_edge
is configured like this:
- name: galaxy_s6_edge
platform: telegram
api_key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
chat_id: xxxxxxxxx
???
ok… remove that line ‘http://xx.xx.xx.xx:8080/photo.jpg’
and put this line http://xx.xx.xx.xx:8080/photo.jpg without ’ ’ i think the problem is that.
I tried that, also tried without the caption. Same error, it’s driving me nuts.
its very strange,
and did you use this configuration?
- platform: mjpeg
mjpeg_url: http://xx.xx.xx.xx:8080/video
name: name_your_cam
right?
whats version HA did you have?
ok try i waiting, i am running 0.40.0 and Works fine
yes, sensor camera
nooooo, sorry create
cameras.yaml and put inside
and configuration.yaml create a new line
camera: !include cameras.yaml
I added it to my existing camera portion in my configuration.yaml.
It gives an “error loading image” on my frontend. The IP webcam is showing (from the “android_ip_webcam” component). I guess it has something to do with having to enter my username and password for the direct link to work.
@Rodolfo_Vieira working!
- alias: 'Send IP Cam photo'
trigger:
platform: time
hours: '/1'
minutes: '0'
seconds: '0'
condition:
condition: state
entity_id: group.all_devices
state: 'not_home'
action:
service: notify.galaxy_s6_edge
data:
title: 'Home Assistant'
message: 'Photo'
data:
photo:
url: http://10.0.0.160:8080/photo.jpg
username: ##USERNAME##
password: ##PASSWORD##
caption: Live from de Residentie
Thanks a lot for your help!
i am very glad, for help you. enjoy