PagerMaid-Modify/utils/mksession.py

10 lines
249 B
Python
Raw Permalink Normal View History

from telethon import TelegramClient
from yaml import load, FullLoader
config = load(open(r"config.yml"), Loader=FullLoader)
api_key = config['api_key']
api_hash = config['api_hash']
bot = TelegramClient('pagermaid', api_key, api_hash)
bot.start()