Skip to main content

No project description provided

Project description

pyelexon

Simple python wrapper for the Elexon BMRS API.

Code style: black pre-commit

Getting started

  • Register on the Elexon BMRS data portal and retrieve your api_key

  • Example usage

from datetime import date
from pyelexon import Elexon

api_key = "123456"
report = "DETSYSPRICES"
params = {
    "settlement_date": "2021-01-01",
    "settlement_period": 1
}

elexon = Elexon(api_key)
# returns content of response
r: bytes = elexon.fetch_data(report, params)

Example with report specific method

from datetime import date
from pyelexon import Elexon

api_key = "123456"
report = "DETSYSPRICES"


elexon = Elexon(api_key)
# returns content of response
r: bytes = elexon.get_detsysprices(
    report,
    settlement_date=date(2021, 1, 1),
    settlement_period=1
)

Tested reports

  • DETSYSPRICES
  • DYNBMDATA
  • PHYBMDATA

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

pyelexon-0.2.7.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

pyelexon-0.2.7-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file pyelexon-0.2.7.tar.gz.

File metadata

  • Download URL: pyelexon-0.2.7.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.3.1 CPython/3.9.12 Darwin/21.2.0

File hashes

Hashes for pyelexon-0.2.7.tar.gz
Algorithm Hash digest
SHA256 84db8278f1339686affe0796df0035e3c3f51c145337de3c8a5981cc3d3c65cf
MD5 67ef4d9fe58d843449301fb8726593b3
BLAKE2b-256 65a4348b3ebd5630052005744b0a6f7a0ba88814ae72365ffc666d4087583b3a

See more details on using hashes here.

File details

Details for the file pyelexon-0.2.7-py3-none-any.whl.

File metadata

  • Download URL: pyelexon-0.2.7-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.3.1 CPython/3.9.12 Darwin/21.2.0

File hashes

Hashes for pyelexon-0.2.7-py3-none-any.whl
Algorithm Hash digest
SHA256 bb60d47f9efd4a68077c8df0de7dc28b8117b3968091afa822eb2ac5e2ffe81b
MD5 5148a6a9f9100222e3eb679bd67ee0b4
BLAKE2b-256 8b29d6e07219027a9b08eb5f11dd045e6222c40330331c753263dab58f53bdcc

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