# Generated by ariadne-codegen
# Source: ./documents

from typing import Any, List, Optional

from pydantic import Field

from .base_model import BaseModel
from .enums import (
    AuthenticationServiceTypes,
    ConnectorTypes,
    EntityState,
    IntegrationServiceTypes,
    UserTypes,
)


class GetUser(BaseModel):
    user: Optional["GetUserUser"]


class GetUserUser(BaseModel):
    id: str
    name: str
    creation_date: Any = Field(alias="creationDate")
    relevance: Optional[float]
    owner: "GetUserUserOwner"
    state: EntityState
    type: Optional[UserTypes]
    identifier: str
    connectors: Optional[List[Optional["GetUserUserConnectors"]]]


class GetUserUserOwner(BaseModel):
    id: str


class GetUserUserConnectors(BaseModel):
    id: str
    name: str
    state: EntityState
    type: Optional[ConnectorTypes]
    authentication: Optional["GetUserUserConnectorsAuthentication"]
    integration: Optional["GetUserUserConnectorsIntegration"]


class GetUserUserConnectorsAuthentication(BaseModel):
    type: AuthenticationServiceTypes
    microsoft: Optional["GetUserUserConnectorsAuthenticationMicrosoft"]
    google: Optional["GetUserUserConnectorsAuthenticationGoogle"]


class GetUserUserConnectorsAuthenticationMicrosoft(BaseModel):
    tenant_id: str = Field(alias="tenantId")
    client_id: str = Field(alias="clientId")
    client_secret: str = Field(alias="clientSecret")


class GetUserUserConnectorsAuthenticationGoogle(BaseModel):
    client_id: str = Field(alias="clientId")
    client_secret: str = Field(alias="clientSecret")


class GetUserUserConnectorsIntegration(BaseModel):
    type: IntegrationServiceTypes
    uri: Optional[str]
    slack: Optional["GetUserUserConnectorsIntegrationSlack"]


class GetUserUserConnectorsIntegrationSlack(BaseModel):
    token: str
    channel: str


GetUser.model_rebuild()
GetUserUser.model_rebuild()
GetUserUserConnectors.model_rebuild()
GetUserUserConnectorsAuthentication.model_rebuild()
GetUserUserConnectorsIntegration.model_rebuild()
