jesserizzo / envoy_reader

MIT License
37 stars 26 forks source link

Support new Token Authentication method for 7.x.x firmware #86

Closed gtdiehl closed 2 years ago

gtdiehl commented 2 years ago

Firmware 7.x.x requires a token to get retrieved from Enphase to be able to locally access the Envoy's web pages

This new functionality with gather a token either using the Commisioned or Uncommissioned option from Enphase's website. In addition to require a login credentials for the Enphase Enlighten website, when a user chooses the Commisioned option they will need to provide their Site ID and Serial Number as is shown in Enlighten. Only the login credentials are needed for the Uncommisioned option.

From tests there is also a slight time difference when these tokens from Enphase expire. Commisioned tokens expire after 12 hours and Uncommisioned token expire after 24 hours. In this library this will not be an issue as it only runs once, but when the library is used in an application such as Home Assistant that application code will need to take the expiration into account.

Pull request recommendations:

Thanks for contributing!

gtdiehl commented 2 years ago

Code has been tested. Merging to release a Pre-Release build to be integrated into Home Assistant 2022.2.0.