Skip to main content

parsimony-eia

U.S. Energy Information Administration (EIA) connector — fetches energy data (petroleum, electricity, natural gas, coal, renewables) from the EIA v2 Open Data API.

Part of the parsimony-connectors monorepo. Distributed standalone on PyPI as parsimony-eia.

Connectors

Name Kind Description
eia_search tool Semantic-search the dataset catalog; returns a dataset route to pass to eia_fetch.
eia_fetch fetch Fetch a dataset by route (e.g. petroleum/pri/spt) with optional measure, facets, frequency, start, end. Paged in full.
eia_fetch_series fetch Fetch by a legacy APIv1 series id (e.g. PET.RWTC.D) via the /v2/seriesid/{id} path.
eia_facets tool List the valid {id, name} values of a dataset's facet dimension, to narrow a fetch to a series.
enumerate_eia enumerator Walk the v2 route tree to one row per leaf dataset (the catalog feed).

Coverage

The catalog indexes all 232 leaf datasets across EIA's 14 top-level categories (petroleum, natural gas, electricity, coal, nuclear, renewables/ densified-biomass, total energy, emissions, international, SEDS, STEO, AEO, IEO, crude-oil imports), each carrying its measure and facet-dimension manifest. EIA's full series universe (~2M series) is the facet cartesian product of those datasets — too large to catalog individually, but every series is fetchable: by route + facets filters, or by its legacy series id via eia_fetch_series. So discovery is at the dataset tier and access is total.

EIA caps every data response at 5,000 rows; the fetch connectors page through to completeness automatically (a request matching more than 300,000 rows is refused with guidance to narrow it). Data is U.S. federal public domain — cite as "Source: U.S. Energy Information Administration".

Install

pip install parsimony-eia

Pulls in a compatible parsimony automatically. Verify discovery:

python -c "from parsimony import discover; print([p.name for p in discover.iter_providers()])"

Configuration

Set the following environment variable:

export EIA_API_KEY="<your-key>"

Get a free key at https://www.eia.gov/opendata/register.php.

Quick start

from parsimony_eia import CONNECTORS

result = CONNECTORS["eia_fetch"](route="petroleum/pri/spt", frequency="monthly")
print(result.raw.head())

For multi-plugin composition:

from parsimony import discover

connectors = discover.load_all()

Provider

License

See LICENSE.

Metadata

Release files for parsimony-eia 0.0.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for parsimony-eia 0.0.2
File Size Uploaded Provenance
parsimony_eia-0.0.2.tar.gz 18.9 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for parsimony-eia 0.0.2
File Interpreter ABI Platform
parsimony_eia-0.0.2-py3-none-any.whl Python 3 none any Details

Total release size: 40.2 kB

Release files / parsimony_eia-0.0.2.tar.gz

Download URL parsimony_eia-0.0.2.tar.gz
Size 18.9 kB
Tags Source
SHA-256 checksum
How to use checksums
b1708e164e4676be19f726a6bee9fba64feff282de7b5b3e704198c74e5ff735
BLAKE2b-256 checksum
How to use checksums
adc9d0ef3d9d3767e16401ee9cae3f1e750932b07150fc518292b93f5adc1e8b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 10, 2026.

Transparency log

Release files / parsimony_eia-0.0.2-py3-none-any.whl

Download URL parsimony_eia-0.0.2-py3-none-any.whl
Size 21.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
642c3c6a77dde30765148e389f0ff136da013b6df244632ad3c477b25eed69a9
BLAKE2b-256 checksum
How to use checksums
f2d8ed64579536a730a0ab45e3e43484ed562b80c053bbe385e9ce969e9838e2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 10, 2026.

Transparency log

Security for parsimony-eia 0.0.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for parsimony_eia-0.0.2.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 10, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.0.2 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page