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

import typing

import pydantic
import typing_extensions
from ...core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
from ...core.serialization import FieldMetadata
from ...types.boarding_application_attachments import BoardingApplicationAttachments
from ...types.created_at import CreatedAt
from ...types.email import Email


class ChargeBackResponse(UniversalBaseModel):
    attachments: typing.Optional[BoardingApplicationAttachments] = pydantic.Field(default=None)
    """
    Object with attached files to response
    """

    contact_email: typing_extensions.Annotated[typing.Optional[Email], FieldMetadata(alias="contactEmail")] = (
        pydantic.Field(default=None)
    )
    """
    Email of response submitter.
    """

    contact_name: typing_extensions.Annotated[typing.Optional[str], FieldMetadata(alias="contactName")] = (
        pydantic.Field(default=None)
    )
    """
    Name of response submitter
    """

    created_at: typing_extensions.Annotated[typing.Optional[CreatedAt], FieldMetadata(alias="createdAt")] = (
        pydantic.Field(default=None)
    )
    """
    Timestamp when response was submitted, in UTC.
    """

    id: typing.Optional[int] = pydantic.Field(default=None)
    """
    Chargeback response identifier
    """

    notes: typing.Optional[str] = pydantic.Field(default=None)
    """
    Response notes
    """

    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
