Department of Energy · Example Payload

Eia Data Response Example

Example EIA API v2 data response for electricity retail sales

EnergyGovernmentRenewable EnergyElectricityNatural GasPetroleumSolarWindElectric VehiclesAlternative FuelsNuclearScientific Research

Eia Data Response Example is an example object payload from Department of Energy, with 5 top-level fields. It illustrates the shape of data this provider's APIs accept or return.

Top-level fields

descriptionapiendpointrequest_paramsresponse

Example Payload

Raw ↑
{
  "description": "Example EIA API v2 data response for electricity retail sales",
  "api": "EIA Open Data API v2",
  "endpoint": "/v2/electricity/retail-sales/data",
  "request_params": {
    "frequency": "monthly",
    "data[0]": "sales",
    "start": "2023-01",
    "end": "2023-12",
    "sort[0][column]": "period",
    "sort[0][direction]": "desc",
    "length": 5
  },
  "response": {
    "response": {
      "total": 600,
      "dateFormat": {
        "monthly": "YYYY-MM"
      },
      "frequency": "monthly",
      "data": [
        {
          "period": "2023-12",
          "stateid": "US",
          "sectorid": "ALL",
          "stateDescription": "U.S. Total",
          "sectorName": "All Sectors",
          "sales": 335012.3,
          "sales-units": "million kilowatthours"
        },
        {
          "period": "2023-11",
          "stateid": "US",
          "sectorid": "ALL",
          "stateDescription": "U.S. Total",
          "sectorName": "All Sectors",
          "sales": 312445.6,
          "sales-units": "million kilowatthours"
        }
      ]
    },
    "request": {
      "command": "/v2/electricity/retail-sales/data/",
      "params": {
        "frequency": "monthly",
        "data": [
          "sales"
        ],
        "start": "2023-01",
        "end": "2023-12"
      }
    }
  }
}

Work with this as data

Every example here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for examples

4 MCP tools reach this
  • find_examplesBrowse and filter every example in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This example
curl "https://apis.io/api/v1/examples/eia-data-response-example"
All examples
curl "https://apis.io/api/v1/examples?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.