13 lines
290 B
Python
13 lines
290 B
Python
from aiogram import Bot, Dispatcher
|
|
from aiogram.client.session.aiohttp import AiohttpSession
|
|
|
|
from app import config
|
|
|
|
session = (
|
|
AiohttpSession(proxy=(config.TG_PROXY,))
|
|
if config.TG_PROXY
|
|
else AiohttpSession()
|
|
)
|
|
bot = Bot(config.BOT_TOKEN, session=session)
|
|
dp = Dispatcher()
|