Hey,
I trie to send an Image to Telegram with OH3 on a raspberry 3b.
I get the image with the ftp upload binding and the image is stored as an image item.
The documentation of the telegram binding says that only url and base64 images can be send.
In dsl rules you have to convert the image item to base64string by using
Webcam_Image.state.toFullString
so far so good. when i use dsl rules, my system slows down after one day and becomes ununsable. so i have to use javascript instead. i tried the following
telegramAction.sendTelegramPhoto(itemRegistry.getItem('HtCamImage').getState(), "sent from openHAB")
telegramAction.sendTelegramPhoto(itemRegistry.getItem('HtCamImage').toString(), "sent from openHAB")
telegramAction.sendTelegramPhoto(itemRegistry.getItem('HtCamImage').toFullString(), "sent from openHAB")
I found some bulky javascript functions but i bet there is an easy way to do this.