# This file was auto-generated by Fern from our API Definition.

from ..core.pydantic_utilities import UniversalBaseModel
import typing
from .time_frame_count import TimeFrameCount
import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2


class AggregationItem(UniversalBaseModel):
    """
    A single item in the aggregations array containing a collection of time-based article counts.
    """

    aggregation_count: typing.List[TimeFrameCount] = pydantic.Field()
    """
    Array of time frames and their corresponding article counts
    """

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True)  # type: ignore # Pydantic v2
    else:

        class Config:
            frozen = True
            smart_union = True
            extra = pydantic.Extra.allow
