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

from ...core.pydantic_utilities import UniversalBaseModel
import pydantic
from .user_info import UserInfo
from ...core.pydantic_utilities import IS_PYDANTIC_V2
import typing


class MetadataResponse(UniversalBaseModel):
    """
    Examples
    --------
    from sayari.metadata import MetadataResponse, UserInfo

    MetadataResponse(
        version="v2.1.0-4841-g41af84af8",
        master_release="reiko_20240712182628",
        watchlist_release="watchlist_reiko_20240718024049",
        user=UserInfo(
            id="abcdefghijklmnopqrstuvwxyz@clients",
            group_display_names="",
            roles="",
        ),
    )
    """

    version: str = pydantic.Field()
    """
    Currently deployed version of the application.
    """

    master_release: str = pydantic.Field()
    """
    Currently deployed main data release.
    """

    watchlist_release: str = pydantic.Field()
    """
    Currently deployed watchlist release.
    """

    user: UserInfo

    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
