This repository has been archived on 2024-07-28. You can view files and clone it, but cannot push or open issues or pull requests.
2022-08-07 04:45:35 -04:00
|
|
|
from aiogram import Bot, Dispatcher
|
|
|
|
from aiogram import types
|
|
|
|
from aiogram.bot.api import TelegramAPIServer
|
|
|
|
from aiogram.contrib.fsm_storage.memory import MemoryStorage
|
|
|
|
|
|
|
|
import config
|
|
|
|
import utils
|
2022-08-16 06:28:08 -04:00
|
|
|
|
2022-08-07 04:45:35 -04:00
|
|
|
storage = MemoryStorage()
|
|
|
|
|
2022-08-13 08:25:52 -04:00
|
|
|
# Create client connection
|
|
|
|
tgc = utils.TelegramClient(config.api_id, config.api_hash, config.token)
|
2022-08-07 04:45:35 -04:00
|
|
|
|
|
|
|
bot = Bot(
|
|
|
|
token=config.token,
|
2022-08-13 08:25:52 -04:00
|
|
|
server=TelegramAPIServer.from_base(config.telegram_api_server),
|
2022-08-07 04:45:35 -04:00
|
|
|
)
|
|
|
|
|
2022-08-13 08:25:52 -04:00
|
|
|
dp = Dispatcher(bot, storage=storage)
|