Files
vpn-control-panel/app/schemas/user.py
smolkik-code 7c7c88621d Initial commit: VPN Control Panel
- 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
2026-07-05 17:50:11 +07:00

23 lines
480 B
Python

from datetime import datetime
from pydantic import BaseModel, ConfigDict
class UserRead(BaseModel):
model_config = ConfigDict(from_attributes=True)
id: int
telegram_id: int
username: str | None = None
full_name: str
language_code: str = "ru"
is_active: bool = True
created_at: datetime
updated_at: datetime
class UserUpdate(BaseModel):
username: str | None = None
full_name: str | None = None
language_code: str | None = None