Skip to main content

Python library for fetching Nord Pool spot prices.

Project description

nordpool

Test Status Coverage Status

Python library for fetching Nord Pool Elspot and Elbas prices.

Python version

The minimum supported Python version is 3.9, which receives security updates until 2025-10. The library won't install without trickery on older versions, so update your Python.

Installing

To install from PyPi, use

pip install nordpool

To upgrade

To upgrade installation from PyPi, use

pip install -U nordpool

Example

# Import library for fetching Elspot data
from nordpool import elspot
from pprint import pprint

# Initialize class for fetching Elspot prices
prices_spot = elspot.Prices()

# Fetch hourly Elspot prices for Finland and print the resulting dictionary
# If the prices are reported as None, it means that the prices fetched aren't yet available.
# The library by default tries to fetch prices for tomorrow and they're released ~13:00 Swedish time.
pprint(prices_spot.hourly(areas=['FI']))
Output
{u'areas': {
    u'FI': {
        u'values': [
            {u'end': datetime.datetime(2014, 10, 3, 23, 0, tzinfo=<UTC>),
             u'start': datetime.datetime(2014, 10, 3, 22, 0, tzinfo=<UTC>),
             u'value': 31.2},
            {u'end': datetime.datetime(2014, 10, 4, 0, 0, tzinfo=<UTC>),
             u'start': datetime.datetime(2014, 10, 3, 23, 0, tzinfo=<UTC>),
             u'value': 30.68},
            ... SNIP ...
            {u'end': datetime.datetime(2014, 10, 4, 22, 0, tzinfo=<UTC>),
             u'start': datetime.datetime(2014, 10, 4, 21, 0, tzinfo=<UTC>),
             u'value': 30.82}]}},
 u'currency': u'EUR',
 u'end': datetime.datetime(2014, 10, 4, 22, 0, tzinfo=<UTC>),
 u'start': datetime.datetime(2014, 10, 3, 22, 0, tzinfo=<UTC>),
 u'updated': datetime.datetime(2014, 10, 3, 10, 42, 42, 110000, tzinfo=<UTC>)}
 ...

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

nordpool-0.4.3.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

nordpool-0.4.3-py3-none-any.whl (5.2 kB view details)

Uploaded Python 3

File details

Details for the file nordpool-0.4.3.tar.gz.

File metadata

  • Download URL: nordpool-0.4.3.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.12.1 Linux/6.5.0-1025-azure

File hashes

Hashes for nordpool-0.4.3.tar.gz
Algorithm Hash digest
SHA256 98986a86c3d3d9aec84597c6ad8daf8f018aca82cff751730ca92f5a0ed4896d
MD5 fd3ec6f40dbf695947c32ced410177b0
BLAKE2b-256 c94e4e785339148dc425a01ecb6222a5bde85221e5da90f3e701a9e2a300c658

See more details on using hashes here.

File details

Details for the file nordpool-0.4.3-py3-none-any.whl.

File metadata

  • Download URL: nordpool-0.4.3-py3-none-any.whl
  • Upload date:
  • Size: 5.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.4 CPython/3.12.1 Linux/6.5.0-1025-azure

File hashes

Hashes for nordpool-0.4.3-py3-none-any.whl
Algorithm Hash digest
SHA256 c6bb90fcdf86f81a7ecc308f11effa78380a305fa6eaccb9de72f12a6dfd2b4d
MD5 7dfcfc2d670b364ca89ee924bc77b824
BLAKE2b-256 e78e0150ccdffcf4d740659e6bee7cea5e4e46c9b3f7ff47deebf2f9fa825f6c

See more details on using hashes here.

Supported by

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