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

import typing

import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from .monday_subitem import MondaySubitem
from .monday_update import MondayUpdate


class MondayItem(UniversalBaseModel):
    """
    Monday.com Item (Task/Row) object - DELETE SUPPORTED
    """

    name: str = pydantic.Field()
    """
    Item name
    """

    column_values: typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]] = pydantic.Field(default=None)
    """
    Column values as JSON object
    """

    updates: typing.Optional[typing.List[MondayUpdate]] = pydantic.Field(default=None)
    """
    Updates/comments on this item
    """

    subitems: typing.Optional[typing.List[MondaySubitem]] = pydantic.Field(default=None)
    """
    Subitems (nested items)
    """

    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
