Since I updated to CIQ 6.2.1 I am getting unexpected type errors from getBodyBatteryHistory. Here is my code.
Before I call the function valBodyB I am making sure SensorHistory is present and getBodyBatteryHistory is present check as well.
Once the watch is confirmed to have Body Battery then we can call the function below.