eia_electricity
Get electricity retail prices, generation, or consumption by state and sector. Includes price, revenue, sales, and customer data for residential, commercial, industrial, or all.
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 |
|---|---|---|---|
| end | No | End date (YYYY-MM or YYYY). Default: latest available | |
| start | No | Start date (YYYY-MM or YYYY). Default: 2 years ago | |
| state | No | Two-letter state code (e.g., 'CA', 'TX'). Omit for national. | |
| length | No | Max rows (API max: 5000). Omit to let date range control volume. | |
| offset | No | Row offset for pagination | |
| 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) |