initial commit
This commit is contained in:
0
app/handlers/__init__.py
Normal file
0
app/handlers/__init__.py
Normal file
10
app/handlers/events.py
Normal file
10
app/handlers/events.py
Normal file
@ -0,0 +1,10 @@
|
||||
from app.settings import bot, secrets
|
||||
from app import views
|
||||
|
||||
|
||||
async def start_bot():
|
||||
await bot.send_message(secrets.admin_id, views.start_bot_message())
|
||||
|
||||
|
||||
async def stop_bot():
|
||||
await bot.send_message(secrets.admin_id, views.stop_bot_message())
|
9
app/handlers/message.py
Normal file
9
app/handlers/message.py
Normal file
@ -0,0 +1,9 @@
|
||||
from aiogram.types import Message, MessageEntity, PhotoSize, ReactionTypeEmoji
|
||||
|
||||
from app.utils.send_to_notion import send_to_notion
|
||||
|
||||
|
||||
async def parse_message(message: Message):
|
||||
await send_to_notion(message)
|
||||
|
||||
await message.react([ReactionTypeEmoji(emoji="👌")])
|
6
app/handlers/simple.py
Normal file
6
app/handlers/simple.py
Normal file
@ -0,0 +1,6 @@
|
||||
from aiogram.types import Message
|
||||
from app import views
|
||||
|
||||
|
||||
async def start_command(message: Message):
|
||||
await message.answer(views.start_text())
|
Reference in New Issue
Block a user