HTTP read energy prices from homepage

Avatar
  • updated

Since the energy prices have gone up I would like to import energy prices to bOS so I could make some desicions according to energy prices. I have read the manual about http driver but I am not a http and api expert and I am not able to understand the manual. Has anybody done such a thing and could explane or share demo how to read values from homepage or api. I understand that reading is different in different pages but maybe with some example I would understand the idea how to GET value to bOS.

Avatar
Jürgen Jürgenson
Quote from Ricardo Pinto

Thanks for sharing Jürgen, even though I'm not using the example (not applicable to my country).

But I'm glad for the help and sharing spirit.


This forum should have a "Thank you" button / helping reputation scale :-D

Best regards 

Thanks!
Yeah this open API only supports EE,FI,LV and LT as of now. But I've made one for EntsoE too - this should work with other regions. Only problem is that it needs user account and tokens to work. If i get more time to play with it, i'll try to simplify it. Then i could share it. 

Sharing is caring :D

Avatar
Ricardo Pinto

Thanks for sharing Jürgen, even though I'm not using the example (not applicable to my country).

But I'm glad for the help and sharing spirit.


This forum should have a "Thank you" button / helping reputation scale :-D

Best regards 

Avatar
Jürgen Jürgenson

Kodu-Http ELERING API.bos

I made some fixes - It now shows the full 24h log - still has trouble with some programs and calculator - cut&paste should fix it though.

Avatar
Jürgen Jürgenson
Quote from Jürgen Jürgenson

Http ELERING API v2.bos

Umm Thanks again. Day calculator's error is also fixed. 
That bad request comes when %3 is missing form the string - there is a program for it, that had an error. It should now update its value automatically when server is reloaded...

Edit: Try running the programs manually if it gives you bad request.

Http ELERING API v2.bos


Seems like there could be some import bugs. I get two problems when importing this template to a empty/new server. 1)The calculator is "broken" and needs to be cut&pasted back otherwise it wont calculate the +1 day value. 

2) %3 value wont update after the import - if I open the programs %3 line again it will work again.

On my home server I dont get these problems. After service reload it gets all the values. Will have to talk to the support guys.

Avatar
Jürgen Jürgenson
Quote from Tanel Matsi

You still have small bug that request info from ENTSO "Calculation +1päev"

Also bad request to ELERING to 24H values.

Http ELERING API v2.bos

Umm Thanks again. Day calculator's error is also fixed. 
That bad request comes when %3 is missing form the string - there is a program for it, that had an error. It should now update its value automatically when server is reloaded...

Edit: Try running the programs manually if it gives you bad request.

Avatar
Tanel Matsi

You still have small bug that request info from ENTSO "Calculation +1päev"

Also bad request to ELERING to 24H values.

Avatar
Jürgen Jürgenson
Quote from Tanel Matsi

Your demo is also linked to another HTTP  driver named HTTP ENTSO-E. "Command current price" gives bad request.

Http ELERING API v2.bos

Thanks for noticing the error, it should be fixed now. As I had recycled some programs from Ensto-e I didn't even notice it myself.

NB! If after the import, it still doesn't work, you can reload the server or run the programs manually. They need to run once to get the dates updated.

Avatar
Tanel Matsi

Your demo is also linked to another HTTP  driver named HTTP ENTSO-E. "Command current price" gives bad request.

Avatar
Jürgen Jürgenson

Http ELERING API v2.bos
Updated with 21hours table and min-max-avg values. I'm not sure why Elering API only gives me 21hours when from entso-e I get the full 24h response. 21H log opens if pressed on the current price button for each region. 

Avatar
Jürgen Jürgenson

Http ELERING API.bos
I made this. It's an super simple dashboard and doesn't need any special tokens or registration. Works for country's EE, FI, LT, LV shows only the current price and logs it - not the full 24h. Info comes from here: LINK So if anyone wants they can add to it.