Enlighten System Data API is in beta

  • Idea
  • Updated 2 years ago
  • Planned
Hi there, I wanted to make sure folks here knew about the new api. It's in beta now, but should be more widely available soon:

http://www.enphaseenergy.com/api/

This thread was originally posted by ilen on Mar 16, 2011 10:52 PM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes

Posted 3 years ago

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
Very cool. Just after I figured how to decode your .json data files too, now you make it official. I have requested access to the api.

Thanks.

This reply was originally posted by rotus8 on Mar 16, 2011 11:26 AM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
Fantastic!

And to think I thought you guys had lost the plot... ;)

Seriously, thank you :)

This reply was originally posted by Patricko on Mar 16, 2011 12:40 PM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
It works!



This reply was originally posted by rotus8 on Mar 16, 2011 8:27 PM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
w00t!!

This reply was originally posted by ilen on Mar 16, 2011 9:37 PM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
Here's my stab at it - an OSX dashboard widget, whee!



(This may be egregious use of the corporate logo, horrible UI design etc, but was just trying to whip something up for my own use at this point).

(And please ignore that timestamp for now ...)

This reply was originally posted by sandeen on Mar 26, 2011 8:18 AM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
Hey Sandeen,

I like it! Pretty good design for just "whip something up"

Let the community know when it could be downloaded

This reply was originally posted by Jacob Michals on Mar 27, 2011 9:49 AM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
Jacob Michals wrote:

" Hey Sandeen,
I like it! Pretty good design for just "whip something up"
Let the community know when it could be downloaded "

I will; I think that's partly up to you guys though, if the API needs to get out of beta before I can share something which uses it... that wasn't totally clear to me.

This reply was originally posted by Sandeen on Mar 27, 2011 10:01 AM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
Is the OSX dashboard widget, also what your using over at

http://pvoutput.org/list.jsp?id=1241&...

If so, I'd like to add my info at pvoutput.org

This reply was originally posted by TackyTeddy on Mar 28, 2011 8:08 AM

Enphase Energy FAQ

  • 966 Posts
  • 19 Likes
The pvoutput.org account is updated using a perl script, firing off every 5 minutes, which uses the API to populate that page. Hm, maybe it could be run out of a dashboard widget, but that'd be sort of an odd way to do it

The current API license agreement (linked off your Enlighten settings page, BTW) seems so draconian, though, I don't know for sure if this sort of thing is actually allowed:

2.2 Restrictions. You acknowledge that the API is a valuable trade secret of Enphase Energy. Accordingly, you agree not to: ... ... (c) use the API in order to build a product or service that is similar to or competitive with any of our products or services or that replicates or attempts to replace the customer's user experience of the Enlighten Service;

I'm not distributing any of this stuff until it's clear that Enphase will allow it - either due to license agreement issues, or simply the fact that the API is in beta; it's not clear what I'm allowed to do yet. I hope that I can distribute it all eventually, of course.

As an aside, I personally think Enphase could be a bit less protective of this interface and the data behind it; especially after a user has paid their subscription fee, they should be able to use their array data as they please.

Perhaps I'm misreading the agreement, but for now I'm proceeding slowly until I have clarification on what I can do with the API, and when I can distribute applications which use it. So stay tuned, I guess. :)

This reply was originally posted by sandeen on Mar 28, 2011 8:51 AM

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes


Graphs too :) Need to figure out how to fit all the info on a small-ish widget, but I think a lot of good things will come of having this data available.

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes


I have the OSX widget ready for testing as soon as Enphase makes clear that I can let others have it for testing purposes. :)

It looks a bit like the graph widget above, but it has 2 views; clicking it cycles between numerical stats and a graph representation.

-Eric

Ted Panofsky, Champion

  • 491 Posts
  • 87 Likes
That's extremely cool. Anxiously awaiting enphase's answer

jasonp_austin

  • 17 Posts
  • 1 Like
Hi Eric, have you been able to release your OSX widget?

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
Yep, it's been out there for a long time now :) (I should have added a "check for updates thing, but there haven't been updates for some time) Anyway, it's at:

http://www.sandeen.net/enlighten_widget/

jasonp_austin

  • 17 Posts
  • 1 Like
Got it, thanks! Looks good, though would be even better if the graph were a bit larger (looks a bit small on my MBP 1650x1080 screen).

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
Hm, not sure offhand how to make it scale with the screen. Do other widgets do that?

jasonp_austin

  • 17 Posts
  • 1 Like
Not sure, but most of the others are big enough to be easy readable. I can see the graph OK but the graph labels are tiny.

TackyTeddy, Champion

  • 164 Posts
  • 14 Likes
I'm an others, and ready for OSX for testing purposes.

Ted Panofsky, Champion

  • 491 Posts
  • 87 Likes
Eric - is an OSX widget anything like a Windows Sidebar Gadget? I am willing to collaborate to get something for the Windows folks.

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
Ted - yes, should be similar.

If the Windows gadgets can be done in javascript (I'm guessing they are, but with M$ who knows ;) then I can factor out my code to make it pretty easy to just wire it up to various different widget components. I've already got an "enlighten-api.js" javascript framework to make retrieving the various bits simpler [1]; I'll refactor the main javascript to take the non-Apple-specific bits out into their own file as well.

It should be pretty trivial to make an iGoogle gadget, a yahoo widget, or whatnot, from the same bits.

[1] but I'm hoping that the license text about "derivative works" don't apply here...

p.s. Enphase folks, if you want to confirm via email to Ted and me that we are both beta testers then maybe we can talk in more detail offline about the API and its use. The old community site was better suited to facilitate specific group discussions like that; I don't see that getsatisfaction has any invite-only groups, unfortunately.

Jacob Michals, Community Manager

  • 1405 Posts
  • 96 Likes
Hey Eric,

Checking with the API team and will follow up with an email soon.

-Jacob

Ilén Zazueta-Hall, Employee

  • 89 Posts
  • 30 Likes
How 'bout I confirm right here. You're both beta testers, collaborate away!

Eric Sandeen, Champion

  • 785 Posts
  • 82 Likes
Cool, thanks. Expect greatness ;)

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
One other thing I was considering writing is a script to send production data from Elighten to Google PowerMeter - basically, make the Envoy look like a PowerMeter-enabled device, but with Enlighten and some glue scripting in between.

Even if one already had a Ted 5000 or a similar device for whole-house data, I think I could make it so you could add solar data to the view as another device on the same account.

However, this would require some always-on computer to periodically query the Enlighten API and upload data to PowerMeter, and a operating system which can run whatever scripting language I'd do it in (probably perl, but I'm flexible). That always-on "computer" could be a wifi router with shell access, perhaps, or a desktop...

so 2 questions for the interested community:


  • Would a script to do this be useful, given the requirements above?

  • Would such a use of API data be acceptable to Enphase?



Maybe some other enterprising Window-savvy person would know how to wrap perl into a Windows service.

OTOH, I don't want to encourage people to leave their computers on 24/7 just for this purpose. :)

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
Using a 3W ARM pogoplug would work well for this though...

Ted Panofsky, Champion

  • 491 Posts
  • 87 Likes
To be honest, I am not a fan of Google PowerMeter. I hooked my TED up to it for a while, but it really is a pretty stupid app. It makes a graph that you can see from anywhere, but that's it. What's the point? I get that and more from Enlighten, my TED5000, and my own website. (and the coming gadget :) )

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
Yeah, it doesn't have much to it... development seems to have ground to a halt, near as I can tell. I still tend to refer to it though, I have no other good place to send my daily consumption data, and I send my solar production data there as well.

Miles Kurland

  • 9 Posts
  • 0 Likes
I know I'm resurrecting a long abandoned thread, but this seemed the appropriate place to post this.

I recently sent an email to apply to the API beta program, being a long-time programmer (of over 25 years) and a new Enphase customer (of under 3 weeks). I haven't heard anything back after several days, even an acknowledgement of my email.

I'm wondering if that was the experience of any of the other beta program applicants - and I should just be more patient - or whether it's just as likely that my email got spam-filtered... and I should try again.

Ilén Zazueta-Hall, Employee

  • 89 Posts
  • 30 Likes
Hi Miles, I'm handling the API Beta Program and for some reason your request has not made it to my inbox... Would you mind sending another quick email to enlightenfeedback@enphaseenergy.com?

Thanks!

Miles Kurland

  • 9 Posts
  • 0 Likes
Ilén - check your mailbox now. If you don't see it, check your spam filter!

Ilén Zazueta-Hall, Employee

  • 89 Posts
  • 30 Likes
No dice, I'll take it up with IT. Thanks for your patience.

Miles Kurland

  • 9 Posts
  • 0 Likes
I just tried again from another email account (Gmail). Sigh.

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
Hi Miles - nope, I got a fairly prompt reply. Your ping here will hopefully get you some attention. :)

What sorts of plans do you have for using the API data? Just curious. :)

Miles Kurland

  • 9 Posts
  • 0 Likes
Well, I'm a data visualization geek, so there's no telling how deeply I might get into the weeds once I see how detailed the data might be, but at the very least having some simple components for web embedding are obvious.

I've got a slot just waiting for real-time reporting data on my blog, and I could put up data scraped off my Envoy (I wrote a PHP/mySQL script for that which also correlates weather from Yahoo's RSS) but I'd prefer to base it on something a bit more detailed and comprehensive.

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
It's a little roundabout, but I have a little widget on http://sandeen.net/wordpress/ which comes back after sending data to pvoutput.org, it's fairly slick. (right now I'm polling the envoy as well as using the API, need to settle on one or the other) :)

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
Oh, and I was trying to work out how to make little embeddable javascript widgets which could be used without requiring the API key to be visible in the HTML source...

Miles Kurland

  • 9 Posts
  • 0 Likes
Nice.

I had been thinking, with respect to an embeddable widget, that one would register an API key on a page that establishes an "account" for you which would then stash the API key in a mySQL database and provide you an embed tag utilizing a distinct unique ID used for talking to the data source. At least that's how I'd plan to do it.

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
So the "account" would have to run elsewhere, and be trusted with the API key I guess?

I do wish Enphase could provide both public & private keys, with the public key providing no more data than what is available on the public Enlighten page...

Miles Kurland

  • 9 Posts
  • 0 Likes
I suppose that in the absence of that, having an explicit privacy policy that states that the data displayed in the widget you are utilizing represents the full extent of the data that will be collected, that none will be stored (yada, yada) is about the best one can do.

xnav

  • 116 Posts
  • 6 Likes
I've put together an iPhone/iPad/iPodTouch app. Is anyone interested in a beta copy? iOS 4.0+ is required.

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
Cool, I'd be happy to test it out ... how do I get it onto my phone? :)

I was pondering trying my hand at an iphone app but hadn't tried to get started yet.

Chris Wendel

  • 9 Posts
  • 0 Likes
I would love to test it out on a Iphone 4 for you you can send instructions where to get it to solar@wendelsworld.com

xnav

  • 116 Posts
  • 6 Likes
I've sent you an email requesting your device's UUID.

Powerskip

  • 106 Posts
  • 3 Likes
Same question here.
We got the Ted-o-meter.
I opened the telnet and remote management in my router, but don't get any connection, when outside my house.
I would like to try the above app, but the problem would be the same, right?

In general, do we have to have a static IP address, in order to have any of those power apps running?

xnav

  • 116 Posts
  • 6 Likes
"I would like to try the above app, but the problem would be the same, right? "
No, the data I'm using comes from http://api.enphaseenergy.com, not directly from your Envoy. If WiFi is not available then the iPhone will use the 3G network. The same for iPad if you have a 3G model.

Powerskip

  • 106 Posts
  • 3 Likes
But the API data have the same 45 delay, right?

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
Enlighten often lags by that much but the API is usually within 5.

xnav

  • 116 Posts
  • 6 Likes
It doesn't seem to, I just did a quick test at 9:03 and the last interval reported was 8:55. (Hawaiian time)

xnav

  • 116 Posts
  • 6 Likes
I need your device's UUID:

Instructions to get UUIID:

1) Launch iTunes and plug in your iPhone/iPod/iPad

2) On the Summary page for your iPhone/iPod/iPad, click on the word “Serial Number:”

3) The serial number on the right of the text should change to the word “Identifier”, followed by the UUID which is a long string of numeric and alphanumeric character

4) Press on Command/AppleKey + C (Mac) or CTRL+C (Windows) and the UUID will be copied to the clipboard and can then be pasted into an Email.

5) Once I have collected UUID's I will email the compressed app file which can be opened by iTunes and then installed by syncing the device.

Your UUID should be sent to me by 'private message', do you known if this forum has that ability?

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
No private messages on this forum as far as I know.

You can probably google me or click here to get my email address... then I can send the uuid back to you?

Virginia Solar PE

  • 7 Posts
  • 0 Likes
Hello-

I am an engineer and been approved for the API beta program.

My programming skills are a bit rusty. i am running a windows xp environment.

can someone point me to how to manipulate the .json data file I've downloaded? I'd like to build some sort of basic widget similar to the beautiful one developed by Mr. Sandeen for Mac OSX (why can't a web browser run something regardless of xp vs. mac? arrggh. any help appreciated - I'd like to be able to have more real time data and graphing up on my computer and the ability to graph and analyze my data more fully. thanks.

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
The widget doesn't run in browser, so that's not really the reason it won't work on XP. :)

But it is written in Javascript, so getting something similar running in a browser isn't too hard.

I pointed you at my hacky demo at http://sandeen.net/enlighten_api_demo/

and the javascript helpers I've written are available at:

http://code.google.com/p/enlighten-ap...

of course javascript isn't the ONLY way to go, but if you want something to display in a web page, it's probably the right place to start. Let me know if you have any questions ...

Virginia Solar PE

  • 7 Posts
  • 0 Likes
ok, got it, Thanks. - I'm talking to you on two threads. :) - I'll stay here for future questions. thanks again.

Ted Panofsky, Champion

  • 496 Posts
  • 87 Likes
I have done some decoding of the .json stuff - http://www.panofsky.net/energy.php. Simple extraction of the data to combine with other data sources. I used jquery.js for the decoding. Look at http://jquery.com/

No pretty graphics - my programming is pretty limited, I'm a hardware hacker.

Amy Niebel

  • 1 Post
  • 0 Likes
Hi Ted, would you mind sharing your code for the implementation into your page? I'd like to have something simple like this on my site as well.

Ted Panofsky, Champion

  • 496 Posts
  • 87 Likes
Sure happy to, but I'll have to remember how it works. :) Shoot me an email here: http://www.google.com/recaptcha/mailh...=

Gary Ferguson

  • 3 Posts
  • 0 Likes
You could try and use ruby for this. Enphase uses ruby/ruby on rails for their application, so this would be a good match. I recommend the switch to Linux / Mac for ruby development though....

Eric Sandeen, Champion

  • 788 Posts
  • 84 Likes
I'd like to ask - is this still "Beta?" What is the ETA for being done and in public?

Sean W.

  • 9 Posts
  • 3 Likes
Didn't see this post earlier and have put together a PHP script to display stats in a web page. Takes a few seconds to load though since it needs to do the queries. In my other post, I was suggesting an SWF widget from Enphase to do the same thing that would hopefully load a little faster.



Source is posted at http://pastebin.com/ZgZv0iD6. The script can be loaded in an iframe for embedding. You need to fill in the API key and optionally, the public URL.

Ilén Zazueta-Hall, Employee

  • 89 Posts
  • 30 Likes
Do you have a demo site somewhere? Would love to see this in action!

Miles Kurland

  • 9 Posts
  • 0 Likes
This is nice.

My PHP install did throw a warning on line 27... it looks like foreach($alerts['alerts'] as $val)
is meant to be
foreach($alert['alerts'] as $val)

Also, I think you could probably reduce hits to enphase's API - and speed things up - by caching the JSON fetched from the API in a writable file on your server, and only request the data once every 5 minutes or so. I do something like that for my widget on my blog.

Eric Sandeen, Champion

  • 772 Posts
  • 81 Likes
Ilen, I tossed a copy up at http://sandeen.net/energy_demos/enlig...

Pretty slick!

Ilén Zazueta-Hall, Employee

  • 89 Posts
  • 30 Likes
Thanks, Eric.

Sean, that *is* pretty slick!

Sean W.

  • 9 Posts
  • 3 Likes
Thanks Miles, fixed it.