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

from ..core.pydantic_utilities import UniversalBaseModel
import pydantic
import typing
from .composition_mode_dto import CompositionModeDto
from ..core.pydantic_utilities import IS_PYDANTIC_V2


class Journey(UniversalBaseModel):
    """
    A journey represents a guided interaction path for specific user scenarios.

    Each journey is triggered by a condition and contains steps to guide the interaction.
    """

    id: str = pydantic.Field()
    """
    Unique identifier for the journey
    """

    title: str = pydantic.Field()
    """
    The title of the journey
    """

    description: str
    conditions: typing.List[str]
    tags: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
    """
    List of tag IDs associated with the journey
    """

    composition_mode: typing.Optional[CompositionModeDto] = 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
