chore: added smappee api

This commit is contained in:
Willem Serruys
2026-08-21 08:02:09 +02:00
parent 1d0a5beb8c
commit c87c09dde3
7 changed files with 67 additions and 25 deletions

View File

@@ -33,11 +33,11 @@ internal class SmappeeChargerService : IChargerService
var response = request switch
{
ChargerRequests.Enable => await httpClient.PutAsJsonAsync<SmappeeRequestBody>(
$"/dev/v3/chargingstations/${options.ChargingStation}/connectors/{options.Connector}/mode",
$"/dev/v3/chargingstations/{options.ChargingStation}/connectors/{options.Connector}/mode",
new SmappeeRequestBody("NORMAL", new Limit("AMPERE", 6))
),
ChargerRequests.Disable => await httpClient.PutAsJsonAsync(
"/dev/v3/chargingstations",
$"/dev/v3/chargingstations/{options.ChargingStation}/connectors/{options.Connector}/mode",
new SmappeeRequestBody("PAUSED", null)
),
_ => throw new NotImplementedException(),