satupeta-main/app/schemas/mapset_history_schema.py
2026-01-27 09:11:58 +07:00

25 lines
572 B
Python

from datetime import datetime
from typing import Optional
from pydantic import Field
from app.core.data_types import UUID7Field
from app.schemas.user_schema import UserSchema
from .base import BaseSchema
class MapsetHistorySchema(BaseSchema):
id: UUID7Field
mapset_id: UUID7Field
validation_type: str
notes: Optional[str]
timestamp: datetime
user_info: UserSchema = Field(alias="user")
class MapsetHistoryCreateSchema(BaseSchema):
mapset_id: UUID7Field
validation_type: str = Field(..., min_length=1)
notes: Optional[str] = None