Battery storage data will only be returned when the battery is installed in the Envoy system. To determine if the battery is installed we check for the presence of the percentFull attribute, as in the above example.
If a battery is not present the /production.json page will return:
Adding Battery storage data that is coming from
/production.json
Battery storage data will only be returned when the battery is installed in the Envoy system. To determine if the battery is installed we check for the presence of the
percentFull
attribute, as in the above example.If a battery is not present the
/production.json
page will return:In which case the API will return a message saying the battery storage is not available.
Pull request recommendations:
Thanks for contributing!