Skip to main content

TenneT-py

DEPRECATED: TenneT.org has been deprecated. Please move to tennet.eu API instead.

Python client for ingesting the TenneT System & transmission data API which can be found here. It is a public API for which no API key is needed.

The library currently supports four data items:

  • Measurement data
  • Imbalance price
  • Balance delta with prices
  • Available capacity

Data can be retrieved as raw text or a Pandas DataFrame.

The client currently has two methods:

  • base_request: retrieves specified data in csv or xml text format
  • query_df: retrieves specified data and returnes a Pandas DataFrame

Installation

pip install tennet-py

Example Usages

from tennet import TenneTClient, DataType, OutputType
import pandas as pd

start = pd.Timestamp("2021-01-01")
end = pd.Timestamp("2021-01-31")

# initiate the client, you can specify a default output to not always specify it per call
client = TenneTClient(default_output=OutputType.CSV)
# retrieve data as text in default output (in this case csv)
data = client.base_request(DataType.settlementprices, d_from=start, d_to=end)
# retrieve data as xml
data = client.base_request(DataType.settlementprices, d_from=start, d_to=end, output_type=OutputType.XML)

# retrieve same data as a dataframe
df = client.query_df(DataType.settlementprices, d_from=start, d_to=end)

Netztransparenz

Also supported is a limited number of endpoints of the german TenneT from the Netztransparenz platform. First register and get oauth credentials as explained on the documentation page here Then can be used as follows:

from tennet import NetztransparenzClient
import pandas as pd

client = NetztransparenzClient(oauth_client_id, oauth_client_secret)
df = client.query_imbalance(start=pd.Timestamp('2023-12-22', tz='europe/amsterdam'), end=pd.Timestamp('2023-12-22 23:59', tz='europe/amsterdam'))

Disclaimer

This is an unoffical package which is not supported or endorsed in any way by TenneT TSO.

Metadata

Release files for tennet-py 0.2.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 tennet-py 0.2.2
File Size Uploaded Provenance
tennet_py-0.2.2.tar.gz 6.6 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for tennet-py 0.2.2
File Interpreter ABI Platform
tennet_py-0.2.2-py3-none-any.whl Python 3 none any Details

Total release size: 13.9 kB

Release files / tennet_py-0.2.2.tar.gz

Download URL tennet_py-0.2.2.tar.gz
Size 6.6 kB
Tags Source
SHA-256 checksum
How to use checksums
0d2554976f049335cdec4ef31df33aa753198821f4d0d002ad91d37365ff6cc1
BLAKE2b-256 checksum
How to use checksums
b37a0181f3437fa6f0c65453974f99613416d313331239b177d06509256fc4cf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.8

Release files / tennet_py-0.2.2-py3-none-any.whl

Download URL tennet_py-0.2.2-py3-none-any.whl
Size 7.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5a151f2efef8ae9872e4133de4d5138deea51197310834388638c263712d47ff
BLAKE2b-256 checksum
How to use checksums
28bef8c876a6400b809c0b64a9bd5e7a4e5ba87142c09081db15ab08c8fbdfbc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.8

Security for tennet-py 0.2.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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

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