# 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 .rcs_agent_details import RcsAgentDetails


class TestAgentResponse(UniversalBaseModel):
    """
    Response returned after creating or updating a test agent.
    """

    id: str = pydantic.Field()
    """
    The unique agent ID. Use this ID when sending messages, whitelisting numbers,
    and performing other agent operations. Always prefixed with `agent_`.
    """

    type: typing.Literal["TEST"] = pydantic.Field(default="TEST")
    """
    The type of the agent. Test agents always have type `TEST`.
    """

    service_id: typing_extensions.Annotated[str, FieldMetadata(alias="serviceId")] = pydantic.Field()
    """
    The RCS service ID assigned to this agent by the carrier network. Used internally
    for routing messages. You can use this to construct RCS deep links manually.
    """

    details: RcsAgentDetails

    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
