Send message from telegram via API - telegram-bot

I am able to send messages from python to Telegram, but I cant seem to find the reverse.
I need to get the message from telegram channel and send it to a certain server using Api. Server can consume that Api and that's not my question. I need to know if Telegram can generate that post request.

Your bot should be a member or administrator of that channel. And then your bot will receive an update containing channel_post.
Note: You can't join your bot to channels or groups unless you're the owner or administrator of the channel. (Bots themselves do not have the ability to join, you add them manually)

Related

Trigger smart speaker announcement via HTTP request

I have a smart speaker with buit-in Google Assistant which I want to automatically make announcements at specific times. The times are determined by a program I wrote running in the cloud which can send HTTP POST requests at those times (e.g. to trigger a Telegram bot or anything else with a usable API).
Is there a way to send POST requests directly to my smart speaker with a message to announce? Or would I need some intermediary app/service to integrate with Google Assistant?

Share telegram bot messages with another user

I have a telegram bot that I send messages to via Python. I would like another user to be able to see these messages as well. Can't seem to figure out how to do it, nor what to do?

How could the app send a message to the phone when certain mission fulfilled?

I can use FCM console to send messages to all users or certain users at a certain time.
Now I want the app send a message to specified users when their in-game energy is full. How to realize it with FCM? And can I know the messages' sends, opens, conversions?
Sending a message to a user can only be done from a trusted environment, such as the Firebase console, or a place where you can trust that the code running is yours (such as your development machine, a server that you control, or something like Cloud Functions/Cloud Run).
For examples of how to send a message by calling FCM's API, see the documentation on building send requests, and this sample use-case of notifying the user when something interesting happens using Cloud Functions.

Using webhooks to retrieve messages from google chat api

I'm trying to create a bot to send and receive messages through Google Chat and I wanted to know if there is any way I can retrieve messages using the webhooks? If not, is there anyway I can request the messages in the chat API without an public IP?
NOTE: if there isn't, I have read the https://developers.google.com/chat/how-tos/service-accounts and I wanted to understand: if I setup a Flask server, will google be able to send me the push notifications back, or do I need a public IP?
I have solved the problem.
There is no way, you must register on google as a developer.
Sorry for taking so long to post the solution

Telegram bot authentification

A web service that contains all the methods for processing data is stored by Azure. In this case, only my telegram can process this data. Other applications are not allowed. But there is a possibility of expanding the service.
How do I know that the service is used by my telegram bot?
How to authenticate the application.
Well, I tried to use OAuth2.0, but i think it is not correct, because user is already authentificated with telegram, when he use telegram bot. My idea was to send a link to google auththentification in the beginning of bot job. By th way, ok, we know user`s data. May be I can check: Id, login etc. But some hacker can substitute this id
How can I make sure that Webhook requests are coming from Telegram? If
you‘d like to make sure that the Webhook request comes from Telegram,
we recommend using a secret path in the URL you give us, e.g.
www.example.com/your_token. Since nobody else knows your bot’s token,
you can be pretty sure it's us.
Telegram Bot FAQ