# Generated by ariadne-codegen
# Source: ./documents

from typing import Any, List, Optional

from pydantic import Field

from .base_model import BaseModel
from .enums import ContentFacetTypes, FacetValueTypes, ObservableTypes


class QueryContentsFacets(BaseModel):
    contents: Optional["QueryContentsFacetsContents"]


class QueryContentsFacetsContents(BaseModel):
    facets: Optional[List[Optional["QueryContentsFacetsContentsFacets"]]]


class QueryContentsFacetsContentsFacets(BaseModel):
    facet: Optional[ContentFacetTypes]
    count: Optional[Any]
    type: Optional[FacetValueTypes]
    value: Optional[str]
    range: Optional["QueryContentsFacetsContentsFacetsRange"]
    observable: Optional["QueryContentsFacetsContentsFacetsObservable"]


class QueryContentsFacetsContentsFacetsRange(BaseModel):
    from_: Optional[str] = Field(alias="from")
    to: Optional[str]


class QueryContentsFacetsContentsFacetsObservable(BaseModel):
    type: Optional[ObservableTypes]
    observable: Optional["QueryContentsFacetsContentsFacetsObservableObservable"]


class QueryContentsFacetsContentsFacetsObservableObservable(BaseModel):
    id: str
    name: Optional[str]


QueryContentsFacets.model_rebuild()
QueryContentsFacetsContents.model_rebuild()
QueryContentsFacetsContentsFacets.model_rebuild()
QueryContentsFacetsContentsFacetsObservable.model_rebuild()
