-
-
Notifications
You must be signed in to change notification settings - Fork 963
How to send a message to channel without user interaction? #71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hello did you seen the command send to channel in the admin dir? This provide what you're looking for, to use this command you should enabled the admin interface of the bot (not the channel) as explained in the readme. Let me know if the documentation is enough clear ask if you have further questions |
Thank you Marco. The example is clear, but I would like to send a message to a channel without interacting with the bot in the Telegram app (ie: without sending a |
Thats all you need to use the class without the bot interface, notice that you should set a cron to read the RSS. |
Perfect! Thank you. |
here's my code for broadcast message to particular chat: https://gist.github.com/ariefbayu/e3ffe27f9c50cb674edd |
Thanks for sharing your CLI-friendly version 😃 A few notes about your code if I may:
|
Awesome, thank you for the suggestion! |
@ariefbayu great! This can help other users! Feel free to open a wiki page with your example that point to your code! |
@MBoretto I wrote it here: https://github.com/akalongman/php-telegram-bot/wiki/How-to-send-message-to-channel-user-without-user-interaction Feel free to enhance it. |
Thanks @ariefbayu! I've forked your gist and made the code PSR2 friendly, then updated the wiki page. Also, it would make sense to add at least a bit of error handling, like some output if no chat id or message is passed. Just a simple And I was playing with the idea of setting the |
@noplanman @frenzis @MBoretto @ariefbayu @boukeversteegh Hi. Is there a script that I can add more members to my grammar channel. |
@ebrahimporiyan No, that is not supported |
Hi, and thank you for your work. I'm trying to send a message to a channel without user interaction. My Bot is admin of the channel. Did you have a simple working example using the
sendMessage
method?The text was updated successfully, but these errors were encountered: