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

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


class OrganizationOptions(UncheckedBaseModel):
    invite_duration: typing.Optional[str] = pydantic.Field(default=None)
    """
    Duration new member invitations will be valid. Default: 168h (7 days), minimum 24h, maximum 168h (7 days).
    """

    forgot_duration: typing.Optional[str] = pydantic.Field(default=None)
    """
    Duration forgotten password invitations will be valid. Default: 24h, minimum 24h, maximum 168h (7 days).
    """

    password_duration: typing.Optional[str] = pydantic.Field(default=None)
    """
    Duration before member password expires, part of required password rotation. Default: 4320h (180 days), minimum: 24h, maximum: 8760h (365 days).
    """

    minimum_password_length: typing.Optional[int] = pydantic.Field(default=None)
    """
    Minimum password length. Default: 8, minimum 8, maximum 72.
    """

    if IS_PYDANTIC_V2:
        model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(
            extra="allow"
        )  # type: ignore # Pydantic v2
    else:

        class Config:
            smart_union = True
            extra = pydantic.Extra.allow
