Making Energimolnet – An open API for energy data (gästinlägg)

In 2012 Playback Energy set out to build an Android app to show energy consumption for the customers of Kungälv Energi. The app was relatively simple; graphs, buttons, login and contact screens. We intended to make this app and then sell a branded version to other electricity companies. However, it was almost a full year before we had a functioning system… Why? What went wrong?

We had discovered what we’ve come to call the Energy Data Fortress.

Kungälv Energi collected consumption data daily. However, the system was composed of specific energy industry IT infrastructure; the authentication controls were custom and quite limited; and there was different data available for different customers. It made it almost impossible to create a generic app that could be used for other companies. If there were only 3 or 4 distribution companies in Sweden that wouldn’t have been a problem, but there are around 170! So we set out to create a structure that:

  • connects to the existing energy industry and is independent of distribution company;
  • is capable of processing the 200 million data inserts possible every day;
  • handles authentication and authorization;
  • exposes a REST+JSON API to developers who want to use energy data; and,
  • most importantly of all, allows the energy user, not their electricity company to determine what products and services should have access to their data.

And, somewhat unsurprisingly, that’s what Energimolnet is. It makes available the data that is recorded every day by an energy company but in the past was stored away, only ever to be used to calculate your bill or, at best, presented on a poorly designed customer portal on the energy company’s homepage.

In January we read a post by Marcus Ljungblad on mashup.se which, very kindly, mentioned us as a company to watch in the area of energy data. Marcus finished the article with…

I am confident that with better access to energy data through APIs we will see both cool and useful services for the hardware that is beginning to hit the market. (My translation)

We agree wholeheartedly, but we think that, in the spirit of sustainability, first we can start to use the data that already exists.

Back when we started designing that first app we decided that our motto should be simplifying energy decisions. It was a little clichéd and showed that we’d spent two years at business school. But when we reflect now it seems that we actually have simplified getting access to, and working with, energy data.

With Energimolnet developers can target consumers directly: If you’ve got a great idea for a product or service by connecting to Energimolnet you can be assured that it will work throughout Sweden without necessarily collaborating with an energy company. Or, if you create something for one company using Energimolnet, you can try and sell it to other companies, safe in the knowledge that the data will be available, independent of distribution area.

The fact that the data is made available in a RESTful API that returns JSON and is authenticated with OAuth2.0 should also increase the number of companies capable of creating products that use energy data. Now someone who has even a limited knowledge of web programming can create a service using energy data, whereas before they would need to know about all sorts of industry specific technologies and protocols, create database structures and design an authentication process.

If you want to get started developing with Energimolnet sign up for an account on the website and email me at david.briggs@playbackenergy.se (Swedish or English) and check out our documentation.