35 lines
573 B
Python
35 lines
573 B
Python
from dataclasses import dataclass
|
|
from typing import Dict, List, Optional
|
|
|
|
|
|
@dataclass
|
|
class Price:
|
|
hours: Dict[str, float]
|
|
now: Optional[float] = None # Price in current hour
|
|
|
|
|
|
@dataclass
|
|
class CheapestHours:
|
|
hours: List[int]
|
|
is_cheapest: Optional[bool] = None
|
|
|
|
|
|
@dataclass
|
|
class DayPrice:
|
|
monthly_fees: float
|
|
monthly_fees_hour: float
|
|
kwh_fees_low: float
|
|
kwh_fees_high: float
|
|
sell_fees: float
|
|
low_tariff_hours: List[int]
|
|
vat: float
|
|
spot: Price
|
|
total: Price
|
|
sell: Price
|
|
cheapest_hours: CheapestHours
|
|
|
|
|
|
|
|
|
|
|