Skip to main content

A client for OMIE - Spain and Portugal electricity market data

Project description

pyomie

CI Status Poetry black pre-commit

PyPI Version pypy downloads Supported Python versions License


Documentation: https://pyomie.readthedocs.io

Source Code: https://github.com/luuuis/pyomie


A command-line interface and asynchronous client library for OMIE - Spain and Portugal electricity market data.

Installation

Install this via pip (or your favourite package manager):

pip install pyomie

Usage

The pyomie CLI allows querying day-ahead market data for a given date.

% pyomie --help

 Usage: pyomie [OPTIONS] [DATE]

 Fetch the OMIE spot price data.

╭─ Arguments ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│   date      [DATE]  Date to fetch in YYYY-MM-DD format [default: today's date]                                                                                                                                                                                              │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Options ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --csv              Print the CSV as returned by OMIE, without parsing.                                                                                                                                                                                                      │
│ --verbose          Verbose mode.                                                                                                                                                                                                                                            │
│ --help             Show this message and exit.                                                                                                                                                                                                                              │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

By default, the output is a JSON payload that may be used by other tooling.

% pyomie 2025-10-02 | jq -c '{date: .market_date, average_pt:(.pt_spot_price|add/length)}'
{"date":"2025-10-02","average_pt":86.3228125}

You can also pipx run pyomie to run the CLI from a temporary virtual environment.

Contributors ✨

Thanks to these contributors (emoji key):

Luis Miranda
Luis Miranda

💻 🤔 📖

This project follows the all-contributors specification. Contributions of any kind welcome!

Credits

This package was created with Copier and the browniebroke/pypackage-template project template.

Project details


Download files

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

Source Distribution

pyomie-1.1.3.tar.gz (14.6 kB view details)

Uploaded Source

Built Distribution

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

pyomie-1.1.3-py3-none-any.whl (13.9 kB view details)

Uploaded Python 3

File details

Details for the file pyomie-1.1.3.tar.gz.

File metadata

  • Download URL: pyomie-1.1.3.tar.gz
  • Upload date:
  • Size: 14.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyomie-1.1.3.tar.gz
Algorithm Hash digest
SHA256 563667b93e3612e9d342cf636333ec395d5372932807de290d069a5664dbfc8b
MD5 8713baca80b8fa3f51f61dd2d5245eb9
BLAKE2b-256 06e0ead97205eab3c6779a48c15ed672402efb5f036b72a753a79cd44fc11c5f

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyomie-1.1.3.tar.gz:

Publisher: ci.yml on luuuis/pyomie

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

File details

Details for the file pyomie-1.1.3-py3-none-any.whl.

File metadata

  • Download URL: pyomie-1.1.3-py3-none-any.whl
  • Upload date:
  • Size: 13.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyomie-1.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 6c1fa328d93e9c30bd3439552e57f25edbef0507d428450d6aa6b09d2297426a
MD5 28eaf00291c1080da55bfd2b984cbbf2
BLAKE2b-256 02a9a92e70c9866f0eb224cde90fc41f9980960b59db6aa0c04410dac073280d

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyomie-1.1.3-py3-none-any.whl:

Publisher: ci.yml on luuuis/pyomie

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

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page