feat: Lensa bot stub — MessengerService interface ready for SDK integration

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-04-03 22:46:26 +05:00
parent 922b1b26a6
commit bfe52bb9f8
2 changed files with 44 additions and 0 deletions
+44
View File
@@ -0,0 +1,44 @@
import logging
from fastapi import Request, Response
from app.messengers.base import MessengerService
logger = logging.getLogger(__name__)
class LensaService(MessengerService):
"""
Stub implementation for Lensa (IVA Technologies) messenger bot.
Lensa's Bot API/SDK is not publicly available.
This stub provides the MessengerService interface so the integration
can be implemented when SDK access is obtained from IVA Technologies.
To integrate:
1. Obtain SDK/API documentation from IVA Technologies (iva-tech.ru)
2. Implement the abstract methods below
3. Register webhook endpoint in main.py (similar to Telegram)
"""
async def setup(self):
logger.info("Lensa bot: stub — SDK not available, skipping setup")
async def shutdown(self):
logger.info("Lensa bot: stub — shutting down")
async def send_message(self, chat_id: str, text: str, **kwargs):
logger.warning(f"Lensa bot: send_message not implemented (chat_id={chat_id})")
async def send_file(self, chat_id: str, file_path: str, caption: str = ""):
logger.warning(f"Lensa bot: send_file not implemented (chat_id={chat_id})")
async def notify_progress(self, chat_id: str, status: str, progress: int | None = None):
logger.warning(f"Lensa bot: notify_progress not implemented (chat_id={chat_id})")
async def feed_webhook(self, request: Request) -> Response:
logger.warning("Lensa bot: webhook received but SDK not implemented")
return Response(status_code=200)
lensa_service = LensaService()