Home Charger

getState([, propertyNames])

Declaration

hmkit.commands.HomeCharger.getState()

Parameters

propertyNames

(optional) Array of names of the properties you want returned.

Returns

HomeChargerResponse

Example

hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.getState(),
  accessCertificate
);

HomeChargerResponse

Parameters

chargingStatus(Object)
data.value

(String) (enum)

timestamp

(Date)

authenticationMechanism(Object)
data.value

(String) (enum)

timestamp

(Date)

plugType(Object)
data.value

(String) (enum)

timestamp

(Date)

solarCharging(Object)
data.value

(String) (enum)

timestamp

(Date)

wifiHotspotEnabled(Object)
data.value

(String) (enum)

timestamp

(Date)

wifiHotspotSSID(Object)
data.value

(String) The Wi-Fi Hotspot SSID

timestamp

(Date)

wiFiHotspotSecurity(Object)
data.value

(String) (enum)

timestamp

(Date)

wiFiHotspotPassword(Object)
data.value

(String) The Wi-Fi Hotspot password

timestamp

(Date)

authenticationState(Object)
data.value

(String) (enum)

timestamp

(Date)

chargeCurrent(Object)
data.value

(Number) (electric_current) The charge current

timestamp

(Date)

maximumChargeCurrent(Object)
data.value

(Number) (electric_current) The maximum possible charge current

timestamp

(Date)

minimumChargeCurrent(Object)
data.value

(Number) (electric_current) The minimal possible charge current

timestamp

(Date)

coordinates(Object)
data.value

(Object)

timestamp

(Date)

priceTariffs(Object)
data.value

(Array)

timestamp

(Date)

chargingPower(Object)
data.value

(Number) (power) Charging power output from the charger

timestamp

(Date)

Example

{
  "chargingStatus": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "charging"
    }
  },
  "authenticationMechanism": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "app"
    }
  },
  "plugType": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "type_2"
    }
  },
  "solarCharging": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "active"
    }
  },
  "wifiHotspotEnabled": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "enabled"
    }
  },
  "wifiHotspotSSID": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "Charger 7612"
    }
  },
  "wiFiHotspotSecurity": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "wpa2_personal"
    }
  },
  "wiFiHotspotPassword": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "ZW3vARNUBe"
    }
  },
  "authenticationState": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": "authenticated"
    }
  },
  "chargeCurrent": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": 0.5,
      "unit": "amperes"
    }
  },
  "maximumChargeCurrent": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": 1,
      "unit": "amperes"
    }
  },
  "minimumChargeCurrent": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": 0.1,
      "unit": "amperes"
    }
  },
  "coordinates": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "latitude": {
        "value": 52.520008
      },
      "longitude": {
        "value": 13.404954
      }
    }
  },
  "priceTariffs": [
    {
      "timestamp": "2021-06-01T15:48:04.887Z",
      "data": {
        "pricingType": {
          "value": "starting_fee"
        },
        "price": {
          "value": 4.5
        },
        "currency": {
          "value": "EUR"
        }
      }
    },
    {
      "timestamp": "2021-06-01T15:48:04.887Z",
      "data": {
        "pricingType": {
          "value": "per_minute"
        },
        "price": {
          "value": 0.3
        },
        "currency": {
          "value": "EUR"
        }
      }
    },
    {
      "timestamp": "2021-06-01T15:48:04.887Z",
      "data": {
        "pricingType": {
          "value": "per_kwh"
        },
        "price": {
          "value": 0.3
        },
        "currency": {
          "value": "Ripple"
        }
      }
    }
  ],
  "chargingPower": {
    "timestamp": "2021-06-01T15:48:04.887Z",
    "data": {
      "value": 350,
      "unit": "kilowatts"
    }
  }
}

getAvailability([, propertyNames])

Declaration

hmkit.commands.HomeCharger.getAvailability()

Parameters

propertyNames

(optional) Array of names of the properties you want returned.

Example

// Get availability for all properties
hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.getAvailability(),
  accessCertificate
);
// Get availability for specific properties
hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.getAvailability(['charging_status']),
  accessCertificate
);

Response

Parameters

availability(Object)
updateRate.value

(String) enum

rateLimit.value

(Number)

rateLimit.unit

(String)

appliesPer.value

(String)

Discussion

The response contains an availability object for each property, as shown in the example

Example

{
  "charging_status": {
    "availability": {
      "updateRate": {
        "value": "trip_high"
      },
      "rateLimit": {
        "value": 64,
        "unit": "hertz"
      },
      "appliesPer": {
        "value": "vehicle"
      }
    }
  }
}

setChargeCurrent({ chargeCurrent })

Parameters

chargeCurrent

(Number) (electric_current) The charge current

Example

hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.setChargeCurrent({
    "chargeCurrent": {
      "amperes": 0.5
    }
  }),
  accessCertificate
);

setPriceTariffs({ priceTariffs })

Parameters

priceTariffs

(Array)

Example

hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.setPriceTariffs({
    "priceTariffs": [
      {
        "pricingType": {
          "value": "starting_fee"
        },
        "price": {
          "value": 4.5
        },
        "currency": {
          "value": "EUR"
        }
      },
      {
        "pricingType": {
          "value": "per_minute"
        },
        "price": {
          "value": 0.3
        },
        "currency": {
          "value": "EUR"
        }
      },
      {
        "pricingType": {
          "value": "per_kwh"
        },
        "price": {
          "value": 0.3
        },
        "currency": {
          "value": "Ripple"
        }
      }
    ]
  }),
  accessCertificate
);

activateDeactivateSolarCharging({ solarCharging })

Parameters

solarCharging

(String) (enum)

Example

hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.activateDeactivateSolarCharging({
    "solarCharging": "active"
  }),
  accessCertificate
);

enableDisableWiFiHotspot({ wifiHotspotEnabled })

Parameters

wifiHotspotEnabled

(String) (enum)

Example

hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.enableDisableWiFiHotspot({
    "wifiHotspotEnabled": "enabled"
  }),
  accessCertificate
);

authenticateExpire({ authenticationState })

Parameters

authenticationState

(String) (enum)

Example

hmkit.telematics.sendCommand(
  hmkit.commands.HomeCharger.authenticateExpire({
    "authenticationState": "authenticated"
  }),
  accessCertificate
);