Grid and Energy Data
GET/v1/griddata/power/generation/{market}/{region}
Latest generation by fuel for a region in MW with the total and the renewables share in basis points (GB, EU zones and US balancing authorities; NEM regions have no public fuel split in DispatchIS and answer pending). Refreshes every 5 minutes.
Price
$0.01/ callEdge cache
150s
Uptime 24h
96.36%
p95
751ms
MCP tool
griddata_power-generation-market-region
The Grid and energy data API provides wholesale electricity prices per market region, grid demand and generation by fuel, and other related data. The API covers four market structures: AEMO NEM, Elexon GB, ENTSO-E EU zones, and EIA US balancing authorities. Data is updated every 5 minutes and is available in a single schema. The API offers latest generation mix by fuel for a region in MW, including the total and renewables share. Parameters include market and region. The API is priced at $0.010 per request.
Parameters
| Name | In | Type | Description |
|---|---|---|---|
| market* | path | string | |
| region* | path | string |
Code
# 1. No key, no payment: the gateway answers 402 with the price
curl -i "https://api.realtimeapi.ai/v1/griddata/power/generation/nem/NSW1"
# 2. Pay: retry with a signed x402 payment (any x402 client builds this header)
curl "https://api.realtimeapi.ai/v1/griddata/power/generation/nem/NSW1" -H "PAYMENT-SIGNATURE: $X402_PAYMENT"// npm i @x402/fetch @x402/core @x402/evm viem
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = x402Client.fromConfig({ schemes: [{ network: "eip155:8453", client: new ExactEvmScheme(privateKeyToAccount(PRIVATE_KEY)) }] });
const pay = wrapFetchWithPayment(fetch, client);
const data = await (await pay("https://api.realtimeapi.ai/v1/griddata/power/generation/nem/NSW1")).json();
console.log(data);# pip install "x402[requests,evm]==2.27.0" eth-account
from eth_account import Account
from x402 import x402ClientSync
from x402.http.clients import x402_requests
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact import register_exact_evm_client
client = x402ClientSync()
register_exact_evm_client(client, EthAccountSigner(Account.from_key(PRIVATE_KEY)))
session = x402_requests(client)
print(session.get("https://api.realtimeapi.ai/v1/griddata/power/generation/nem/NSW1").json())curl "https://api.realtimeapi.ai/v1/griddata/power/generation/nem/NSW1" -H "X-API-Key: $RTAPI_KEY"Frequently asked questions
What data is provided by the API?
Wholesale electricity prices, grid demand, generation by fuel, and other related data.
What market structures are covered?
AEMO NEM, Elexon GB, ENTSO-E EU zones, and EIA US balancing authorities.
How often is the data updated?
Every 5 minutes.
What is the price of the API?
$0.010 per request.
What parameters are required?
Market and region.