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

import typing

import pydantic
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel


class Case(UniversalBaseModel):
    """
    Customer support ticket
    """

    subject: str
    status: typing.Optional[str] = None
    priority: typing.Optional[str] = pydantic.Field(default=None)
    """
    High, Medium, or Low
    """

    origin: typing.Optional[str] = pydantic.Field(default=None)
    """
    e.g., Phone, Email, Web
    """

    type: typing.Optional[str] = pydantic.Field(default=None)
    """
    e.g., Problem, Question, Feature Request
    """

    reason: typing.Optional[str] = None
    account_id: typing.Optional[str] = None
    contact_id: typing.Optional[str] = None
    description: typing.Optional[str] = None
    customer_email: typing.Optional[str] = None
    customer_name: typing.Optional[str] = None
    customer_phone: typing.Optional[str] = None

    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
