# 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 RegisterResponse(UniversalBaseModel):
    """
    Response schema for user registration endpoint.
    """

    success: bool = pydantic.Field()
    """
    Whether registration was successful
    """

    user_id: str = pydantic.Field()
    """
    User ID (UUID)
    """

    email: str
    email_key: str = pydantic.Field()
    """
    Email verification key (UUID)
    """

    verification_required: bool = pydantic.Field()
    """
    Whether email verification is required
    """

    type: str = pydantic.Field()
    """
    Verification type: 'registration'
    """

    message: str = pydantic.Field()
    """
    Human-readable status message
    """

    recommended_username: typing.Optional[str] = pydantic.Field(default=None)
    """
    Recommended username if not provided during registration
    """

    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
