-
-
Notifications
You must be signed in to change notification settings - Fork 137
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
Create Telegram bot #355
Create Telegram bot #355
Conversation
Telegram extractor
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wth
@@ -0,0 +1,29 @@ | |||
import logging | |||
from telegram.ext import Updater, CommandHandler, MessageHandler |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
which library is that ? not added to the requirements
import logging | ||
from telegram.ext import Updater, CommandHandler, MessageHandler | ||
|
||
TOKEN = 7901866660:AAFJ2Te56IAreu3nxnXKgRrQXNEKMF3CoSg # |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you should NEVER give publicly any credentials, this violates point 4.5 of the Telegram Bot Platform Developer Terms of Service (https://telegram.org/tos/bot-developers#4-5-credentials)
|
||
logging.basicConfig(level=logging.INFO) | ||
|
||
def save_restricted_content(update, context): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's the purpose of this ?
|
||
def restrict_access(update, context): | ||
# Restrict access to saved content | ||
context.bot.send_message(chat_id=(link unavailable), text='Access restricted.') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah yeah, the famous variable link unavailable
this has to be the wankiest PR I've ever seen :
this PR won't be accepted |
Telegram extractor