# Generated by ariadne-codegen
# Source: openhexa/graphql/queries.graphql

from typing import Any, List, Optional

from pydantic import Field

from .base_model import BaseModel


class Dataset(BaseModel):
    dataset: Optional["DatasetDataset"]


class DatasetDataset(BaseModel):
    id: str
    slug: str
    name: str
    description: Optional[str]
    created_at: Any = Field(alias="createdAt")
    updated_at: Any = Field(alias="updatedAt")
    created_by: Optional["DatasetDatasetCreatedBy"] = Field(alias="createdBy")
    permissions: "DatasetDatasetPermissions"
    versions: "DatasetDatasetVersions"
    workspace: Optional["DatasetDatasetWorkspace"]


class DatasetDatasetCreatedBy(BaseModel):
    id: Any
    display_name: str = Field(alias="displayName")
    email: str


class DatasetDatasetPermissions(BaseModel):
    update: bool
    delete: bool
    create_version: bool = Field(alias="createVersion")


class DatasetDatasetVersions(BaseModel):
    items: List["DatasetDatasetVersionsItems"]


class DatasetDatasetVersionsItems(BaseModel):
    id: str
    name: str
    changelog: Optional[str]
    created_at: Any = Field(alias="createdAt")
    created_by: Optional["DatasetDatasetVersionsItemsCreatedBy"] = Field(
        alias="createdBy"
    )


class DatasetDatasetVersionsItemsCreatedBy(BaseModel):
    id: Any
    display_name: str = Field(alias="displayName")


class DatasetDatasetWorkspace(BaseModel):
    slug: str
    name: str


Dataset.model_rebuild()
DatasetDataset.model_rebuild()
DatasetDatasetVersions.model_rebuild()
DatasetDatasetVersionsItems.model_rebuild()
