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

import typing

import pydantic
from ...core.pydantic_utilities import IS_PYDANTIC_V2
from ...core.unchecked_base_model import UncheckedBaseModel


class CallTelephonyRequestSip(UncheckedBaseModel):
    """
    SIP (Session Initiation Protocol) call configuration object.
    """

    to_number: str = pydantic.Field()
    """
    Called number (target phone number), in E.164 format.
    """

    from_number: str = pydantic.Field()
    """
    Caller ID (the number that initiated the call), in E.164 format.
    """

    rtc_uid: str = pydantic.Field()
    """
    The RTC UID used by the SIP gateway.
    """

    rtc_token: str = pydantic.Field()
    """
    The RTC token used by the SIP gateway.
    """

    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
