I just want a simple screenshot of my IP camera to Telegram.
I got a simple message working. The LUA I have(more like stole from someone with actual knowledge about this on the internet):
It works every time I test it.
Code: Select all
commandArray = {}
token = "53148xxxxx:AAGXWKsYHZYmepiSTvPWYE2EOn2CAxxxxxx"
chatid = '-10017864xxxxx'
message = 'Dit is een bericht vanuit Domoticz!'
if (devicechanged['camtest'] == 'On') then
os.execute('curl --data chat_id='..chatid..' --data-urlencode "text='..message..'" "https://api.telegram.org/bot'..token..'/sendMessage" ')
chat_id=-10017864xxxxxx -F photo="@https://192.168.2.x:xxxx/shot.jpg" ')
end
return commandArray
Code: Select all
curl -s -X POST "https://api.telegram.org/bot<TOKEN>/sendPhoto" -F chat_id=<CHATID> -F photo="@</path/to/your/photo.jpg>"
Then I found an Italian video (I'm not Italian btw). It led me to this site: This site.
But that simply doesn't work for me.
I've tested it succesfull with the email notification and attacement.
So the camera does work, and the script does do something, but it just doesn't go to Telegram...
I Also tried it with the prefix - user:[email protected]:xxxx/shot.jpg, but no photo.
I'm lost. Can someone help me..please!

