Forecast API

GET /v1/forecast — 168h hourly prices (ct/kWh) for EPEX AT. In Loxone: Forecast guide. Open REST for any client; Community 120 requests/day (free).

The Forecast API returns a list of hourly electricity prices for Austria — from right now up to 168 hours (one week) ahead.

Everyday example

Your app shows a bar chart: “Tonight 3 ct/kWh, tomorrow lunch 18 ct/kWh.” You call the API once, loop through forecast[], and draw the bars. No extra logic needed from SpotpriceAPI.

When to use / when not

Use when:

  • You display prices in an app, dashboard, or Loxone UI
  • You write your own “find cheapest hours” logic
  • Other endpoints (Decision, Windows, Hours Demand) are too much — you only need numbers

Do not use when:

  • You want a ready-made “charge now” signal → Decision API
  • You know how many hours you need and want the API to pick them → Decision Windows
  • You have a battery SOC and want a full charging plan → Hours Demand

What you need

  • Optional: API key in header X-API-Key: sf_live_YOUR_KEY (168 h with Community+)
  • Base URL: https://api.spotpriceapi.com

Step by step

1. Get a key from the portal (or skip for 48 h Basic). 2. Call GET /v1/forecast with the header above. 3. Check access.full_version_available — is the full week unlocked? 4. Check forecast_status — only use data when ok or degraded. 5. Loop forecast[] — each row is one hour with start and price_ct_kwh (the model/point price — use this for control logic, never rewritten). 6. Optional: every hour also carries dump_risk_pct (0…100, always a number) and dump_scenario_ct_kwh (dump price when pct > 0, else the point price — always usable). Pick one number to display/act on — model price or dump scenario — never both, never a manual mashup. 7. Optional: add ?timezone=Europe/Vienna if you need another timezone.

Minimal request and response


curl "https://api.spotpriceapi.com/v1/forecast?timezone=Europe/Vienna" \
  -H "X-API-Key: sf_live_YOUR_KEY"

{
  "api_version": "v1",
  "market": "EPEX_AT",
  "generated_at": "2026-08-01T06:05:00+02:00",
  "timezone": "Europe/Vienna",
  "access": { "tier": "community", "full_version_available": true },
  "horizon_hours": 168,
  "forecast_status": "ok",
  "forecast": [
    {
      "start": "2026-08-01T13:00:00+02:00",
      "price_ct_kwh": 4.2,
      "price_source": "forecast_d1",
      "dump_risk": "HIGH",
      "dump_risk_p": 0.72,
      "dump_risk_pct": 72.0,
      "dump_scenario_ct_kwh": 3.02,
      "dump_risk_scope": "midday_11_16",
      "dump_risk_version": "live_v0_heuristic"
    },
    {
      "start": "2026-08-01T08:00:00+02:00",
      "price_ct_kwh": 9.15,
      "price_source": "day_ahead",
      "dump_risk": null,
      "dump_risk_p": 0.0,
      "dump_risk_pct": 0.0,
      "dump_scenario_ct_kwh": 9.15
    }
  ]
}

Reading the response: forecast[] is your price list. Field start is the hour begin (not timestamp). price_source: day_ahead is the official auction; forecast_d2 is a model prediction. price_ct_kwh is the model/point price — never rewritten, on every hour. dump_risk_pct (0…100) and dump_scenario_ct_kwh (dump when pct > 0, else point price) are always present as usable numbers when a price exists; dump_risk / dump_risk_p add the tier/probability on ML hours. Exchange hours (today/day_ahead) show pct = 0 and dump_scenario_* = point price. Your app picks one number for calculations — model price or dump scenario.

Endpoint


GET https://api.spotpriceapi.com/v1/forecast

Parameters

NameRequiredDefaultWhat it does
X-API-Key (header)NoYour key; without it you get Basic (48 h)
timezone (query)NoEurope/ViennaTimezone for all timestamps in the response

Important response fields

FieldWhat it means
marketAlways EPEX_AT (Austrian spot market)
generated_atWhen this forecast was built
horizon_hoursNumber of hours returned in this response
tier_horizon_hoursMaximum hours your tier allows
model_versionInternal forecast model version
forecast_statusok, degraded (cache >3 h old), or missing
cache_age_minutesHow old the data is (shown when degraded)
forecast[].startStart of that hour (ISO-8601)
forecast[].price_ct_kwh / price_eur_mwhModel/point price — the number to display and control on. Never rewritten by dump risk or anything else
forecast[].price_sourcetoday, day_ahead, forecast_d0forecast_d6
forecast[].dump_riskOptional: LOW / MEDIUM / HIGH / EXTREME — deep midday dump risk tier. Only on ML hours (forecast_d*), typically 11–16 Vienna; null on exchange hours
forecast[].dump_risk_p0…1 estimated dump probability; compat field, 0 when there is no risk
forecast[].dump_risk_pctAlways present, 0…100 — same probability as dump_risk_p but as a percent. 0 when there is no risk (including all exchange hours)
forecast[].dump_scenario_ct_kwh / dump_scenario_eur_mwhAlways usable when a price exists: when pct > 0, a lead-aware blend toward price × dump_risk_pct / 100 (full strength on D+1, attenuated on D+2/D+3+; never above the model price), otherwise the point price. Use dump_risk_pct (or dump_risk) to know whether the value is a dump illustration. Scope is typically midday 11–16 — evenings are unchanged
forecast[].dump_risk_scopeOptional: e.g. midday_11_16
forecast[].dump_risk_versionOptional: scorer version
summaryOptional short human text about the forecast

Common mistakes

  • Looking for timestamp — the field is start
  • Assuming HTTP 401 when the key is wrong — you get HTTP 200 with reduced data instead.
  • Using prices when forecast_status is missing.
  • Polling every few seconds — prices update roughly hourly; see Rate limits.
  • Confusing ct/kWh with €/MWh — our field is always ct/kWh.
  • Treating dump_scenario_ct_kwh as a rewritten price_ct_kwh — they are two separate fields, pick one.
  • Assuming dump_scenario_ct_kwh is only on Forecast — it is also copied onto decision[]/forecast[] in Decision, slot hours in Windows, and charge_hours in Hours Demand.

Next steps

Start with SpotpriceAPI

Register for Community or code samples with your personal key.

Live API status