17 lines
401 B
Python
17 lines
401 B
Python
from datetime import datetime
|
|
|
|
from pydantic import BaseModel, Field
|
|
|
|
|
|
class SubscriptionData(BaseModel):
|
|
devices: int = Field()
|
|
expires_at: datetime = Field()
|
|
addon_ids: list[str] = Field()
|
|
|
|
|
|
class UserInfo(BaseModel):
|
|
username: str | None = Field(None)
|
|
telegram_id: str | None = Field(None)
|
|
subscription: SubscriptionData | None = Field(None)
|
|
referal_code: str = Field()
|