eia_electricity
Retrieve electricity retail prices, generation, or consumption data by state and sector (residential, commercial, industrial, transportation, all). Filter by date range, frequency, and data type such as price, revenue, sales, or customers.
Instructions
Get electricity retail prices, generation, or consumption by state and sector.
Sectors: residential (RES), commercial (COM), industrial (IND), transportation (TRA), all (ALL). Data types: 'price' (cents/kWh), 'revenue' (M$), 'sales' (MWh), 'customers'
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| state | No | Two-letter state code (e.g., 'CA', 'TX'). Omit for national. | |
| sector | No | Sector: RES=residential, COM=commercial, IND=industrial, ALL=default | |
| data_type | No | Data type (default: price in cents/kWh) | |
| frequency | No | Frequency (default: monthly) | |
| start | No | Start date (YYYY-MM or YYYY). Default: 2 years ago | |
| end | No | End date (YYYY-MM or YYYY). Default: latest available | |
| length | No | Max rows (API max: 5000). Omit to let date range control volume. | |
| offset | No | Row offset for pagination |