23 lines
398 B
Python
23 lines
398 B
Python
import datetime
|
|
|
|
from pydantic import BaseModel
|
|
|
|
|
|
class WeatherValue(BaseModel):
|
|
date: datetime.datetime
|
|
cloudness: str
|
|
temperature: int
|
|
wind_speed: int
|
|
wind_gust: int
|
|
wind_direction: str
|
|
precipitation: float
|
|
pressure: int
|
|
humidity: int
|
|
|
|
|
|
class WeatherResponse(BaseModel):
|
|
location: str
|
|
date: datetime.date
|
|
period: str
|
|
values: list[WeatherValue]
|