skodaconnect / myskoda

Python library for interacting with MySkoda APIs.
MIT License
9 stars 22 forks source link

Feature: Enable pre-conditioning by timer like in App #166

Open ThraaxSession opened 2 weeks ago

ThraaxSession commented 2 weeks ago

The official app supports pre-conditioning with a timer. Would be awesome to have similar possibilities like in the main app.

prvakt commented 2 weeks ago

Below you can find some info how to activate the timer.

HTTP POST https://mysmob.api.connect.skoda-auto.cz/api/v1/vehicle-automatization/TMBXXXXXXXXXXXXXX/departure/timers
{
    "deviceDateTime": "2024-11-06T20:43:11.841+01:00",
    "timers": [
        {
            "charging": true,
            "climatisation": true,
            "enabled": true,
            "id": 1,
            "oneOffDay": "THURSDAY",
            "preferredChargingTimes": [
                {
                    "enabled": true,
                    "endTime": "06:00",
                    "id": 1,
                    "startTime": "00:00"
                }
            ],
            "targetBatteryStateOfChargeInPercent": 90,
            "time": "07:00",
            "type": "ONE_OFF"
        }
    ]
}

or

{
    "deviceDateTime": "2024-11-06T20:40:15.287+01:00",
    "timers": [
        {
            "charging": true,
            "climatisation": true,
            "enabled": true,
            "id": 1,
            "preferredChargingTimes": [
                {
                    "enabled": true,
                    "endTime": "06:00",
                    "id": 1,
                    "startTime": "00:00"
                }
            ],
            "recurringOn": [
                "MONDAY",
                "TUESDAY",
                "WEDNESDAY",
                "THURSDAY",
                "FRIDAY",
                "SATURDAY",
                "SUNDAY"
            ],
            "targetBatteryStateOfChargeInPercent": 90,
            "time": "07:00",
            "type": "RECURRING"
        }
    ]
}

where timers["id"] is identification of the timer (1,2 or 3)

ThraaxSession commented 2 weeks ago

Ah not sure it's what I need. This seems to be about charging only, not heating/cooling.

prvakt commented 2 weeks ago

just set charging to false and climatisation to true.. then time attribute should be set to time when you want to have you car ready

prvakt commented 1 day ago

when playing with timers today, I have found out there are 2 different timers in MySkoda app with different endpoints and slightly different structure

I think it should be possible to implement both timers into HA but priority for me is auxiliary heating at the moment