# Generated by ariadne-codegen on 2023-06-06 10:49
# Source: graphql/queries.graphql

from typing import List, Optional

from pydantic import Field

from .base_model import BaseModel


class GetCalendarCompetitionResults(BaseModel):
    get_calendar_competition_results: Optional[
        "GetCalendarCompetitionResultsGetCalendarCompetitionResults"
    ] = Field(alias="getCalendarCompetitionResults")


class GetCalendarCompetitionResultsGetCalendarCompetitionResults(BaseModel):
    competition: Optional[
        "GetCalendarCompetitionResultsGetCalendarCompetitionResultsCompetition"
    ]
    event_titles: Optional[
        List[
            Optional[
                "GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitles"
            ]
        ]
    ] = Field(alias="eventTitles")
    options: Optional[
        "GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptions"
    ]
    parameters: Optional[
        "GetCalendarCompetitionResultsGetCalendarCompetitionResultsParameters"
    ]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsCompetition(BaseModel):
    date_range: Optional[str] = Field(alias="dateRange")
    end_date: Optional[str] = Field(alias="endDate")
    name: Optional[str]
    ranking_category: Optional[str] = Field(alias="rankingCategory")
    start_date: Optional[str] = Field(alias="startDate")
    venue: Optional[str]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitles(BaseModel):
    event_title: Optional[str] = Field(alias="eventTitle")
    events: Optional[
        List[
            Optional[
                "GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEvents"
            ]
        ]
    ]
    ranking_category: Optional[str] = Field(alias="rankingCategory")


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEvents(
    BaseModel
):
    event: Optional[str]
    event_id: Optional[int] = Field(alias="eventId")
    gender: Optional[str]
    is_relay: Optional[bool] = Field(alias="isRelay")
    per_result_wind: Optional[bool] = Field(alias="perResultWind")
    races: Optional[
        List[
            Optional[
                "GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEventsRaces"
            ]
        ]
    ]
    summary: Optional[
        List[
            Optional[
                "GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEventsSummary"
            ]
        ]
    ]
    with_wind: Optional[bool] = Field(alias="withWind")


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEventsRaces(
    BaseModel
):
    date: Optional[str]
    day: Optional[int]
    race: Optional[str]
    race_id: Optional[int] = Field(alias="raceId")
    race_number: Optional[int] = Field(alias="raceNumber")
    wind: Optional[str]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEventsSummary(
    BaseModel
):
    mark: Optional[str]
    nationality: Optional[str]
    place_in_race: Optional[str] = Field(alias="placeInRace")
    place_in_round: Optional[str] = Field(alias="placeInRound")
    points: Optional[int]
    race_number: Optional[int] = Field(alias="raceNumber")
    records: Optional[str]
    wind: Optional[str]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptions(BaseModel):
    days: Optional[
        List[
            Optional[
                "GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptionsDays"
            ]
        ]
    ]
    events: Optional[
        List[
            Optional[
                "GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptionsEvents"
            ]
        ]
    ]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptionsDays(BaseModel):
    date: Optional[str]
    day: Optional[int]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptionsEvents(
    BaseModel
):
    gender: Optional[str]
    id: Optional[int]
    name: Optional[str]
    combined: Optional[bool]


class GetCalendarCompetitionResultsGetCalendarCompetitionResultsParameters(BaseModel):
    competition_id: Optional[int] = Field(alias="competitionId")
    day: Optional[int]
    event_id: Optional[int] = Field(alias="eventId")


GetCalendarCompetitionResults.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResults.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsCompetition.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitles.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEvents.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEventsRaces.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsEventTitlesEventsSummary.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptions.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptionsDays.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsOptionsEvents.update_forward_refs()
GetCalendarCompetitionResultsGetCalendarCompetitionResultsParameters.update_forward_refs()
