Skip to main content

pyinegi

A typed Python client for querying indicators and metadata from the INEGI Indicators API.

Installation

pip install pyinegi

Quick start

Set your API token outside source code, then query an indicator:

export INEGI_TOKEN="your-token"
from pyinegi import InegiClient

series = InegiClient().get_indicator("1002000001", geography="00")
for observation in series[0].observations:
    print(observation.period, observation.value)

Install pyinegi[pandas] to use pyinegi.pandas.to_dataframe.

Metadata catalogs

Retrieve indicator metadata or another documented catalog with get_catalog:

entries = InegiClient().get_catalog("CL_INDICATOR", "1002000001")
print(entries[0].description)

Pass record_id=None to retrieve every record in a supported catalog.

Development

See CONTRIBUTING.md. The project uses protected-main pull requests, English Conventional Commits, pre-commit hooks, and GitHub Actions quality gates.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyinegi-0.1.0.tar.gz (129.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyinegi-0.1.0-py3-none-any.whl (8.8 kB view details)

Uploaded Python 3

File details

Details for the file pyinegi-0.1.0.tar.gz.

File metadata

  • Download URL: pyinegi-0.1.0.tar.gz
  • Upload date:
  • Size: 129.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for pyinegi-0.1.0.tar.gz
Algorithm Hash digest
SHA256 0da5a4dd77bcec2ab8e27bf22a3e7b159fb81b746c127653b1f7e21f9ce73172
MD5 b349cc7e24d6810dcbb2d8b9c04f3193
BLAKE2b-256 1b5cbb5d0d6cff0a6df4fe3792a7db237c5cdf0e39f3688c256c591e4e9b583e

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyinegi-0.1.0.tar.gz:

Publisher: release.yml on guadaloop-07/pyinegi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyinegi-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pyinegi-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 8.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for pyinegi-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 17cc75436802ea6d69bd61008db99564e6602eaf704464d152baadc08f0e3c42
MD5 227f61e6df3e3894c529be3dae3717ff
BLAKE2b-256 8a6a98cc0ae4b119069986b00f54628569b17e37e27b39711e3466f7f5259746

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyinegi-0.1.0-py3-none-any.whl:

Publisher: release.yml on guadaloop-07/pyinegi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

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