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

from typing import Any, Optional

from pydantic import Field

from .base_model import BaseModel
from .enums import BillableMetrics, ContentTypes, EntityTypes, FileTypes, OperationTypes


class QueryUsage(BaseModel):
    usage: Optional[list[Optional["QueryUsageUsage"]]]


class QueryUsageUsage(BaseModel):
    id: Optional[str]
    correlation_id: Optional[str] = Field(alias="correlationId")
    date: Any
    credits: Optional[Any]
    name: str
    metric: Optional[BillableMetrics]
    workflow: Optional[str]
    entity_type: Optional[EntityTypes] = Field(alias="entityType")
    entity_id: Optional[str] = Field(alias="entityId")
    project_id: str = Field(alias="projectId")
    owner_id: str = Field(alias="ownerId")
    uri: Optional[str]
    duration: Optional[Any]
    throughput: Optional[float]
    content_type: Optional[ContentTypes] = Field(alias="contentType")
    file_type: Optional[FileTypes] = Field(alias="fileType")
    model_service: Optional[str] = Field(alias="modelService")
    model_name: Optional[str] = Field(alias="modelName")
    processor_name: Optional[str] = Field(alias="processorName")
    prompt_tokens: Optional[int] = Field(alias="promptTokens")
    completion_tokens: Optional[int] = Field(alias="completionTokens")
    tokens: Optional[int]
    count: Optional[int]
    operation: Optional[str]
    operation_type: Optional[OperationTypes] = Field(alias="operationType")


QueryUsage.model_rebuild()
