bundesAPI / smard-api

https://smard.api.bund.dev
54 stars 8 forks source link

Marketdata is available on smard.de #8

Open nandbert2 opened 2 years ago

nandbert2 commented 2 years ago

There are further parameters possible to access market data (hourly prices) from smard.de: An access is as follows, the parameter 4169 is used as an example; full list is below:

  1. get list of timestamps curl https://www.smard.de/app/chart_data/4169/DE/index_hour.json timestamps.json

  2. select one timestamp and get the data curl https://www.smard.de/app/table_data/4169/DE/4169_DE_hour_1655676000000.json > marketdata_4169.json

As before the parameter needs to be repeated and the "DE" must be always there even when accessing market data from other regions.

The list of possible parameters I found when downloading data from on smard.de:

Can this list be added to the yaml/smard-api?

lukaspanni commented 1 year ago

It looks like there is a table-data endpoint additionally to the documented chart-data endpoint and you discovered more filters. However this endpoint is not available for all filters.

Still, adjusting the documentation should be straightforward, feel free to create a PR. I'll try to work on this next week, if you don't want to work on it yourself.

nandbert2 commented 1 year ago

I created a pull-request; please have a look. Let me know if things are missing; my experiences with openapi and github are limited.