Models¶
polestar_api.models ¶
Typed protobuf-backed models exposed by the Polestar API client.
ChargeLocation
dataclass
¶
ChargeLocation(location_id: str = '', location_alias: str = '', latitude: float = 0.0, longitude: float = 0.0, amp_limit: int = 0, minimum_soc: int = 0, is_optimised_charging_enabled: bool = False, is_bidirectional_charging_enabled: bool = False, available_optimised_charging: OptimisedChargingType = OptimisedChargingType.UNAVAILABLE, location_type: ChargeLocationType = ChargeLocationType.UNSPECIFIED, charge_timers: tuple[ChargeLocationTimer, ...] = (), departure_times: tuple[ChargeLocationDepartureTime, ...] = ())
A saved charge location with per-location charging settings.
ChargeLocationDepartureTime
dataclass
¶
ChargeLocationDepartureTime(id: str = '', activated: bool = False, hour: int = 0, minute: int = 0, active_days: tuple[Weekday, ...] = ())
A departure time associated with a specific charge location.
ChargeLocationTimer
dataclass
¶
ChargeLocationTimer(id: str = '', activated: bool = False, start_hour: int = 0, start_minute: int = 0, stop_hour: int = 0, stop_minute: int = 0, active_days: tuple[Weekday, ...] = ())
A charge timer associated with a specific charge location.
VehicleRequest
dataclass
¶
VehicleRequest(id: str = '', vin: str = '')
ExteriorStatus
dataclass
¶
ExteriorStatus(central_lock: CentralLockStatus | None = None, doors: DoorsStatus | None = None, windows: WindowsStatus | None = None, sunroof: SunroofStatus | None = None, hood: HoodStatus | None = None, tailgate: TailgateStatus | None = None, tank_lid: TankLidStatus | None = None)
Bases: ProtoMessage
InvocationRequest
dataclass
¶
InvocationRequest(vin: str = '')
InvocationResponse
dataclass
¶
InvocationResponse(id: str = '', vin: str = '', status: InvocationStatus = InvocationStatus.UNKNOWN_ERROR, message: str = '', timestamp: int = 0)
OdometerStatus
dataclass
¶
OdometerStatus(timestamp: Timestamp | None = None, odometer_meters: int = 0, trip_meter_manual_km: float = 0.0, trip_meter_automatic_km: float = 0.0)
Bases: ProtoMessage
Odometer and trip meter readings from the DT odometer service.
Field 2 is odometer in meters (per Odometer.ODOMETER_METERS_FIELD_NUMBER).
ParkingClimateTimer
dataclass
¶
ParkingClimateTimer(timer_id: str = '', index: int = 0, ready_at_hour: int = 0, ready_at_minute: int = 0, activated: bool = False, repeat: bool = False, weekdays: tuple[Weekday, ...] = ())
A scheduled parking climate timer.