Custom Integration: Haggle — AGL Australia smart-meter data → Energy dashboard

Hi all :waving_hand:

Just sharing a custom integration I’ve been building for AGL Energy
(Australian electricity retailer) customers with smart meters.

Repo: GitHub - NaanyaBiz/haggle: AGL Australia smart meter -> Home Assistant Energy dashboard (Claude-generated custom integration) · GitHub
Status: beta (v0.2.0-beta.1), HACS default-repo submission pending

What it does

Pulls half-hourly interval consumption from AGL’s mobile-app API and feeds
it into Home Assistant’s Energy dashboard as proper long-term
statistics (device_class=energy, state_class=total_increasing,
imported via async_add_external_statistics). You get:

  • Per-contract consumption (kWh) — appears in the Energy dashboard
    consumption picker
  • Per-contract cost (AUD) using your plan’s GST-inclusive rates
  • 30-day historical backfill on first run, incremental updates daily
  • Multi-contract accounts (pick the meter to monitor in config flow)

Install

HACS → Custom repositories → add https://github.com/NaanyaBiz/haggle
as category Integration → install → restart → Add integration
AGL Haggle.

The config flow shows you a login URL — open it in your real browser
(handles Akamai bot-protection + MFA transparently), log in, then paste
the post-login URL back into HA. Done.

Caveats — please read before installing

  • Unofficial. Not affiliated with, endorsed by, or supported by AGL
    Energy Limited. Uses the same undocumented API their mobile app uses;
    if AGL change it, things will break and I’ll fix on a best-effort
    basis.
  • Australia only, AGL electricity accounts with a smart meter only.
  • 24–48 h data lag. AGL receive AEMO interval data on that delay,
    so the dashboard always trails by a day or so. This is upstream and
    can’t be sped up.
  • Beta. Core data path is working and tested, but I’d love more eyes
    on edge cases (multi-contract accounts, solar export, time-of-use
    tariffs).

Feedback / bugs

Issues: Issues · NaanyaBiz/haggle · GitHub
Happy to hear what works, what doesn’t, and what AGL data points you’d
like exposed next.

Cheers!

2 Likes

Great work on this integration, ive been using it for a few weeks and its been great. Makes it easy to drag the data out of HA into Excel via power query.
Dose AGL expose the export data as well? It'd be amazing to also have the solar feed figure kw and $ for a period, to add into my bill estimator.

I'm sure it does but I don't have solar export at the moment - it should come through in a few days (our solar should be fitted off next wednesday as it happens) and i'll test it then. If you're interested in testing, log a feature request and i'll tag you so you can test it.

1 Like

Have you tried the solar fixtures? I’m looking for testers of the latest beta to confirm it’s all good so i can cut a full release?