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

from ..core.pydantic_utilities import UniversalBaseModel
import pydantic
import datetime as dt
import typing
from .canned_response_field import CannedResponseField
from ..core.pydantic_utilities import IS_PYDANTIC_V2


class CannedResponse(UniversalBaseModel):
    id: str = pydantic.Field()
    """
    Unique identifier for the tag
    """

    creation_utc: dt.datetime = pydantic.Field()
    """
    UTC timestamp of when the canned response was created
    """

    value: str = pydantic.Field()
    """
    The textual content of the canned response.
    """

    fields: typing.List[CannedResponseField] = pydantic.Field()
    """
    A sequence of canned response fields associated with the canned response.
    """

    tags: typing.List[str] = pydantic.Field()
    """
    Collection of tag IDs associated with the canned response.
    """

    signals: typing.List[str] = pydantic.Field()
    """
    A sequence of signals associated with the canned response, to help with filtering and matching.
    """

    metadata: typing.Dict[str, typing.Optional[typing.Any]] = pydantic.Field()
    """
    Additional metadata associated with the canned response.
    """

    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
