Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Provider: FirstEnergy and subsidiaries #67

Open
micle546 opened this issue Jan 29, 2024 · 2 comments
Open

New Provider: FirstEnergy and subsidiaries #67

micle546 opened this issue Jan 29, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@micle546
Copy link

micle546 commented Jan 29, 2024

FirstEnergy and it's subsidiaries are using opower. Creating this issue to support the addition of FirstEnergy.

I've done some of the initial work to support this. Will continue over the course of the next few days

login page - https://www.firstenergycorp.com/content/customer/log_in.html
or
https://www.firstenergycorp.com/log_in.fecorplogin.html

https://www.firstenergycorp.com/my_account/analyze-usage.html

First Energy: Ohio Edison uses feoe.opower.com

Others appear to be: (need verified)
(?) https://fepa.opower.com/
MetEd(?) - https://feme.opower.com/
PennPower (?) - https://fepp.opower.com/
(?) - https://fepn.opower.com/
ToledoEdison (?) - https://fete.opower.com/

@micle546
Copy link
Author

I think it's returned as an oauth bearer token? (not a webdev)
POST to https://www.firstenergycorp.com/log_in.fecorplogin.html

login:<USERNAME>
password:<PASSWORD>

Response from https://www.firstenergycorp.com/my_account/analyze-usage.html?cache=no

<script>
var currentWidgetOpco = 'FEOE';

window.addEventListener('opower:unauthorized', function(event) {
  var authorize = event.detail.authorize;
  var authorization = {
   accessToken: '<TOKEN>'
  }
  authorize(null, authorization); // Do not call if user is logged out
});

Used with GET

authorization: Bearer <TOKEN>
opower-selected-entities: ["urn:opower:customer:uuid:<UUID>"]

@micle546
Copy link
Author

If I POST the login and passwd to the log_in.html page, I should just be able to GET the analyze-usage.html page to pull the bearer token after some specified waiting period for processing, right?

I'm mostly stumbling in the dark here.

Done some python, but never any web stuff, particularly with async/await threading.

@tronikos tronikos added the enhancement New feature or request label Apr 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants