Y Yoldi Member Jan 5, 2020 #1 Regards. When sending with a telegram bot (with the jTelegrambot version 0.24 library) an image with this instruction: jtb.sendPhoto (jtb.byId (from.Id), jtb.MediaByFile (File.DirApp, "Cafeteria.jpg"), "Caption Document", False, Null, replbld.hideCustomKeyboard) send it and give this error java.lang.RuntimeException: com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "file_unique_id" (class io.fouad.jtb.core.beans.PhotoSize), not marked as ignorable (5 known properties: "file_path" , "file_size", "file_id", "height", "width"]) The same happens if I send a document. How can it be corrected? Thank you B4X: Copy B4X: Copy
Regards. When sending with a telegram bot (with the jTelegrambot version 0.24 library) an image with this instruction: jtb.sendPhoto (jtb.byId (from.Id), jtb.MediaByFile (File.DirApp, "Cafeteria.jpg"), "Caption Document", False, Null, replbld.hideCustomKeyboard) send it and give this error java.lang.RuntimeException: com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "file_unique_id" (class io.fouad.jtb.core.beans.PhotoSize), not marked as ignorable (5 known properties: "file_path" , "file_size", "file_id", "height", "width"]) The same happens if I send a document. How can it be corrected? Thank you B4X: Copy B4X: Copy
DonManfred Expert Licensed User Longtime User Jan 5, 2020 #2 Please use [CODE]code here...[/CODE] tags when posting code. There is also NO need to change the font to bold. Use Quote tag when posting logs. Last edited: Jan 5, 2020 Upvote 0
Please use [CODE]code here...[/CODE] tags when posting code. There is also NO need to change the font to bold. Use Quote tag when posting logs.
behnam_tr Active Member Licensed User Longtime User Jan 6, 2020 #4 use this code i use this code and is ok for sending a photo to user in telegrambot (jtelegrambot v0.24) B4X: Copy jtb2.sendPhoto(jtb2.byId(uid),jtb2.MediaByFile(File.DirApp&"/user_reports",filename),"your caption",True,Null,mark) Upvote 0
use this code i use this code and is ok for sending a photo to user in telegrambot (jtelegrambot v0.24) B4X: Copy jtb2.sendPhoto(jtb2.byId(uid),jtb2.MediaByFile(File.DirApp&"/user_reports",filename),"your caption",True,Null,mark)
DonManfred Expert Licensed User Longtime User Jan 7, 2020 #5 try again with V0.25 (See Librarythread) Upvote 0