Skip to main content
Solved

Can we get access to the OVO energy online account API to download our smart meter usage data?

  • March 9, 2017
  • 214 replies
  • 35549 views

Show first post

214 replies

Transparent
Rank 20
Forum|alt.badge.img+2
  • Rank 20
  • October 15, 2020

Please confirm @Jequinlan - does this solution only work on PCs running Windoze?


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

PS:

In order to save the output in the same folder as the exe I had to specify .\output.csv as the file name


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

You can put them in there to save typing them all the time! Thats all. Then you can omit those params from command line.


Ought to be in the readme (as a programmer I guessed that might be the case)


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

If I add my username and password into the settings json file I get

 

OvoData.exe -f 01/01/2020 -t 04/02/2020 -o .\OvoData.csv
Unable to login - 401 - Unauthorized
   at OvoData.OvoLiveRepository.OvoConnect.GetLoginCookieAsync(String userName, String password)
   at OvoData.OvoOrchestrator.ExportData()
   at OvoData.Program.EntryPoint.Run()


Jequinlan
Rank 10
Forum|alt.badge.img+6
  • Rank 10
  • October 15, 2020

Please confirm @Jequinlan - does this solution only work on PCs running Windoze?

Hmm, i would think so I am afraid  but i will see if i can make a docker version for mac or linux users.


Jequinlan
Rank 10
Forum|alt.badge.img+6
  • Rank 10
  • October 15, 2020

If I add my username and password into the settings json file I get

 

OvoData.exe -f 01/01/2020 -t 04/02/2020 -o .\OvoData.csv
Unable to login - 401 - Unauthorized
   at OvoData.OvoLiveRepository.OvoConnect.GetLoginCookieAsync(String userName, String password)
   at OvoData.OvoOrchestrator.ExportData()
   at OvoData.Program.EntryPoint.Run()

Oh! Erm, please just use commandline then  no idea why that didnt work! (You kept the "" right?)


SianiAnni
Rank 4
  • Rank 4
  • October 15, 2020

@Tim_OVO Given that some of Ovo’s customers have been asking for this and more for many years, I think @Jequinlan deserves a big round of applause for sharing his code. I agree that without the backing of Ovo, it should be used with a degree of caution. It could just stop working one day, when Ovo next change their api? interface, as happened in the Hive community recently. 


Jequinlan
Rank 10
Forum|alt.badge.img+6
  • Rank 10
  • October 15, 2020

@Tim_OVO Given that some of Ovo’s customers have been asking for this and more for many years, I think @Jequinlan deserves a big round of applause for sharing his code. I agree that without the backing of Ovo, it should be used with a degree of caution. It could just stop working one day, when Ovo next change their api? interface, as happened in the Hive community recently. 

Yes, if the api changes it could stop, but also the apis are soft coded in the config file so if a trivial change the config will just need updating. The risk of any 3rd party integration exists if any 1st party changes an apinin any situation.

 

If ovo want to see the code , then i am happy to discuss.


Transparent
Rank 20
Forum|alt.badge.img+2
  • Rank 20
  • October 15, 2020

@Jequinlanwrote:

i will see if i can make a docker version for mac or linux users.

Linux would be great :)

Raspberry-Pi or Arduino would be better still because we can then make our own IHDs   :hugging:


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

Btw, I can confirm there is no risk of insecure as you will see from the command line the details are on your machine and provided to directly access ovo, the exe has been made by best practice .net core code and is a standalone on pc only exe.


Is the program open or closed source?


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

If I add my username and password into the settings json file I get

 

OvoData.exe -f 01/01/2020 -t 04/02/2020 -o .\OvoData.csv
Unable to login - 401 - Unauthorized
   at OvoData.OvoLiveRepository.OvoConnect.GetLoginCookieAsync(String userName, String password)
   at OvoData.OvoOrchestrator.ExportData()
   at OvoData.Program.EntryPoint.Run()

Oh! Erm, please just use commandline then  no idea why that didnt work! (You kept the "" right?)

Yep, I kept the quotes to make sure it’s still valid json string.


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

@Tim_OVO Given that some of Ovo’s customers have been asking for this and more for many years, I think @Jequinlan deserves a big round of applause for sharing his code. I agree that without the backing of Ovo, it should be used with a degree of caution. It could just stop working one day, when Ovo next change their api? interface, as happened in the Hive community recently. 

Yes, if the api changes it could stop, but also the apis are soft coded in the config file so if a trivial change the config will just need updating. The risk of any 3rd party integration exists if any 1st party changes an apinin any situation.

 

If ovo want to see the code , then i am happy to discuss.

Warning: This only protects the user if the API end-point changes, not when the format of data it fetches changes.


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

Hi All,

I have just written a PowerShell script to fetch all of my readings from January 2017 to present-day a month at a time.

You can find it on GitHub at

https://github.com/MikeWilliams-UK/Bulk-Fetch-Ovo-Readings

Have fun


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

@Tim_OVO @Transparent @TerryE @andsee @SianiAnni

Here is it: The API exe I promised that takes all that HH data and nicely formats it into a consumable Sheet

https://drive.google.com/drive/folders/1A7XRov0579O53T8OsIGe3wXCk09jul0F?usp=sharing

Download all the files, and read the Readme! (oh, and Enjoy) - now I can start work on ther TOU comparison tool!! 

If anyone is willing to send me their export please do!  - It will help me build the tooling.

John (at) QuinlanServices (dot) Com 

 

Examining the downloaded csv file

  1. The following columns are always empty
    MeterPointIdentifier, CostCurrencyUnit
  2. YearColumn is always same as MonthOfYear column
  3. CostAmmount is always zero
  4. IntervalStart and IntervalEnd columns do not require fractions of a second
    2018-12-01T04:30:00.0000000 → 2018-12-01T04:30:00 please.

Not sure if these are your columns, but the output could do with tidying up.

As a programmer I can help with this.


Jequinlan
Rank 10
Forum|alt.badge.img+6
  • Rank 10
  • October 15, 2020

Btw, I can confirm there is no risk of insecure as you will see from the command line the details are on your machine and provided to directly access ovo, the exe has been made by best practice .net core code and is a standalone on pc only exe.


Is the program open or closed source?

At the moment I am discussing if I should open source it or if OVO themselves may be interested to make it or a basis of it integrated as a supported offering.


MikeWilliams
Newcomer
Forum|alt.badge.img
  • Newcomer
  • October 15, 2020

Btw, I can confirm there is no risk of insecure as you will see from the command line the details are on your machine and provided to directly access ovo, the exe has been made by best practice .net core code and is a standalone on pc only exe.


Is the program open or closed source?

At the moment I am discussing if I should open source it or if OVO themselves may be interested to make it or a basis of it integrated as a supported offering.


Would be good if it were made open source, then the community could help to fix any issues.


Transparent
Rank 20
Forum|alt.badge.img+2
  • Rank 20
  • October 15, 2020

There’s another issue to consider if OVO were to take this on. I believe that their new Billing System is being developed such that it can be licensed to 3rd parties. Such an arrangement means that they would need to secure some rights over any externally-sourced code within the suite and be able to provide rapid support if an element of that code were to fail or require upgrading.

That’s a legal minefield.

And let’s remember that it was the failure of a 3rd party software provider to resolve issues with parts of their billing system which caused OVO to embark on creating their own in the first place. It didn’t help that Ofgem clobbered them with a hefty fine for the failed usage-estimation provisions in that software.

You will understand that there would be a significant level of reluctance for OVO to become embroiled in such a scenario again.


Tim_OVO
OVO Staff
  • OVO Forum Legend
  • October 16, 2020

Sorry for another spamming comment but I’m keen to hear if others have checked out this work done by @Jequinlan this week? 

 

@Gary @GarethMarlow @rgphilpott @atilagiant @Deanohol @Peter_Mat @didge05 @sam_cat @jmontalvo @adec @Pramsbottom @ryck @CeeJayCee @alexbaulch @Random @maccordingley @sfgreenwood @johnk @jadam @Fordy @Steveo67 @Siggy0 @CerebralDigits @deanjames @ChrisB @jadam @DaveJenYearsley @ErTnEc @Marshcroft @jordanharper @Simonfea @obiwanzamora @AdamJ @dorinho @Ross2411 @Chrherms  @blakedrayson @TerryE @VibroAxe @jdenver @maurorappa @adec @100903609 @Riscy @r3m0dul8 @MyZoe.Uk @Ajk @AlanN51 @CloudCircus @r3m0dul8 @technogeoff @resoai @Fuzzysteve @mattc @andsee @uvarvu  @g-de 


Jequinlan
Rank 10
Forum|alt.badge.img+6
  • Rank 10
  • October 16, 2020

On a side note, a v2 with fixed year field coming next week.


ThePaulAdams
Newcomer
  • Newcomer
  • October 16, 2020

Sorry for another spamming comment but I’m keen to hear if others have checked out this work done by @Jequinlan this week? 

 

In the same boat without an account now,

So not unless it’s open-sourced, especially when they managed to make it almost 100mb in size. I’d say no to running that
 


uvarvu
Newcomer
  • Newcomer
  • October 16, 2020

Gave up when I saw the file extension, was hoping for something written that I could run on my Pi.   I tried to decompile it using Visual Studio but didn’t get far.


ThePaulAdams
Newcomer
  • Newcomer
  • October 16, 2020

Gave up when I saw the file extension, was hoping for something written that I could run on my Pi.   I tried to decompile it using Visual Studio but didn’t get far.

Looks like C++ I’m guessing it’s using a large library for the http requests and that’s taking up the size, but haven’t had too deep a look myself


Forum|alt.badge.img
  • Rank 5
  • December 7, 2022

Not sure who to ask this question of. Possibly @Tim_OVO.

I have a smart meter on the V2G trial. I have the Kaluza phone app and the OVO Computer app. If I want to see my half hourly imports, exports to The Grid and Exports to the house I simply go to the Kaluza phone app and click on the download arrow in the top right corner of the screen and I can download the complete month’s data in spreadsheet form, ready to go on my Apple computer.

If I want to do the same with my OVO account I can get the data on a daily basis showing ½ hourly info but there is no way (that I can see) how to download the info…..other then highlight the numbers...but then it’s not compatible with Apple’s “Numbers” App and I have some copying and pasting to do...for every day of the month.

If Kaluza have the ability to download the data easily, do OVO have a similar method that I've missed...and if not, are there any plans to do so? At present the data for Kaluza is brilliant but OVO is a struggle.

 

Can you also tell me, The National Grid record data in GMT throughout the year, even when it’s BST but some sites record data an hour later than the clock time...explained that for Solar Data, Mid Day isn’t always 12.00 noon, sometimes before and sometimes after so it’s recorded so that 1.00pm is actually 12.00 noon. Hence to avoid the extra hour in Winter and lesser hour in Spring the time is always recorded GMT. Is the time data as recorded by OVO the same time as Kaluza and is this time GMT?


Tim_OVO
OVO Staff
  • OVO Forum Legend
  • December 8, 2022

Hi @Leo Moran 

 

Great second question, add your first question is a popular one. The answer is currently that there isn’t a way to download online account usage.

 

The second question, I know that smart meters use a time switch that DOESN’T change in BST vs GMT. Which means peak / off peak usage shifts forward an hour. However I don’t know how this impacts the online account. My assumption is that the online account uses a system to correctly shift usage blocks in terms of local time. @Blastoise186, what ae your thoughts? 


Forum|alt.badge.img
  • Rank 5
  • December 8, 2022

Thanks for that @Tim_OVO ...and I’ll make a coffee and reread the second part to understand what you said...the grey matter isn’t as quick as it used to be.

 

 

 


Feedback