Build a NEM electricity price alerting tool
Get NEM 5-minute dispatch prices and rolling averages by region as JSON, refreshed every dispatch interval. ausdata.io wraps AEMO's live feed so you can write the alerting logic, not the parsing logic. Triggers fire within seconds of the dispatch.
The problem
AEMO publishes dispatch data as CSV archives and live feeds with their own schemas. Building anything that reacts to spot prices means handling timezone quirks, dispatch-vs-trading interval semantics, and a CSV pipeline that has to keep up with a 5-minute cadence.
The fix
/v1/energy-snapshot returns the latest spot price per region. /v1/nem-dispatch-5min returns the full 5-minute history filterable by region. Both are clean JSON with ISO 8601 timestamps in Australia/Brisbane. Poll on a cron or open a long-running fetch loop.
Endpoints used
Code
import requests, time
KEY = "YOUR_API_KEY"
H = {"Authorization": f"Bearer {KEY}"}
def alert_on_spike(region="NSW1", threshold=300):
while True:
r = requests.get("https://api.ausdata.io/v1/energy-snapshot",
headers=H).json()
row = next(x for x in r["data"] if x["region"] == region)
if row["price_aud_mwh"] > threshold:
print(f"SPIKE {region}: ${row['price_aud_mwh']}/MWh at {row['dispatch_time']}")
time.sleep(60)Steps
- 1
Pick your regions
NSW1, VIC1, QLD1, SA1, TAS1. Filter to the regions your assets sit in.
- 2
Poll the snapshot endpoint
Every 30 to 60 seconds is enough to catch any 5-minute dispatch within the first interval after it sets.
- 3
Set thresholds
Spikes above $300/MWh, sustained negative pricing, or rolling-average breaches. Whatever your trade or load-shift logic needs.
- 4
Send the alert
Webhook, SMS, email, Slack. ausdata.io ships the data; routing the alert is your call.
Other use cases
Start building
500 free calls per month. No credit card.
Get a free key