- FastAPI REST API with JWT auth - aiogram 3 Telegram bot with admin middleware - APScheduler daily tasks (expiry, reminders, revoke, sync) - SQLAlchemy 2 async ORM with Alembic migrations - Jinja2 admin panel (Dashboard, Users, Payments, Servers, Tariffs) - VPN provider abstraction with MockProvider - Stats service with revenue/subscription analytics - Docker Compose (PostgreSQL + Redis + app) - Healthcheck endpoint
18 lines
432 B
Python
18 lines
432 B
Python
from aiogram import Router
|
|
from aiogram.filters import Command
|
|
from aiogram.types import Message
|
|
|
|
from app.bot.texts import START, HELP
|
|
|
|
router = Router(name="start")
|
|
|
|
|
|
@router.message(Command("start"))
|
|
async def cmd_start(message: Message) -> None:
|
|
await message.answer(START, parse_mode="HTML")
|
|
|
|
|
|
@router.message(Command("help"))
|
|
async def cmd_help(message: Message) -> None:
|
|
await message.answer(HELP, parse_mode="HTML")
|