# 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 .assets_inputs_asset_response_response_body import AssetsInputsAssetResponseResponseBody
from .assets_inputs_aux_input_response_body import AssetsInputsAuxInputResponseBody
from .assets_inputs_response_response_body_units import AssetsInputsResponseResponseBodyUnits


class AssetsInputsResponseResponseBody(UniversalBaseModel):
    """
    Full assets inputs objects.
    """

    asset: AssetsInputsAssetResponseResponseBody
    aux_input: typing_extensions.Annotated[
        typing.Optional[AssetsInputsAuxInputResponseBody],
        FieldMetadata(alias="auxInput"),
        pydantic.Field(alias="auxInput"),
    ] = None
    happened_at_time: typing_extensions.Annotated[
        str,
        FieldMetadata(alias="happenedAtTime"),
        pydantic.Field(alias="happenedAtTime", description="UTC timestamp in RFC 3339 format of the event."),
    ]
    units: AssetsInputsResponseResponseBodyUnits = pydantic.Field()
    """
    Units of the values in the returned data.  Valid values: `boolean`, `millivolts`, `microamps`
    """

    value: str = pydantic.Field()
    """
    Value of the data point.
    """

    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
