from telegram import Update from telegram.ext import Updater, CommandHandler, CallbackContext import logging
defstart(update: Update, context: CallbackContext) -> None: context.bot.send_message(chat_id=update.effective_chat.id, text="I'm a bot, created by Edlison.")
1 2 3 4 5 6 7 8 9 10
if __name__ == '__main__': REQUEST_KWARGS = {'proxy_url': 'socks5h://127.0.0.1:1080'} u = Updater('bot token here', use_context=True, request_kwargs=REQUEST_KWARGS)