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

from typing import List, Optional

from pydantic import Field

from .base_model import BaseModel
from .enums import ExecutionResultStateEnum, RunOnEnum


class ClientResult(BaseModel):
    client_result: Optional["ClientResultClientResult"] = Field(alias="clientResult")


class ClientResultClientResult(BaseModel):
    results: Optional[List[Optional["ClientResultClientResultResults"]]]


class ClientResultClientResultResults(BaseModel):
    id: str
    state: Optional[ExecutionResultStateEnum]
    message: Optional[str]
    granularity: Optional[int]
    neops_task: Optional["ClientResultClientResultResultsNeopsTask"] = Field(
        alias="neopsTask"
    )
    client: Optional["ClientResultClientResultResultsClient"]
    execution: Optional["ClientResultClientResultResultsExecution"]


class ClientResultClientResultResultsNeopsTask(BaseModel):
    id: str
    name: Optional[str]


class ClientResultClientResultResultsClient(BaseModel):
    id: str
    macaddress: Optional[str]


class ClientResultClientResultResultsExecution(BaseModel):
    id: str
    run_on: Optional[RunOnEnum] = Field(alias="runOn")
