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 Dispatcher,Bot
|
|
|
|
from environs import Env
|
|
|
|
|
|
|
|
env = Env()
|
|
|
|
env.read_env()
|
|
|
|
|
2022-11-06 03:48:10 -05:00
|
|
|
USE_WEBHOOK = True
|
2022-08-07 04:45:35 -04:00
|
|
|
|
|
|
|
# bot token
|
|
|
|
token = env.str("bot_token")
|
|
|
|
|
2022-11-06 03:48:10 -05:00
|
|
|
group_id = env.int("group_id")
|
|
|
|
second_group_id = env.int("second_group_id")
|
|
|
|
|
|
|
|
limit_of_warns = 5
|
2022-08-07 04:45:35 -04:00
|
|
|
|
|
|
|
# Telegram Application
|
2022-08-13 08:25:52 -04:00
|
|
|
api_id = env.int("api_id")
|
2022-08-07 04:45:35 -04:00
|
|
|
api_hash = env.str("api_hash")
|
|
|
|
|
2022-08-16 06:28:08 -04:00
|
|
|
group_permissions = {
|
|
|
|
"can_send_messages":True,
|
|
|
|
"can_send_media_messages":False,
|
|
|
|
"can_send_other_messages":True,
|
|
|
|
"can_send_polls":False,
|
|
|
|
"can_invite_users":False,
|
|
|
|
"can_change_info":False,
|
|
|
|
"can_add_web_page_previews":False,
|
|
|
|
"can_pin_messages":False
|
|
|
|
}
|
2022-08-07 04:45:35 -04:00
|
|
|
|
|
|
|
db_url = env.str("db_url")
|
|
|
|
|
|
|
|
telegram_api_server = env.str("telegram_api_server").split(":")
|
2022-11-06 03:48:10 -05:00
|
|
|
telegram_api_server = f"http://{telegram_api_server[0]}:{telegram_api_server[1]}"
|