REST api wrapper for nordpool average daily spot prices
Project description
Python package for querying nordpool for average daily and hourly prices per kWh. Prices can only be obtained for the current year and the previous year. Incremet is how much you need to add to the price if you chargeback someone per kWh. It's optional and the default is zero.
Supported areacode's | Suported currency's | Increment |
---|---|---|
"SE1" |
"SEK" |
"0.15" |
"SE2" |
"EUR" |
|
"SE3" |
||
"SE4" |
||
"NO1" |
||
"NO2" |
||
"NO3" |
||
"NO4" |
||
"NO5" |
||
"FI" |
||
"DK1" |
||
"DK2" |
Environment variables | Usage | Required | Syntax | Comment |
---|---|---|---|---|
LOGLEVEL | stdout logging level | No | DEBUG | Defaults to INFO if not used |
Usage:
pip install nordpool-daily-averages
#Getting average price for 2024-08-30, for areacode SE3 and in Euro and 15 cents is added to the prices
from nordpool import Daily as daily
#instantiate class
price = daily("SE3", "EUR", "0.15")
#Get the price
price.get_prices_for_one_date("2024-08-30")
#Getting average price for 2024-08-29 for areacode SE3 in SEK and 15 öre is added to the prices
from nordpool import Daily as daily
#instantiate class
price = daily("SE3", "SEK", "0.15")
#Get the price
price.get_prices_for_one_date("2024-08-29")
#Getting average price for 2024-08-28 for areacode SE2 in SEK and no increment is added to the prices
from nordpool import Daily as daily
#instantiate class
price = daily("SE2", "SEK")
#Get the price
price.get_prices_for_one_date("2024-08-28")
#Getting all price's for current year and last year for areacode SE2 in SEK and no increment is added to the prices
from nordpool import Daily as daily
#instantiate class
price = daily("SE2", "SEK")
#Get all price's
price.get_all_prices()
import asyncio
from nordpool import Hourly as hour
#Getting hourly data prices for one date
async def main():
#instantiate class
daily_average = hour(areacode="SE3", currency="SEK")
usage = await daily_average.get_hourly_prices("2024-09-04")
print(usage)
asyncio.run(main())
Project details
Release history Release notifications | RSS feed
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
File details
Details for the file nordpool_daily_averages-1.1.34.tar.gz
.
File metadata
- Download URL: nordpool_daily_averages-1.1.34.tar.gz
- Upload date:
- Size: 5.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6f88759315791104685e170a0af81de34e2f34da37e44e58e6d1ff74e2daedf3 |
|
MD5 | 93e368307ef88eadda7581a5e3444b02 |
|
BLAKE2b-256 | b5a141339f5e7e3115a5036086d99781c6e711e5dc6c28aca24e71d3d9032742 |
File details
Details for the file nordpool_daily_averages-1.1.34-py3-none-any.whl
.
File metadata
- Download URL: nordpool_daily_averages-1.1.34-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6962d30f3ebc1a362ad62005e394f02fbfbb5f614b1cc23cf9c8f482a349197d |
|
MD5 | bc260a2743ed65e300c96ad4c631fb46 |
|
BLAKE2b-256 | 6f50fb58162d958a5ceb23cc8e5202a1abd3788eff59df7c043c908988534988 |