telegram

Handling “flags” types in telegram's TL schema language

梦想的初衷 提交于 2019-12-24 00:01:15
问题 I wrote a tl parser so can now use the latest layer (53). But I am unsure how to handle "flags" types. They are only mentioned in the tl docs but not defined (as far as I can tell) at the bottom of the page here: link. For example, when a method returns a 'message' type it should look like this: message#c09be45f flags:# out:flags.1?true mentioned:flags.4?true media_unread:flags.5?true silent:flags.13?true post:flags.14?true id:int from_id:flags.8?int to_id:Peer fwd_from:flags.2

How to use Telegram API (to include Chat Application) in my existing android app?

只谈情不闲聊 提交于 2019-12-23 20:36:50
问题 I want to use telegram APIs in order to develop chatting feature in My Existing Android App. I am not getting how to implement. 回答1: I think, it is a good idea to take a look at the Telegram Database Library (Beta) from here TDLib (Russian, but translate with Google) and the Java doc (English) from here. The information is a little poor yet, but I think you can understand it. 回答2: Use this API. Refer to the Getting Started section to integrate Telegram in your app. 来源: https://stackoverflow

Telegram-bot user control

不羁的心 提交于 2019-12-23 17:27:06
问题 I want to create a telegram bot for a home project and i wish the bot only talk to 3 people, how can I do this? I thought to create a file with the chat id of each of us and check it before responding to any command, I think it will work. the bot will send the correct info if it's one of us and "goodbye" to any other But is there any other way to block any other conversation with my bot? Pd: I'm using python-telegram-bot 回答1: For the first part of your question you can make a private group

How to handle multiple users on Telegram bot in C#?

被刻印的时光 ゝ 提交于 2019-12-23 12:46:53
问题 I wrote a bot which asks your name and writes it on a photo and sends it to you and it works. But the problem is when there is more than one user on the bot It doesn't work and crashes and I wanted to know how to separate users entries and outputs.(like each user who connects get a separated session because now everything happens in one session and it crashes) This is my code: void bot_OnMessage(object sender, Telegram.Bot.Args.MessageEventArgs e) { KeyboardButton[] btns = new KeyboardButton

Message not receiving automatically for Telegram CHATBOT funciton using PHP

纵饮孤独 提交于 2019-12-23 04:33:31
问题 In order to integrate Telegram Chatbot using PHP, I have already followed below steps. Server with SSL certificate Webhook with working condition URL : https://api.telegram.org/bot/setWebhook?url=https://mywebsite.com/path/to/filename.php Created ChatBot and have a valid Token After that, I have made simple PHP file using following line of code. <?php define('BOT_TOKEN', 'CHANGE-ME'); define('API_URL', 'https://api.telegram.org/bot'.BOT_TOKEN.'/'); // This is to read incoming message and

Telegram (Telesharp) - Massive requests (discuss about flood prevention limit)

自闭症网瘾萝莉.ら 提交于 2019-12-22 12:44:36
问题 (I'm using TLSharp for connect to Telegram Service) I want search 400,000 channels, so call service SearchUserAsync for 400,000 times. I call this service every 15 seconds, but I get flood prevention for 1 day (~70000 seconds). What's best way for Call telegram services for n times? 来源: https://stackoverflow.com/questions/45256430/telegram-telesharp-massive-requests-discuss-about-flood-prevention-limit

How can I differentiate between a 'Message' update and a 'Callback Query' update? (Telegram Bot API)

时间秒杀一切 提交于 2019-12-22 11:15:50
问题 Sorry if my question gets too messy, I'm new here, so, any advice is welcome. How can I differentiate between a 'Message' update and a 'Callback Query' update? I've managed to make an inline keyboard, but when I use it, the bot just hangs, he doesn't reply anything. I did a little bit of research and found this question, which helped me understand the problem, but not much else. My bot uses something like this right now: // read incoming info and grab the chatID $content = file_get_contents(

Telegram API vs Bot API [closed]

廉价感情. 提交于 2019-12-22 05:33:13
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 3 years ago . Can you help me understand the differences for Telegram API vs Bot API please, I tried telegram website but just get confused? Thanks Ramin 回答1: Telegram APIs This API allows you to build your own customized Telegram clients. It is 100% open for all developers who wish to create Telegram applications on our

send long message with photo on telegram with php bot

陌路散爱 提交于 2019-12-22 04:37:24
问题 I need send to telegram long text with photo but telegram image caption has 200 character limit. How can send long text with photo using php and bot? sendPhoto method has 200 character limit. I see a telegram bot it's send long text and photo see my sample photo. 回答1: You can use empty character! Just set parse_mode Field to HTML in sendMessage method , then in text Field insert the URL of the image into href The hyperlink will not be seen when you use empty character : <a href="https://www

Telegram, getting file_id for existing sticker

自闭症网瘾萝莉.ら 提交于 2019-12-22 01:45:56
问题 I'm writing a Telegram bot and I want it to send a sticker. It is said here, that to send a sticker that already exists on Telegram servers we can simply pass file_id . The thing is, I have absolutely no idea how to obtain file_id of any sticker. E.g. how do I send any sticker from Greater Minds pack? I suppose, this pack is on Telegram servers since they include it in every app. 回答1: To discover a sticker's file_id : Send the sticker from Telegram App to your bot. Use the bot's getUpdates