Python client for Dataverse
Project description
Dataverse Python Client
Python client for Dataverse platform.
Pre-requisites
- Python version 3.14+
- Environment variable
DATAVERSE_BASE_URL - Environment variable
DATAVERSE_AUTH_TOKEN - or both can be passed explicitly to
create_clientfunction as arguments.
You can generate an authentication token in the Terraverse SmartCube portal.
Intial values for both DATAVERSE_BASE_URL and DATAVERSE_AUTH_TOKEN will be issued once your SmartCube account
will become active and if your subscription plan includes Dataverse.
Quickstart
from dtvr.client import create_client
client = create_client()
with client.last_exchange_rates() as resp:
reader = resp.as_csv_rows()
for row in reader:
print(row) # use the data here
from dtvr.client import create_client, CEPS_AREA_DOMAIN
from dtvr.timeutil import today_start_end
client = create_client()
start, end = today_start_end()
with client.procured_balancing_capacity_daily(CEPS_AREA_DOMAIN, start, end) as resp:
df = resp.as_pandas()
df.info(memory_usage=True)
# use the dataframe here
DateLike arguments
Several methods of the client accepts arguments representing start and end of some date range for which you need to download the data. To pass something as date-like argument you can either:
- use datetime
- use date
- use string with the format
yyyy-MM-dd,yyyy-MM-dd HH:mmoryyyy-MM-dd HH:mm:ss
Features
- Easy to use client library that will help you to consume Datavere endpoints quickly.
- Response containing data can be converted to either:
- iterator representing CSV rows (list of string and numeric values)
- pandas DataFrame
- Several convenience functions for manipulating date & time in module
dtvr.timeutil.
Available Dataverse Endpoints
| method | short description |
|---|---|
| last_exchange_rates | Returns the last known exchange rates. Data source is the Czech National Bank (CNB); rates are expressed in CZK. |
| balancing_energy_bid | Returns ENTSOE balancing energy bid data for the specified connecting domain and time interval. |
| balancing_energy_bid_raw | Returns raw ENTSOE balancing energy bid data for the specified connecting domain and time interval. |
| procured_balancing_capacity_daily | Returns ENTSOE daily-auction procured balancing capacity data for the specified area domain and time interval. |
| procured_balancing_capacity_yearly | Returns ENTSOE yearly-auction procured balancing capacity data for the specified area domain and year. |
| exchanged_volume | Returns TransnetBW cross-border exchanged balancing volumes for the specified day. |
| cross_border_marginal_price | Returns TransnetBW cross-border marginal prices for the specified day. |
| ceps_current_system_imbalance_actual | Returns the last ~15 minutes of system imbalance (ACE) data. |
| ceps_current_system_imbalance_daily | Returns system imbalance (ACE) data for the specified day. |
| ceps_svr_activations_actual | Returns the last ~15 minutes of SVR (balancing services) activation data. |
| ceps_svr_activations_daily | Returns SVR (balancing services) activation data for the specified day. |
| ceps_svr_export_import_actual | Returns the last ~15 minutes of SVR cross-border balancing energy exchange data. |
| ceps_svr_export_import_daily | Returns SVR cross-border balancing energy exchange data for the specified day. |
| ceps_svr_maximum_dt_price | Returns SVR daily price caps for ancillary service activations on the specified day. |
| ceps_cross_border_power_flows_actual | Returns the last ~15 minutes of real-time cross-border power flows data. |
| ceps_cross_border_power_flows_daily | Returns real-time cross-border power flows data for the specified day. |
| ceps_emergency_exchange | Returns emergency exchange data for the specified day. |
| ceps_generation | Returns actual electricity generation data for the specified day, broken down by source type. |
| ceps_generation_plan | Returns the generation plan for the specified day. |
| ceps_generation_renewable_source_actual | Returns the last ~15 minutes of real-time renewable energy generation data. |
| ceps_generation_renewable_source_daily | Returns real-time renewable energy generation data for the specified day. |
| ceps_imbalance_price_prediction | Returns the hourly imbalance price prediction for the specified day. |
| ceps_power_balance | Returns the power balance report for the specified year. |
| procured_balancing_capacity_daily_raw | Returns raw ENTSOE daily-auction procured balancing capacity data for the specified area domain and time interval. |
| procured_balancing_capacity_yearly_raw | Returns raw ENTSOE yearly-auction procured balancing capacity data for the specified area domain and time interval. |
| evaluation_party | Returns MMS party (subject) hourly evaluation data for the specified business date. |
| evaluation_party_contract | Returns MMS party contract hourly evaluation data for the specified business date. |
| evaluation_party_additional_costs | Returns MMS party additional costs hourly evaluation data for the specified business date. |
| evaluation_monthly_party | Returns MMS monthly party (subject) evaluation data for the specified business month. |
| evaluation_monthly_contract | Returns MMS monthly contract evaluation data for the specified business month. |
| evaluation_asset_hourly | Returns MMS asset hourly evaluation data for the specified business date. |
| evaluation_asset_quarter_hourly | Returns MMS asset quarter-hour (QH) evaluation data for the specified business date. |
| evaluation_marginal_price | Returns MMS marginal price evaluation data for the specified business date. |
| evaluation_reg_energy_unit | Returns MMS regulating energy unit QH evaluation data for the specified business date. |
| evaluation_reg_energy_unit_ans | Returns MMS regulating energy unit per ancillary service (ANS) QH evaluation data for the specified business date. |
| evaluation_reg_energy_contract | Returns MMS regulating energy contract QH evaluation data for the specified business date. |
| evaluation_reg_energy_hourly_contract | Returns MMS regulating energy hour-contract evaluation data for the specified business date. |
| evaluation_reg_energy_hourly_party | Returns MMS regulating energy hour-party evaluation data for the specified business date. |
| evaluation_reg_energy_minute | Returns MMS regulating energy minute evaluation data for the specified business date. |
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file dtvr-1.0.0.tar.gz.
File metadata
- Download URL: dtvr-1.0.0.tar.gz
- Upload date:
- Size: 13.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9a1555c0ef9425f591c38e9c25afad72e5a3e87a818e0bc8248cc61b4fe909e2
|
|
| MD5 |
90a6cbe36717bc4f1c1060f15734c974
|
|
| BLAKE2b-256 |
dfa4af9e33c4b231486eeffc8cbd56ec2d032db5ecca5603f8209e785db8277e
|
Provenance
The following attestation bundles were made for dtvr-1.0.0.tar.gz:
Publisher:
publish.yml on terra-verse/terraverse-dataverse-python-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
dtvr-1.0.0.tar.gz -
Subject digest:
9a1555c0ef9425f591c38e9c25afad72e5a3e87a818e0bc8248cc61b4fe909e2 - Sigstore transparency entry: 1671497320
- Sigstore integration time:
-
Permalink:
terra-verse/terraverse-dataverse-python-client@7bb58c15d2d54316a89b56a149733d6aff618412 -
Branch / Tag:
refs/heads/master - Owner: https://github.com/terra-verse
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@7bb58c15d2d54316a89b56a149733d6aff618412 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file dtvr-1.0.0-py3-none-any.whl.
File metadata
- Download URL: dtvr-1.0.0-py3-none-any.whl
- Upload date:
- Size: 11.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b72e9aa79230266a17c123510f42e4fd9e658a649694457da1d89016154250c7
|
|
| MD5 |
5f23935f0ff0c467ae1fec1374c6e2e0
|
|
| BLAKE2b-256 |
04dbcfcdd202a643bc415738473b03dac13bf952848dac282bafd41c93433cdc
|
Provenance
The following attestation bundles were made for dtvr-1.0.0-py3-none-any.whl:
Publisher:
publish.yml on terra-verse/terraverse-dataverse-python-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
dtvr-1.0.0-py3-none-any.whl -
Subject digest:
b72e9aa79230266a17c123510f42e4fd9e658a649694457da1d89016154250c7 - Sigstore transparency entry: 1671497336
- Sigstore integration time:
-
Permalink:
terra-verse/terraverse-dataverse-python-client@7bb58c15d2d54316a89b56a149733d6aff618412 -
Branch / Tag:
refs/heads/master - Owner: https://github.com/terra-verse
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@7bb58c15d2d54316a89b56a149733d6aff618412 -
Trigger Event:
workflow_dispatch
-
Statement type: