Json API to pull usage data

IT_Guy
83 Replies 635954 Views

Hi Agl

 

Is there an API available so i can pull my usage data ( same data found in the downloadable scv at https://myaccount.agl.com.au/usage )  from my agl account to a database i'm creating to analyse my solar generation across multiple system and my power usage 

85 Comments
David_AGL
AGL Community Manager

hi @IT_Guy, good question. I'm not aware of such an API existing, but I can check in with the My Account team. This actually sounds like a similar project to what another of our community users (@NeilC) was attempting to put together. 

 

What's the end goal you had in mind?

Dim
Starter

Hi David,

 

I'm not sure of @IT_Guy plans, but I've used data pulled from a previous providers API ( Mojo power ) to a home automation system.

 

I was able to estimate bills and display usage data on a display in the house.

 

If an API was available for AGL I'd love to be able to do the same again 🙂

Sydmd
Switched-on

@David_AGLI too would like access to an API key in an effort to make a HomeBridge plugin.

Is this something AGL is working on?

 

Thanks in advance.

vidgen13
Starter

I want a REST API too.

David_AGL
AGL Community Manager
Status changed to: Good Idea, Vote!

I've moved this across to the My Account ideas page to get it more visibility. Definitely seems there is some support for this feature. Please Like it and let us know what you'd like to accomplish with the access.

john_loyola
Sparky

Hi @David_AGL ,

 

Good day. 

 

I would be very interested to consume the usage data via a REST API (JSON payload) be it daily / weekly / monthly / for a specific time period if there is a provision from AGL to provide it.  As @IT_Guy mentioned, its the same data that is available in MyAccount -> Usage as a CSV download.  Not sure what is the API enablement strategy in AGL, but the step towards it would be really benefit the customers as well as the enterprise.

 

Thanks,

Johnny.

David_AGL
AGL Community Manager

Hi @john_loyola thanks for the input.

 

I really like the idea, but can you help me understand what the benefits would be to having direct access as opposed to utilizing the current CSV download? Creating and maintaining any access like this would probably have some developer effort associated with it, so to help make the case I would need to know what solutions it could provide.

vidgen13
Starter

I can link it to my homeassistant app. Instead of downloading and parsing csv files. Its Its easier if it has a rest api.

RyanQLD
Starter

Hi @David_AGL 

 

I'm yet another person who would appreciate an API for usage data.

 


I really like the idea, but can you help me understand what the benefits would be to having direct access as opposed to utilizing the current CSV download? Creating and maintaining any access like this would probably have some developer effort associated with it, so to help make the case I would need to know what solutions it could provide.

The current CSV download is difficult to automate because it requires creating a scraper that handles your authentication process, which is quite complicated as it involves several redirects and steps. Ideally there would be an endpoint where we could send our AGL username and password in an Authorization header and get the usage data back. Bonus points if there was a way to filter it by time but that's not necessary. More bonus points if it's in JSON format rather than CSV.

 

The benefits to customers are that we can automate our usage, display it on dashboards, analyse it and so on.

 

The benefits to AGL are in customer acquisition and retention. By not having the API, you risk having customers leave in search of a provider who does. And by having the API, you encourage customers to leave other providers and join AGL.

 

-Ryan

David_AGL
AGL Community Manager

Cheers @RyanQLD , that's very helpful.