feat: Telegram bot — full functionality with inline keyboards, file upload, auth

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-03 22:46:20 +05:00
parent 397b999558
commit 922b1b26a6
8 changed files with 439 additions and 0 deletions
+7
View File
@@ -9,7 +9,9 @@ from app.api.protocols import router as protocols_router
from app.api.recordings import router as recordings_router
from app.api.settings import router as settings_router
from app.api.templates import router as templates_router
from app.config import settings
from app.database import async_session
from app.messengers.telegram.bot import api_router as telegram_router, telegram_service
from app.models.prompt_template import PromptTemplate
from app.prompts.defaults import DEFAULT_TEMPLATES
@@ -27,7 +29,11 @@ async def seed_default_templates():
@asynccontextmanager
async def lifespan(app: FastAPI):
await seed_default_templates()
if settings.telegram_bot_token:
await telegram_service.setup()
yield
if settings.telegram_bot_token:
await telegram_service.shutdown()
app = FastAPI(title="Meeting Protocol Service", lifespan=lifespan)
@@ -37,6 +43,7 @@ app.include_router(protocols_router)
app.include_router(templates_router)
app.include_router(exports_router)
app.include_router(settings_router)
app.include_router(telegram_router)
@app.get("/api/health")