25 lines
564 B
Python
25 lines
564 B
Python
"""Collection/franchise response schemas."""
|
|||
|
|
|
||
|
|
from __future__ import annotations
|
||
|
|
|
||
|
|
from datetime import datetime
|
||
|
|
|
||
|
|
from pydantic import BaseModel
|
||
|
|
|
||
|
|
from app.schemas.movie import MovieSummaryOut
|
||
|
|
from app.schemas.tv import SeriesSummaryOut
|
||
|
|
|
||
|
|
|
||
|
|
class CollectionDetailOut(BaseModel):
|
||
|
|
id: str
|
||
|
|
type: str = "collection"
|
||
|
|
name: str
|
||
|
|
overview: str | None = None
|
||
|
|
poster_path: str | None = None
|
||
|
|
backdrop_path: str | None = None
|
||
|
|
movies: list[MovieSummaryOut] = []
|
||
|
|
series: list[SeriesSummaryOut] = []
|
||
|
|
|
||
|
|
created_at: datetime
|
||
|
|
updated_at: datetime
|