# 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 .benefits_related_entity import BenefitsRelatedEntity
from .plan_coverage import PlanCoverage
from .service_coverage import ServiceCoverage


class CoverageBenefits(UniversalBaseModel):
    plan_coverage: typing.Optional[PlanCoverage] = None
    service_specific_coverage: typing.Optional[typing.List[ServiceCoverage]] = None
    benefits_related_entities: typing.Optional[typing.List[BenefitsRelatedEntity]] = None
    notes: typing.Optional[str] = None
    auto_updated_eligibility_check_id: typing.Optional[str] = pydantic.Field(
        alias="autoUpdatedEligibilityCheckId", default=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
