"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""

from __future__ import annotations
from .acceptorganizationinviteresponse import (
    AcceptOrganizationInviteResponse,
    AcceptOrganizationInviteResponseTypedDict,
)
from factify.types import BaseModel
from factify.utils import FieldMetadata, PathParamMetadata, RequestMetadata
from typing import Dict, List
from typing_extensions import Annotated, TypedDict


class AcceptOrganizationInviteAcceptOrganizationInviteRequestTypedDict(TypedDict):
    r"""AcceptOrganizationInviteRequest contains the token to accept an invitation."""

    token: str
    r"""The invitation token from the email link."""


class AcceptOrganizationInviteAcceptOrganizationInviteRequest(BaseModel):
    r"""AcceptOrganizationInviteRequest contains the token to accept an invitation."""

    token: str
    r"""The invitation token from the email link."""


class AcceptOrganizationInviteRequestTypedDict(TypedDict):
    organization_id: str
    r"""Organization the invitation belongs to (for validation).
    Pattern: org_[0-9a-hjkmnp-tv-z]{26}
    """
    body: AcceptOrganizationInviteAcceptOrganizationInviteRequestTypedDict


class AcceptOrganizationInviteRequest(BaseModel):
    organization_id: Annotated[
        str, FieldMetadata(path=PathParamMetadata(style="simple", explode=False))
    ]
    r"""Organization the invitation belongs to (for validation).
    Pattern: org_[0-9a-hjkmnp-tv-z]{26}
    """

    body: Annotated[
        AcceptOrganizationInviteAcceptOrganizationInviteRequest,
        FieldMetadata(request=RequestMetadata(media_type="application/json")),
    ]


class AcceptOrganizationInviteResponseResponseTypedDict(TypedDict):
    headers: Dict[str, List[str]]
    result: AcceptOrganizationInviteResponseTypedDict


class AcceptOrganizationInviteResponseResponse(BaseModel):
    headers: Dict[str, List[str]]

    result: AcceptOrganizationInviteResponse
