# 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 DeviceInformation(UniversalBaseModel):
    """
    Device information for authentication tracking.
    """

    device: typing.Optional[str] = pydantic.Field(default=None)
    """
    Device name
    """

    location: typing.Optional[str] = pydantic.Field(default=None)
    """
    Geographic location
    """

    latitude: typing.Optional[str] = pydantic.Field(default=None)
    """
    Latitude coordinate
    """

    longitude: typing.Optional[str] = pydantic.Field(default=None)
    """
    Longitude coordinate
    """

    device_id: typing.Optional[str] = pydantic.Field(default=None)
    """
    Unique device identifier
    """

    operating_system: typing.Optional[str] = pydantic.Field(default=None)
    """
    Operating system name
    """

    platform: typing.Optional[str] = pydantic.Field(default=None)
    """
    Platform type
    """

    user_agent: typing.Optional[str] = pydantic.Field(default=None)
    """
    User agent string
    """

    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
