from pydantic import BaseModel, Field


class CreateAssetLibraryRequest(BaseModel):
    project_id: str = Field(..., min_length=1)
    name: str = Field(..., min_length=1, max_length=100)
    kind: str = Field(..., pattern="^(video|voice|image)$")


class AssetLibraryResponse(BaseModel):
    id: str
    project_id: str
    name: str
    kind: str
    asset_count: int
    total_size: int


class ListAssetLibrariesResponse(BaseModel):
    items: list[AssetLibraryResponse]


class EnsureDefaultLibraryRequest(BaseModel):
    project_id: str = Field(..., min_length=1)
    kind: str = Field(..., pattern="^(video|voice|image)$")
